/**
 * SERVICIOS.CSS — Páginas individuales por servicio (psicología, psicopedagogía,
 * fonoaudiología, terapia ocupacional, evaluaciones ADOS-2/ADI-R, neurocognitiva).
 * Comparten paleta, tipografía y componentes (nav, botones, FAQ, footer) con
 * index.html para que se lean como parte del mismo sitio, no una sección aparte.
 */
:root {
  --navy:       #08202e;
  --teal-deep:  #0e4d5c;
  --teal:       #1a7a8a;
  --teal-mid:   #2aaec2;
  --teal-texto: #166875;
  --teal-soft:  #7ed6e4;
  --teal-pale:  #d4f2f7;
  --cream:      #f7f2eb;
  --white:      #ffffff;
  --bg:         #f5fafc;
  --text:       #0d2535;
  --text-mid:   #3a5a6a;
  --text-soft:  #5a7583;
  --easing: cubic-bezier(0.16, 1, 0.3, 1);
  --r: 18px;
  --r-lg: 28px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--teal-soft); outline-offset: 3px; border-radius: 4px;
}

body {
  font-family: 'Nunito', sans-serif; background: var(--bg); color: var(--text);
  overflow-x: hidden;
}

.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 2000;
  background: var(--navy); color: white; padding: 12px 22px; border-radius: 10px;
  font-weight: 700; font-size: 0.9rem; text-decoration: none;
  transform: translateY(-72px); transition: transform 0.2s var(--easing);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}
.skip-link:focus { transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* ═══ NAV (idéntico a index.html) ═══ */
nav.svc-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1002;
  padding: 16px 6%; display: flex; align-items: center; justify-content: space-between;
  background: rgba(8,32,46,0.95); backdrop-filter: blur(20px);
  box-shadow: 0 2px 40px rgba(0,0,0,0.25);
}
.svc-brand { display: flex; align-items: center; gap: 13px; text-decoration: none; }
.svc-brand .logo-symbol { color: var(--teal-soft); font-size: 1.8rem; line-height: 1; }
.svc-brand b {
  display: block; font-family: 'Playfair Display', serif; font-size: 1.25rem;
  font-weight: 700; color: white; letter-spacing: 0.08em;
}
.svc-brand small {
  font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--teal-soft); font-weight: 500;
}
.svc-nav-cta {
  background: var(--teal); color: white; padding: 10px 22px; border-radius: 50px;
  text-decoration: none; font-weight: 700; font-size: 0.85rem;
  transition: background 0.25s, transform 0.25s;
  display: flex; align-items: center; gap: 8px;
  touch-action: manipulation;
}
.svc-nav-cta:active { background: var(--teal-soft); color: var(--navy); transform: scale(0.96); }
@media(max-width:640px){ .svc-nav-cta span.txt { display:none; } .svc-nav-cta { padding:10px 14px; } }

/* ═══ MIGA DE PAN + HERO DE SERVICIO ═══ */
.svc-hero {
  background: linear-gradient(165deg, var(--navy), var(--teal-deep));
  padding: 130px 6% 70px; position: relative; overflow: hidden;
}
.svc-hero::before {
  content:''; position:absolute; inset:0;
  background: radial-gradient(ellipse 70% 60% at 70% 20%, rgba(42,174,194,0.2) 0%, transparent 65%);
}
.svc-hero-inner { max-width: 760px; margin: 0 auto; position: relative; z-index: 1; }
.svc-breadcrumb { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 22px; }
.svc-breadcrumb a { color: rgba(255,255,255,0.55); text-decoration: none; font-size: 0.82rem; transition: color 0.2s; }
.svc-breadcrumb a:active { color: white; }
.svc-breadcrumb span { color: rgba(255,255,255,0.3); font-size: 0.82rem; }
.svc-breadcrumb em { color: var(--teal-soft); font-style: normal; font-size: 0.82rem; font-weight: 600; }
.svc-tag {
  display: inline-flex; align-items: center; gap: 10px; font-size: 0.72rem;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--teal-soft);
  font-weight: 700; margin-bottom: 16px;
}
.svc-title {
  font-family: 'Playfair Display', serif; font-size: clamp(2.1rem, 5vw, 3.2rem);
  font-weight: 500; line-height: 1.15; color: white; margin-bottom: 18px;
}
.svc-title em { font-style: italic; color: var(--teal-soft); }
.svc-lead { font-size: 1.05rem; line-height: 1.8; color: rgba(255,255,255,0.65); max-width: 620px; }
.svc-facts {
  font-size: 0.8rem; line-height: 1.7; color: rgba(255,255,255,0.4);
  max-width: 620px; margin-top: 16px;
}
.svc-hero-cta { margin-top: 34px; display: flex; gap: 14px; flex-wrap: wrap; }
.svc-btn-main {
  background: linear-gradient(135deg, var(--teal-deep), var(--teal)); color: white;
  padding: 15px 32px; border-radius: 50px; text-decoration: none; font-weight: 700;
  font-size: 0.95rem; display: flex; align-items: center; gap: 10px;
  box-shadow: 0 8px 26px rgba(0,0,0,0.28); transition: transform 0.3s var(--easing), box-shadow 0.3s var(--easing);
  touch-action: manipulation;
}
.svc-btn-main:active { transform: scale(0.97); box-shadow: 0 4px 16px rgba(0,0,0,0.28); }
.svc-btn-ghost {
  color: rgba(255,255,255,0.75); border: 1px solid rgba(255,255,255,0.2);
  padding: 15px 28px; border-radius: 50px; text-decoration: none; font-weight: 600;
  font-size: 0.95rem; background: rgba(255,255,255,0.04); transition: all 0.3s;
  touch-action: manipulation;
}
.svc-btn-ghost:active { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.4); color: white; }

/* ═══ CONTENIDO ═══ */
main.svc-main { max-width: 820px; margin: 0 auto; padding: 70px 6% 40px; }
.svc-section { margin-bottom: 56px; }
.svc-section h2 {
  font-family: 'Playfair Display', serif; font-size: 1.7rem; font-weight: 500;
  color: var(--navy); margin-bottom: 16px;
}
.svc-section h2 em { font-style: italic; color: var(--teal-texto); }
.svc-section p { font-size: 1rem; line-height: 1.85; color: var(--text-mid); margin-bottom: 14px; }
.svc-section ul { list-style: none; margin-top: 6px; }
.svc-section ul li {
  font-size: 0.97rem; color: var(--text-mid); line-height: 1.7; padding: 6px 0 6px 26px;
  position: relative;
}
.svc-section ul li::before {
  content: ''; position: absolute; left: 0; top: 15px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--teal-mid);
}

.svc-callout {
  background: var(--teal-pale); border-radius: var(--r); padding: 22px 26px;
  font-size: 0.92rem; line-height: 1.7; color: var(--teal-texto); margin: 30px 0;
}
.svc-callout strong { color: var(--navy); }

.svc-cud-strip {
  background: linear-gradient(135deg, var(--teal-deep), var(--teal)); border-radius: var(--r-lg);
  padding: 28px 30px; display: flex; gap: 20px; align-items: flex-start; margin: 40px 0;
}
.svc-cud-strip svg { flex-shrink: 0; color: white; width: 26px; height: 26px; margin-top: 3px; }
.svc-cud-strip h3 { font-family: 'Playfair Display', serif; font-size: 1.15rem; color: white; margin-bottom: 6px; }
.svc-cud-strip p { font-size: 0.9rem; color: rgba(255,255,255,0.8); line-height: 1.6; margin: 0; }

/* pasos */
.svc-pasos { display: grid; gap: 18px; margin-top: 20px; }
.svc-paso { display: flex; gap: 18px; align-items: flex-start; }
.svc-paso-num {
  flex-shrink: 0; width: 40px; height: 40px; border-radius: 50%;
  background: var(--teal-pale); color: var(--teal-texto); font-weight: 800;
  display: flex; align-items: center; justify-content: center; font-family: 'Playfair Display', serif;
}
.svc-paso h4 { font-size: 1rem; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.svc-paso p { font-size: 0.9rem; margin: 0; }

/* FAQ (mismo componente visual que index.html) */
.svc-faq-item { border-bottom: 1px solid rgba(42,174,194,0.12); }
.svc-faq-q {
  width: 100%; background: none; border: none; cursor: pointer; display: flex;
  align-items: center; justify-content: space-between; padding: 20px 0; text-align: left;
  gap: 20px; font-family: 'Nunito', sans-serif; font-size: 0.98rem; font-weight: 700;
  color: var(--navy); transition: color 0.2s;
}
.svc-faq-q:active { color: var(--teal-texto); }
.svc-faq-icon {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; background: var(--teal-pale);
  color: var(--teal-texto); display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; transition: background 0.3s, color 0.3s, transform 0.3s var(--easing);
}
.svc-faq-item.open .svc-faq-icon { background: var(--teal); color: white; transform: rotate(45deg); }
.svc-faq-a { max-height: 0; overflow: hidden; transition: max-height 0.4s var(--easing); }
.svc-faq-item.open .svc-faq-a { max-height: 260px; }
.svc-faq-a p { padding: 0 40px 20px 0; font-size: 0.92rem; color: var(--text-soft); line-height: 1.7; margin: 0; }

/* enlaces a otros servicios */
.svc-relacionados { margin-top: 50px; }
.svc-relacionados h2 { margin-bottom: 18px; }
.svc-rel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 14px; }
.svc-rel-card {
  background: white; border: 1.5px solid rgba(42,174,194,0.1); border-radius: var(--r);
  padding: 18px 20px; text-decoration: none; color: inherit; transition: all 0.3s var(--easing);
  display: block; touch-action: manipulation;
}
.svc-rel-card:active { border-color: var(--teal-mid); transform: scale(0.98); box-shadow: 0 6px 16px rgba(8,32,46,0.1); }
.svc-rel-card b { display: block; font-family: 'Playfair Display', serif; color: var(--navy); font-size: 1rem; margin-bottom: 4px; }
.svc-rel-card span { font-size: 0.82rem; color: var(--text-soft); }

/* CTA final */
.svc-cta-final {
  background: linear-gradient(145deg, var(--navy), var(--teal-deep)); padding: 70px 6%;
  text-align: center; margin-top: 30px;
}
.svc-cta-final h2 { font-family: 'Playfair Display', serif; color: white; font-size: 1.6rem; margin-bottom: 14px; font-weight: 500; }
.svc-cta-final p { color: rgba(255,255,255,0.6); font-size: 0.95rem; margin-bottom: 28px; max-width: 460px; margin-left: auto; margin-right: auto; }

/* footer (idéntico a index.html, versión reducida) */
footer.svc-footer { background: #050f17; padding: 40px 6% 130px; text-align: center; }
footer.svc-footer p { color: rgba(255,255,255,0.45); font-size: 0.82rem; }
footer.svc-footer a { color: var(--teal-soft); text-decoration: none; }
footer.svc-footer a:active { text-decoration: underline; }
footer.svc-footer .svc-footer-contacto { margin-bottom: 8px; color: rgba(255,255,255,0.6); }

@media(max-width:640px){
  .svc-hero { padding: 110px 6% 50px; }
  main.svc-main { padding: 50px 6% 30px; }
}

/* Hover con transform/scale: solo en dispositivos que de verdad tienen mouse.
   En touch, :hover se dispara con el tap y queda "pegado" hasta el próximo
   toque en otro lado — mover estas reglas acá evita ese efecto (mismo
   patrón que juegos.css/ejercicios.css/infantil.css/sonidos.css). */
@media (hover: hover) and (pointer: fine) {
  .svc-nav-cta:hover { background: var(--teal-soft); color: var(--navy); transform: translateY(-1px); }
  .svc-breadcrumb a:hover { color: white; }
  .svc-btn-main:hover { transform: translateY(-3px); box-shadow: 0 14px 38px rgba(0,0,0,0.32); }
  .svc-btn-ghost:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.4); color: white; }
  .svc-faq-q:hover { color: var(--teal-texto); }
  .svc-rel-card:hover { border-color: var(--teal-mid); transform: translateY(-3px); box-shadow: 0 12px 30px rgba(8,32,46,0.08); }
  footer.svc-footer a:hover { text-decoration: underline; }
}
