/* ======================================================
   Cognitia · Particular English Institute — styles.css
   Identidad: navy profundo + marfil + dorado heráldico + acero
   Tipografía: Cormorant Garamond (display) + Inter (texto/UI)
   ====================================================== */

:root {
  --navy-950: #050f28;
  --navy-900: #081734;
  --navy-800: #0d2347;
  --navy-700: #16335f;
  --navy-600: #21447f;

  --gold: #c3a14e;
  --gold-soft: #e2c982;
  --gold-deep: #9a7a2c;

  --ivory: #f6f2e9;
  --ivory-2: #ece4d4;
  --slate: #8fa2c2;      /* texto tenue sobre navy */

  --ink: #17202f;        /* texto sobre marfil */
  --muted: #5a6577;

  --white: #ffffff;
  --radius: 14px;
  --radius-lg: 22px;
  --max: 1160px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --shadow: 0 24px 60px -28px rgba(5, 15, 40, .55);
}

/* ---------- Reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 86px; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--ivory);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul, ol { list-style: none; }

h1, h2, h3 { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 600; line-height: 1.08; letter-spacing: .2px; }

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: 24px; }

/* Encabezado de sección reutilizable */
.section-head { max-width: 680px; margin-bottom: 3rem; }
.kicker {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .82rem; font-weight: 600; letter-spacing: .3px; color: var(--gold-deep);
  margin-bottom: .9rem;
}
.kicker::before { content: ""; width: 26px; height: 2px; background: var(--gold); display: inline-block; }
.kicker.light { color: var(--gold-soft); }
.kicker.light::before { background: var(--gold-soft); }
.section-head h2 { font-size: clamp(2.1rem, 4.6vw, 3.1rem); color: var(--navy-900); margin-bottom: .7rem; }
.section-lead { color: var(--muted); font-size: 1.08rem; max-width: 60ch; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  font-family: 'Inter', sans-serif; font-weight: 600; font-size: .96rem;
  padding: .85rem 1.7rem; border-radius: 999px; border: 1.5px solid transparent;
  cursor: pointer; transition: transform .25s var(--ease), box-shadow .25s, background .25s, color .25s, border-color .25s;
}
.btn-gold { background: linear-gradient(135deg, var(--gold-soft), var(--gold)); color: var(--navy-900); box-shadow: 0 12px 28px -12px rgba(195, 161, 78, .6); }
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 18px 34px -12px rgba(195, 161, 78, .7); }
.btn-ghost { background: transparent; color: var(--ivory); border-color: rgba(246, 242, 233, .35); }
.btn-ghost:hover { border-color: var(--gold-soft); color: var(--gold-soft); }
.btn-navy { background: var(--navy-800); color: var(--ivory); }
.btn-navy:hover { background: var(--navy-700); transform: translateY(-2px); }
.btn-outline { background: transparent; color: var(--navy-800); border-color: rgba(13, 35, 71, .25); }
.btn-outline:hover { border-color: var(--navy-800); background: var(--navy-800); color: var(--ivory); }
.btn-whatsapp { background: #1fab54; color: #fff; }
.btn-whatsapp:hover { background: #178f45; transform: translateY(-2px); box-shadow: 0 16px 30px -14px rgba(23, 143, 69, .6); }
.btn-block { width: 100%; margin-top: .4rem; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background .35s, box-shadow .35s, border-color .35s;
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(8, 23, 52, .95); backdrop-filter: blur(10px);
  border-bottom-color: rgba(195, 161, 78, .22); box-shadow: 0 12px 30px -22px rgba(0,0,0,.8);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; padding-block: .75rem; }
.brand-logo { height: 50px; width: auto; filter: drop-shadow(0 4px 12px rgba(0,0,0,.4)); transition: transform .3s var(--ease); }
.brand:hover .brand-logo { transform: scale(1.03); }

.nav-links { display: flex; align-items: center; gap: 1.7rem; }
.nav-links a { color: rgba(246, 242, 233, .82); font-weight: 500; font-size: .94rem; position: relative; transition: color .25s; }
.nav-links a:not(.nav-cta):hover { color: var(--white); }
.nav-links a:not(.nav-cta)::after {
  content: ""; position: absolute; left: 0; bottom: -5px; height: 2px; width: 0; background: var(--gold);
  transition: width .3s var(--ease);
}
.nav-links a:not(.nav-cta):hover::after { width: 100%; }
.nav-cta {
  background: linear-gradient(135deg, var(--gold-soft), var(--gold)); color: var(--navy-900) !important;
  padding: .5rem 1.15rem; border-radius: 999px; font-weight: 600; transition: transform .25s var(--ease), box-shadow .25s;
}
.nav-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 24px -10px rgba(195,161,78,.6); }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 6px; z-index: 101; }
.nav-toggle span { width: 26px; height: 2.5px; background: var(--ivory); border-radius: 2px; transition: .3s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* Fondo oscuro detrás del menú móvil (oculto en escritorio) */
.nav-backdrop { display: none; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; color: var(--ivory); overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    linear-gradient(115deg, var(--navy-950) 0%, var(--navy-900) 45%, var(--navy-800) 100%);
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background-image: url('https://images.unsplash.com/photo-1523240795612-9a054b0db644?auto=format&fit=crop&w=1800&q=80');
  background-size: cover; background-position: center; opacity: .16; mix-blend-mode: luminosity;
}
.hero-veil {
  position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(circle at 78% 30%, rgba(195,161,78,.16), transparent 42%);
}
.hero-inner { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 2.5rem; padding-top: 86px; }
.hero-content { max-width: 680px; }
.hero-kicker { color: var(--gold-soft); font-weight: 500; letter-spacing: 3px; text-transform: uppercase; font-size: .78rem; margin-bottom: 1.1rem; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.5rem); font-weight: 600; margin-bottom: 1.3rem; }
.hero-sub { font-size: clamp(1.05rem, 2vw, 1.25rem); color: rgba(246,242,233,.82); font-weight: 300; max-width: 56ch; margin-bottom: 2.2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 2.6rem; }

.hero-facts { display: flex; flex-wrap: wrap; gap: 1.6rem 2rem; }
.hero-facts li { display: flex; align-items: center; gap: .6rem; font-size: .95rem; color: rgba(246,242,233,.9); font-weight: 500; }
.hero-facts i { color: var(--gold-soft); }

.hero-crest { flex-shrink: 0; }
.hero-crest img { width: 232px; height: auto; filter: drop-shadow(0 28px 50px rgba(0,0,0,.55)); animation: floatCrest 6s ease-in-out infinite; }
@keyframes floatCrest { 0%,100% { transform: translateY(0) rotate(-1.5deg); } 50% { transform: translateY(-16px) rotate(1.5deg); } }

/* ---------- Programas ---------- */
section { padding-block: clamp(4rem, 8vw, 6.5rem); }
.programs { background: var(--ivory); }
.programs-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.program-card {
  background: var(--white); border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--ivory-2); display: flex; flex-direction: column;
  transition: transform .3s var(--ease), box-shadow .3s;
}
.program-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.program-media { position: relative; aspect-ratio: 4/3; overflow: hidden; }
.program-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.program-card:hover .program-media img { transform: scale(1.06); }
.program-age {
  position: absolute; top: 12px; left: 12px; background: rgba(8,23,52,.85); color: var(--gold-soft);
  font-size: .76rem; font-weight: 600; letter-spacing: .3px; padding: .3rem .8rem; border-radius: 999px;
  backdrop-filter: blur(4px);
}
.program-body { padding: 1.4rem 1.4rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.program-body h3 { font-size: 1.65rem; color: var(--navy-900); margin-bottom: .5rem; }
.program-body p { color: var(--muted); font-size: .95rem; margin-bottom: 1.2rem; flex: 1; }
.program-link { color: var(--gold-deep); font-weight: 600; font-size: .9rem; display: inline-flex; align-items: center; gap: .4rem; transition: gap .25s; }
.program-link::after { content: "\2192"; transition: transform .25s; }
.program-link:hover::after { transform: translateX(4px); }

/* ---------- Método ---------- */
.method { background: linear-gradient(180deg, var(--ivory), var(--ivory-2)); }
.method-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: 3.5rem; align-items: center; }
.method-media { position: relative; }
.method-media img { border-radius: var(--radius-lg); box-shadow: var(--shadow); aspect-ratio: 4/5; object-fit: cover; }
.method-badge {
  position: absolute; bottom: -20px; left: -20px; background: var(--navy-900); color: var(--ivory);
  padding: 1rem 1.4rem; border-radius: var(--radius); box-shadow: var(--shadow); border-left: 3px solid var(--gold);
}
.method-badge strong { display: block; font-family: 'Cormorant Garamond', serif; font-size: 1.3rem; color: var(--gold-soft); }
.method-badge span { font-size: .82rem; color: var(--slate); }
.method-text h2 { font-size: clamp(2.1rem, 4.4vw, 3rem); color: var(--navy-900); margin-bottom: 1.1rem; }
.method-text > p { color: var(--muted); font-size: 1.06rem; margin-bottom: 1.8rem; max-width: 54ch; }
.method-points { display: grid; gap: 1.1rem; margin-bottom: 2rem; }
.method-point { display: flex; gap: 1rem; align-items: flex-start; }
.method-point i { color: var(--gold-deep); font-size: 1.1rem; background: #fff; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; box-shadow: 0 8px 18px -12px rgba(0,0,0,.3); }
.method-point strong { display: block; color: var(--navy-900); font-size: 1rem; }
.method-point span { color: var(--muted); font-size: .92rem; }

/* ---------- Niveles ---------- */
.levels { background: var(--navy-900); color: var(--ivory); }
.levels .section-head h2 { color: var(--ivory); }
.levels .section-lead { color: var(--slate); }
.levels-track { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; }
.level-step {
  position: relative; padding: 1.8rem 1.5rem; border-radius: var(--radius);
  background: rgba(255,255,255,.035); border: 1px solid rgba(195,161,78,.2);
  border-top: 3px solid var(--gold); transition: background .3s, transform .3s var(--ease);
}
.level-step:hover { background: rgba(255,255,255,.06); transform: translateY(-5px); }
.level-tag { font-size: .76rem; font-weight: 600; letter-spacing: .4px; color: var(--gold-soft); text-transform: uppercase; }
.level-step h3 { font-size: 1.5rem; color: var(--ivory); margin: .5rem 0 .6rem; }
.level-step p { color: var(--slate); font-size: .92rem; }

/* ---------- Modalidades ---------- */
.modes { background: var(--ivory-2); }
.modes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.mode-card { background: var(--white); border-radius: var(--radius); padding: 2.2rem 1.9rem; border: 1px solid #e2d9c6; }
.mode-card i { font-size: 1.5rem; color: var(--navy-800); background: var(--ivory); width: 58px; height: 58px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 1.1rem; border: 1px solid var(--ivory-2); }
.mode-card h3 { font-size: 1.5rem; color: var(--navy-900); margin-bottom: .5rem; }
.mode-card p { color: var(--muted); font-size: .96rem; }

/* ---------- Cómo empezar (secuencia real → numeración justificada) ---------- */
.steps { background: var(--ivory); }
.steps-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8rem; counter-reset: step; }
.step { position: relative; padding: 2rem 1.8rem 1.8rem; background: var(--white); border-radius: var(--radius); border: 1px solid var(--ivory-2); }
.step-num {
  position: absolute; top: -22px; left: 1.8rem;
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: var(--navy-900); color: var(--gold-soft); font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem; font-weight: 700; border: 2px solid var(--gold);
}
.step h3 { font-size: 1.5rem; color: var(--navy-900); margin: .9rem 0 .5rem; }
.step p { color: var(--muted); font-size: .96rem; }

/* ---------- Planes ---------- */
.plans { background: var(--ivory); }
.plans-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem; align-items: stretch; }
.plan-card { position: relative; background: var(--white); border-radius: var(--radius-lg); padding: 2.4rem 2rem; border: 1px solid var(--ivory-2); display: flex; flex-direction: column; }
.plan-card.featured { background: linear-gradient(170deg, var(--navy-800), var(--navy-950)); color: var(--ivory); border-color: var(--gold); transform: translateY(-10px); box-shadow: var(--shadow); }
.plan-flag { position: absolute; top: -13px; left: 50%; transform: translateX(-50%); background: linear-gradient(135deg, var(--gold-soft), var(--gold)); color: var(--navy-900); font-size: .74rem; font-weight: 700; letter-spacing: .4px; padding: .35rem 1.1rem; border-radius: 999px; text-transform: uppercase; }
.plan-card h3 { font-size: 1.75rem; color: var(--navy-900); }
.plan-card.featured h3 { color: var(--ivory); }
.plan-tag { color: var(--gold-deep); font-weight: 600; font-size: .9rem; margin-bottom: 1.4rem; }
.plan-card.featured .plan-tag { color: var(--gold-soft); }
.plan-card ul { display: grid; gap: .7rem; margin-bottom: 1.8rem; flex: 1; }
.plan-card li { display: flex; align-items: flex-start; gap: .6rem; font-size: .95rem; color: var(--ink); }
.plan-card.featured li { color: rgba(246,242,233,.9); }
.plan-card li i { color: var(--gold-deep); font-size: .8rem; margin-top: .35rem; }
.plan-card.featured li i { color: var(--gold-soft); }

/* ---------- FAQ ---------- */
.faq { background: var(--ivory-2); }
.faq-wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: 3rem; align-items: start; }
.faq-head { margin-bottom: 0; position: sticky; top: 110px; }
.faq-list { display: grid; gap: .9rem; }
.faq-item { background: var(--white); border: 1px solid #e3dac8; border-radius: var(--radius); overflow: hidden; }
.faq-item summary {
  list-style: none; cursor: pointer; padding: 1.15rem 1.4rem; font-weight: 600; color: var(--navy-900);
  font-size: 1.02rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary i { color: var(--gold-deep); transition: transform .3s var(--ease); flex-shrink: 0; }
.faq-item[open] summary i { transform: rotate(45deg); }
.faq-item p { padding: 0 1.4rem 1.3rem; color: var(--muted); font-size: .96rem; margin: 0; }

/* ---------- Contacto ---------- */
.contact { background: linear-gradient(135deg, var(--navy-800), var(--navy-950)); color: var(--ivory); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.contact-info h2 { font-size: clamp(2.1rem, 4.4vw, 3rem); color: var(--ivory); margin-bottom: 1rem; }
.contact-info > p { color: rgba(246,242,233,.82); margin-bottom: 2rem; max-width: 46ch; }
.contact-list { display: grid; gap: 1.1rem; }
.contact-list li { display: flex; align-items: center; gap: 1rem; }
.contact-list i { font-size: 1.25rem; color: var(--gold-soft); background: rgba(195,161,78,.14); width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.contact-list span { display: block; font-size: .76rem; text-transform: uppercase; letter-spacing: .6px; color: var(--slate); }
.contact-list a { font-weight: 600; color: var(--ivory); transition: color .25s; }
.contact-list a:hover { color: var(--gold-soft); }

.contact-card { background: var(--white); color: var(--ink); border-radius: var(--radius-lg); padding: 2.4rem; box-shadow: var(--shadow); }
.contact-card h3 { color: var(--navy-900); font-size: 1.7rem; margin-bottom: 1.4rem; }
.contact-card label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .4rem; color: var(--navy-900); }
.contact-card input, .contact-card select {
  width: 100%; padding: .85rem 1rem; border: 1.5px solid var(--ivory-2); border-radius: var(--radius);
  font-family: 'Inter', sans-serif; font-size: 1rem; margin-bottom: 1.2rem; background: var(--ivory); color: var(--ink);
  transition: border-color .25s, box-shadow .25s, background .25s;
}
.contact-card input:focus, .contact-card select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(195,161,78,.15); background: #fff; }
.contact-card input[type="date"]::-webkit-calendar-picker-indicator { filter: invert(.45) sepia(1) saturate(4) hue-rotate(5deg); cursor: pointer; opacity: .85; }
.form-hint { font-size: .82rem; color: var(--muted); text-align: center; margin-top: .9rem; }
.form-hint.error { color: #c0392b; font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-950); color: var(--slate); padding-top: 3.5rem; padding-bottom: 0; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 2.5rem; padding-bottom: 2.5rem; }
.footer-brand-top { display: flex; align-items: center; gap: 1.1rem; margin-bottom: 1.1rem; flex-wrap: wrap; }
.footer-logo { height: 54px; width: auto; filter: drop-shadow(0 6px 14px rgba(0,0,0,.5)); }
.footer-shield { height: 68px; width: auto; filter: drop-shadow(0 6px 14px rgba(0,0,0,.5)); }
.footer-desc { font-size: .93rem; max-width: 340px; line-height: 1.7; }
.footer-col h4 { color: var(--ivory); font-family: 'Inter', sans-serif; font-size: 1rem; margin-bottom: 1rem; }
.footer-col a { display: block; margin-bottom: .6rem; font-size: .92rem; transition: color .25s, padding-left .25s; }
.footer-col a:hover { color: var(--gold-soft); padding-left: 4px; }
.footer-col a i { width: 20px; color: var(--gold); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); text-align: center; padding-block: 1.4rem; font-size: .84rem; }

/* ---------- WhatsApp flotante ---------- */
.float-whats {
  position: fixed; bottom: 24px; right: 24px; z-index: 90; width: 58px; height: 58px; border-radius: 50%;
  background: #1fab54; color: #fff; display: grid; place-items: center; font-size: 1.7rem;
  box-shadow: 0 12px 28px -8px rgba(23,143,69,.6); transition: transform .3s var(--ease);
}
.float-whats:hover { transform: scale(1.08); }

/* ---------- Revelado sutil (solo encabezados, un gesto orquestado) ---------- */
.section-head, .hero-content { opacity: 0; transform: translateY(20px); animation: rise .9s var(--ease) forwards; }
.hero-content { animation-delay: .1s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .programs-grid { grid-template-columns: repeat(2, 1fr); }
  .levels-track { grid-template-columns: repeat(2, 1fr); }
  .hero-crest img { width: 190px; }
}
@media (max-width: 900px) {
  .method-grid { grid-template-columns: 1fr; gap: 3rem; }
  .method-media { max-width: 420px; margin-inline: auto; }
  .modes-grid, .steps-row, .testi-grid, .plans-grid { grid-template-columns: 1fr; }
  .plan-card.featured { transform: none; }
  .faq-wrap { grid-template-columns: 1fr; gap: 1.8rem; }
  .faq-head { position: static; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .hero-crest { display: none; }
  .hero-inner { justify-content: flex-start; }
}
@media (max-width: 760px) {
  .nav-links {
    position: fixed; top: 0; right: 0; bottom: 0;
    height: 100vh; height: 100dvh;
    width: min(82%, 330px);
    background: var(--navy-950);
    flex-direction: column; align-items: flex-start; justify-content: flex-start;
    padding: 6rem 2rem 2.5rem; gap: 1.5rem;
    transform: translateX(105%); transition: transform .4s var(--ease);
    box-shadow: -24px 0 60px rgba(0,0,0,.55);
    z-index: 200; overflow-y: auto;
  }
  .nav-links a { font-size: 1.05rem; width: 100%; }
  .nav-links .nav-cta { width: 100%; text-align: center; margin-top: .4rem; }
  .nav-links.open { transform: translateX(0); }
  .nav-toggle { display: flex; z-index: 201; }

  .nav-backdrop {
    display: block; position: fixed; inset: 0; background: rgba(4, 11, 30, .6);
    opacity: 0; visibility: hidden; transition: opacity .35s var(--ease), visibility .35s;
    z-index: 150;
  }
  .nav-backdrop.show { opacity: 1; visibility: visible; }

  .brand-logo { height: 44px; }
}
@media (max-width: 560px) {
  .programs-grid, .levels-track, .footer-grid { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; align-items: stretch; }
}

/* Accesibilidad: reduce motion */
@media (prefers-reduced-motion: reduce) {
  *, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .section-head, .hero-content { opacity: 1; transform: none; }
}
