/* Shared components for every page. Reads tokens.css; no colours or fonts are
   hard-coded here. CSP forbids inline style attributes, so all styling lives in files. */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  font-family: var(--font);
  font-weight: var(--w-body);
  font-size: var(--text);
  line-height: var(--leading);
  background: var(--black);
  color: var(--on-black);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }  /* width/height attributes reserve space, CSS keeps the ratio */
a { color: inherit; }
:focus-visible { outline: 3px solid var(--persian-rose); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Skip link for keyboard users */
.skip {
  position: absolute; left: 12px; top: -60px; z-index: 50;
  background: var(--off-white); color: var(--black);
  padding: 12px 18px; border-radius: var(--radius-pill); font-weight: var(--w-heading);
  text-decoration: none;
}
.skip:focus { top: 12px; }

/* Type roles */
.title {
  font-weight: var(--w-title);
  text-transform: uppercase;
  letter-spacing: var(--track-title);
  line-height: 1.05;
}
.heading { font-weight: var(--w-heading); line-height: 1.25; }
.sub { font-weight: var(--w-sub); }
.eyebrow {
  font-weight: var(--w-heading);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: var(--track-eyebrow);
}
.lede { font-size: 1.125rem; color: var(--on-black-muted); max-width: 38ch; }

/* Buttons — only contrast-safe pairings */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); padding: 0 26px;
  border: 0; border-radius: var(--radius-pill);
  font: var(--w-heading) var(--text-sm) / 1 var(--font);
  text-decoration: none; cursor: pointer;
  transition: transform .15s ease, filter .15s ease;
}
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: scale(.97); }
.btn-hot { background: var(--hot-purple); color: var(--on-hot); }
.btn-violet { background: var(--blue-violet); color: var(--on-violet); }
.btn-honey { background: var(--honey-flower); color: var(--on-honey); }
.btn-line { background: transparent; color: currentColor; box-shadow: inset 0 0 0 2px currentColor; }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: var(--text-xs); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(0, 0, 0, .92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(253, 253, 253, .14);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 68px; }
.brand { display: flex; align-items: center; color: var(--off-white); text-decoration: none; }
.brand svg { width: 76px; height: auto; }
.nav { display: flex; align-items: center; gap: 10px; }
.nav-links { display: none; list-style: none; padding: 0; }
.nav-links a { display: block; padding: 10px 12px; text-decoration: none; font-weight: var(--w-sub); font-size: var(--text-sm); border-radius: 10px; }
.nav-links a:hover { background: rgba(253, 253, 253, .08); }
.menu-btn {
  display: inline-grid; place-items: center; width: var(--tap); height: var(--tap);
  border-radius: 50%; border: 1.5px solid rgba(253, 253, 253, .4);
  background: transparent; color: var(--off-white); cursor: pointer;
}
.menu-btn svg { width: 20px; height: 20px; }
.menu-btn[aria-expanded="true"] { background: var(--off-white); color: var(--black); }
/* Mobile: links drop down under the header when the menu is open */
.nav-links.open {
  display: block; position: absolute; left: 0; right: 0; top: 68px;
  background: var(--black); border-bottom: 1px solid rgba(253, 253, 253, .14);
  padding: 8px var(--gutter) 18px;
}
.nav-links.open a { padding: 14px 4px; font-size: var(--text); border-bottom: 1px solid rgba(253, 253, 253, .1); border-radius: 0; }

/* Sections framed by the guide's thin rules */
.section { padding: clamp(56px, 9vw, 96px) 0; }
.rule-title {
  border-top: var(--rule); border-bottom: var(--rule);
  padding: 14px 0; margin-bottom: 32px; text-align: center;
  font-size: clamp(1.3rem, 4.6vw, 2.1rem);
}
.light { background: var(--off-white); color: var(--on-light); }
.light .lede { color: var(--on-light-muted); }
.light a:not(.btn) { color: var(--on-light-link); }

/* Cards */
.card { border-radius: var(--radius); overflow: hidden; background: #111; }
.light .card { background: transparent; border: 1.5px solid var(--black); }
.card-body { padding: 22px 22px 26px; }
.card-body .eyebrow { color: var(--on-black-accent); }
.light .card-body .eyebrow { color: var(--cobalt); }
.card-body h3 { font-size: 1.35rem; margin: 6px 0 8px; }
.card-body p { color: var(--on-black-muted); }
.light .card-body p { color: var(--on-light-muted); }
.card img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }

/* The F.I.T concepts — the guide's concept logos (home, app) */
.concepts-lede { margin: 0 auto 36px; text-align: center; max-width: 50ch; }
.concept-grid {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 20px; align-items: center;
}
.concept-grid img { width: 100%; max-width: 210px; margin: 0 auto; }
.concept-grid li { text-align: center; }
.concept-name { display: block; margin-top: 10px; font-weight: var(--w-heading); font-size: var(--text-sm); }

/* Tilted, black-framed photo — the guide's signature treatment */
.tilt { border: 12px solid var(--black); outline: 2px solid rgba(253, 253, 253, .85); transform: rotate(3deg); }

/* Footer */
.site-footer { background: var(--black); border-top: 1px solid rgba(253, 253, 253, .14); padding: 56px 0 40px; }
.site-footer .wrap { display: grid; gap: 32px; }
.footer-logo { width: 150px; }
.footer-cols { display: grid; gap: 28px; }
.footer-cols h2 { font-size: var(--text-xs); margin-bottom: 10px; color: var(--on-black-muted); }
.footer-cols ul { list-style: none; padding: 0; display: grid; gap: 6px; }
.footer-cols a { text-decoration: none; }
.footer-cols a:hover { text-decoration: underline; }
.footer-cols .handle { color: var(--on-black-muted); font-size: var(--text-sm); }
.legal { grid-column: 1 / -1; font-size: var(--text-xs); color: var(--on-black-muted); border-top: 1px solid rgba(253, 253, 253, .14); padding-top: 20px; }

/* Short full-height message pages: 404, offline */
.notice {
  min-height: 62vh; display: grid; place-items: center; text-align: center;
  background:
    radial-gradient(ellipse at center, rgba(0, 0, 0, .78) 0%, rgba(0, 0, 0, .5) 60%, rgba(0, 0, 0, .25) 100%),
    var(--black) url(/assets/img/particles-1280.webp) center / cover no-repeat;
}
.notice .wrap { max-width: 640px; padding-top: 64px; padding-bottom: 64px; }
.notice h1 { font-size: clamp(2.2rem, 9vw, 4rem); margin: 12px 0 16px; }
.notice .eyebrow { color: var(--on-black-accent); }
.notice .lede { margin: 0 auto 28px; }

.nav-links a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--persian-rose); text-decoration-thickness: 3px; text-underline-offset: 8px; }

@media (min-width: 1080px) {
  .nav-links { display: flex; gap: 2px; }
  .nav-links .nav-extra { display: none; }
  .menu-btn { display: none; }
}

@media (min-width: 900px) {
  .concept-grid { grid-template-columns: repeat(6, 1fr); gap: 24px; }
  .brand svg { width: 88px; }
  .footer-cols { grid-template-columns: repeat(3, 1fr); }
  .site-footer .wrap { grid-template-columns: 220px 1fr; align-items: start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
}
