/* ===== Variables y reset ===== */
:root {
  --navy: #1b3a52;          /* azul oscuro de secciones y botones */
  --navy-deep: #14293a;
  --white: #ffffff;
  --text-muted: #4a5568;    /* gris de los textos secundarios */
  --radius-pill: 999px;
  --font-title: "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--navy);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, dt { font-family: var(--font-title); font-weight: 700; line-height: 1.15; }

/* ===== Degradado de fondo (hero y "Our Work") =====
   Se construye con varias manchas de color superpuestas (radial-gradient)
   en vez de una imagen: pesa unos pocos bytes y se ve nítido en cualquier pantalla. */
.gradient {
  position: relative;
  isolation: isolate;
  background-color: #c6cfdb;
  background-image:
    radial-gradient(70% 55% at 30% 12%,  rgba(247, 181, 41, 0.95) 0%, rgba(247, 181, 41, 0) 60%),
    radial-gradient(65% 60% at 52% 20%,  rgba(255, 138, 24, 0.98) 0%, rgba(255, 138, 24, 0) 62%),
    radial-gradient(60% 65% at 74% 22%,  rgba(240, 100, 70, 0.92) 0%, rgba(240, 100, 70, 0) 62%),
    radial-gradient(80% 70% at 8%  75%,  rgba(196, 208, 224, 0.9) 0%, rgba(196, 208, 224, 0) 70%),
    radial-gradient(85% 70% at 92% 85%,  rgba(200, 210, 224, 0.9) 0%, rgba(200, 210, 224, 0) 70%);
}

/* Grano sutil por encima del degradado, como en las capturas */
.gradient::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.35;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.35'/%3E%3C/svg%3E");
}

/* ===== Botón ===== */
.btn {
  display: inline-block;
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 1.05rem;
  border: none;
  border-radius: var(--radius-pill);
  padding: 1rem 2.75rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.2s ease;
}
.btn:hover { background: var(--navy-deep); transform: translateY(-2px); }
.btn:disabled { opacity: 0.6; cursor: default; transform: none; }

/* ===== Hero ===== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1.5rem 4rem;
  text-align: center;
}

.brand {
  font-family: var(--font-body);
  font-size: 1.5rem;
  color: var(--white);
  letter-spacing: 0.01em;
}

.hero-content {
  margin: auto 0;                /* centra verticalmente el bloque */
  max-width: 60rem;
}

.hero h1 {
  color: var(--white);
  font-size: clamp(2.5rem, 5.6vw, 4.5rem);
  letter-spacing: -0.02em;
}

.lead {
  color: var(--white);
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  margin: 1.25rem 0 2.5rem;
}

/* ===== Areas of expertise ===== */
.expertise {
  background: var(--navy);
  color: var(--white);
  padding: 6rem 1.5rem 7rem;
  text-align: center;
}

.expertise h2 { font-size: clamp(2rem, 4.5vw, 3rem); margin-bottom: 3.5rem; }

.pill-grid {
  max-width: 68rem;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.pill-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem 5rem;
}

/* Las filas de 2 elementos se desplazan media columna: crea el zigzag */
.pill-row.offset {
  grid-template-columns: repeat(2, 1fr);
  width: 66%;
  margin: 0 auto;
}

.pill {
  background: var(--white);
  color: var(--navy);
  border-radius: var(--radius-pill);
  padding: 1rem 1.5rem;
  font-size: 1rem;
}

/* ===== Our Work ===== */
.work {
  padding: 6rem 1.5rem 7rem;
  text-align: center;
}

.work h2 {
  color: var(--white);
  font-size: clamp(2rem, 4.5vw, 3rem);
  margin-bottom: 3.5rem;
}

.work-list {
  max-width: 34rem;
  margin: 0 auto;
  text-align: left;
}

.work-item + .work-item { margin-top: 1.75rem; }

.work-item dt { color: var(--white); font-size: 1.4rem; }
.work-item dd { color: var(--text-muted); font-size: 1.02rem; }

/* ===== Contacto ===== */
.contact {
  background: var(--white);
  padding: 5rem 1.5rem 6rem;
  text-align: center;
}

.contact h2 { font-size: clamp(2.25rem, 5vw, 3.25rem); color: #111827; }

.lead-dark {
  max-width: 26rem;
  margin: 1rem auto 3rem;
  font-size: 1.1rem;
  color: #1f2937;
}

form {
  max-width: 34rem;
  margin: 0 auto;
  text-align: left;
}

label {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  color: #111827;
}

input, textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1.05rem;
  color: var(--navy);
  padding: 0.9rem 1rem;
  margin-bottom: 1.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: var(--white);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input::placeholder, textarea::placeholder { color: #9aa4b2; }

input:focus, textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(27, 58, 82, 0.12);
}

textarea { resize: vertical; min-height: 7rem; }

form .btn { display: block; margin: 0.5rem auto 0; }

/* Campo trampa: oculto sin usar display:none, que algunos bots detectan */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

#form-status { text-align: center; margin-top: 1rem; min-height: 1.5rem; font-size: 0.95rem; }
#form-status.ok { color: #15803d; }
#form-status.error { color: #b91c1c; }

/* ===== Footer ===== */
footer {
  background: var(--navy);
  color: var(--white);
  padding: 3.5rem clamp(1.5rem, 5vw, 4rem);
}

footer h2 { font-size: 1.9rem; margin-bottom: 2rem; }
footer p { margin-bottom: 1.25rem; }
footer a { color: var(--white); text-decoration: none; }
footer a:hover { text-decoration: underline; }
footer .copy { margin-bottom: 0; opacity: 0.9; }

/* ===== Móvil ===== */
@media (max-width: 720px) {
  .pill-row, .pill-row.offset {
    grid-template-columns: 1fr;
    width: 100%;
    gap: 1rem;
  }
  .pill { display: block; }
  .work-list { max-width: 100%; }
  .hero { min-height: 90vh; }
}

/* Respeta a quien prefiere menos animación */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}
