/* ============================================================
   Beachvolley Måløv – stylesheet
   Farvetema: sand, havblå, MIF-grøn og "net-gul"
   ============================================================ */

:root {
  --sand: #f8f3e8;          /* sidebaggrund (sand) */
  --sand-dark: #efe6d1;     /* alternativ sektion */
  --ink: #24333d;           /* brødtekst */
  --sea: #0d5c75;           /* havblå – primær farve */
  --sea-dark: #0a4759;
  --mif-green: #8dc63f;     /* Måløv Idrætsforenings grøn */
  --net-yellow: #f6c445;    /* gul som nettet på banen */
  --white: #ffffff;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(36, 51, 61, 0.12);
  --font-head: "Poppins", sans-serif;
  --font-body: "Inter", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

/* Så anker-links ikke lander under den sticky header */
section[id] { scroll-margin-top: 80px; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--sand);
  line-height: 1.65;
}

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

h1, h2, h3 {
  font-family: var(--font-head);
  line-height: 1.2;
  color: var(--sea-dark);
}

h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); margin-bottom: 1rem; }
h2.center, p.center { text-align: center; }
.lead { max-width: 640px; margin: 0 auto 2.5rem; font-size: 1.05rem; }

.container { width: min(1100px, 92%); margin: 0 auto; }
.section { padding: 5rem 0; }
.section-alt { background: var(--sand-dark); }

/* ---------- Knapper ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 600;
  text-decoration: none;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-primary { background: var(--net-yellow); color: var(--ink); }
.btn-primary:hover { background: #ffd35e; }
.btn-ghost { border-color: var(--white); color: var(--white); background: rgba(255,255,255,0.08); }
.btn-ghost:hover { background: rgba(255,255,255,0.2); }
.btn-small { padding: 0.5rem 1.1rem; font-size: 0.9rem; background: var(--sea); color: var(--white); }
.btn-small:hover { background: var(--sea-dark); }
.btn-full { width: 100%; font-size: 1rem; }

/* ---------- Header / navigation ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 243, 232, 0.92);
  backdrop-filter: blur(8px);
  transition: box-shadow 0.2s ease;
}
.header.scrolled { box-shadow: 0 4px 18px rgba(36, 51, 61, 0.12); }

.nav { display: flex; align-items: center; justify-content: space-between; padding: 0.7rem 0; }

.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand-logo { width: 46px; height: 46px; object-fit: contain; }
.brand-text {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--sea-dark);
}
.brand-text em { font-style: normal; color: #4a7519; } /* mørk grøn: 4,93:1 kontrast på sandbaggrund (WCAG OK) */

.nav-links { display: flex; align-items: center; gap: 1.6rem; list-style: none; }
.nav-links a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--sea); }
.nav-links .nav-cta {
  background: var(--sea);
  color: var(--white);
  padding: 0.5rem 1.2rem;
  border-radius: 999px;
}
.nav-links .nav-cta:hover { background: var(--sea-dark); color: var(--white); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span { width: 26px; height: 3px; background: var(--sea-dark); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  background:
    linear-gradient(rgba(9, 42, 56, 0.55), rgba(9, 42, 56, 0.35)),
    url("../assets/hero.jpg") center 30% / cover no-repeat;
  color: var(--white);
  text-align: center;
}
.hero-inner { padding: 6rem 0 8rem; }
.hero-kicker {
  display: inline-block;
  background: var(--mif-green);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.35rem 1rem;
  border-radius: 999px;
  margin-bottom: 1.2rem;
}
.hero h1 {
  color: var(--white);
  font-size: clamp(2.6rem, 7vw, 4.5rem);
  font-weight: 800;
  text-shadow: 0 4px 24px rgba(0,0,0,0.35);
}
.hero h1 span { color: var(--net-yellow); }
.hero-sub {
  max-width: 620px;
  margin: 1.2rem auto 2.2rem;
  font-size: clamp(1rem, 2vw, 1.2rem);
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 70px;
  fill: var(--sand);
}

/* ---------- Split-sektioner (tekst + billede) ---------- */
.split {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.split-text p { margin-bottom: 1rem; }
.split-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}

/* ---------- Kort ---------- */
.feature-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
  margin-top: 2rem;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.6rem 1.4rem;
  box-shadow: var(--shadow);
}
.card-icon {
  width: 42px;
  height: 42px;
  fill: var(--sea);
  margin-bottom: 0.8rem;
}
.card h3 { font-size: 1.05rem; margin-bottom: 0.4rem; }
.card p { font-size: 0.92rem; }

/* ---------- Praktisk info ---------- */
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.4rem;
}
.info-card h3 { margin-bottom: 0.6rem; color: var(--sea); }
.info-card a { color: var(--sea); font-weight: 600; }

/* ---------- Galleri ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}
.gallery-item {
  border: none;
  padding: 0;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: zoom-in;
  box-shadow: var(--shadow);
  background: none;
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.gallery-item:hover img { transform: scale(1.06); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(15, 30, 38, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 2rem;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: min(1000px, 95vw);
  max-height: 85vh;
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.lightbox-close {
  position: absolute;
  top: 1.2rem;
  right: 1.6rem;
  font-size: 2.4rem;
  color: var(--white);
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
}

/* ---------- Kontakt ---------- */
.contact-facts { list-style: none; margin: 1.2rem 0 1.6rem; }
.contact-facts li { margin-bottom: 0.4rem; }
.mif-logo { width: 110px; height: 110px; object-fit: contain; }

.contact-form {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
}
.form-row { margin-bottom: 1.1rem; }
.form-row label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.35rem;
}
.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  padding: 0.7rem 0.9rem;
  border: 2px solid #ddd3bd;
  border-radius: 10px;
  background: #fffdf8;
  transition: border-color 0.15s ease;
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--sea);
}
.form-row .error { border-color: #d64545; }
.form-status { margin-top: 0.9rem; font-size: 0.92rem; font-weight: 500; min-height: 1.4em; }
.form-status.ok { color: #2e7d32; }
.form-status.feijl { color: #c62828; }

/* Honeypot-felt: skjult uden for skærmen (ikke display:none, som bots kan detektere) */
.hp { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Footer ---------- */
.footer { background: var(--sea-dark); color: #dcebf0; padding: 2.5rem 0; }
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
}
.footer-brand { display: flex; align-items: center; gap: 0.9rem; }
.footer-logo { width: 54px; height: 54px; object-fit: contain; }
.footer-brand strong { display: block; font-family: var(--font-head); color: var(--white); }
.footer-brand span { font-size: 0.85rem; }
.footer-links { display: flex; gap: 1.2rem; list-style: none; flex-wrap: wrap; }
.footer-links a { color: #dcebf0; text-decoration: none; font-size: 0.92rem; }
.footer-links a:hover { color: var(--net-yellow); }
.footer-copy { font-size: 0.85rem; width: 100%; text-align: center; margin-top: 0.8rem; opacity: 0.8; }

/* ---------- Scroll-animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- Mobil ---------- */
@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; }
  .feature-cards { grid-template-columns: 1fr; }
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--sand);
    box-shadow: 0 14px 24px rgba(36, 51, 61, 0.15);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .nav-links.open { max-height: 480px; }
  .nav-links li { border-top: 1px solid var(--sand-dark); }
  .nav-links a { display: block; padding: 0.9rem 1.4rem; }
  .nav-links .nav-cta { margin: 0.6rem 1.4rem; text-align: center; }
  .section { padding: 3.5rem 0; }
}
