/* Westfield Global Education Services: marketing site. Tokens mirror the CRM (navy + gold). */
@import url("/assets/fonts/fonts.css");

:root {
  --ink: #0f2447;
  --navy: #1b3a6b;
  --navy-2: #2a4f8f;
  --paper: #f8f5ee;
  --paper-2: #efe9db;
  --card: #fffdf8;
  --gold: #e2b04f;
  --gold-deep: #8a5f10;
  --text: #1d2433;
  --muted: #4a5468;
  --line: rgba(15, 36, 71, 0.14);
  --ok: #17663a;
  --err: #a32121;
  --r-card: 18px;
  --r-field: 8px;
  --shadow: 0 1px 2px rgba(15, 36, 71, 0.06), 0 12px 32px -16px rgba(15, 36, 71, 0.28);
  --display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: min(1160px, calc(100% - 2rem));
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 1.0625rem/1.6 var(--body); color: var(--text); background: var(--paper); }
img, svg { max-width: 100%; display: block; }
a { color: var(--navy); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
h1, h2, h3 { font-family: var(--display); color: var(--ink); line-height: 1.1; letter-spacing: -0.015em; margin: 0 0 0.6em; font-weight: 600; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
h3 { font-size: 1.25rem; letter-spacing: -0.005em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: 1rem; top: -4rem; background: var(--ink); color: #fff; padding: 0.7rem 1rem; border-radius: 8px; z-index: 100; }
.skip:focus { top: 1rem; }
.wrap { width: var(--wrap); margin-inline: auto; }
.eyebrow { font: 600 0.8rem/1 var(--body); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 1rem; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: 46ch; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 48px; padding: 0 1.4rem; border-radius: 999px; font: 600 1rem/1 var(--body); text-decoration: none; border: 2px solid transparent; cursor: pointer; transition: transform 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease; }
.btn:active { transform: translateY(1px); }
.btn-gold { background: var(--gold); color: var(--ink); box-shadow: 0 8px 24px -10px rgba(226, 176, 79, 0.9); }
.btn-gold:hover { background: #ecc16f; color: var(--ink); }
.btn-ghost { border-color: rgba(255, 255, 255, 0.45); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--ink); color: #fff; }
.btn[disabled] { opacity: 0.6; cursor: progress; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(15, 36, 71, 0.94); backdrop-filter: blur(10px); border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.bar { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: 0.7rem; text-decoration: none; color: #fff; }
.brand:hover { color: #fff; }
.brand-name { font: 600 1.35rem/1 var(--display); letter-spacing: -0.01em; }
.brand-sub { display: block; font: 500 0.62rem/1 var(--body); letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255, 255, 255, 0.72); margin-top: 0.3rem; }
.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav a { color: rgba(255, 255, 255, 0.88); text-decoration: none; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
.nav a:hover { color: var(--gold); }
.nav a.btn-gold, .nav a.btn-gold:hover { color: var(--ink); }
.nav .btn { min-height: 44px; padding: 0 1.1rem; }
.menu-btn { display: none; min-width: 48px; min-height: 48px; border: 1px solid rgba(255, 255, 255, 0.35); border-radius: 12px; background: transparent; color: #fff; cursor: pointer; }
.menu-btn svg { margin: auto; }

/* Hero */
.hero { position: relative; color: #fff; background: radial-gradient(900px 480px at 85% -10%, rgba(226, 176, 79, 0.28), transparent 60%), radial-gradient(700px 500px at -10% 110%, rgba(42, 79, 143, 0.7), transparent 60%), linear-gradient(180deg, var(--ink), #0b1b38); overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='.5'/></svg>"); opacity: 0.07; pointer-events: none; mix-blend-mode: soft-light; }
.hero-inner { position: relative; z-index: 1; padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(2.5rem, 5vw, 4rem); }
.hero h1 { color: #fff; font-size: clamp(2.5rem, 6.2vw, 5rem); max-width: 14ch; line-height: 1.02; letter-spacing: -0.025em; }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero .eyebrow { color: var(--gold); }
.hero .lede { color: rgba(255, 255, 255, 0.86); margin-bottom: 2rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.route { margin-top: clamp(2rem, 4vw, 3rem); }
.route-svg { width: 100%; height: auto; overflow: visible; }
.route-path { fill: none; stroke: rgba(255, 255, 255, 0.22); stroke-width: 2; stroke-dasharray: 3 8; stroke-linecap: round; }
.route-trail { fill: none; stroke: var(--gold); stroke-width: 3; stroke-linecap: round; }
.route-stop circle { fill: var(--ink); stroke: var(--gold); stroke-width: 2.5; }
.route-stop text { fill: #fff; font: 700 13px var(--body); text-anchor: middle; dominant-baseline: central; }
.route-legend { list-style: none; margin: 1.2rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0.6rem 1.2rem; counter-reset: s; }
.route-legend li { counter-increment: s; display: flex; align-items: center; gap: 0.6rem; font-weight: 500; color: rgba(255, 255, 255, 0.9); }
.route-legend li::before { content: counter(s); flex: none; width: 1.7rem; height: 1.7rem; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--gold); font: 700 0.8rem/1 var(--body); color: #fff; }

/* Sections */
section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.alt { background: var(--paper-2); }
.head { max-width: 62ch; margin-bottom: 2.4rem; }
.head p { color: var(--muted); font-size: 1.1rem; }
.grid { display: grid; gap: 1.1rem; }
.g3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.g4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
@media (min-width: 900px) { .g3 { grid-template-columns: repeat(3, 1fr); } .steps { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-card); padding: 1.5rem; box-shadow: var(--shadow); }
.card h3 { margin-bottom: 0.4rem; }
.card p { color: var(--muted); margin: 0; }
.ico { width: 2.9rem; height: 2.9rem; border-radius: 12px; display: grid; place-items: center; background: var(--ink); color: var(--gold); margin-bottom: 1rem; }
.ico svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.dest { position: relative; overflow: hidden; }
.dest::before { content: attr(data-code); position: absolute; right: 1rem; top: 0.9rem; font: 700 3.4rem/1 var(--display); letter-spacing: 0.02em; color: rgba(27, 58, 107, 0.1); pointer-events: none; }
.dest h3 { font-size: 1.45rem; }
.note { margin-top: 1.4rem; color: var(--muted); }

/* Journey list */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.1rem; counter-reset: st; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.steps li { counter-increment: st; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-card); padding: 1.5rem; position: relative; }
.steps li::before { content: counter(st, decimal-leading-zero); display: block; font: 600 2.2rem/1 var(--display); color: var(--gold-deep); margin-bottom: 0.7rem; }
.steps h3 { margin-bottom: 0.3rem; }
.steps p { margin: 0; color: var(--muted); }
.promise { margin-top: 1.6rem; padding: 1.2rem 1.4rem; border-left: 4px solid var(--gold); background: rgba(226, 176, 79, 0.16); border-radius: 0 12px 12px 0; max-width: 70ch; }

/* Dark band */
.band { background: var(--ink); color: #fff; }
.band h2, .band h3 { color: #fff; }
.band .card { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.14); box-shadow: none; }
.band .card p { color: rgba(255, 255, 255, 0.82); }
.band .head p { color: rgba(255, 255, 255, 0.82); }
.band .eyebrow { color: var(--gold); }

/* FAQ */
.faq { max-width: 820px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 1.15rem 2.5rem 1.15rem 0; font: 600 1.15rem/1.35 var(--display); color: var(--ink); position: relative; min-height: 48px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0.3rem; top: 0.9rem; font: 400 1.6rem/1 var(--body); color: var(--gold-deep); transition: transform 0.2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 2.5rem 1.2rem 0; color: var(--muted); margin: 0; }

/* Form */
.enquiry { display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
@media (min-width: 900px) { .enquiry { grid-template-columns: 0.9fr 1.1fr; align-items: start; } }
.form { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-card); padding: clamp(1.2rem, 3vw, 2rem); box-shadow: var(--shadow); display: grid; gap: 1rem; }
.row2 { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.field label, .field .lbl { display: block; font-weight: 600; margin-bottom: 0.35rem; color: var(--ink); }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 0.7rem 0.85rem; border: 1.5px solid #8b94a6; border-radius: var(--r-field); background: #fff; font: inherit; color: var(--text); }
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--gold); outline-offset: 1px; border-color: var(--navy); }
.field .hint { font-size: 0.9rem; color: var(--muted); margin-top: 0.3rem; }
.field [aria-invalid="true"] { border-color: var(--err); }
.err { color: var(--err); font-size: 0.92rem; margin-top: 0.3rem; font-weight: 500; }
.check { display: flex; gap: 0.7rem; align-items: flex-start; }
.check input { flex: none; width: 1.4rem; height: 1.4rem; margin-top: 0.15rem; accent-color: var(--navy); }
.check label { font-weight: 400; margin: 0; color: var(--text); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.status { padding: 0.9rem 1rem; border-radius: 10px; font-weight: 500; }
.status.ok { background: #e3f3e9; color: var(--ok); }
.status.bad { background: #fbe7e7; color: var(--err); }
.contact-list { list-style: none; padding: 0; margin: 1.4rem 0 0; display: grid; gap: 0.7rem; }
.contact-list a { font-weight: 600; }

/* Footer */
.site-footer { background: #0b1b38; color: rgba(255, 255, 255, 0.82); padding: 3rem 0 2rem; font-size: 0.97rem; }
.site-footer a { color: #fff; }
.foot { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.foot h4 { font: 600 0.8rem/1 var(--body); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); margin: 0 0 0.9rem; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.4rem; }
.foot a { display: inline-block; padding: 0.2rem 0; }
.legal { margin-top: 2rem; padding-top: 1.2rem; border-top: 1px solid rgba(255, 255, 255, 0.14); font-size: 0.9rem; }

/* Legal pages */
.doc { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.doc .wrap { max-width: 780px; }
.doc h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
.doc h2 { font-size: 1.5rem; margin-top: 2rem; }
.draft { background: rgba(226, 176, 79, 0.2); border: 1px solid var(--gold); border-radius: 10px; padding: 0.9rem 1rem; margin-bottom: 1.6rem; }

/* Reveal motion: one orchestrated entrance, staggered */
.rv { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; transition-delay: calc(var(--i, 0) * 70ms); }
.rv.in { opacity: 1; transform: none; }
.no-js .rv { opacity: 1; transform: none; }

/* Chat widget */
.cw-launch { position: fixed; right: 1rem; bottom: 1rem; z-index: 60; min-height: 56px; padding: 0 1.2rem 0 1rem; border-radius: 999px; border: 0; background: var(--gold); color: var(--ink); font: 700 1rem/1 var(--body); display: inline-flex; align-items: center; gap: 0.55rem; cursor: pointer; box-shadow: 0 14px 34px -10px rgba(15, 36, 71, 0.6); }
.cw-launch svg { width: 1.4rem; height: 1.4rem; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.cw-panel { position: fixed; right: 1rem; bottom: 5.2rem; z-index: 61; width: min(400px, calc(100vw - 2rem)); height: min(620px, calc(100dvh - 7rem)); display: none; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 30px 70px -20px rgba(15, 36, 71, 0.55); overflow: hidden; }
.cw-panel.open { display: flex; }
.cw-head { background: var(--ink); color: #fff; padding: 0.9rem 1rem; display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; }
.cw-head strong { font: 600 1.1rem/1.2 var(--display); display: block; }
.cw-head small { color: rgba(255, 255, 255, 0.78); font-size: 0.78rem; }
.cw-close { min-width: 44px; min-height: 44px; border: 0; background: transparent; color: #fff; cursor: pointer; border-radius: 10px; font-size: 1.5rem; line-height: 1; }
.cw-head, .cw-form, .cw-compose, .cw-count { flex: none; }
.cw-log { flex: 1 1 0; min-height: 0; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.7rem; background: var(--paper); }
.cw-msg { max-width: 88%; padding: 0.65rem 0.85rem; border-radius: 14px; font-size: 0.97rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.cw-msg.bot { background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 4px; align-self: flex-start; }
.cw-msg.me { background: var(--navy); color: #fff; border-bottom-right-radius: 4px; align-self: flex-end; }
.cw-tag { display: inline-block; font: 700 0.65rem/1 var(--body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 0.3rem; }
.cw-src { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.5rem; }
.cw-src span { font-size: 0.75rem; padding: 0.2rem 0.55rem; border-radius: 999px; background: var(--paper-2); color: var(--ink); }
.cw-banner { background: rgba(226, 176, 79, 0.25); border: 1px solid var(--gold); color: var(--ink); border-radius: 10px; padding: 0.6rem 0.8rem; font-size: 0.9rem; }
.cw-form { display: none; padding: 0.8rem 1rem; border-top: 1px solid var(--line); background: #fff; gap: 0.5rem; }
.cw-form.show { display: grid; max-height: 50%; overflow-y: auto; }
.cw-form input[type="text"], .cw-form input[type="email"], .cw-form input[type="tel"] { min-height: 44px; padding: 0.5rem 0.7rem; border: 1.5px solid #8b94a6; border-radius: 8px; font: inherit; width: 100%; }
.cw-form .check label { font-size: 0.85rem; }
.cw-compose { display: flex; gap: 0.5rem; padding: 0.7rem; border-top: 1px solid var(--line); background: #fff; align-items: flex-end; }
.cw-compose textarea { flex: 1; min-height: 48px; max-height: 120px; resize: none; padding: 0.7rem 0.8rem; border: 1.5px solid #8b94a6; border-radius: 12px; font: inherit; }
.cw-send { min-height: 48px; min-width: 48px; border: 0; border-radius: 12px; background: var(--navy); color: #fff; font-weight: 700; cursor: pointer; padding: 0 1rem; }
.cw-send[disabled] { opacity: 0.5; cursor: progress; }
.cw-count { font-size: 0.72rem; color: var(--muted); padding: 0 0.9rem 0.5rem; text-align: right; background: #fff; }
.cw-offline { padding: 1.2rem; background: var(--paper); flex: 1 1 0; min-height: 0; overflow-y: auto; }
.cw-typing { display: inline-flex; gap: 4px; padding: 0.2rem 0; }
.cw-typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: cw-b 1s infinite ease-in-out; }
.cw-typing i:nth-child(2) { animation-delay: 0.15s; }
.cw-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes cw-b { 0%, 80%, 100% { opacity: 0.25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }

@media (max-width: 860px) {
  .menu-btn { display: inline-flex; }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--ink); flex-direction: column; align-items: stretch; gap: 0; padding: 0.5rem 1rem 1rem; border-bottom: 1px solid rgba(255, 255, 255, 0.1); display: none; }
  .nav.open { display: flex; }
  .nav a { min-height: 52px; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
  .nav .btn { margin-top: 0.8rem; justify-content: center; border-bottom: 0; }
  .bar { position: relative; }
}
@media (max-width: 600px) {
  .route-stop text { display: none; }
  .route-stop circle { stroke-width: 7; r: 20; }
  .route-path { stroke-width: 5; stroke-dasharray: 6 16; }
  .route-trail { stroke-width: 6; }
}
@media (max-width: 480px) {
  .cw-panel { right: 0; bottom: 0; width: 100vw; height: 100dvh; border-radius: 0; }
  .cw-launch span { display: none; }
  .cw-launch { padding: 0 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rv { opacity: 1; transform: none; transition: none; }
  .route-trail { stroke-dasharray: none !important; stroke-dashoffset: 0 !important; }
  .cw-typing i { animation: none; opacity: 0.7; }
  .btn { transition: none; }
}
@media print { .site-header, .cw-launch, .cw-panel { display: none; } body { background: #fff; } }
