/* Vanaase — page layout on top of the Modernist tokens (assets/styles.css).
   Every color/space/font value comes from the token sheet; literals here are
   the handoff's site-specific values (overlays, 760px breakpoint, content caps). */

html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  padding-bottom: 96px; /* keeps the floating contact button off the last line */
}
a { color: var(--color-text); }
a:hover { color: var(--color-accent-700); }

/* Russian pages: Archivo has no Cyrillic, so they use Wix Madefor (Display for headings, Text for
   body; loaded per language via i18n/languages.json). The brand and the language switcher keep
   Archivo (--font-latin) on every page, so the header looks the same in all languages. */
:root { --font-latin: "Archivo", system-ui, sans-serif; }
html[lang="ru"] {
  --font-heading: "Wix Madefor Display", system-ui, sans-serif;
  --font-body: "Wix Madefor Text", system-ui, sans-serif;
}

.wrap { max-width: 1280px; margin: 0 auto; padding-left: var(--space-6); padding-right: var(--space-6); }

/* — header — */
.header { position: relative; z-index: 40; background: var(--color-bg); border-bottom: 2px solid var(--color-divider); }
/* brand · nav · language switcher · hamburger — the nav (or, on phones, the switcher) takes the free space */
.header-row {
  max-width: 1280px; margin: 0 auto;
  padding: var(--space-3) clamp(12px, 3vw, 24px);
  display: flex; align-items: center; justify-content: flex-start;
  gap: clamp(8px, 2vw, 24px);
}
.brand {
  display: flex; align-items: center; gap: clamp(6px, 1.5vw, 12px);
  font-family: var(--font-latin); font-weight: 800;
  font-size: clamp(16px, 4.4vw, 22px); letter-spacing: -0.02em;
  text-transform: uppercase; text-decoration: none; white-space: nowrap;
}
.brand-mark { width: clamp(26px, 7vw, 34px); height: clamp(26px, 7vw, 34px); flex: none; display: block; }

.nav-desktop {
  margin-left: auto;
  display: flex; align-items: center; gap: var(--space-4);
  font-size: 14px; font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase;
}
.nav-desktop a { text-decoration: none; }
.nav-desktop .btn { text-transform: uppercase; }

.nav-toggle {
  display: none; width: 48px; height: 48px; padding: 0;
  flex-direction: column; justify-content: center; gap: 5px;
  background: none; border: 0; cursor: pointer;
}
.nav-toggle span { display: block; width: 26px; height: 2px; background: var(--color-text); }

.nav-mobile {
  display: none; flex-direction: column;
  border-top: 2px solid var(--color-divider);
  font-family: var(--font-heading); font-weight: 800; font-size: 18px;
  letter-spacing: -0.01em; text-transform: uppercase;
}
.header.open .nav-mobile { display: flex; }
.nav-mobile a {
  text-decoration: none; padding: var(--space-4) clamp(12px, 3vw, 24px);
  min-height: 56px; display: flex; align-items: center;
  border-bottom: 2px solid var(--color-divider);
}
.nav-mobile a.ext { color: var(--color-accent-700); border-bottom: 0; }

/* language switcher: codes after a 2px rule, the current one underlined in the accent */
.lang {
  display: flex; align-items: center; flex: none;
  padding-left: var(--space-2); border-left: 2px solid var(--color-divider);
}
.lang a {
  display: flex; align-items: center; justify-content: center;
  min-width: 34px; min-height: 44px; padding: 0 5px;
  font-family: var(--font-latin);
  font-size: 14px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
  text-decoration: none; color: var(--color-neutral-700);
}
.lang a:hover { color: var(--color-accent-700); }
.lang a[aria-current] {
  color: var(--color-text);
  text-decoration: underline; text-decoration-thickness: 2px;
  text-underline-offset: 7px; text-decoration-color: var(--color-accent);
}

/* 960px, not the handoff's 760: with the language switcher the desktop nav needs ~930px */
@media (max-width: 960px) {
  .nav-desktop { display: none; }
  .nav-toggle { display: flex; }
  .lang { margin-left: auto; padding-left: 0; border-left: 0; }
}
@media (min-width: 961px) {
  .nav-mobile { display: none !important; }
}
/* Russian menu labels are longer (the sub-pages need ~990px), so there the phone menu takes
   over below 1010px */
@media (min-width: 961px) and (max-width: 1010px) {
  html[lang="ru"] .nav-desktop { display: none; }
  html[lang="ru"] .nav-toggle { display: flex; }
  html[lang="ru"] .lang { margin-left: auto; padding-left: 0; border-left: 0; }
  html[lang="ru"] .header.open .nav-mobile { display: flex !important; }
}

/* — hero — */
.hero { position: relative; border-bottom: 2px solid var(--color-divider); }
.hero-media { height: min(70vh, 620px); min-height: 380px; overflow: hidden; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(32,30,29,0.78), rgba(32,30,29,0.15) 60%); }
.hero-content { position: absolute; left: 0; right: 0; bottom: 0; }
.hero-content > div { max-width: 1280px; margin: 0 auto; padding: 0 var(--space-6) var(--space-8); color: var(--color-bg); }
.hero h1 {
  /* Floor shrinks on narrow phones so "MEDITATSIOONITALU" (10.5em wide) fits between the 24px gutters. */
  margin: 0; font-weight: 800; font-size: clamp(min(36px, calc(9.25vw - 4.5px)), 6.4vw, 88px);
  line-height: 0.96; letter-spacing: -0.035em; text-transform: uppercase; max-width: 16ch;
}
/* Home hero: title flush right, and the photo shifted up (only matters on wide screens)
   so the barn and sauna in hero.jpg sit above the title instead of behind it. */
.hero-right .hero-content > div { text-align: right; }
.hero-right h1 { max-width: none; }
.hero-right .hero-media img { object-position: 50% 70%; }
.hero.hero-sm .hero-media { height: min(56vh, 460px); min-height: 300px; }
.hero.hero-sm .hero-overlay { background: linear-gradient(to top, rgba(32,30,29,0.8), rgba(32,30,29,0.1) 65%); }
.hero.hero-sm .hero-content > div { max-width: 1000px; }
.hero.hero-sm h1 { font-size: clamp(34px, 6vw, 76px); line-height: 0.98; }

.kicker {
  margin: 0 0 var(--space-3); font-size: 13px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--color-accent-400);
}

/* — event list — */
.events { max-width: 1280px; margin: 0 auto; padding: var(--space-8) var(--space-6) 0; }
.events-head {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: var(--space-3); padding-bottom: var(--space-4); border-bottom: 2px solid var(--color-text);
}
.events-head h2 {
  margin: 0; font-weight: 800; font-size: clamp(28px, 4vw, 52px);
  line-height: 1; letter-spacing: -0.03em; text-transform: uppercase;
}
.event {
  padding: var(--space-8) 0; border-bottom: 2px solid var(--color-divider);
  display: flex; flex-wrap: wrap; gap: var(--space-4) var(--space-8);
}
.event:last-child { border-bottom: 0; }
.event-date {
  margin: 0; flex: 0 0 auto; width: 230px; max-width: 100%;
  font-family: var(--font-heading); font-weight: 800; font-size: 20px;
  letter-spacing: -0.01em; color: var(--color-accent-700);
}
.event-main { flex: 1 1 460px; min-width: 0; }
.event-main h3 {
  margin: 0 0 var(--space-4); font-weight: 800; font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.05; letter-spacing: -0.03em;
}
.event-main p { margin: 0 0 var(--space-3); font-size: 18px; line-height: 1.6; max-width: 62ch; text-wrap: pretty; }
.event-img {
  height: clamp(200px, 26vw, 300px); overflow: hidden;
  margin-bottom: var(--space-4); border: 2px solid var(--color-text);
}
.event-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.event-main .btn { margin-top: var(--space-1); }

/* — discgolf band — */
.band { position: relative; border-top: 2px solid var(--color-text); border-bottom: 2px solid var(--color-text); }
.band-media { position: absolute; inset: 0; overflow: hidden; }
.band-media img { width: 100%; height: 100%; object-fit: cover; }
.band-overlay { position: absolute; inset: 0; background: rgba(32,30,29,0.66); }
.band-content {
  position: relative; max-width: 1280px; margin: 0 auto;
  padding: clamp(48px, 8vw, 112px) var(--space-6); color: var(--color-bg);
}
.band-content h2 {
  margin: 0 0 var(--space-4); font-weight: 800; font-size: clamp(34px, 6vw, 76px);
  line-height: 0.96; letter-spacing: -0.035em; text-transform: uppercase; max-width: 15ch;
}
.band-content p:not(.kicker) { margin: 0 0 var(--space-6); font-size: 19px; line-height: 1.55; max-width: 52ch; text-wrap: pretty; }

/* — about teaser — */
.teaser { max-width: 1280px; margin: 0 auto; padding: var(--space-8) var(--space-6); }
.teaser-row { display: flex; flex-wrap: wrap; gap: var(--space-8); align-items: center; }
.teaser-img { flex: 1 1 420px; min-width: 0; height: clamp(220px, 30vw, 380px); overflow: hidden; }
.teaser-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.teaser-text { flex: 1 1 380px; min-width: 0; }
.teaser-text h2 {
  margin: 0 0 var(--space-4); font-weight: 800; font-size: clamp(26px, 3.6vw, 44px);
  line-height: 1.02; letter-spacing: -0.03em; text-transform: uppercase;
}
.teaser-text p { margin: 0 0 var(--space-6); font-size: 18px; line-height: 1.6; max-width: 58ch; text-wrap: pretty; }

/* — retreat page prose — */
.prose { max-width: 1000px; margin: 0 auto; padding: var(--space-8) var(--space-6); }
.prose > p:first-child {
  margin: 0 0 var(--space-6); font-family: var(--font-heading); font-weight: 600;
  font-size: clamp(21px, 2.4vw, 28px); line-height: 1.3; letter-spacing: -0.02em; text-wrap: pretty;
}
.prose p { margin: 0 0 var(--space-4); font-size: 18px; line-height: 1.65; text-wrap: pretty; }
.prose h2 {
  margin: var(--space-8) 0 var(--space-4); font-weight: 800;
  font-size: clamp(24px, 3.2vw, 36px); letter-spacing: -0.03em; text-transform: uppercase;
}
.prose-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-6); }

.facts {
  display: flex; flex-wrap: wrap; gap: var(--space-6) var(--space-8);
  padding: var(--space-6); background: var(--color-surface);
  border-left: 2px solid var(--color-accent);
  margin: var(--space-6) 0;
}
.fact { flex: 1 1 200px; }
.fact:last-child { flex: 1 1 140px; }
.fact-label {
  margin: 0 0 var(--space-1); font-size: 12px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--color-neutral-700);
}
.fact p { margin: 0; font-size: 18px; line-height: 1.5; }

/* — page (meist / kontakt) — */
.page { max-width: 1280px; margin: 0 auto; padding: var(--space-8) var(--space-6); }
.page h1 {
  margin: 0 0 var(--space-8); font-weight: 800; font-size: clamp(36px, 6vw, 80px);
  line-height: 0.96; letter-spacing: -0.035em; text-transform: uppercase;
}

.cols {
  display: flex; flex-wrap: wrap; gap: var(--space-8); max-width: 1080px;
  padding-bottom: var(--space-8); border-bottom: 2px solid var(--color-divider);
}
.col { flex: 1 1 380px; min-width: 0; }
.col-img { height: clamp(200px, 22vw, 280px); overflow: hidden; margin-bottom: var(--space-4); }
.col-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.col h2 {
  margin: 0 0 var(--space-4); font-weight: 800; font-size: clamp(22px, 2.8vw, 32px);
  letter-spacing: -0.03em; text-transform: uppercase;
}
.col p { margin: 0 0 var(--space-4); font-size: 18px; line-height: 1.65; text-wrap: pretty; }
.col p:last-child { margin-bottom: 0; }

.gallery {
  margin-top: var(--space-8); display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--space-2);
}
.gallery > div { height: clamp(200px, 24vw, 300px); overflow: hidden; }
.gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* — contact — */
.contact-cols { display: flex; flex-wrap: wrap; gap: var(--space-8); max-width: 1080px; }
.contact-info { flex: 1 1 340px; min-width: 0; }
.contact-info .intro { margin: 0 0 var(--space-6); font-size: 19px; line-height: 1.6; max-width: 46ch; text-wrap: pretty; }
.kv { display: grid; gap: var(--space-4); }
.kv-label {
  margin: 0 0 var(--space-1); font-size: 12px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--color-neutral-700);
}
.kv a { font-size: 19px; text-decoration: none; border-bottom: 2px solid var(--color-accent); }
.kv p { margin: 0; font-size: 19px; line-height: 1.45; }
.kv p + p { margin-top: var(--space-2); }

.contact-form {
  flex: 1 1 420px; min-width: 0; display: grid; gap: var(--space-4);
  padding: var(--space-6); background: var(--color-surface);
  border-left: 2px solid var(--color-accent);
  align-self: start; align-content: start;
}
.contact-form .btn { justify-self: start; }
.field-error { display: none; margin: 5px 0 0; font-size: 13px; font-weight: 600; color: var(--color-accent-700); }
.field.invalid .field-error { display: block; }
.field.invalid .input { border-color: var(--color-accent); }
.form-note { margin: 0; font-size: 14px; line-height: 1.5; }
.form-note.error { color: var(--color-accent-700); }
.form-success h2 {
  margin: 0 0 var(--space-3); font-weight: 800; font-size: clamp(20px, 2.4vw, 26px);
  letter-spacing: -0.02em; text-transform: uppercase;
}
.form-success p { margin: 0; font-size: 16px; line-height: 1.55; }
.honey { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* — footer — */
.footer { border-top: 2px solid var(--color-text); margin-top: var(--space-8); }
.footer-row {
  max-width: 1280px; margin: 0 auto; padding: var(--space-6);
  display: flex; flex-wrap: wrap; gap: var(--space-4) var(--space-8);
  justify-content: space-between; align-items: flex-end;
}
.footer-name {
  margin: 0 0 var(--space-1); font-family: var(--font-heading); font-weight: 800;
  font-size: 22px; letter-spacing: -0.02em; text-transform: uppercase;
}
.footer-sub { margin: 0; font-size: 14px; color: var(--color-neutral-700); }
.footer-links {
  display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-6);
  font-size: 14px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
}
.footer-links a { text-decoration: none; }

/* — floating contact button — */
.fab {
  position: fixed; right: clamp(16px, 3vw, 32px); bottom: clamp(16px, 3vw, 32px); z-index: 50;
  padding: var(--space-4) var(--space-6); font-size: 15px;
  text-transform: uppercase; box-shadow: var(--shadow-lg);
}
