/* Visit Flesberg – shared styles. Fonts are self-hosted (no Google Fonts, no consent needed). */
@font-face { font-family: 'Inter Display'; src: url('/assets/fonts/interdisplay-900.woff') format('woff'); font-weight: 900; font-display: swap; }
@font-face { font-family: 'Inter Display'; src: url('/assets/fonts/interdisplay-800.woff') format('woff'); font-weight: 800; font-display: swap; }
@font-face { font-family: 'Inter'; src: url('/assets/fonts/inter-400.woff') format('woff'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Inter'; src: url('/assets/fonts/inter-600.woff') format('woff'); font-weight: 600; font-display: swap; }

:root {
  /* Style C "Fjordblå". Alternatives A "Nordlys" and B "Sommer i Numedal" are listed in README.md */
  --blue:       #1638D8;
  --blue-dark:  #0E27A8;
  --blue-deep:  #0A1B6E;
  --blue-soft:  #E8EDFF;
  --lime:       #D7F75B;
  --lime-dark:  #C2E63A;
  --pink:       #FF7AB6;
  --pink-dark:  #D93F86;
  --pink-soft:  #FFE6F1;
  --paper:      #F6F7FF;
  --ink:        #0D1440;
  --text:       #262D52;
  --muted:      #5A6185;
  --line:       #DDE1F2;
  --white:      #FFFFFF;
  --radius:     18px;
  --shadow:     0 1px 2px rgba(13,20,64,.05), 0 12px 32px rgba(13,20,64,.08);
  --display:    'Inter Display', 'Inter', system-ui, sans-serif;
  --sans:       'Inter', system-ui, -apple-system, sans-serif;
  --wrap:       1200px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
html, body { overflow-x: clip; }
body { font-family: var(--sans); color: var(--text); background: var(--paper); font-size: 16.5px; line-height: 1.7; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: var(--blue); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1.5rem; }

/* ── Draft banner ── */
.draft { background: var(--pink); color: var(--ink); text-align: center; font-size: .8rem; font-weight: 600; padding: .35rem 1rem; letter-spacing: .02em; }

/* ── Header ── */
.header { position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.header .wrap { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.logo img { height: 44px; width: auto; }
.nav { display: flex; gap: 1.9rem; list-style: none; align-items: center; }
.nav a { text-decoration: none; color: var(--ink); font-weight: 600; font-size: .92rem; padding: .3rem 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a.current { border-bottom-color: var(--blue); }
.nav .nav-cta { background: var(--lime); color: var(--blue); padding: .55rem 1.1rem; border-radius: 999px; border: 0; }
.nav .nav-cta:hover { background: var(--lime-dark); }
.burger { display: none; background: none; border: 0; width: 42px; height: 42px; cursor: pointer; position: relative; z-index: 1001; }
.burger span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px auto; transition: transform .25s, opacity .25s; }
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Type ── */
h1, h2, h3 { font-family: var(--display); color: var(--ink); font-weight: 900; line-height: .98; letter-spacing: -.035em; }
h3 { font-weight: 800; letter-spacing: -.02em; line-height: 1.15; }
h1 { font-size: clamp(3rem, 8vw, 6.4rem); }
h2 { font-size: clamp(2.2rem, 4.8vw, 3.6rem); margin-bottom: .9rem; }
h3 { font-size: 1.4rem; }
em.accent { font-style: normal; color: var(--blue); }
.eyebrow { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--blue); background: var(--blue-soft); padding: .3rem .7rem; border-radius: 999px; margin-bottom: .8rem; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 660px; }
.section { padding: 6rem 0; }
.section-white { background: var(--white); }
.section-cream { background: var(--blue-soft); }
.section-green { background: var(--blue); color: rgba(255,255,255,.88); }
.section-green h2, .section-green h3 { color: #fff; }
.section-green .lead { color: rgba(255,255,255,.78); }
.section-green .eyebrow { color: var(--blue); background: var(--lime); }
.section-green em.accent { color: var(--lime); }
.head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: 2.6rem; }
.head-row h2 { margin-bottom: 0; }
.link-more { font-weight: 700; text-decoration: none; color: var(--blue); white-space: nowrap; }
.link-more:hover { color: var(--pink-dark); }

/* ── Buttons ── */
.btn { display: inline-flex; align-items: center; gap: .5rem; padding: .9rem 1.5rem; border-radius: 999px; font-weight: 600; font-size: .95rem; text-decoration: none; border: 2px solid var(--lime); background: var(--lime); color: var(--blue); font-weight: 700; cursor: pointer; font-family: var(--sans); transition: background .2s, border-color .2s, color .2s; }
.btn:hover { background: var(--lime-dark); border-color: var(--lime-dark); }
.btn-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.8); }
.btn-light:hover { background: #fff; color: var(--blue); border-color: #fff; }
.btn-green { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-green:hover { background: var(--blue-dark); border-color: var(--blue-dark); }
.btn-line { background: transparent; color: var(--blue); border-color: var(--blue); }
.btn-line:hover { background: var(--blue); color: #fff; }
.btns { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }

/* ── Hero ── */
.hero { position: relative; min-height: min(86vh, 780px); display: flex; align-items: flex-end; color: #fff; background: var(--blue) center / cover no-repeat; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(22,56,216,.96) 0%, rgba(22,56,216,.82) 34%, rgba(22,56,216,.25) 66%, rgba(22,56,216,0) 100%); }
.hero .wrap { position: relative; z-index: 1; width: 100%; padding-bottom: 4.5rem; }
.hero h1 { color: #fff; max-width: 860px; }
.hero h1 em { white-space: nowrap; font-style: normal; color: var(--lime); }
.hero p { font-size: 1.15rem; max-width: 580px; margin-top: 1.1rem; color: rgba(255,255,255,.92); }
.hero-sub { min-height: 440px; }
.hero-sub h1 { font-size: clamp(2.4rem, 5.6vw, 3.8rem); }
.crumb, .hero .crumb { display: inline-block; max-width: none; margin-top: 0; font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; color: var(--blue); background: var(--lime); padding: .3rem .75rem; border-radius: 999px; margin-bottom: .8rem; }

/* ── Village cards ── */
.villages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.village { position: relative; border-radius: var(--radius); overflow: hidden; min-height: 380px; display: flex; align-items: flex-end; color: #fff; text-decoration: none; background: var(--blue) center / cover no-repeat; box-shadow: var(--shadow); }
.village::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(22,56,216,.95) 0%, rgba(22,56,216,.35) 55%, rgba(22,56,216,0) 100%); transition: background .3s; }
.village:hover::after { background: linear-gradient(to top, rgba(22,56,216,.97) 0%, rgba(22,56,216,.55) 70%, rgba(22,56,216,.15) 100%); }
.village div { position: relative; z-index: 1; padding: 1.5rem; }
.village h3 { color: #fff; font-size: 2rem; font-weight: 900; }
.village p { font-size: .9rem; color: rgba(255,255,255,.85); margin-top: .3rem; }
.village span { display: inline-block; margin-top: .8rem; font-size: .82rem; font-weight: 700; color: var(--lime); }

/* ── Category tiles ── */
.cats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.cat { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; color: inherit; display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s; }
.cat:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(27,36,32,.06), 0 18px 40px rgba(27,36,32,.12); }
.cat img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.cat div { padding: 1.5rem 1.6rem 1.7rem; }
.cat h3 { margin-bottom: .35rem; }
.cat p { color: var(--muted); font-size: .95rem; }
.cat .go { display: inline-block; margin-top: .9rem; font-weight: 700; color: var(--blue); font-size: .9rem; }

/* ── Split block ── */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.split.flip > :first-child { order: 2; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 2rem; }
.fact { border-top: 3px solid var(--pink); padding-top: .7rem; }
.fact b { display: block; font-family: var(--display); font-weight: 900; letter-spacing: -.03em; font-size: 2rem; color: var(--blue); line-height: 1.05; }
.fact span { font-size: .82rem; color: var(--muted); }

/* ── Directory ── */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.chip { border: 1px solid var(--line); background: var(--white); color: var(--ink); border-radius: 999px; padding: .45rem 1rem; font-size: .88rem; font-weight: 600; cursor: pointer; font-family: var(--sans); }
.chip.on { background: var(--blue); color: #fff; border-color: var(--blue); }
.dir { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.entry { background: var(--white); border-radius: var(--radius); padding: 1.4rem 1.5rem; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .35rem; }
.entry[hidden] { display: none; }
.entry .tagrow { display: flex; gap: .4rem; flex-wrap: wrap; }
.tag { font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--blue); background: var(--blue-soft); border-radius: 999px; padding: .2rem .6rem; }
.tag.place { color: var(--pink-dark); background: var(--pink-soft); }
.entry h3 { font-size: 1.22rem; margin-top: .3rem; }
.entry p { font-size: .92rem; color: var(--muted); }
.entry .meta { font-size: .82rem; color: var(--muted); margin-top: auto; padding-top: .6rem; }
.entry .check { font-size: .75rem; color: var(--pink-dark); font-weight: 700; }
.entry.member { outline: 3px solid var(--lime); }

/* ── Events / Facebook ── */
.empty { background: var(--white); border: 1px dashed var(--line); border-radius: var(--radius); padding: 2.2rem; text-align: center; color: var(--muted); }
.empty h3 { margin-bottom: .4rem; }

/* ── Membership ── */
.price-card { background: var(--white); border-radius: 26px; box-shadow: var(--shadow); padding: 2.4rem; border-top: 8px solid var(--lime); }
.price-card .amount { font-family: var(--display); font-weight: 900; letter-spacing: -.04em; font-size: 4rem; color: var(--blue); line-height: 1; }
.price-card .amount small { font-family: var(--sans); font-size: 1rem; color: var(--muted); font-weight: 400; }
.benefits { list-style: none; margin: 1.6rem 0; display: grid; gap: .8rem; }
.benefits li { display: flex; gap: .8rem; align-items: flex-start; }
.benefits li::before { content: ""; flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 13px no-repeat; margin-top: .2rem; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; counter-reset: s; }
.step { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius); padding: 1.6rem; }
.step::before { counter-increment: s; content: counter(s); display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--lime); color: var(--blue); font-weight: 800; font-weight: 600; margin-bottom: .9rem; }
.step p { font-size: .94rem; }

/* ── Form ── */
.form { background: var(--white); border-radius: 22px; box-shadow: var(--shadow); padding: 2.2rem; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.fg { margin-bottom: 1rem; }
.form label { display: block; font-size: .8rem; font-weight: 600; color: var(--ink); margin-bottom: .35rem; }
.form input, .form select, .form textarea { width: 100%; padding: .8rem .95rem; border: 1px solid var(--line); border-radius: 10px; font: inherit; font-size: .95rem; background: var(--paper); color: var(--text); }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--blue); outline-offset: 1px; background: #fff; }
.form textarea { min-height: 110px; resize: vertical; }
.form-ok { display: none; background: var(--blue); color: #fff; padding: .9rem 1.1rem; border-radius: 10px; margin-bottom: 1rem; }

/* ── Join banner ── */
.join { background: var(--blue); border-radius: 30px; padding: 3.2rem; display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; color: rgba(255,255,255,.86); position: relative; overflow: hidden; }
.join::after { content: ""; position: absolute; right: -60px; top: -60px; width: 240px; height: 240px; border-radius: 50%; background: var(--pink); opacity: .9; }
.join h2 { color: #fff; }
.join > * { position: relative; z-index: 1; }
.join .btns { justify-content: flex-start; }
.join::after { right: -80px; top: -80px; width: 200px; height: 200px; }

/* ── Footer ── */
.footer { background: var(--blue-deep); color: rgba(255,255,255,.72); padding: 4rem 0 2.5rem; font-size: .9rem; }
.footer .cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 2.5rem; }
.footer img { height: 44px; width: auto; margin-bottom: 1rem; }
.footer h4 { color: #fff; font-size: .75rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: .8rem; }
.footer ul { list-style: none; }
.footer li { padding: .2rem 0; }
.footer a { color: rgba(255,255,255,.85); text-decoration: none; }
.footer a:hover { color: #fff; }
.footer .legal { border-top: 1px solid rgba(255,255,255,.12); margin-top: 2.5rem; padding-top: 1.5rem; font-size: .8rem; color: rgba(255,255,255,.55); }

/* ── Responsive ── */
@media (max-width: 1000px) {
  .villages { grid-template-columns: 1fr 1fr; }
  .dir, .cats { grid-template-columns: 1fr 1fr; }
  .split, .join { grid-template-columns: 1fr; gap: 2.4rem; }
  .split.flip > :first-child { order: 0; }
  .split img { aspect-ratio: 16 / 10; }
  .join .btns { justify-content: flex-start; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .header .wrap { height: 66px; }
  .logo img { height: 38px; }
  .header { backdrop-filter: none; -webkit-backdrop-filter: none; background: #fff; }
  .burger { display: block; }
  .nav { display: none; position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; background: #fff; flex-direction: column; justify-content: center; gap: 1.6rem; z-index: 1000; }
  .nav.open { display: flex; }
  .nav a { font-family: var(--display); font-size: 2rem; font-weight: 900; letter-spacing: -.03em; }
  .nav .nav-cta { font-family: var(--sans); font-size: 1.1rem; }
  .section { padding: 4rem 0; }
  .hero { min-height: 80vh; }
  .hero .wrap { padding-bottom: 3rem; }
  .villages, .dir, .cats, .row2, .footer .cols { grid-template-columns: 1fr; }
  .village { min-height: 260px; }
  .facts { grid-template-columns: 1fr 1fr 1fr; }
  .join { padding: 2.2rem 1.6rem; }
  .form, .price-card { padding: 1.5rem; }
}

/* ── Privacy page text ── */
.prose h2 { font-size: 1.6rem; margin: 2.2rem 0 .6rem; }
.prose p { margin-bottom: 1rem; }
.prose a { font-weight: 600; }
.prose .list { margin: 0 0 1rem 1.2rem; }
.prose .list li { margin-bottom: .4rem; }
.cookie-declaration { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.6rem; margin-top: 1rem; font-size: .9rem; overflow-x: auto; }

/* ── Cookiebot banner in Visit Flesberg colours (Cookiebot injects it into this page, so our CSS styles it) ── */
#CybotCookiebotDialog { font-family: var(--sans) !important; border-radius: 22px !important; box-shadow: 0 20px 60px rgba(13,20,64,.25) !important; color: var(--text) !important; border-top: 8px solid var(--lime) !important; }
#CybotCookiebotDialog h2, #CybotCookiebotDialogBodyContentTitle { font-family: var(--display) !important; font-weight: 900 !important; letter-spacing: -.02em !important; color: var(--ink) !important; }
#CybotCookiebotDialog a, #CybotCookiebotDialog .CybotCookiebotDialogDetailBodyContentCookieLink { color: var(--blue) !important; }
#CybotCookiebotDialog .CybotCookiebotDialogBodyButton { border-radius: 999px !important; font-weight: 700 !important; font-family: var(--sans) !important; }
#CybotCookiebotDialogBodyLevelButtonLevelOptinAllowAll, #CybotCookiebotDialogBodyButtonAccept { background: var(--blue) !important; border-color: var(--blue) !important; color: #fff !important; }
#CybotCookiebotDialogBodyButtonDecline, #CybotCookiebotDialogBodyLevelButtonCustomize, #CybotCookiebotDialogBodyLevelButtonLevelOptinAllowallSelection { background: #fff !important; border: 2px solid var(--blue) !important; color: var(--blue) !important; }
#CybotCookiebotDialog input:checked + .CybotCookiebotDialogBodyLevelButtonSlider { background-color: var(--blue) !important; }
#CybotCookiebotDialogNav .CybotCookiebotDialogNavItemLink.CybotCookiebotDialogActive { color: var(--blue) !important; border-bottom-color: var(--blue) !important; }

/* ── Kommunekart (own SVG, Kartverket border) ── */
.kart { width: 100%; height: auto; display: block; }
.kart .k-land { fill: var(--blue-soft); stroke: var(--blue); stroke-width: 2.5; stroke-linejoin: round; }
.kart .k-road { fill: none; stroke: var(--blue); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; opacity: .35; }
.kart .k-side { fill: none; stroke: var(--blue); stroke-width: 2; stroke-dasharray: 2 6; stroke-linecap: round; opacity: .45; }
.kart .k-road-l { font-size: 12px; font-weight: 700; fill: var(--blue); opacity: .6; letter-spacing: .05em; }
.kart .k-fjell { fill: var(--blue); opacity: .25; }
.kart .k-sub { font-size: 13px; font-weight: 600; fill: var(--muted); }
.kart .k-pin { cursor: pointer; }
.kart .k-pin text { font-family: var(--display); font-weight: 900; font-size: 19px; fill: var(--ink); paint-order: stroke; stroke: var(--blue-soft); stroke-width: 5px; stroke-linejoin: round; }
.kart .k-dot { fill: var(--lime); stroke: var(--blue); stroke-width: 3; transition: r .2s; }
.kart .k-pin:hover .k-dot { fill: var(--pink); }
.kart .k-pin:hover text { fill: var(--blue); }
.kart .k-pin.on .k-dot { fill: var(--pink); stroke: var(--ink); }
.kart .k-pin.on text { fill: var(--blue); }
.kart .k-ring { fill: none; stroke: var(--pink); stroke-width: 2; opacity: .6; animation: kpulse 2.2s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes kpulse { 0% { transform: scale(.6); opacity: .8; } 100% { transform: scale(1.5); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .kart .k-ring { animation: none; } }
.kart-credit { font-size: .72rem; color: var(--muted); margin-top: .4rem; text-align: right; }
.kart-split { align-items: start; }
.byg-text .lead + .lead { margin-top: 1rem; }
.did { margin-top: 1.4rem; background: var(--lime); color: var(--ink); border-radius: var(--radius); padding: 1.1rem 1.3rem; font-size: .95rem; }
.did b { display: block; font-family: var(--display); font-weight: 900; color: var(--blue); font-size: 1.1rem; margin-bottom: .2rem; }

/* ── Bygd sponsor bar ── */
.sponsor-bar { background: var(--ink); color: rgba(255,255,255,.85); font-size: .88rem; padding: .7rem 0; }
.sponsor-bar a { color: var(--lime); font-weight: 700; text-decoration: none; margin-left: .3rem; }
.sponsor-bar a:hover { text-decoration: underline; }
.sponsor-bar.open { background: var(--blue-deep); }
.sponsor-offer { margin: 1.2rem 0; padding: .9rem 1rem; border-radius: var(--radius); background: var(--pink-soft); color: var(--ink); font-size: .9rem; }
.crumb a { color: inherit; text-decoration: none; }
.crumb a:hover { text-decoration: underline; }

.villages-3 { grid-template-columns: repeat(3, 1fr); }
.skjer-cta .wrap { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.skjer-cta .lead { margin-top: .4rem; }
@media (max-width: 900px) {
  .villages-3 { grid-template-columns: 1fr; }
  .villages-3 .village { min-height: 220px; }
}
@media (max-width: 760px) {
  .kart .k-pin text { font-size: 25px; }
  .kart .k-sub, .kart .k-road-l { font-size: 16px; }
  .kart-credit { text-align: left; }
}
.entry .more { font-size: .85rem; font-weight: 700; color: var(--blue); text-decoration: none; margin-top: .3rem; }
.entry .more:hover { text-decoration: underline; }
.sources { font-size: .8rem; color: var(--muted); margin-top: 1.4rem; }
.sources a { color: var(--blue); }

/* Language switch */
.nav a.nav-lang { font-size: .78rem; font-weight: 800; letter-spacing: .08em; border: 2px solid var(--blue); color: var(--blue); border-radius: 999px; padding: .2rem .6rem; }
.nav a.nav-lang:hover { background: var(--blue); color: #fff; }
