/* ==========================================================================
   First Cut Photo — style.css
   Tokens from DESIGN.md. Two saturated colors only: teal + orange.
   ========================================================================== */

:root {
  /* Color — see DESIGN.md "Tokens" */
  --teal: #1A6E68;          /* primary brand: headings, links, accents on light */
  --teal-bright: #79CBBD;   /* accents on dark / over photo */
  --orange: #E07B2C;        /* the action accent: primary CTAs only */
  --on-orange: #331402;     /* text on orange */
  --paper: #F5EEDD;         /* text on dark and over photos */
  --canvas: #F4EFE6;        /* light section background */
  --ink: #16261E;           /* dark sections, primary text on light */
  --fairway: #547040;       /* quiet secondary: hairlines, small accents only */

  /* Type */
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Hanken Grotesk", "Inter", system-ui, sans-serif;

  /* Scale: magazine-cover headlines, quiet body */
  --size-hero: clamp(2.5rem, 5.5vw + 1rem, 4.75rem);
  --size-h2: clamp(1.875rem, 3vw + 0.75rem, 3rem);
  --size-h3: 1.375rem;
  --size-lead: 1.1875rem;
  --size-body: 1.0625rem;
  --size-small: 0.875rem;
  --size-eyebrow: 0.8125rem;

  /* Space: luxury reads as room */
  --section-pad: clamp(4.5rem, 9vw, 8rem);
  --container: 72rem;
  --container-narrow: 46rem;
}

/* --------------------------------- Base --------------------------------- */

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--size-body);
  line-height: 1.65;
  color: var(--ink);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 550;
  line-height: 1.08;
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
}

h2 { font-size: var(--size-h2); }
h3 { font-size: var(--size-h3); line-height: 1.25; }

p { margin: 0 0 1rem; }

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

figure { margin: 0; }

a { color: var(--teal); }

html { scroll-behavior: smooth; }

:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
  border-radius: 2px;
}

.section-dark :focus-visible,
.hero :focus-visible,
.footer :focus-visible {
  outline-color: var(--teal-bright);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  border-radius: 4px;
  transition: top 120ms ease;
}

.skip-link:focus-visible { top: 1rem; }

/* ------------------------------ Utilities ------------------------------- */

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
}

.container-narrow { max-width: var(--container-narrow); }

.section { padding-block: var(--section-pad); }

.section-light { background: var(--canvas); color: var(--ink); }

.section-dark { background: var(--ink); color: var(--paper); }

.section-dark h2 { color: var(--paper); }

.section-lead {
  font-size: var(--size-lead);
  max-width: 40rem;
  margin-bottom: 2.5rem;
}

/* Eyebrow: field-notes label */
.eyebrow {
  font-size: var(--size-eyebrow);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 1.25rem;
}

.eyebrow-on-dark { color: var(--teal-bright); }

/* Buttons */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  padding: 0.9rem 1.9rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

.btn-primary {
  background: var(--orange);
  color: var(--on-orange);
}

.btn-primary:hover {
  background: color-mix(in srgb, var(--orange), var(--ink) 14%);
}

.btn-ghost {
  background: transparent;
  color: var(--paper);
  border-color: color-mix(in srgb, var(--paper), transparent 40%);
}

.btn-ghost:hover {
  border-color: var(--paper);
  background: color-mix(in srgb, var(--paper), transparent 90%);
}

/* --------------------------------- Hero --------------------------------- */

.hero {
  position: relative;
  min-height: 92svh;
  display: flex;
  flex-direction: column;
  color: var(--paper);
  isolation: isolate;
  overflow: hidden;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

/* Soft dark scrim keeps cream text legible over the photograph.
   The uniform veil matters as much as the gradients: bright skies and clouds
   sit right behind the headline on many golf frames. */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to top, color-mix(in srgb, var(--ink), transparent 20%) 0%, transparent 70%),
    linear-gradient(to bottom, color-mix(in srgb, var(--ink), transparent 45%) 0%, transparent 35%)
    color-mix(in srgb, var(--ink), transparent 62%);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  max-width: var(--container);
  width: 100%;
  margin-inline: auto;
  padding: 1.75rem clamp(1.25rem, 4vw, 2.5rem);
}

.logo {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--paper);
}

.nav-links {
  display: flex;
  gap: 2.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-size: var(--size-eyebrow);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--paper);
}

.nav-links a:hover { color: var(--teal-bright); }

.hero-content {
  margin-top: auto;
  max-width: var(--container);
  width: 100%;
  margin-inline: auto;
  padding: 0 clamp(1.25rem, 4vw, 2.5rem) clamp(3.5rem, 7vw, 6rem);
}

.hero-headline {
  font-size: var(--size-hero);
  max-width: 15ch;
  margin-bottom: 1.25rem;
}

.hero-headline .accent {
  font-style: italic;
  color: var(--teal-bright);
}

.hero-sub {
  font-size: var(--size-lead);
  max-width: 34rem;
  margin-bottom: 2rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ---------------------- Compare: snapshot vs frame ----------------------- */

.compare {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  touch-action: none;
}

.compare-panel img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.compare-after {
  position: absolute;
  inset: 0;
  clip-path: inset(0 0 0 var(--pos));
}

.compare-label {
  position: absolute;
  top: 1rem;
  font-size: var(--size-eyebrow);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink), transparent 20%);
  color: var(--paper);
}

.compare-label-before { left: 1rem; }
.compare-label-after { right: 1rem; }

/* The range input is the real control: native keyboard + touch dragging.
   It sits invisibly over the whole comparison; the handle mirrors its value. */
.compare-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: 2px;
  transform: translateX(-1px);
  background: var(--paper);
  pointer-events: none;
}

.compare-thumb {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  font-size: 1.1rem;
  box-shadow: 0 2px 10px color-mix(in srgb, var(--ink), transparent 60%);
}

.compare-range:focus-visible ~ .compare-handle .compare-thumb {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
}

/* ------------------------------- Gallery -------------------------------- */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(0.75rem, 2vw, 1.5rem);
}

.gallery-item { position: relative; }

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
}

.gallery-wide { grid-column: span 2; }

.gallery-caption {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  font-size: var(--size-eyebrow);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--paper);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink), transparent 30%);
}

/* ----------------------------- How it works ------------------------------ */

.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2.25rem;
  max-width: var(--container-narrow);
}

.step {
  counter-increment: step;
  position: relative;
  padding-left: 4.5rem;
}

/* Numbered markers are earned here: this is a real sequence (DESIGN.md) */
.step::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1px solid var(--fairway);
  color: var(--teal);
  font-family: var(--font-display);
  font-size: 1.25rem;
}

.step h3 { margin-bottom: 0.35rem; }

.step p { margin: 0; max-width: 36rem; }

/* -------------------------------- Trust ---------------------------------- */

.trust-quotes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  margin-bottom: 3rem;
}

.quote {
  margin: 0;
  padding: 2rem;
  border: 1px solid color-mix(in srgb, var(--paper), transparent 82%);
  border-radius: 6px;
}

.quote p {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-style: italic;
  line-height: 1.45;
  margin-bottom: 1.25rem;
}

.quote cite {
  font-style: normal;
  font-size: var(--size-small);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal-bright);
}

.trust-cta { text-align: center; }

/* ------------------------------- Inquiry --------------------------------- */

.inquiry-form {
  display: grid;
  gap: 1.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-field label {
  font-size: var(--size-small);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--teal);
}

.form-field input,
.form-field select {
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid color-mix(in srgb, var(--ink), transparent 70%);
  border-radius: 6px;
  padding: 0.85rem 1rem;
}

.form-field input:focus-visible,
.form-field select:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 1px;
  border-color: var(--teal);
}

.btn-submit {
  justify-self: start;
  font-size: 1.05rem;
}

.form-note {
  font-size: var(--size-small);
  color: color-mix(in srgb, var(--ink), transparent 30%);
  margin: 0;
}

/* -------------------------------- Footer --------------------------------- */

.footer {
  background: var(--ink);
  color: var(--paper);
  padding-block: clamp(3rem, 6vw, 4.5rem);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: 2.5rem;
  align-items: start;
}

.logo-footer { color: var(--paper); }

.footer-tagline {
  margin-top: 1rem;
  max-width: 26rem;
  color: color-mix(in srgb, var(--paper), transparent 25%);
}

.footer-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.footer-nav a,
.footer-contact a {
  color: var(--paper);
  text-decoration: none;
  font-size: var(--size-small);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
}

.footer-nav a:hover,
.footer-contact a:hover { color: var(--teal-bright); }

.footer-fineprint {
  margin-top: 1.25rem;
  font-size: var(--size-small);
  color: color-mix(in srgb, var(--paper), transparent 40%);
}

/* ------------------------------ Responsive ------------------------------- */

@media (max-width: 44rem) {
  .nav-links li:not(:last-child) { display: none; }

  .logo,
  .nav-links a { white-space: nowrap; }

  .logo { font-size: 0.875rem; }

  /* Narrow screens: keep the two compare labels from colliding */
  .compare-label {
    font-size: 0.6875rem;
    padding: 0.35rem 0.7rem;
  }

  .compare-label-after {
    top: auto;
    bottom: 1rem;
  }

  .form-row { grid-template-columns: 1fr; }

  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }

  .gallery-grid { grid-template-columns: 1fr; }

  .gallery-wide { grid-column: auto; }

  .step { padding-left: 3.75rem; }

  .step::before { width: 2.6rem; height: 2.6rem; }
}

/* --------------------------- Reduced motion ------------------------------ */

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }

  /* Comparison degrades to a static side-by-side */
  .compare {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    touch-action: auto;
    overflow: visible;
  }

  .compare-after {
    position: static;
    clip-path: none;
  }

  .compare-panel { position: relative; }

  .compare-panel img { border-radius: 6px; }

  .compare-label-after { right: auto; left: 1rem; }

  .compare-range,
  .compare-handle { display: none; }
}

@media (prefers-reduced-motion: reduce) and (max-width: 44rem) {
  .compare { grid-template-columns: 1fr; }
}
