:root {
  --paper: #efe9da;        /* cream sketch paper */
  --paper-deep: #e6dfcc;
  --ink: #1d1a14;          /* black ink */
  --green: #4c7a2b;        /* racing green */
  --green-deep: #2e4a1a;
  --gold: #c2922e;         /* ochre gold */
  --anno-font: "Architects Daughter", cursive;
  --serif: "Playfair Display", Georgia, serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  overflow-x: hidden;
}
a { color: var(--green-deep); text-decoration: none; border-bottom: 1px dashed var(--gold); }

/* handwritten annotation voice */
.anno {
  font-family: var(--anno-font);
  letter-spacing: 0.06em;
}

/* ---------- film grain overlay ---------- */
.grain {
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  z-index: 90;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3CfeComponentTransfer%3E%3CfeFuncA type='linear' slope='0.06'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain-shift 0.9s steps(3) infinite;
}
@keyframes grain-shift {
  0% { transform: translate(0,0); } 33% { transform: translate(-2%,1%); }
  66% { transform: translate(1%,-2%); } 100% { transform: translate(0,0); }
}

/* ---------- Fixed nav ---------- */
.hud {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 28px;
  font-family: var(--anno-font);
  font-size: 14px;
  letter-spacing: 0.14em;
  color: var(--ink);
  background: linear-gradient(180deg, rgba(239,233,218,0.92), rgba(239,233,218,0));
}
.hud-brand { font-weight: 700; }
.hud-brand .dim { color: var(--green); }
.hud-mid { color: var(--gold); }
.hud-right { border-bottom: 2px solid var(--green); color: var(--ink); }

/* ---------- Cinematic scrub sections ---------- */
.cinematic { position: relative; height: 520vh; }
.cinematic.short { height: 380vh; }
.sticky {
  position: sticky; top: 0;
  height: 100vh; width: 100%;
  overflow: hidden;
  display: grid; place-items: center;
  background: var(--paper);
}
.sticky canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.paper-vignette {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(120% 95% at 50% 45%, transparent 55%, rgba(46,42,32,0.28) 100%),
    linear-gradient(180deg, rgba(239,233,218,0.55) 0%, transparent 18%, transparent 78%, rgba(46,42,32,0.3) 100%);
}

/* ---------- Overlay copy ---------- */
.overlay { position: relative; z-index: 10; text-align: center; padding: 0 24px; }
.line {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: max-content; max-width: 92vw;
  font-family: var(--serif);
  font-weight: 900;
  font-size: clamp(2.4rem, 7.5vw, 6.4rem);
  letter-spacing: 0.06em;
  line-height: 1.06;
  color: var(--ink);
  opacity: 0;
  text-shadow: 0 2px 0 rgba(239,233,218,0.8), 0 0 34px rgba(239,233,218,0.85);
  will-change: opacity, transform;
}
.line.sub { font-size: clamp(1.8rem, 5.4vw, 4.4rem); font-weight: 700; }
.line.story {
  font-size: clamp(1.7rem, 4.6vw, 3.8rem);
  font-weight: 700; font-style: italic;
  color: var(--green-deep);
}
.line .anno {
  display: inline-block;
  font-size: 0.5em;
  font-weight: 400;
  color: var(--gold);
  letter-spacing: 0.12em;
}

/* ---------- Telemetry corners ---------- */
.telemetry {
  position: absolute; z-index: 12;
  font-size: 13px; letter-spacing: 0.18em;
  color: var(--green-deep);
}
.tl { top: 86px; left: 28px; }
.tr { top: 86px; right: 28px; }
.bl { bottom: 66px; left: 28px; }
.br { bottom: 66px; right: 28px; }

/* ---------- Progress + hint ---------- */
.progress {
  position: absolute; left: 28px; right: 28px; bottom: 44px;
  height: 2px; background: rgba(29,26,20,0.15); z-index: 12;
}
.progress-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--green), var(--gold));
}
.scroll-hint {
  position: absolute; bottom: 12px; left: 50%;
  transform: translateX(-50%); z-index: 12;
  font-size: 14px; letter-spacing: 0.3em; color: var(--ink);
  animation: bob 1.8s ease-in-out infinite;
  transition: opacity 0.4s;
}
@keyframes bob { 0%,100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(6px); } }

/* ---------- Scroll reveals ---------- */
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}
.reveal.in { opacity: 1; transform: none; }

/* ---------- Section chrome ---------- */
.section-head { text-align: center; margin-bottom: 56px; }
.section-head .kicker { color: var(--gold); font-size: 1.05rem; }
.section-head h2 {
  font-family: var(--serif); font-weight: 900;
  font-size: clamp(2.2rem, 5vw, 4rem);
  letter-spacing: 0.04em; margin: 8px 0 6px;
}
.section-head h2::after {
  content: ""; display: block; width: 110px; height: 3px;
  margin: 14px auto 0;
  background: linear-gradient(90deg, var(--green), var(--gold));
  transform: rotate(-0.6deg);
}

/* ---------- Services spec sheet ---------- */
.services {
  position: relative;
  padding: 110px 6vw 90px;
  background:
    linear-gradient(0deg, rgba(76,122,43,0.05), rgba(76,122,43,0.05)),
    var(--paper);
}
.spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 28px;
  max-width: 1240px; margin: 0 auto;
}
.spec-card {
  position: relative;
  border: 2px solid var(--ink);
  border-radius: 4px 14px 4px 12px;
  padding: 30px 26px 26px;
  background: rgba(255,253,246,0.6);
  box-shadow: 4px 4px 0 rgba(46,74,26,0.25);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.spec-card:hover { transform: translateY(-6px) rotate(-0.4deg); box-shadow: 7px 9px 0 rgba(46,74,26,0.3); }
.spec-card .fig {
  position: absolute; top: -12px; left: 18px;
  background: var(--gold); color: var(--paper);
  padding: 2px 10px; font-size: 12px; letter-spacing: 0.2em;
  transform: rotate(-2deg);
}
.spec-card h3 {
  font-family: var(--serif); font-weight: 900;
  font-size: 1.7rem; margin-bottom: 12px;
  border-bottom: 2px dashed var(--gold); display: inline-block; padding-bottom: 4px;
}
.spec-card ul { list-style: none; margin-bottom: 14px; color: var(--green-deep); font-size: 0.95rem; }
.spec-card ul li::before { content: "• "; color: var(--gold); }
.spec-card p { font-size: 0.95rem; line-height: 1.6; color: rgba(29,26,20,0.8); }

/* ---------- Stats ---------- */
.stats {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: clamp(28px, 6vw, 90px);
  margin: 80px auto 0; text-align: center;
}
.stats b {
  display: block; font-family: var(--serif); font-weight: 900;
  font-size: clamp(2rem, 4.4vw, 3.4rem); color: var(--green-deep);
}
.stats .anno { color: var(--gold); font-size: 1rem; }

/* ---------- Contact ---------- */
.contact { padding: 110px 6vw 40px; background: var(--paper-deep); }
.contact-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 56px; max-width: 1100px; margin: 0 auto;
}
.contact-col h3 { color: var(--gold); font-size: 1.1rem; letter-spacing: 0.2em; margin: 26px 0 10px; }
.contact-col h3:first-child { margin-top: 0; }
.contact-col .big { font-family: var(--serif); font-size: 1.6rem; font-weight: 700; line-height: 1.35; }
.contact-col p { margin-bottom: 8px; line-height: 1.7; }
.hours { border-collapse: collapse; font-size: 1.05rem; color: var(--green-deep); }
.hours td { padding: 4px 26px 4px 0; border-bottom: 1px dashed rgba(29,26,20,0.25); }
.small { font-size: 0.95rem; color: var(--gold); }
.map {
  width: 100%; height: 260px; border: 2px solid var(--ink);
  border-radius: 6px; margin-top: 18px;
  filter: sepia(0.35) saturate(0.8);
  box-shadow: 5px 5px 0 rgba(46,74,26,0.25);
}

/* ---------- Form ---------- */
.book-form {
  border: 2px solid var(--ink);
  border-radius: 12px 4px 14px 4px;
  padding: 34px 30px;
  background: rgba(255,253,246,0.7);
  box-shadow: 6px 6px 0 rgba(194,146,46,0.35);
  height: fit-content;
}
.book-form label {
  display: block; margin-bottom: 16px;
  font-family: var(--anno-font); font-size: 1rem; color: var(--green-deep);
}
.book-form input, .book-form textarea {
  display: block; width: 100%; margin-top: 6px;
  padding: 11px 13px;
  font-family: "Inter", sans-serif; font-size: 0.98rem;
  color: var(--ink);
  background: var(--paper);
  border: 1.5px solid rgba(29,26,20,0.5);
  border-radius: 3px;
  outline: none;
}
.book-form input:focus, .book-form textarea:focus { border-color: var(--green); box-shadow: 2px 2px 0 rgba(76,122,43,0.3); }
.book-form button {
  width: 100%; margin-top: 6px; padding: 15px;
  font-family: var(--anno-font); font-size: 1.15rem; letter-spacing: 0.14em;
  color: var(--paper); background: var(--green-deep);
  border: 2px solid var(--ink); border-radius: 4px;
  cursor: pointer;
  box-shadow: 4px 4px 0 var(--gold);
  transition: transform 0.2s, box-shadow 0.2s;
}
.book-form button:hover { transform: translate(-2px,-2px); box-shadow: 6px 6px 0 var(--gold); }
.form-note { margin-top: 14px; color: var(--green); }

footer {
  text-align: center; margin-top: 90px; padding: 26px 0;
  border-top: 2px dashed rgba(29,26,20,0.3);
  color: var(--gold); font-size: 0.95rem; letter-spacing: 0.2em;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .scroll-hint, .grain { animation: none; }
}

/* ---------- Mobile pass ---------- */
@media (max-width: 700px) {
  .hud { padding: 12px 16px; font-size: 12px; }
  .hud-mid { display: none; }
  .telemetry { font-size: 10px; letter-spacing: 0.12em; }
  .tl, .tr { top: 60px; }
  .progress { left: 16px; right: 16px; }
  .cinematic { height: 380vh; }
  .cinematic.short { height: 300vh; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .spec-grid { grid-template-columns: 1fr; }
  .stats { gap: 26px; }
}
