/* Base, layout and shared components */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--slate-600);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
/* <picture> only switches formats (AVIF/WebP); layout rules target the <img> directly */
picture { display: contents; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; }

h1, h2, h3 {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
}
h1 { font-size: var(--fs-h1); line-height: 1.05; letter-spacing: -.03em; }
h2 { font-size: var(--fs-h2); line-height: 1.1; letter-spacing: -.025em; }
h3 { font-size: var(--fs-h3); line-height: 1.2; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0; }
em { font-style: italic; }

:focus-visible {
  outline: 2px solid var(--red-600);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}
.on-dark :focus-visible { outline-color: var(--red-500); }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  padding: 12px 20px;
  background: var(--navy-950); color: var(--white);
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 16px; }

/* Layout */
.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: var(--section-y); }
.section--white { background: var(--white); }
.section--paper { background: var(--paper); }
.section--dark { background: var(--navy-950); color: var(--mist); }
.section--dark h2, .section--dark h3 { color: var(--white); }

.section-head { max-width: 40rem; }
.section-head h2 { margin-top: var(--space-4); }
.section-head .lead { margin-top: var(--space-5); }
.section-head--split {
  display: flex; flex-wrap: wrap; align-items: flex-end;
  justify-content: space-between; gap: var(--space-5);
  max-width: none;
}
.section-head--split > div { max-width: 40rem; }

.lead { font-size: var(--fs-lead); line-height: 1.6; max-width: 36rem; }

/* Eyebrow: red square marker + spaced caps */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  margin: 0;
  color: var(--ink);
  font-size: var(--fs-eyebrow); font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase; line-height: 1.2;
}
.eyebrow::before {
  content: ""; width: 8px; height: 8px; flex: none;
  background: var(--red-600);
}
.section--dark .eyebrow, .on-dark .eyebrow { color: var(--white); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 28px;
  border: 1.5px solid transparent; border-radius: var(--radius-xs);
  font-size: var(--fs-small); font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; text-decoration: none; line-height: 1;
  cursor: pointer;
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.btn .arrow { transition: transform var(--dur) var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
.btn--primary { background: var(--red-600); color: var(--white); }
.btn--primary:hover { background: var(--red-700); }
.btn--secondary { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--secondary:hover { background: var(--ink); color: var(--white); }
.on-dark .btn--secondary, .section--dark .btn--secondary { border-color: var(--white); color: var(--white); }
.on-dark .btn--secondary:hover, .section--dark .btn--secondary:hover { background: var(--white); color: var(--ink); }
.btn--ghost { border-color: var(--line-dark); color: var(--white); }
.btn--ghost:hover { border-color: var(--white); }
@media (min-width: 1024px) { .btn { min-height: 52px; } }

.text-link {
  min-height: 44px;
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ink);
  font-size: var(--fs-small); font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; text-decoration: none;
}
.text-link .arrow { transition: transform var(--dur) var(--ease); }
.text-link:hover { text-decoration: underline; text-underline-offset: 6px; }
.text-link:hover .arrow { transform: translateX(4px); }
.section--dark .text-link { color: var(--white); }

/* Diagonal stripes motif (from the "4" in the logo) */
.stripes { width: 56px; height: 36px; color: var(--red-600); }

/* Stripes "draw" in from the left when they enter the viewport */
/* clip-path keeps the element's box intact, so IntersectionObserver always sees it */
.js .draw { clip-path: inset(0 100% 0 0); }
.js .draw.is-in { clip-path: inset(0 0 0 0); transition: clip-path 500ms var(--ease); }

/* Open frame corner (from the business card): max one key image per page */
.frame-corner {
  position: absolute; left: -12px; bottom: -12px; z-index: 1;
  width: 88px; height: 88px;
  border-left: 2px solid var(--red-600); border-bottom: 2px solid var(--red-600);
  pointer-events: none;
}
@media (min-width: 1024px) { .frame-corner { left: -20px; bottom: -20px; width: 120px; height: 120px; } }

/* "Coming soon" panel (portfolio without real photos yet) */
.coming-soon {
  position: relative; overflow: hidden;
  display: grid; gap: var(--space-4); justify-items: start;
  padding: var(--space-7) var(--space-5);
  background: var(--white);
  border: 1px solid var(--stone-200); border-radius: var(--radius-sm);
}
.coming-soon h2, .coming-soon h3 { max-width: 20ch; }
.coming-soon p { max-width: 34rem; }
.coming-soon__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-5); margin-top: var(--space-3); }
.coming-soon__stripes {
  position: absolute; right: var(--space-5); top: var(--space-5);
  width: 72px; height: 46px; color: var(--red-600);
}
.coming-soon--dark { background: var(--navy-900); border-color: var(--line-dark); }
.coming-soon--dark h3 { color: var(--white); }
.coming-soon--dark p { color: var(--mist); }
@media (min-width: 768px) { .coming-soon { padding: var(--space-8) var(--space-7); } }

/* Placeholder for missing real content */
.tbd {
  display: inline-block;
  padding: 2px 8px;
  border: 1px dashed var(--stone-400);
  border-radius: var(--radius-xs);
  color: var(--slate-600);
  font-size: var(--fs-small);
  font-family: var(--font-body);
}

/* Header (always light so the original logo stays legible) */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--stone-200);
  transition: box-shadow var(--dur) var(--ease);
}
.site-header.is-scrolled { box-shadow: 0 6px 24px rgba(11, 21, 48, .08); }
.site-header__inner {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-5);
  height: var(--header-h);
  transition: height var(--dur) var(--ease);
}
.site-header__logo img { width: 96px; height: auto; }
.site-nav { display: none; }
.site-header__actions { display: none; }

.menu-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; padding: 0;
  border: 1px solid var(--stone-200); border-radius: var(--radius-xs);
  background: var(--white); color: var(--ink); cursor: pointer;
}
.menu-toggle__bars, .menu-toggle__bars::before, .menu-toggle__bars::after {
  display: block; width: 18px; height: 2px; background: currentColor; content: "";
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.menu-toggle__bars { position: relative; }
.menu-toggle__bars::before { position: absolute; top: -6px; }
.menu-toggle__bars::after { position: absolute; top: 6px; }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars { background: transparent; }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::after { transform: translateY(-6px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: var(--header-h) 0 0 0; z-index: 49;
  display: flex; flex-direction: column; gap: var(--space-6);
  padding: var(--space-6) var(--gutter) var(--space-8);
  background: var(--paper);
  overflow-y: auto;
  transform: translateX(100%);
  visibility: hidden;
  transition: transform 300ms var(--ease), visibility 0s linear 300ms;
}
.mobile-menu.is-open { transform: none; visibility: visible; transition: transform 300ms var(--ease); }
.mobile-menu ul { list-style: none; margin: 0; padding: 0; }
.mobile-menu li + li { border-top: 1px solid var(--stone-200); }
.mobile-menu a:not(.btn) {
  display: block; padding: 16px 0;
  color: var(--ink); font-family: var(--font-display); font-size: 1.75rem; font-weight: 700; letter-spacing: -.02em; text-decoration: none;
}
.mobile-menu .btn { width: 100%; }
body.menu-open { overflow: hidden; }

@media (min-width: 1024px) {
  .site-header.is-scrolled { --header-h: 72px; }
  .site-header__logo img { width: 120px; }
  .menu-toggle, .mobile-menu { display: none; }
  .site-nav { display: block; }
  .site-nav ul { display: flex; gap: var(--space-6); list-style: none; margin: 0; padding: 0; }
  .site-nav a {
    position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0;
    color: var(--ink); font-size: .9375rem; font-weight: 600; text-decoration: none;
  }
  .site-nav a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 2px;
    background: var(--red-600); transform: scaleX(0); transform-origin: left;
    transition: transform var(--dur) var(--ease);
  }
  .site-nav a:hover::after, .site-nav a[aria-current="page"]::after { transform: scaleX(1); }
  .site-header__actions { display: flex; align-items: center; gap: var(--space-5); }
  .site-header__phone {
    color: var(--ink); font-weight: 700; font-size: .9375rem; text-decoration: none; white-space: nowrap;
  }
  .site-header__phone:hover { color: var(--navy-700); }
}

/* Footer (light) */
.site-footer { background: var(--paper); border-top: 1px solid var(--stone-200); padding-block: var(--space-8) var(--space-6); }
.site-footer__grid { display: grid; gap: var(--space-7); }
.site-footer__brand img { width: 140px; }
.site-footer__brand p { margin-top: var(--space-4); max-width: 22rem; }
.site-footer__tagline { color: var(--ink); font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; letter-spacing: -.01em; }
.site-footer h2 {
  margin-bottom: var(--space-4);
  color: var(--ink); font-family: var(--font-body);
  font-size: var(--fs-eyebrow); font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.site-footer a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.site-footer li > .tbd { margin-top: 10px; }
.site-footer a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.site-footer__bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-4);
  margin-top: var(--space-8); padding-top: var(--space-5);
  border-top: 1px solid var(--stone-200);
  font-size: var(--fs-small);
}
@media (min-width: 768px) {
  .site-footer__grid { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; }
}

/* Mobile contact bar */
.contact-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: grid; grid-template-columns: 1fr 1fr 1.3fr;
  background: var(--navy-950);
  border-top: 1px solid var(--line-dark);
  padding-bottom: env(safe-area-inset-bottom);
  transform: translateY(110%);
  transition: transform var(--dur) var(--ease);
}
.contact-bar.is-visible { transform: none; }
.no-js .contact-bar { transform: none; }
.contact-bar a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 56px;
  color: var(--white); font-size: var(--fs-small); font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase; text-decoration: none;
}
.contact-bar a + a { border-left: 1px solid var(--line-dark); }
.contact-bar a.is-primary { background: var(--red-600); border-left: 0; }
.contact-bar svg { width: 18px; height: 18px; }
@media (min-width: 1024px) { .contact-bar { display: none; } }
@media (max-width: 1023px) { body { padding-bottom: 56px; } }

/* Reveal on scroll (only hidden when JS is running) */
.js .reveal { opacity: 0; transform: translateY(16px); }
.js .reveal.is-in {
  opacity: 1; transform: none;
  transition: opacity var(--dur-reveal) var(--ease), transform var(--dur-reveal) var(--ease);
  transition-delay: calc(var(--i, 0) * 60ms);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0ms !important; animation-duration: 0ms !important; }
  .js .reveal { opacity: 1; transform: none; }
  .js .draw { clip-path: none; }
}
