/* Leeway Studio — leewaystudio.ca
   Built to the brand kit (navy, final) and its approved website layout. Mobile first. */

@font-face { font-family: "Jost"; src: url("assets/fonts/jost-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("assets/fonts/jost-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Jost"; src: url("assets/fonts/jost-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("assets/fonts/dm-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
  /* brand kit tokens */
  --navy: #151F37;
  --navy-black: #0B1222;
  --paper: #F4F1EC;
  --white: #FFFFFF;
  --tint: #D9D8D6;
  --navy-light: #363E53;
  --nav-blue: #5268A0;
  --blue: #7B91C2;
  --steel: #202F4F;
  --muted: #6B675F;
  --line: #DDD8D0;
  --radius-button: 12px;

  --font: "Jost", system-ui, sans-serif;
  --mono: "DM Mono", ui-monospace, monospace;

  /* type */
  --fs-label: 0.75rem;                                     /* 12, DM Mono caps */
  --fs-small: 0.875rem;                                    /* 14 */
  --fs-body: 1.0625rem;                                    /* 17 */
  --fs-item: 1.25rem;                                      /* 20 */
  --fs-card: 1.5rem;                                       /* 24 */
  --fs-title: clamp(2rem, 1.35rem + 2.2vw, 3.25rem);       /* 32–52 */
  --fs-hero: clamp(1.25rem, 0.55rem + 2.9vw, 3.25rem);     /* 20–52 */

  --margin: clamp(22px, 5vw, 120px);
  --gutter: clamp(16px, 2vw, 28px);
  --section: clamp(72px, 9vw, 128px);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--paper);
  color: var(--navy-black);
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, h4 { font-weight: inherit; text-wrap: balance; }
p { text-wrap: pretty; }
:target { scroll-margin-top: 1rem; }
::selection { background: var(--navy); color: var(--paper); }
:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; }
.site-header :focus-visible, .hero :focus-visible, .section--navy :focus-visible, .card--pick :focus-visible, .site-footer :focus-visible { outline-color: var(--paper); }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -100px; z-index: 30; padding: 12px 16px; background: var(--paper); color: var(--navy); border-radius: var(--radius-button); font-size: var(--fs-small); }
.skip:focus { top: 12px; }

.wrap { width: min(100% - 2 * var(--margin), 1200px); margin-inline: auto; }

/* ---------- type pieces ---------- */
.label {
  font-family: var(--mono);
  font-size: var(--fs-label);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.4;
}
.title {
  font-size: var(--fs-title);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.01em;
}
.label + .title { margin-top: 18px; }
.num, .kind { font-family: var(--mono); font-size: var(--fs-label); letter-spacing: 0.06em; color: var(--muted); }

/* ---------- buttons and links ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border: 1.5px solid transparent;
  border-radius: var(--radius-button);
  font: 500 0.8125rem/1 var(--font);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 140ms var(--ease-out), background-color 180ms ease, color 180ms ease, border-color 180ms ease;
}
.btn:active { transform: scale(0.97); }
.btn--paper { background: var(--paper); color: var(--navy); }
.btn--ghost { background: transparent; color: var(--paper); border-color: rgba(244, 241, 236, 0.35); }
.btn--navy { background: var(--navy); color: var(--paper); }
.btn--nav { background: transparent; color: var(--blue); border-color: var(--nav-blue); min-height: 42px; padding: 0 20px; }
.btn--blue { background: var(--blue); color: var(--navy-black); }

.text-link { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.25em; }

@media (hover: hover) and (pointer: fine) {
  .btn--paper:hover { background: var(--white); }
  .btn--ghost:hover { border-color: var(--paper); }
  .btn--navy:hover { background: var(--navy-light); }
  .btn--nav:hover { background: var(--nav-blue); color: var(--paper); }
  .btn--blue:hover { background: var(--paper); }
  .nav-link:hover { color: var(--paper); }
  .text-link:hover { text-decoration-thickness: 2px; }
}

/* ---------- header (navy-black, three columns) ---------- */
.site-header {
  position: relative;
  z-index: 20;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--gutter);
  padding: 18px var(--margin);
  background: var(--navy-black);
  color: var(--tint);
  border-bottom: 1px solid var(--steel);
}
.brand { grid-column: 2; }
.brand img { width: 150px; }
.nav-left, .nav-right { display: none; }
.nav-link { font-size: var(--fs-small); text-decoration: none; transition: color 180ms ease; }

.menu { grid-column: 3; justify-self: end; }
.menu summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-right: -10px;
}
.menu summary::-webkit-details-marker { display: none; }
.burger, .burger::before, .burger::after, .burger > span { display: block; width: 22px; height: 1.5px; background: var(--nav-blue); }
.burger { position: relative; background: transparent; }
.burger::before, .burger::after { content: ""; position: absolute; left: 0; transition: transform 200ms var(--ease-out); }
.burger::before { top: -7px; }
.burger::after { top: 7px; }
.burger > span { transition: opacity 150ms ease; }
.menu[open] .burger > span { opacity: 0; }
.menu[open] .burger::before { transform: translateY(7px) rotate(45deg); }
.menu[open] .burger::after { transform: translateY(-7px) rotate(-45deg); }
.menu:not([open]) .menu-panel { display: none; }
.menu-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  display: grid;
  gap: 4px;
  padding: 16px var(--margin) 28px;
  background: var(--navy-black);
  border-bottom: 1px solid var(--steel);
}
.menu-panel a:not(.btn) { color: var(--paper); text-decoration: none; font-size: var(--fs-card); font-weight: 300; padding: 8px 0; }
.menu-panel .btn { margin-top: 16px; }

@media (min-width: 64em) {
  .site-header { padding-block: 22px; }
  .brand img { width: 172px; }
  .nav-left { display: flex; gap: 32px; justify-self: start; }
  .nav-right { display: flex; align-items: center; gap: 28px; justify-self: end; }
  .menu { display: none; }
}

/* ---------- hero (navy-black, wordmark only) ---------- */
.hero {
  display: grid;
  justify-items: center;
  padding: clamp(80px, 11vw, 150px) var(--margin) clamp(64px, 9vw, 128px);
  background: var(--navy-black);
  color: var(--white);
  text-align: center;
}
.hero-rule { display: block; width: 64px; height: 1px; background: rgba(255, 255, 255, 0.35); }
.hero-title {
  margin: 26px 0;
  font-size: var(--fs-hero);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: 0.38em;
  margin-right: -0.38em;          /* tracking adds space after the last letter; this keeps it centred */
  text-transform: uppercase;
}
.hero-actions { display: grid; gap: 12px; width: 100%; margin-top: 44px; }
.hero-actions .btn { width: 100%; min-height: 52px; }

@media (min-width: 48em) {
  .hero-title { margin: 32px 0; }
  .hero-actions { display: flex; justify-content: center; width: auto; margin-top: 56px; }
  .hero-actions .btn { width: auto; min-height: 48px; }
}

/* ---------- sections ---------- */
.section { padding: var(--section) 0; }
.section--white { background: var(--white); }
.section--paper { background: var(--paper); }
.section--navy { background: var(--navy); color: var(--paper); }
.section--navy .label { color: var(--blue); }

.section-head { display: grid; gap: 20px; margin-bottom: 44px; }
.section-intro { color: var(--navy-black); font-size: var(--fs-body); line-height: 1.65; max-width: 44ch; }

@media (min-width: 64em) {
  .section-head {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--gutter);
    align-items: end;
    margin-bottom: 56px;
  }
  .section-head-main { grid-column: 1 / span 7; }
  .section-intro { grid-column: 8 / -1; padding-bottom: 0.4em; }
}

/* what we do: four-across list under thin rules */
.caps { display: grid; gap: 28px var(--gutter); }
.cap { border-top: 1px solid var(--line); padding-top: 18px; }
.cap h3 { font-size: var(--fs-item); font-weight: 400; line-height: 1.3; }
.cap p { margin-top: 8px; font-size: var(--fs-body); line-height: 1.6; max-width: 36ch; }
@media (min-width: 40em) { .caps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64em) { .caps { grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: 40px; } }

/* cards */
.group-title { font-size: var(--fs-item); font-weight: 400; margin: 0 0 18px; }
.group-title ~ .group-title, .cards + .group-title { margin-top: 56px; }
.group-note { display: block; margin-top: 4px; font-size: var(--fs-small); color: var(--muted); }
.cards { display: grid; gap: 14px; }
.card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 22px 22px 28px;
}
.section--white .card { background: var(--white); }
.card-top { display: flex; justify-content: space-between; gap: 12px; }
.card-name { margin-top: 30px; font-size: var(--fs-card); font-weight: 400; line-height: 1.25; }
.card-price { margin-top: 6px; font-weight: 500; font-variant-numeric: tabular-nums; }
.card-desc { margin-top: 14px; line-height: 1.6; }
.card-plus { margin-top: 20px; font-size: var(--fs-small); font-weight: 500; }
.card-list { margin-top: 18px; font-size: var(--fs-small); line-height: 1.5; }
.card-plus + .card-list { margin-top: 10px; }
.card-list li { padding: 10px 0; border-top: 1px solid var(--line); }
.card-list li:last-child { border-bottom: 1px solid var(--line); }

.card--pick { background: var(--navy); border-color: var(--navy); color: var(--paper); }
.card--pick .num { color: var(--tint); }
.card--pick .kind { color: var(--blue); }
.card--pick .card-list li { border-color: var(--navy-light); }

@media (min-width: 48em) {
  .cards--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; }
  .cards--2 .card + .card { border-left: 0; }
  .card { padding: 26px 26px 32px; }
}
@media (min-width: 64em) {
  .cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
  .cards--3 .card + .card { border-left: 0; }
  .cards--3 .card--pick + .card { border-left: 0; }
}

.note-row { display: grid; gap: 8px; margin-top: 28px; font-size: var(--fs-small); line-height: 1.55; }
.note-row p:last-child { max-width: 70ch; }
@media (min-width: 48em) { .note-row { grid-template-columns: 140px 1fr; gap: 24px; align-items: baseline; } }

/* split: heading on the left, content on the right */
.split { display: grid; gap: 40px; }
@media (min-width: 64em) {
  .split { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: start; }
  .split-side { grid-column: 1 / span 6; padding-right: var(--gutter); }
  .split > :last-child { grid-column: 7 / -1; }
}

/* simple, honest pricing: rows under thin rules */
.row { border-top: 1px solid var(--line); padding: 20px 0; display: grid; gap: 6px; }
.row:last-child { border-bottom: 1px solid var(--line); }
.row h3 { font-size: var(--fs-item); font-weight: 400; line-height: 1.35; }
.row p { font-size: var(--fs-body); line-height: 1.6; max-width: 48ch; }
@media (min-width: 48em) { .row { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--gutter); } }

/* how it works: four steps under heavier rules */
.steps { display: grid; gap: 32px var(--gutter); }
.step { border-top: 1.5px solid var(--navy); padding-top: 18px; }
.step h3 { margin-top: 14px; font-size: var(--fs-item); font-weight: 400; }
.step p { margin-top: 8px; font-size: var(--fs-body); line-height: 1.6; max-width: 32ch; }
@media (min-width: 40em) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64em) { .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* why leeway (navy): points two across */
.points { display: grid; gap: 28px var(--gutter); }
.point { border-top: 1px solid var(--navy-light); padding-top: 18px; }
.point h3 { font-size: var(--fs-item); font-weight: 400; line-height: 1.3; }
.point p { margin-top: 8px; font-size: var(--fs-body); line-height: 1.6; color: var(--tint); max-width: 36ch; }
@media (min-width: 40em) { .points { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 36px; } }

/* contact */
.contact { display: grid; gap: 48px; }
.contact-copy { margin-top: 20px; max-width: 46ch; font-size: var(--fs-body); line-height: 1.65; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; margin-top: 28px; }
.contact-list div { border-top: 1px solid var(--line); padding: 14px 0; }
.contact-list div:last-child { border-bottom: 1px solid var(--line); }
.contact-list dd { margin-top: 4px; font-size: var(--fs-item); }
@media (min-width: 64em) {
  .contact { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: end; }
  .contact-main { grid-column: 1 / span 7; }
  .contact-list { grid-column: 9 / -1; }
}

/* ---------- footer (navy-black, logo in blue) ---------- */
.site-footer { background: var(--navy-black); color: var(--tint); padding: 32px 0 36px; }
.footer-inner { display: grid; gap: 18px; }
.footer-logo { width: 150px; }
.footer-cta { width: 100%; min-height: 52px; margin-top: 10px; }
.footer-contact, .footer-copy { font-size: var(--fs-small); }
.footer-contact a { text-decoration: none; }
@media (min-width: 48em) {
  .site-footer { padding: 28px 0; }
  .footer-inner { grid-template-columns: auto 1fr; align-items: center; }
  .footer-cta, .footer-contact { display: none; }
  .footer-copy { justify-self: end; }
}

/* ---------- motion (content stays visible without JavaScript and under reduced motion) ---------- */
@media (prefers-reduced-motion: no-preference) {
  /* signature: the wordmark settles in between its two rules */
  .js .hero-rule { transform: scaleX(0.2); opacity: 0; animation: rule-open 900ms var(--ease-expo) 150ms forwards; }
  .js .hero-title { opacity: 0; transform: translateY(10px); animation: settle 1000ms var(--ease-out) 250ms forwards; }
  .js .hero-actions { opacity: 0; transform: translateY(12px); animation: settle 800ms var(--ease-out) 650ms forwards; }

  /* sections: each block rises into place once, staggered */
  .js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 650ms var(--ease-out), transform 750ms var(--ease-out); transition-delay: calc(var(--d, 0) * 80ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }

  /* card lists draw their rules in after the card arrives */
  .js .card[data-reveal] .card-list li { opacity: 0; transition: opacity 500ms ease; }
  .js .card[data-reveal].is-in .card-list li { opacity: 1; transition-delay: calc(var(--d, 0) * 80ms + 250ms); }
}
@keyframes rule-open { to { transform: none; opacity: 1; } }
@keyframes settle { to { opacity: 1; transform: none; } }
