/* Samichlaus Adligenswil – Stylesheet (weihnachtliches Farbkonzept, Hell/Dunkel)
   Header, Logo-Position und Flyout-Menü entsprechen dem Aufbau von samichlaus-adligenswil.ch */

/* ---------- Farb-Tokens: hell ---------- */
:root {
  --bg: #fbf6ec;            /* Kerzenlicht-Creme */
  --bg-alt: #f3e9d6;
  --surface: #ffffff;
  --text: #3f3a33;
  --muted: #6b645a;
  --heading: #1d4034;       /* Tannengrün */
  --accent: #1f6b4f;        /* Links */
  --accent-hover: #14402f;
  --red: #a81d27;           /* Weihnachtsrot */
  --red-dark: #7d131b;
  --gold: #b8892f;
  --header-bg: #fbf6ec;
  --line: #e4d8bf;
  --band: #17392d;          /* dunkles Tannengrün für Streifen */
  --band-text: #f5ecd7;
  --band-muted: #cfd8cc;
  --footer-bg: #17392d;
  --footer-text: #e7e0cd;
  --footer-link: #f0cf7e;
  --flyout-bg: rgba(251,246,236,.97);
  --hamburger: #1d4034;
  --hamburger-hover: #a81d27;
  --shadow: 0 2px 14px rgba(60,40,10,.12);
  --shadow-hover: 0 10px 28px rgba(60,40,10,.20);
  --todo-bg: #fff3c9; --todo-line: #c9a400; --todo-text: #5a4700;
  --logo-filter: none;
  --ph-from: #1d4034; --ph-to: #7d3a2a;
  --radius: 10px;
  --maxw: 1200px;
  color-scheme: light;
}
/* ---------- Farb-Tokens: dunkel ---------- */
:root[data-theme="dark"] {
  --bg: #0f1a15; --bg-alt: #15241d; --surface: #1b2c24;
  --text: #e6dfcf; --muted: #aaa392; --heading: #f6ecd2;
  --accent: #8fd3b0; --accent-hover: #bdebd2;
  --red: #c4343f; --red-dark: #dd4b56; --gold: #e3bb62;
  --header-bg: #0f1a15; --line: #2a4136;
  --band: #0a120f; --band-text: #f6ecd2; --band-muted: #b5bdb0;
  --footer-bg: #0a120f; --footer-text: #cfc9b8; --footer-link: #e3bb62;
  --flyout-bg: rgba(10,18,15,.97);
  --hamburger: #f6ecd2; --hamburger-hover: #e3bb62;
  --shadow: 0 2px 14px rgba(0,0,0,.5); --shadow-hover: 0 10px 28px rgba(0,0,0,.65);
  --todo-bg: #3a3210; --todo-line: #b99a00; --todo-text: #f1dc7a;
  --logo-filter: invert(.92);
  --ph-from: #15241d; --ph-to: #4a2a24;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1a15; --bg-alt: #15241d; --surface: #1b2c24;
    --text: #e6dfcf; --muted: #aaa392; --heading: #f6ecd2;
    --accent: #8fd3b0; --accent-hover: #bdebd2;
    --red: #c4343f; --red-dark: #dd4b56; --gold: #e3bb62;
    --header-bg: #0f1a15; --line: #2a4136;
    --band: #0a120f; --band-text: #f6ecd2; --band-muted: #b5bdb0;
    --footer-bg: #0a120f; --footer-text: #cfc9b8; --footer-link: #e3bb62;
    --flyout-bg: rgba(10,18,15,.97);
    --hamburger: #f6ecd2; --hamburger-hover: #e3bb62;
    --shadow: 0 2px 14px rgba(0,0,0,.5); --shadow-hover: 0 10px 28px rgba(0,0,0,.65);
    --todo-bg: #3a3210; --todo-line: #b99a00; --todo-text: #f1dc7a;
    --logo-filter: invert(.92);
    --ph-from: #15241d; --ph-to: #4a2a24;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: 'Mulish', system-ui, sans-serif; font-size: 18px; line-height: 1.6;
  transition: background-color .25s, color .25s;
}
img { max-width: 100%; height: auto; }
a { color: var(--accent); }
a:hover { color: var(--accent-hover); }
h1, h2, h3 { font-family: 'Baskervville', Georgia, serif; font-weight: 400; color: var(--heading); line-height: 1.25; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); }
h3 { font-size: clamp(1.3rem, 2.4vw, 1.7rem); }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--surface); color: var(--text); padding: 10px 14px; z-index: 100000; }
.skip:focus { left: 10px; top: 10px; }

/* Zuckerstangen-Band unter dem Header */
.candy { height: 6px; background: repeating-linear-gradient(135deg, var(--red) 0 10px, #fbf6ec 10px 20px); }
:root[data-theme="dark"] .candy { background: repeating-linear-gradient(135deg, var(--red) 0 10px, #2a4136 10px 20px); }

/* ---------- Header: Logo links, Menü rechts ---------- */
.site-header { position: sticky; top: 0; z-index: 10011; background: var(--header-bg); transition: background-color .25s; }
.site-header .inner { display: flex; align-items: center; justify-content: space-between; padding: 5px 30px; }
.logo img { display: block; height: 78px; width: auto; filter: var(--logo-filter); }
.header-tools { display: flex; align-items: center; gap: 6px; position: relative; z-index: 99999; }
.theme-toggle, .menu-toggle {
  display: flex; align-items: center; justify-content: center;
  min-width: 44px; min-height: 44px; background: none; border: 0; cursor: pointer; color: var(--hamburger); padding: 8px;
}
.theme-toggle:hover, .theme-toggle:focus-visible { color: var(--hamburger-hover); }
.theme-toggle svg { width: 24px; height: 24px; fill: currentColor; }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: block; }
}
.menu-toggle { flex-direction: column; gap: 6px; padding: 12px 8px; }
.menu-toggle .line { display: block; width: 30px; height: 3px; background: var(--hamburger); transition: .25s ease-in-out; }
.menu-toggle:hover .line, .menu-toggle:focus-visible .line { background: var(--hamburger-hover); }
.menu-open .menu-toggle .line:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.menu-open .menu-toggle .line:nth-child(2) { opacity: 0; }
.menu-open .menu-toggle .line:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ---------- Flyout-Menü ---------- */
.flyout {
  position: fixed; inset: 0; z-index: 99997; background: var(--flyout-bg);
  display: flex; align-items: center; justify-content: center; overflow-y: auto;
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s;
}
.menu-open .flyout { opacity: 1; visibility: visible; }
.menu-open { overflow: hidden; }
.flyout ul { list-style: none; margin: 0; padding: 70px 0 30px; text-align: center; }
.flyout li { padding: 12px 0; }
.flyout a { font-family: 'Karla', sans-serif; font-weight: 700; font-size: 22px; color: var(--heading); text-decoration: none; padding: 6px 12px; display: inline-block; }
.flyout a:hover, .flyout a:focus-visible, .flyout a[aria-current="page"] { color: var(--red); }
:root[data-theme="dark"] .flyout a:hover, :root[data-theme="dark"] .flyout a[aria-current="page"] { color: var(--gold); }
.flyout .minor a { font-weight: 400; font-size: 17px; color: var(--muted); }
.flyout .divider { height: 2px; width: 60px; background: var(--gold); margin: 6px auto; padding: 0; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: clamp(320px, 60vh, 640px); display: flex; align-items: flex-end; color: #fff; overflow: hidden; background: linear-gradient(135deg, var(--ph-from), var(--ph-to)); }
.hero .bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8,18,13,.85) 0%, rgba(8,18,13,.45) 45%, rgba(8,18,13,.05) 80%); }
.hero .content { position: relative; z-index: 2; padding: 40px 20px 56px; width: 100%; max-width: var(--maxw); margin: 0 auto; }
.hero.has-cards .content { padding-bottom: 130px; }  /* Platz für die überlappenden Kacheln */
.hero h1 { color: #fff; margin: 0 0 .35em; text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.hero .eyebrow { letter-spacing: .14em; text-transform: uppercase; font-size: .85rem; font-weight: 700; color: #f2d27a; margin-bottom: .6em; }
.hero p { max-width: 640px; font-size: 1.15rem; margin: 0; text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.hero.small { min-height: clamp(260px, 42vh, 440px); }
.snow { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.ph-label { position: absolute; top: 12px; right: 12px; z-index: 3; background: rgba(255,255,255,.9); color: #444; font-size: 12px; padding: 4px 8px; border-radius: 4px; }
.ph { background: linear-gradient(135deg, var(--ph-from), var(--ph-to)); }

/* ---------- Sektionen ---------- */
section { padding: 56px 0; }
section.alt { background: var(--bg-alt); }
.lead { font-size: 1.2rem; max-width: 760px; }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }
.center h2::after { content: "✦"; display: block; color: var(--gold); font-size: 1rem; margin-top: .3em; letter-spacing: .5em; }

/* ---------- Kacheln ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: -90px; position: relative; z-index: 5; }
.card { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; text-decoration: none; color: var(--text); transition: transform .2s, box-shadow .2s; border-top: 4px solid var(--red); }
.card:nth-child(2) { border-top-color: var(--heading); }
.card:nth-child(3) { border-top-color: var(--gold); }
:root[data-theme="dark"] .card:nth-child(2) { border-top-color: #4f8a6f; }
.card:hover, .card:focus-visible { transform: translateY(-4px); box-shadow: var(--shadow-hover); color: var(--text); }
.card .img { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }
.card .img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s; }
.card:hover .img img { transform: scale(1.04); }
.card .body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card .kicker { font-family: 'Karla', sans-serif; font-weight: 700; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; color: var(--red); }
:root[data-theme="dark"] .card .kicker { color: var(--gold); }
.card h3 { margin: 0; }
.card p { margin: 0 0 8px; flex: 1; }
.card .more { font-family: 'Karla', sans-serif; font-weight: 700; color: var(--red); }
:root[data-theme="dark"] .card .more { color: var(--gold); }
.card:hover .more { text-decoration: underline; }

/* ---------- Saison-Streifen ---------- */
.season { background: var(--band); color: var(--band-text); padding: 38px 0; margin-top: 56px; border-top: 3px solid var(--gold); border-bottom: 3px solid var(--gold); }
.season h2 { color: var(--band-text); font-size: 1.8rem; margin-bottom: .8em; }
.season ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.season li { border-left: 3px solid var(--red); padding-left: 14px; }
.season li strong { display: block; font-family: 'Karla', sans-serif; font-size: 1.05rem; }
.season li span { color: var(--band-muted); font-size: .95rem; }
.season a { color: #f2d27a; }

/* ---------- Zweispalter ---------- */
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.two .ph { position: relative; aspect-ratio: 4 / 3; border-radius: var(--radius); }
.photo { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 4 / 3; }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.stat { font-family: 'Baskervville', serif; font-size: 3rem; color: var(--red); line-height: 1; }
:root[data-theme="dark"] .stat { color: var(--gold); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; min-height: 44px; padding: 12px 26px; border-radius: 6px;
  background: var(--red); color: #fff; text-decoration: none; font-family: 'Karla', sans-serif; font-weight: 700; font-size: 1.05rem; border: 2px solid var(--red);
  transition: background .2s, color .2s;
}
.btn:hover, .btn:focus-visible { background: var(--red-dark); border-color: var(--red-dark); color: #fff; }
.btn.ghost { background: transparent; color: var(--red); }
.btn.ghost:hover { background: var(--red); color: #fff; border-color: var(--red); }
:root[data-theme="dark"] .btn.ghost { color: var(--gold); border-color: var(--gold); }
:root[data-theme="dark"] .btn.ghost:hover { background: var(--gold); color: #1a1405; border-color: var(--gold); }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 20px; }

/* ---------- Inhalte ---------- */
.steps { list-style: none; counter-reset: s; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.steps li { counter-increment: s; background: var(--surface); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.steps li::before { content: counter(s); display: block; font-family: 'Baskervville', serif; font-size: 2.2rem; color: var(--red); line-height: 1; margin-bottom: 8px; }
:root[data-theme="dark"] .steps li::before { color: var(--gold); }
.steps strong { display: block; font-family: 'Karla', sans-serif; color: var(--heading); }

.days { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 20px; }
.day { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; border-top: 4px solid var(--red); }
.day h3 { font-size: 1.25rem; margin: 0 0 4px; }
.day .date { font-family: 'Karla', sans-serif; font-weight: 700; color: var(--red); margin-bottom: 10px; display: block; }
:root[data-theme="dark"] .day .date { color: var(--gold); }
.day ul { margin: 0; padding-left: 18px; font-size: .95rem; }
.search { margin-top: 16px; }
.search input { width: 100%; max-width: 420px; min-height: 44px; padding: 10px 14px; font: inherit; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.search-result { margin-top: 10px; font-weight: 700; color: var(--accent); min-height: 1.5em; }

.callout { background: var(--surface); border-left: 4px solid var(--red); border-radius: 0 var(--radius) var(--radius) 0; padding: 18px 22px; box-shadow: var(--shadow); margin: 20px 0; }
.todo { background: var(--todo-bg); border: 1px dashed var(--todo-line); color: var(--todo-text); border-radius: 6px; padding: 2px 8px; font-size: .92em; }
.season .todo { color: var(--todo-text); }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-top: 24px; }
.tile { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.tile .ph, .tile .shot { position: relative; aspect-ratio: 16 / 10; }
.tile .shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile .t-body { padding: 18px 22px 22px; }
.tile h3 { margin-bottom: .3em; }
.who { font-size: .92rem; color: var(--muted); }
.quote { font-family: 'Baskervville', serif; font-size: 1.6rem; color: var(--heading); font-style: italic; margin: 18px 0; }

details { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 10px; }
summary { cursor: pointer; padding: 16px 20px; font-family: 'Karla', sans-serif; font-weight: 700; font-size: 1.05rem; min-height: 44px; list-style: none; position: relative; padding-right: 48px; color: var(--heading); }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); font-size: 1.5rem; color: var(--red); }
:root[data-theme="dark"] summary::after { color: var(--gold); }
details[open] summary::after { content: "–"; }
details > div { padding: 0 20px 18px; }

.legal { max-width: 800px; }
.legal h1 { font-size: 2.4rem; }
.legal h2 { font-size: 1.5rem; margin-top: 1.6em; }
.legal p { font-size: 1rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--footer-bg); color: var(--footer-text); font-size: 15px; padding: 40px 0 18px; border-top: 3px solid var(--gold); }
.foot-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 28px; }
.site-footer h4 { margin: 0 0 .5em; font-family: 'Karla', sans-serif; font-size: 1.05rem; color: #f2d27a; }
.site-footer a { color: var(--footer-link); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 4px; }
.copyright { margin-top: 26px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.15); font-size: 12px; opacity: .85; }

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

/* ---------- Tablet / Mobil ---------- */
@media (max-width: 1000px) {
  .season ul, .days, .steps { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 800px) {
  body { font-size: 17px; }
  .site-header .inner { padding: 5px 16px; }
  .logo img { height: 52px; }
  .cards { grid-template-columns: 1fr; margin-top: -70px; gap: 20px; }
  .hero.has-cards .content { padding-bottom: 100px; }
  .two, .foot-grid, .grid-2 { grid-template-columns: 1fr; }
  section { padding: 40px 0; }
}
@media (max-width: 560px) {
  .season ul, .days, .steps, .grid-3 { grid-template-columns: 1fr; }
  .btn { display: block; text-align: center; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } .snow { display: none; } }
