:root {
  --ink: #1a211c;
  --ink-soft: #3a453f;
  --paper: #eef1ec;
  --paper-deep: #e0e6df;
  --heat: #e85d04;
  --heat-deep: #c44a00;
  --sage: #3f5244;
  --header-h: 4.25rem;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  overflow-x: hidden;
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: rgba(232, 93, 4, 0.15);
}

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

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

h1,
h2,
h3,
.brand,
.logo,
.footer-brand,
.step-num {
  font-family: "Bebas Neue", "Haettenschweiler", "Impact", sans-serif;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 0.95;
}

:focus-visible {
  outline: 3px solid var(--heat);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 50;
  padding: 0.75rem 1rem;
  background: var(--ink);
  color: #fff;
}

.skip-link:focus {
  left: 0;
}

/* Header */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
  padding: 0 var(--gutter);
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  padding-right: max(var(--gutter), env(safe-area-inset-right));
  background: rgba(238, 241, 236, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(26, 33, 28, 0.1);
}

.logo {
  font-size: clamp(1.2rem, 4.5vw, 1.45rem);
  letter-spacing: 0.04em;
  text-decoration: none;
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav a {
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.2s ease;
}

.nav a.nav-cta {
  color: var(--heat);
  font-weight: 600;
}

.menu-toggle {
  display: none;
  flex: 0 0 auto;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  touch-action: manipulation;
}

.menu-toggle span {
  display: block;
  width: 1.4rem;
  height: 2px;
  margin: 0.35rem auto;
  background: var(--ink);
  transition: transform 0.25s var(--ease);
}

.menu-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(4px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-4px) rotate(-45deg);
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-items: end;
  color: #fff7ef;
  overflow: hidden;
}

.hero-media,
.hero-media picture {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  transform: scale(1.06);
  animation: hero-drift 18s var(--ease) infinite alternate;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(
      180deg,
      rgba(26, 33, 28, 0.4) 0%,
      rgba(26, 33, 28, 0.2) 35%,
      rgba(26, 33, 28, 0.85) 100%
    ),
    radial-gradient(
      ellipse 80% 55% at 70% 20%,
      rgba(232, 93, 4, 0.28),
      transparent 60%
    );
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(42rem, 100%);
  padding: calc(var(--header-h) + 2rem) var(--gutter) clamp(3rem, 8vh, 5rem);
  padding-left: max(var(--gutter), env(safe-area-inset-left));
  animation: rise 0.9s var(--ease) both;
}

.brand {
  margin: 0 0 0.85rem;
  font-size: clamp(2.5rem, 9vw, 5.5rem);
  color: #fff;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.3);
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(1.75rem, 5.5vw, 3rem);
  color: #fff;
}

.lede {
  margin: 0 0 1.75rem;
  max-width: 32rem;
  font-size: clamp(1rem, 3.5vw, 1.1rem);
  color: rgba(255, 247, 239, 0.9);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: 0.9rem 1.35rem;
  border: 1.5px solid transparent;
  font-family: inherit;
  font-size: 0.98rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  touch-action: manipulation;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s var(--ease);
}

.btn-primary {
  background: var(--heat);
  color: #fff;
  border-color: var(--heat);
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}

.btn[disabled] {
  opacity: 0.75;
  cursor: default;
  transform: none;
}

@media (hover: hover) {
  .nav a:hover {
    color: var(--ink);
  }

  .nav a.nav-cta:hover {
    color: var(--heat-deep);
  }

  .btn:hover:not([disabled]) {
    transform: translateY(-1px);
  }

  .btn-primary:hover:not([disabled]) {
    background: var(--heat-deep);
    border-color: var(--heat-deep);
  }

  .btn-ghost:hover:not([disabled]) {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
  }
}

/* Sections */
.section {
  padding: clamp(4rem, 10vw, 7.5rem) var(--gutter);
  scroll-margin-top: var(--header-h);
}

.section-inner {
  width: min(68rem, 100%);
  margin: 0 auto;
}

.section h2 {
  margin: 0 0 0.85rem;
  font-size: clamp(2.25rem, 7vw, 4.25rem);
}

.section-copy {
  margin: 0 0 2.5rem;
  max-width: 34rem;
  color: var(--ink-soft);
  font-size: clamp(1.03rem, 3.4vw, 1.125rem);
}

/* How */
.how {
  background: linear-gradient(
    160deg,
    var(--paper) 0%,
    var(--paper-deep) 55%,
    #d2dbd4 100%
  );
}

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

.steps li {
  padding-top: 0.25rem;
  border-top: 2px solid var(--ink);
}

.step-num {
  display: block;
  margin-bottom: 1.1rem;
  font-size: 2rem;
  color: var(--heat);
}

.steps h3 {
  margin: 0 0 0.65rem;
  font-size: 1.85rem;
}

.steps p {
  margin: 0;
  color: var(--ink-soft);
}

/* Events */
.events {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: stretch;
  padding: 0;
  background: var(--ink);
  color: var(--paper);
}

.events-media {
  min-height: min(70vh, 36rem);
  overflow: hidden;
}

.events-media img {
  width: 100%;
  height: 100%;
  min-height: min(70vh, 36rem);
  object-fit: cover;
  transform: scale(1.04);
  transition: transform 1.4s var(--ease);
}

.events-media.is-in img {
  transform: scale(1);
}

.events-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(3.5rem, 8vw, 6rem) var(--gutter) clamp(3.5rem, 8vw, 6rem)
    clamp(1.25rem, 3vw, 1.5rem);
}

.events h2 {
  color: #fff;
}

.events-copy > p {
  margin: 0 0 1.5rem;
  max-width: 28rem;
  color: rgba(238, 241, 236, 0.8);
  font-size: clamp(1.03rem, 3.4vw, 1.1rem);
}

.event-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.event-list li {
  padding: 0.85rem 0;
  border-top: 1px solid rgba(238, 241, 236, 0.18);
  font-weight: 500;
}

.event-list li:last-child {
  border-bottom: 1px solid rgba(238, 241, 236, 0.18);
}

/* Book */
.book {
  background:
    radial-gradient(
      ellipse 70% 50% at 10% 0%,
      rgba(232, 93, 4, 0.1),
      transparent 55%
    ),
    linear-gradient(180deg, #e4ebe5 0%, var(--paper) 100%);
}

.book-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1.15rem 1.25rem;
  width: min(40rem, 100%);
}

.book-form label {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  min-width: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.book-form .full {
  grid-column: 1 / -1;
}

.book-form input,
.book-form textarea {
  width: 100%;
  min-height: 2.9rem;
  padding: 0.8rem 0.95rem;
  border: 1.5px solid rgba(26, 33, 28, 0.2);
  border-radius: 0;
  background: #f7f9f6;
  color: var(--ink);
  font-family: inherit;
  /* 16px minimum keeps iOS Safari from zooming on focus */
  font-size: max(1rem, 1.0625rem);
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.book-form input:focus,
.book-form textarea:focus {
  outline: none;
  border-color: var(--heat);
  background: #fff;
}

.book-form textarea {
  resize: vertical;
  min-height: 7rem;
}

.book-form .btn.full {
  width: fit-content;
  margin-top: 0.35rem;
}

.form-note {
  margin: 0;
  min-height: 1.4rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--heat-deep);
}

/* Footer */
.site-footer {
  padding: 2.5rem var(--gutter) calc(3rem + env(safe-area-inset-bottom));
  background: var(--sage);
  color: #edf0ea;
  text-align: center;
}

.footer-brand {
  margin: 0 0 0.4rem;
  font-size: 1.75rem;
  color: #fff;
}

.site-footer p {
  margin: 0.35rem 0;
  font-size: 0.95rem;
  color: rgba(237, 240, 234, 0.85);
}

.site-footer a {
  color: #fff;
}

/* Motion */
.reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition:
    opacity 0.7s var(--ease),
    transform 0.7s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

.steps .reveal:nth-child(2) {
  transition-delay: 0.1s;
}

.steps .reveal:nth-child(3) {
  transition-delay: 0.2s;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(1.5rem);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes hero-drift {
  from {
    transform: scale(1.06) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.12) translate3d(-1.5%, -1%, 0);
  }
}

/* Responsive */
@media (max-width: 900px) {
  .steps {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .events {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .events-media,
  .events-media img {
    min-height: 16rem;
    max-height: 60vh;
  }

  .events-copy {
    padding: clamp(2.5rem, 8vw, 3.5rem) var(--gutter) clamp(4rem, 10vw, 7.5rem);
  }
}

@media (max-width: 720px) {
  .menu-toggle {
    display: block;
  }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.25rem var(--gutter) 1rem;
    background: var(--paper);
    border-bottom: 1px solid rgba(26, 33, 28, 0.1);
    box-shadow: 0 18px 30px -22px rgba(26, 33, 28, 0.5);
  }

  .nav.is-open {
    display: flex;
  }

  .nav a {
    padding: 0.95rem 0;
    font-size: 1rem;
    border-bottom: 1px solid rgba(26, 33, 28, 0.1);
  }

  .nav a:last-child {
    border-bottom: 0;
  }

  .hero-actions .btn {
    flex: 1 1 12rem;
  }
}

/* Short landscape phones: don't let the hero force a tall scroll */
@media (max-height: 520px) and (orientation: landscape) {
  .hero {
    min-height: auto;
  }

  .hero-content {
    padding-top: calc(var(--header-h) + 1.25rem);
    padding-bottom: 2.5rem;
  }

  .brand {
    font-size: clamp(2rem, 7vh, 3rem);
  }
}

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

  .hero-media img,
  .hero-content,
  .reveal,
  .events-media img {
    animation: none !important;
    transition: none !important;
    opacity: 1;
    transform: none;
  }
}
