/* COOLHAND Studio — hand-written stylesheet, 2026 redesign.
   Monochrome, photography-led, road-case utilitarian. One variable font
   (Archivo, weight 100-900 × width 62-125%) does display and body duty. */

@font-face {
  font-family: "Archivo";
  src: url(/static/fonts/archivo.woff2) format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --black: #000;
  --ink: #111;
  --paper: #fff;
  --rule: #e3e3e3;
  --muted: #6b6b6b;        /* 5.3:1 on white */
  --muted-dark: #9c9c9c;   /* 7.4:1 on black */
  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --container: 1320px;
  --pad: clamp(1rem, 4vw, 2.5rem);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --z-nav: 10;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Reserve the scrollbar gutter on every page so the layout doesn't
   shift sideways navigating between short and long pages. */
html {
  scrollbar-gutter: stable;
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--ink);
  text-decoration: none;
}

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* On the black nav, currentColor is near-black for the brand link and
   toggle — force a visible ring. */
.site-nav :focus-visible {
  outline-color: #fff;
}

.icon {
  width: 1.5rem;
  height: 1.5rem;
  display: block;
}

.skip-link {
  position: absolute;
  left: -9999px;
  background: var(--paper);
  color: var(--ink);
  padding: 0.75rem 1.25rem;
  font-weight: 600;
}

.skip-link:focus {
  left: 0;
  top: 0;
  z-index: calc(var(--z-nav) + 1);
}

/* ── Display voice ───────────────────────────────────────────────────── */

.display {
  font-stretch: 125%;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1.02;
  text-wrap: balance;
}

/* ── Nav ─────────────────────────────────────────────────────────────── */

.site-nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  background: var(--black);
  /* Clear space ≈ the wordmark's own height above and below (logo
     clear-space rule); the brand link's own 0.5rem padding completes it. */
  padding: clamp(0.75rem, 1.8vw, 1.25rem) var(--pad);
}

.brand img {
  display: block;
  padding: 0.5rem 0;
}

.menu {
  display: flex;
  gap: clamp(0.25rem, 1.5vw, 1.25rem);
}

.menu a {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  font-stretch: 110%;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.5rem 0.25rem;
  text-decoration: underline 2px transparent;
  text-underline-offset: 6px;
  transition: text-decoration-color 0.2s var(--ease-out);
}

.menu a:hover,
.menu a[aria-current] {
  text-decoration-color: #fff;
}

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 0.5rem;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #fff;
  margin: 4px 0;
}

@media (max-width: 767px) {
  .nav-toggle {
    display: block;
  }
  .menu {
    display: none;
    flex-direction: column;
    width: 100%;
    gap: 0;
    padding: 0.75rem 0 1rem;
  }
  .menu.open {
    display: flex;
  }
  .menu a {
    padding: 0.625rem 0.25rem;
    font-size: 1rem;
  }
}

/* ── Layout ──────────────────────────────────────────────────────────── */

main {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--pad) clamp(4rem, 8vw, 7rem);
}

.page-title {
  font-size: clamp(1.25rem, 1.8vw, 1.5rem);
  margin: clamp(2.25rem, 4.5vw, 3rem) 0 clamp(1.5rem, 3vw, 2.25rem);
}

/* ── One-page layout ─────────────────────────────────────────────────── */

main.home {
  max-width: none;
  padding: 0 0 clamp(4rem, 8vw, 7rem);
}

/* Anchor sections; scroll-margin keeps headings clear of the sticky nav. */
.section {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--pad);
  scroll-margin-top: 6.5rem;
}

.section + .section {
  margin-top: clamp(3.5rem, 7vw, 6rem);
}

.hero-img {
  display: block;
  width: 100%;
  height: clamp(420px, 72vh, 820px);
  object-fit: cover;
  animation: hero-img 0.9s var(--ease-out) both;
}

.home-intro {
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(3rem, 7vw, 5.5rem) var(--pad) 0;
}

.home-intro h1 {
  margin: 0;
  font-size: clamp(1.375rem, 2.2vw, 1.75rem);
  animation: rise 0.7s var(--ease-out) 0.1s both;
}

.home-intro p {
  max-width: 44ch;
  margin: 1.5rem 0 0;
  font-size: clamp(1.0625rem, 1.3vw, 1.1875rem);
  font-weight: 550;
  line-height: 1.5;
  text-wrap: pretty;
  animation: rise 0.7s var(--ease-out) 0.2s both;
}

.home-intro .intro-contact {
  max-width: none;
  margin-top: 2.25rem;
  font-size: clamp(1rem, 1.4vw, 1.1875rem);
  font-weight: 650;
  animation-delay: 0.3s;
}

.intro-contact a {
  text-decoration: underline 2px;
  text-underline-offset: 6px;
  transition: text-decoration-color 0.2s var(--ease-out);
}

.intro-contact a:hover {
  text-decoration-color: transparent;
}

@keyframes hero-img {
  from {
    opacity: 0;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
}

/* ── Info / footer ───────────────────────────────────────────────────── */

.site-footer {
  margin-top: auto;
  background: var(--black);
  color: #fff;
  padding: clamp(3rem, 6vw, 4.5rem) var(--pad) 2rem;
}

.site-footer .inner {
  max-width: var(--container);
  margin: 0 auto;
}

.info-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2.5rem 2rem;
  margin: 0;
}

.info-list > div {
  margin: 0;
}

.info-list dt {
  font-size: 0.8rem;
  font-weight: 600;
  font-stretch: 110%;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted-dark);
  margin: 0 0 0.75rem;
}

.info-list dd {
  font-size: clamp(1rem, 1.3vw, 1.125rem);
  font-weight: 600;
  line-height: 1.5;
  margin: 0;
}

.info-list a {
  color: #fff;
  text-decoration: underline 2px transparent;
  text-underline-offset: 5px;
  transition: text-decoration-color 0.2s var(--ease-out);
}

.info-list a:hover {
  text-decoration-color: #fff;
}

.site-footer .colophon {
  margin: clamp(3rem, 5vw, 4rem) 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid #2a2a2a;
  font-size: 0.85rem;
  color: var(--muted-dark);
}

/* ── Galleries ───────────────────────────────────────────────────────── */

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-flow: dense;
  gap: clamp(1rem, 2vw, 1.5rem);
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Galleries compose as blocks of three: one 2×2 feature + two stacked
   singles (or three across as a rest beat). Each <ul class="gallery">
   is one composition; generous space between them lets the
   high-contrast photography breathe. */
.gallery + .gallery {
  margin-top: clamp(2.5rem, 5vw, 4.5rem);
}

.gallery .feature {
  grid-column: span 2;
  grid-row: span 2;
}

@media (max-width: 991px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }
  .gallery .feature {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (max-width: 600px) {
  .gallery {
    grid-template-columns: 1fr;
  }
}

/* Contact-sheet variant: a uniform grid (4-up on desktop), no features. */
.gallery-sheet {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 991px) {
  .gallery-sheet {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 600px) {
  .gallery-sheet {
    grid-template-columns: repeat(2, 1fr);
  }
}

.gallery a {
  display: block;
  height: 100%;
  cursor: zoom-in;
}

.gallery img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  transition: opacity 0.3s var(--ease-out);
}

.gallery .feature img {
  aspect-ratio: auto;
}

.gallery a:hover img {
  opacity: 0.85;
}

/* ── Equipment / 404 ─────────────────────────────────────────────────── */

.lead {
  max-width: 60ch;
}

.lead p {
  margin: 0 0 1.5rem;
  font-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
  max-width: 52ch;
}

.lead p:first-child {
  font-size: clamp(1.125rem, 1.5vw, 1.3125rem);
  font-weight: 650;
  font-stretch: 105%;
  line-height: 1.4;
  max-width: 44ch;
  margin-bottom: 1.5rem;
  text-wrap: balance;
}

.back-link {
  font-weight: 650;
  text-decoration: underline 2px;
  text-underline-offset: 5px;
}

.brand-logos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  list-style: none;
  max-width: 880px;
  margin: clamp(3rem, 6vw, 5rem) 0 0;
  padding: 0;
}

@media (max-width: 600px) {
  .brand-logos {
    grid-template-columns: repeat(2, 1fr);
  }
  .brand-logos li:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }
}

.brand-logos li {
  display: grid;
  place-items: center;
  background: var(--paper);
  padding: clamp(1.75rem, 4vw, 3rem) clamp(1.25rem, 3vw, 2.25rem);
}

.brand-logos img {
  display: block;
  width: 100%;
  max-width: 150px;
}

/* ── Contact ─────────────────────────────────────────────────────────── */

.contact-links {
  margin: 0 0 clamp(3rem, 5vw, 4rem);
}

.contact-links a {
  display: inline-block;
  font-size: clamp(1.125rem, 1.8vw, 1.5rem);
  font-weight: 750;
  font-stretch: 110%;
  line-height: 1.45;
  text-decoration: underline 2px transparent;
  text-underline-offset: 6px;
  transition: text-decoration-color 0.2s var(--ease-out);
  overflow-wrap: anywhere;
}

.contact-links a:hover {
  text-decoration-color: var(--black);
}

/* ── Lightbox ────────────────────────────────────────────────────────── */

.lightbox {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: 100vw;
  max-height: 100vh;
  width: 100vw;
  height: 100vh;
  display: none;
  align-items: center;
  justify-content: center;
}

.lightbox[open] {
  display: flex;
  opacity: 1;
  transition: opacity 0.25s var(--ease-out);
}

@starting-style {
  .lightbox[open] {
    opacity: 0;
  }
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.94);
}

.lightbox figure {
  margin: 0;
  text-align: center;
}

.lightbox img {
  max-width: calc(100vw - 9rem);
  max-height: calc(100vh - 6rem);
  width: auto;
  height: auto;
}

.lightbox figcaption {
  color: var(--muted-dark);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  margin-top: 0.75rem;
}

.lightbox button {
  background: none;
  border: 0;
  color: #fff;
  cursor: pointer;
  padding: 1rem;
  opacity: 0.75;
  transition: opacity 0.3s var(--ease-out);
}

.lightbox button:hover {
  opacity: 1;
}

.lightbox .lb-close {
  position: fixed;
  top: 0.5rem;
  right: 0.5rem;
}

@media (max-width: 575px) {
  .lightbox img {
    max-width: 100vw;
  }
  .lightbox .lb-prev,
  .lightbox .lb-next {
    position: fixed;
    bottom: 0.5rem;
  }
  .lightbox .lb-prev {
    left: 0.5rem;
  }
  .lightbox .lb-next {
    right: 0.5rem;
  }
}

/* ── Reduced motion ──────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.01ms !important;
  }
}
