/* ═══════════════════════════════════════════════════════
   Svensk Andungeklubb
   4 colors: --bg / --card / --white / --brass
   ═══════════════════════════════════════════════════════ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg:         #0e1923;
  --card:       #152130;      /* dark navy card */
  --card-alt:   #1a2d3d;      /* mid navy card */
  --card-dark:  #0c1620;      /* deepest card */
  --card-accent:#1b4f72;      /* marine blue accent — our "red" */
  --white:      #f0f4f6;
  --white-dim:  rgba(240,244,246,.62);
  --white-faint:rgba(240,244,246,.32);
  --brass:      #b8914a;
  --nav-h:      64px;  /* initial — JS overrides */
  --max-w:      1180px;
  --pad:        clamp(1.5rem, 5vw, 6rem);
}

html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--white);
  font-family: "Cormorant Garamond", Georgia, serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ── Navbar ──────────────────────────────────────────────────── */
.navbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: 64px;  /* JS will animate this */
  z-index: 100;
  display: flex; align-items: center; justify-content: flex-end;
  padding: 0 var(--pad);
  background: rgba(14,25,35,.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(184,145,74,.15);
  transition: border-color .4s;
  will-change: height;
}
.nav-links {
  display: flex; gap: 2rem; align-items: center;
  opacity: 1;
  position: absolute;
  right: var(--pad);
  top: 50%;
  transform: translateY(-50%);
  /* Stays at top of navbar regardless of height change */
  top: 20px;
  transform: none;
}
.nav-links a {
  font-family: sans-serif; font-size: 0.72rem;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--white-dim); transition: color .2s;
}
.nav-links a:hover { color: var(--white); }
.nav-sep { color: rgba(184,145,74,.35); }

/* ── Logo ────────────────────────────────────────────────────── */
#logo-block {
  position: fixed; z-index: 200; pointer-events: none;
  display: flex; flex-direction: column; align-items: center;
}
.logo-line {
  display: block;
  font-family: "Cinzel", Georgia, serif;
  font-weight: 400; text-transform: uppercase;
  line-height: 1.08; white-space: nowrap;
  color: var(--white);
}
#duck-img {
  position: fixed; z-index: 300;
  pointer-events: none; opacity: 0;
  filter: brightness(0) invert(1);
}

/* ── Hero ────────────────────────────────────────────────────── */
.hero {
  position: relative; height: 100vh;
  overflow: hidden;
  display: flex; align-items: center;
  justify-content: center;
}
.hero-img {
  position: absolute; inset: 0;
}
.hero-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 55%;
}
/* Gradient: dark edges, slightly lighter centre so image reads */
.hero-grad {
  position: absolute; inset: 0;
  background:
    linear-gradient(to bottom,
      rgba(14,25,35,.80) 0%,
      rgba(14,25,35,.20) 35%,
      rgba(14,25,35,.20) 55%,
      rgba(14,25,35,.85) 100%);
}
.hero-inner {
  position: relative; z-index: 10;
  width: 100%; max-width: var(--max-w);
  padding: 140px var(--pad) 5rem;  /* top = initial navbar height */
  text-align: center;
}
.hero-lbl {
  font-family: sans-serif; font-size: .9rem;
  letter-spacing: .28em; text-transform: uppercase;
  color: var(--brass); margin-bottom: 1.4rem;
  display: block;
}
.hero-h1 {
  font-size: clamp(4rem, 10vw, 9rem);
  font-weight: 300; letter-spacing: .04em;
  line-height: 1.05; color: var(--white);
  margin-bottom: 1.4rem;
}
.hero-sub {
  font-style: italic; font-size: clamp(1.3rem, 2.2vw, 1.8rem);
  color: var(--white-dim); line-height: 1.65;
  max-width: 520px; margin: 0 auto 2.4rem;
}
.hero-btns {
  display: flex; gap: 1rem;
  justify-content: center; flex-wrap: wrap;
}

/* Scroll indicator */
.hero-scroll {
  position: absolute; bottom: 2.2rem; left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
  font-family: sans-serif; font-size: .55rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--white-faint);
}
.hero-scroll-line {
  width: 1px; height: 40px;
  background: linear-gradient(to bottom, var(--brass), transparent);
  animation: scrollpulse 2s ease-in-out infinite;
}
@keyframes scrollpulse {
  0%,100% { opacity: .4; transform: scaleY(1); }
  50%      { opacity: 1;  transform: scaleY(1.15); }
}

/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
  display: inline-block; padding: .75rem 2.4rem;
  font-family: sans-serif; font-size: .66rem;
  letter-spacing: .2em; text-transform: uppercase;
  transition: all .25s; cursor: pointer;
  background: transparent; border: none;
}
.btn-outline { border: 1px solid var(--brass); color: var(--brass); }
.btn-outline:hover { background: var(--brass); color: var(--bg); }
.btn-ghost { border: 1px solid var(--white-faint); color: var(--white-dim); }
.btn-ghost:hover { border-color: var(--white-dim); color: var(--white); }
.btn-white { border: 1px solid var(--white); color: var(--white); }
.btn-white:hover { background: var(--white); color: var(--bg); }

/* ── Type helpers ────────────────────────────────────────────── */
.lbl {
  font-family: sans-serif; font-size: .8rem;
  letter-spacing: .26em; text-transform: uppercase;
  color: var(--brass); display: block;
}
.rule { width: 38px; height: 1px; background: var(--brass); margin: 1.1rem 0; }

/* Card heading — Folkoperan-scale: large, light, serif */
.h2 {
  font-size: clamp(2.4rem, 4vw, 3.8rem);
  font-weight: 300; letter-spacing: .03em;
  line-height: 1.15; color: var(--white);
}
.h3 {
  font-size: clamp(1.8rem, 2.8vw, 2.6rem);
  font-weight: 300; letter-spacing: .03em;
  line-height: 1.2; color: var(--white);
}
/* Body — larger and more readable */
.body {
  font-size: clamp(1.2rem, 1.8vw, 1.4rem);
  font-weight: 300; color: var(--white-dim);
  line-height: 1.6;
}
.link-arr {
  display: inline-block; margin-top: 1.6rem;
  font-family: sans-serif; font-size: .78rem;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--brass);
  border-bottom: 1px solid rgba(184,145,74,.35);
  padding-bottom: 2px; transition: border-color .2s;
}
.link-arr:hover { border-color: var(--brass); }

/* ── Folk grid ───────────────────────────────────────────────── */
.folk-grid { max-width: var(--max-w); margin: 0 auto; }

.folk-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 320px 500px;
}
.folk-block-flip { grid-template-rows: 500px 320px; }

.f-img-tall {
  grid-row: 1 / 3;
  position: relative; overflow: hidden;
}
.f-img { position: relative; overflow: hidden; }

.f-img-tall .inner,
.f-img .inner {
  position: absolute; inset: 0;
  transition: transform 1s ease;
}
/* image scale + desaturate on hover — defined in overlay section above */
.f-img-tall .inner,
.f-img .inner { transform: scale(1); transition: transform 1s ease, filter .45s ease; }
.f-img-tall:hover .inner,
.f-img:hover .inner { transform: scale(1.04); }

.f-overlay {
  position: absolute; inset: 0; z-index: 1;
  /* Base gradient — lighter at top, dark at bottom for text legibility */
  background: linear-gradient(to bottom,
    rgba(14,25,35,.10) 0%,
    rgba(14,25,35,.45) 50%,
    rgba(14,25,35,.88) 100%);
  transition: background .45s ease;
}
/* On hover: whole card darkens significantly */
.f-img-tall:hover .f-overlay,
.f-img:hover .f-overlay {
  background: linear-gradient(to bottom,
    rgba(14,25,35,.55) 0%,
    rgba(14,25,35,.72) 50%,
    rgba(14,25,35,.94) 100%);
}
/* Image desaturates slightly on hover */
.f-img-tall:hover .inner,
.f-img:hover .inner {
  filter: saturate(0.6) brightness(0.85);
}
.f-body {
  position: absolute; bottom: 0; left: 0; right: 0;
  z-index: 2; padding: 2.4rem 2.8rem;
  /* Text slides up on hover */
  transform: translateY(0);
  transition: transform .45s ease;
}
.f-img-tall:hover .f-body,
.f-img:hover .f-body {
  transform: translateY(-10px);
}

.f-solid {
  display: flex; flex-direction: column; justify-content: center;
  padding: 3rem 3.5rem;
  cursor: pointer;
  transition: background .35s ease;
}
.f-solid-a { background: var(--card); }
.f-solid-b { background: var(--card-alt); }
.f-solid-c { background: var(--card-dark); }
.f-solid-a:hover { background: #1e3348; }
.f-solid-accent { background: var(--card-accent); }
.f-solid-accent:hover { background: #216080; }
.f-solid-b:hover { background: #243d52; }
.f-solid-c:hover { background: #142232; }

/* Solid card text nudges up on hover */
.f-solid:hover .h2,
.f-solid:hover .h3,
.f-solid:hover .body,
.f-solid:hover .lbl,
.f-solid:hover .rule,
.f-solid:hover .link-arr {
  transform: translateY(-6px);
  transition: transform .4s ease;
}
.f-solid .h2,
.f-solid .h3,
.f-solid .body,
.f-solid .lbl,
.f-solid .rule,
.f-solid .link-arr {
  transition: transform .4s ease;
}

/* All image cards need pointer cursor */
.f-img-tall, .f-img { cursor: pointer; }

/* Placeholder fills */
.ph {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-family: sans-serif; font-size: .58rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: rgba(184,145,74,.2);
}
.ph-1 { background: linear-gradient(160deg,#0a1520,#0f2035,#0c1b2e); }
.ph-2 { background: linear-gradient(160deg,#0c1a28,#132438,#0f2030); }
.ph-3 { background: linear-gradient(160deg,#0d1c2c,#152840,#0e1f30); }
.ph-4 { background: linear-gradient(160deg,#0a1820,#122030,#0c1a28); }
.ph-5 { background: linear-gradient(160deg,#0c1622,#14203a,#101828); }
.ph-6 { background: linear-gradient(160deg,#0e1c2c,#1a2e42,#101e2e); }

@media (max-width: 740px) {
  .folk-block, .folk-block-flip {
    grid-template-columns: 1fr;
    grid-template-rows: 340px 300px 340px;
  }
  .f-img-tall { grid-row: auto; }
}

/* ── Quote banner ────────────────────────────────────────────── */
.quote-banner {
  background: var(--card);
  padding: 6rem var(--pad);
  text-align: center;
  border-top: 1px solid rgba(184,145,74,.12);
  border-bottom: 1px solid rgba(184,145,74,.12);
}
.quote-banner blockquote {
  font-style: italic; font-weight: 300;
  font-size: clamp(1.8rem, 3.2vw, 2.8rem);
  color: var(--white); line-height: 1.65;
  max-width: 680px; margin: .9rem auto 2.2rem;
}

/* ── Newsletter ──────────────────────────────────────────────── */
.newsletter {
  padding: 6rem var(--pad); text-align: center;
  border-top: 1px solid rgba(184,145,74,.08);
}
.nl-form {
  display: flex; gap: .5rem;
  justify-content: center; flex-wrap: wrap; margin-top: 2rem;
}
.nl-form input[type=email] {
  background: transparent;
  border: 1px solid rgba(184,145,74,.35);
  color: var(--white); padding: .75rem 1.4rem;
  font-family: inherit; font-size: 1rem;
  width: 290px; outline: none; transition: border-color .2s;
}
.nl-form input:focus { border-color: var(--brass); }
.nl-form input::placeholder { color: var(--white-dim); }

/* ── Footer ──────────────────────────────────────────────────── */
footer {
  background: #07101a;
  padding: 5rem var(--pad) 2.5rem;
  border-top: 1px solid rgba(184,145,74,.1);
}
.footer-inner { max-width: var(--max-w); margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem; margin-bottom: 3rem;
}
.footer-logo {
  font-family: "Cinzel", serif; font-size: 1rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--white); margin-bottom: 1rem;
}
.footer-brand p { font-size: .95rem; color: var(--white-dim); line-height: 1.6; }
.footer-col h4 {
  font-family: sans-serif; font-size: .78rem;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--brass); margin-bottom: 1.2rem;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: .6rem; }
.footer-col a { font-size: .95rem; color: var(--white-dim); transition: color .2s; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.05);
  padding-top: 1.5rem;
  display: flex; justify-content: space-between;
  font-family: sans-serif; font-size: .6rem;
  letter-spacing: .12em; text-transform: uppercase; color: #2a3f52;
}
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* ── Hamburger menu ───────────────────────────────────────────── */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 26px; height: 18px;
  cursor: pointer;
  background: none; border: none;
  padding: 0; z-index: 201;
  position: fixed; top: 22px; right: var(--pad);
}
.hamburger span {
  display: block; width: 100%; height: 2px;
  background: var(--white);
  transition: transform .3s, opacity .3s, width .3s;
  transform-origin: left center;
}
.hamburger.open span:nth-child(1) { transform: rotate(40deg) translate(1px, -2px); }
.hamburger.open span:nth-child(2) { opacity: 0; width: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-40deg) translate(1px, 2px); }

/* Mobile nav drawer */
.nav-drawer {
  display: none;
  position: fixed; inset: 0; top: 64px;
  background: rgba(10,18,26,.97);
  backdrop-filter: blur(16px);
  z-index: 199;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2.2rem;
  opacity: 0;
  transition: opacity .25s;
  pointer-events: none;
}
.nav-drawer.open {
  opacity: 1;
  pointer-events: all;
}
.nav-drawer a {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem; letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--white-dim);
  transition: color .2s;
}
.nav-drawer a:hover, .nav-drawer a:active { color: var(--white); }

@media (max-width: 860px) {
  .hamburger { display: flex; }
  .nav-links { display: none; }
  .nav-drawer { display: flex; }

  /* Hero adjustments */
  .hero-h1 { font-size: clamp(2.8rem, 10vw, 5rem) !important; }
  .hero-sub { font-size: clamp(1rem, 3.5vw, 1.3rem) !important; }
  .hero-btns { gap: .6rem !important; }
  .hero-btns .btn { font-size: .65rem !important; padding: .6rem 1rem !important; }

  /* Page hero */
  .page-hero { min-height: 40vh; }
  .page-hero-content h1 { font-size: clamp(2.2rem, 8vw, 4rem); }

  /* Info box padding */
  .info-box { padding: 1.4rem 1.5rem; }

  /* Form */
  .andunge-form input,
  .andunge-form textarea,
  .andunge-form select { font-size: 1rem; }
}

/* ── Scroll reveal ───────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s ease, transform .8s ease; }
.reveal.visible { opacity: 1; transform: none; }
.d1 { transition-delay: .12s; }
.d2 { transition-delay: .24s; }
.d3 { transition-delay: .36s; }
