/* ==========================================================================
   Clockwork · Private Investment Mechanics
   One stylesheet for the whole site. Brand values from the
   Clockwork Brand Guidelines 2026 (colors p.27, typefaces p.28, layout p.30).
   ========================================================================== */

/* ---------- Fonts (self-hosted: no third-party requests, faster) ---------- */
@font-face { font-family: "Questrial"; src: url("/assets/fonts/Questrial-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Nunito"; src: url("/assets/fonts/Nunito-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Nunito"; src: url("/assets/fonts/Nunito-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Nunito"; src: url("/assets/fonts/Nunito-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

/* ---------- Brand tokens: change colors here ---------- */
:root {
  --dark-blue: #101527;     /* primary anchor */
  --white: #ffffff;         /* primary anchor */
  --anchor-gray: #313748;   /* body text, icons */
  --cobalt: #074075;        /* accent, links, buttons */
  --periwinkle: #c9cfe4;    /* lines, soft accents */
  --ghost: #f5f6fa;         /* section backgrounds */

  --muted: #5a6072;         /* secondary text (AA on white and ghost) */
  --focus: #074075;

  --font-main: "Questrial", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-support: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 16px;
  --radius-sm: 10px;
  --max: 1160px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(56px, 9vw, 112px);
  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0;
  font-family: var(--font-main);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--anchor-gray);
  background: var(--white);
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--cobalt); text-underline-offset: 3px; }
a:hover { color: var(--dark-blue); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3, h4 { font-family: var(--font-main); font-weight: 400; color: var(--dark-blue); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.25rem, 5.5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); }
h3 { font-size: 1.3rem; line-height: 1.3; }
p { margin: 0 0 1em; }
.lede { font-size: clamp(1.125rem, 2vw, 1.3rem); color: var(--anchor-gray); max-width: 62ch; }
.eyebrow { font-family: var(--font-support); font-weight: 600; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--cobalt); margin: 0 0 1rem; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--section) 0; }
.section--ghost { background: var(--ghost); }
.section--dark { background: var(--dark-blue); color: #dfe3f0; }
.section--dark h1, .section--dark h2, .section--dark h3 { color: var(--white); }
.section--dark .eyebrow { color: var(--periwinkle); }
.section__head { max-width: 720px; margin-bottom: clamp(32px, 5vw, 56px); }

.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--dark-blue); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); z-index: 100; }
.skip-link:focus { left: 8px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Placeholders: content still needed from Clockwork ----------
   Every placeholder uses this class and starts with "PLACEHOLDER".
   Search the files for "PLACEHOLDER" to find them all before launch. */
.ph {
  background: #fff6d6; color: #5c4400; border: 1px dashed #c9a227;
  border-radius: 6px; padding: 0 .35em; font-family: var(--font-support); font-size: .92em;
}
.ph-block { display: block; padding: 1rem 1.1rem; margin: 0 0 1rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--font-support); font-weight: 600; font-size: 1rem; line-height: 1;
  padding: 15px 24px; border-radius: 999px; text-decoration: none;
  border: 1.5px solid transparent; transition: background-color .15s, color .15s, border-color .15s;
}
.btn--primary { background: var(--cobalt); color: var(--white); }
.btn--primary:hover { background: var(--dark-blue); color: var(--white); }
.btn--ghost { border-color: var(--periwinkle); color: var(--dark-blue); }
.btn--ghost:hover { border-color: var(--cobalt); color: var(--cobalt); }
.section--dark .btn--primary { background: var(--white); color: var(--dark-blue); }
.section--dark .btn--primary:hover { background: var(--periwinkle); }
.section--dark .btn--ghost { color: var(--white); border-color: rgba(201,207,228,.5); }
.section--dark .btn--ghost:hover { border-color: var(--white); color: var(--white); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--ghost); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--dark-blue); }
.brand img { width: 150px; }
.brand__divider { width: 1px; height: 28px; background: var(--periwinkle); }
.brand__name { font-family: var(--font-support); font-weight: 600; font-size: .82rem; letter-spacing: .06em; line-height: 1.25; text-transform: uppercase; }

.nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.nav a { display: block; padding: 10px 14px; border-radius: 999px; color: var(--anchor-gray); text-decoration: none; font-size: .98rem; }
.nav a:hover { color: var(--cobalt); background: var(--ghost); }
.nav a[aria-current="page"] { color: var(--dark-blue); background: var(--ghost); }
.nav .btn { margin-left: 10px; padding: 12px 20px; color: var(--white); }
.nav .btn:hover, .nav .btn[aria-current="page"] { color: var(--white); background: var(--dark-blue); }
.nav-toggle { display: none; }

@media (max-width: 880px) {
  .brand img { width: 128px; }
  .brand__name { font-size: .72rem; }
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px;
    border: 1px solid var(--periwinkle); border-radius: 12px; background: var(--white); color: var(--dark-blue); cursor: pointer;
  }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--periwinkle); display: none; }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; align-items: stretch; padding: 8px var(--gutter) 20px; gap: 2px; }
  .nav a { padding: 14px 12px; border-radius: var(--radius-sm); }
  .nav .btn { margin: 10px 0 0; justify-content: center; }
}
@media (max-width: 420px) { .brand__divider, .brand__name { display: none; } }

/* ---------- Hero (Full Dark Editorial layout) ---------- */
.hero { background: var(--dark-blue); color: #dfe3f0; padding: clamp(56px, 10vw, 120px) 0 clamp(56px, 8vw, 96px); overflow: hidden; }
.hero h1 { color: var(--white); max-width: 15ch; }
.hero .lede { color: #c9cfe4; }
.hero .eyebrow { color: var(--periwinkle); }
.hero .btn--primary { background: var(--white); color: var(--dark-blue); }
.hero .btn--primary:hover { background: var(--periwinkle); color: var(--dark-blue); }
.hero .btn--ghost { color: var(--white); border-color: rgba(201,207,228,.5); }
.hero .btn--ghost:hover { color: var(--white); border-color: var(--white); }
.hero__grid { display: grid; grid-template-columns: 1.25fr .9fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.hero__card { background: #1a2036; border: 1px solid #262d47; border-radius: var(--radius); padding: clamp(24px, 3.5vw, 36px); }
.hero__card h2 { font-size: 1.15rem; color: var(--white); margin-bottom: 1rem; }
.hero__card ul { list-style: none; margin: 0; padding: 0; }
.hero__card li { padding: 12px 0; border-top: 1px dashed #343c5a; display: flex; gap: 12px; }
.hero__card li:first-child { border-top: 0; padding-top: 0; }
.hero__card .num { font-family: var(--font-support); font-weight: 700; color: var(--periwinkle); min-width: 1.8em; }
.page-hero { padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px); }
.page-hero h1 { max-width: 18ch; }
@media (max-width: 880px) { .hero__grid { grid-template-columns: 1fr; } }

/* ---------- Metrics (numeric hierarchy, p.30) ---------- */
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px dashed var(--periwinkle); border-bottom: 1px dashed var(--periwinkle); }
.metric { padding: 28px 24px 28px 0; }
.metric + .metric { padding-left: 24px; border-left: 1px dashed var(--periwinkle); }
.metric__value { font-family: var(--font-support); font-weight: 700; font-size: clamp(2.25rem, 4.5vw, 3rem); line-height: 1; color: var(--dark-blue); }
.metric__value small { font-size: .45em; font-weight: 700; margin-left: .15em; }
.metric__label { font-family: var(--font-support); font-size: .95rem; color: var(--muted); margin-top: 8px; }
@media (max-width: 760px) {
  .metrics { grid-template-columns: 1fr 1fr; }
  .metric:nth-child(3) { padding-left: 0; border-left: 0; }
  .metric:nth-child(n+3) { border-top: 1px dashed var(--periwinkle); }
}

/* ---------- Cards & grids ---------- */
.grid { display: grid; gap: 20px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid--3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .grid--2, .grid--3 { grid-template-columns: 1fr; } }
.card { background: var(--white); border: 1px solid #e3e6f0; border-radius: var(--radius); padding: clamp(22px, 3vw, 32px); }
.section--ghost .card { border-color: transparent; }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.card__icon { width: 44px; height: 44px; border-radius: 12px; background: var(--ghost); color: var(--cobalt); display: grid; place-items: center; margin-bottom: 18px; }
.section--ghost .card__icon { background: var(--ghost); }
.card__icon svg { width: 22px; height: 22px; }

/* ---------- Split (Split Sidebar layout) ---------- */
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
@media (max-width: 880px) { .split { grid-template-columns: 1fr; } }
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { position: relative; padding: 14px 0 14px 34px; border-top: 1px dashed var(--periwinkle); }
.checklist li:first-child { border-top: 0; }
.checklist li::before { content: ""; position: absolute; left: 0; top: 19px; width: 18px; height: 18px; border-radius: 50%; background: var(--cobalt) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center/12px no-repeat; }

/* ---------- Curriculum ---------- */
.modules { list-style: none; margin: 0; padding: 0; counter-reset: mod; }
.module { display: grid; grid-template-columns: 88px 1fr; gap: 24px; padding: 32px 0; border-top: 1px dashed var(--periwinkle); }
.module:last-child { border-bottom: 1px dashed var(--periwinkle); }
.module__num { font-family: var(--font-support); font-weight: 700; font-size: 2.25rem; line-height: 1; color: var(--cobalt); }
.module__meta { font-family: var(--font-support); font-size: .9rem; color: var(--muted); margin: 0 0 .5rem; }
.module h3 { font-size: 1.45rem; }
@media (max-width: 600px) { .module { grid-template-columns: 1fr; gap: 8px; } .module__num { font-size: 1.6rem; } }

.agenda { width: 100%; border-collapse: collapse; font-size: .98rem; }
.agenda caption { text-align: left; font-family: var(--font-support); font-weight: 600; color: var(--dark-blue); padding-bottom: 12px; font-size: 1.05rem; }
.agenda th, .agenda td { text-align: left; padding: 12px 12px 12px 0; border-top: 1px dashed var(--periwinkle); vertical-align: top; }
.agenda th { font-family: var(--font-support); font-weight: 600; color: var(--muted); white-space: nowrap; width: 9.5rem; }
.agenda-wrap + .agenda-wrap { margin-top: 32px; }

/* ---------- Faculty ---------- */
.person { display: grid; grid-template-columns: 120px 1fr; gap: 24px; align-items: start; }
.person__photo { width: 120px; aspect-ratio: 1; border-radius: var(--radius); background: var(--ghost); display: grid; place-items: center; font-family: var(--font-support); font-weight: 700; font-size: 1.6rem; color: var(--cobalt); overflow: hidden; }
.person__photo img { width: 100%; height: 100%; object-fit: cover; }
.person__role { font-family: var(--font-support); font-weight: 600; color: var(--cobalt); font-size: .95rem; margin: -0.2em 0 .8em; }
@media (max-width: 520px) { .person { grid-template-columns: 1fr; } }

/* ---------- FAQ (native <details>: accessible, no JavaScript) ---------- */
.faq-group + .faq-group { margin-top: 48px; }
.faq details { border-top: 1px dashed var(--periwinkle); }
.faq details:last-child { border-bottom: 1px dashed var(--periwinkle); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 44px 20px 0; position: relative; font-size: 1.15rem; color: var(--dark-blue); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 12px; height: 12px; margin-top: -9px; border-right: 2px solid var(--cobalt); border-bottom: 2px solid var(--cobalt); transform: rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq .answer { padding: 0 0 22px; max-width: 70ch; }

/* ---------- Partner strip (partner logos first, divider, Clockwork — p.25) ---------- */
.partners { display: flex; flex-wrap: wrap; align-items: center; gap: 24px 32px; }
.partners__logo { min-width: 140px; height: 64px; border-radius: var(--radius-sm); display: grid; place-items: center; padding: 0 16px; }
.partners__divider { width: 1px; height: 48px; background: var(--periwinkle); }
.partners img.cw { width: 170px; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.steps li { background: var(--white); border-radius: var(--radius); padding: 24px; }
.steps .num { font-family: var(--font-support); font-weight: 700; color: var(--cobalt); font-size: 1.6rem; line-height: 1; display: block; margin-bottom: 14px; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* ---------- CTA band ---------- */
.section--cta { padding-top: 0; }
.section--ghost + .section--cta { padding-top: var(--section); }
.cta-band { background: var(--dark-blue); border-radius: var(--radius); padding: clamp(32px, 6vw, 64px); color: #dfe3f0; display: grid; grid-template-columns: 1.4fr auto; gap: 24px; align-items: center; }
.cta-band h2 { color: var(--white); margin-bottom: .3em; }
.cta-band p { margin: 0; color: var(--periwinkle); }
.cta-band .btn--primary { background: var(--white); color: var(--dark-blue); }
.cta-band .btn--primary:hover { background: var(--periwinkle); }
@media (max-width: 760px) { .cta-band { grid-template-columns: 1fr; } }

/* ---------- Form ---------- */
.form-card { background: var(--white); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); border: 1px solid #e3e6f0; }
.form-card .hs-form-placeholder { min-height: 240px; }
.small { font-size: .9rem; color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer { background: var(--dark-blue); color: #aeb5cc; padding: 56px 0 32px; font-size: .95rem; }
.site-footer a { color: #dfe3f0; text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 32px; }
.site-footer img { width: 160px; margin-bottom: 16px; }
.site-footer h2 { font-family: var(--font-support); font-weight: 600; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--periwinkle); margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer__bottom { margin-top: 40px; padding-top: 20px; border-top: 1px dashed #2c3350; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .85rem; }
@media (max-width: 760px) { .site-footer__grid { grid-template-columns: 1fr; } }

/* ---------- 404 ---------- */
.notfound { min-height: 60vh; display: grid; align-items: center; }
.notfound .code { font-family: var(--font-support); font-weight: 700; font-size: clamp(4rem, 14vw, 8rem); line-height: 1; color: var(--cobalt); margin-bottom: 12px; }
