/* ═══════════════════════════════════════════════════════════════════════════
   AHlles Paletti · Shared Stylesheet
   Schrift: Inter (600/700/800 Headings · 400/500 Body)
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Lokale Fonts (DSGVO-konform – keine Übertragung an Google) ───────────────── */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 300; font-display: swap;
  src: url('fonts/inter-latin-300-normal.woff2') format('woff2'), url('fonts/inter-latin-300-normal.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('fonts/inter-latin-400-normal.woff2') format('woff2'), url('fonts/inter-latin-400-normal.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('fonts/inter-latin-500-normal.woff2') format('woff2'), url('fonts/inter-latin-500-normal.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('fonts/inter-latin-600-normal.woff2') format('woff2'), url('fonts/inter-latin-600-normal.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('fonts/inter-latin-700-normal.woff2') format('woff2'), url('fonts/inter-latin-700-normal.woff') format('woff'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 800; font-display: swap;
  src: url('fonts/inter-latin-800-normal.woff2') format('woff2'), url('fonts/inter-latin-800-normal.woff') format('woff'); }
@font-face { font-family: 'Caveat'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('fonts/caveat-latin-500-normal.woff2') format('woff2'), url('fonts/caveat-latin-500-normal.woff') format('woff'); }
@font-face { font-family: 'Caveat'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('fonts/caveat-latin-700-normal.woff2') format('woff2'), url('fonts/caveat-latin-700-normal.woff') format('woff'); }
/* Fraunces — display serif (DSGVO-konform, selbst gehostet) */
@font-face { font-family: 'Fraunces'; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('fonts/fraunces-normal-latin.woff2') format('woff2'); }
@font-face { font-family: 'Fraunces'; font-style: italic; font-weight: 400 700; font-display: swap;
  src: url('fonts/fraunces-italic-latin.woff2') format('woff2'); }

/* ── TOKENS — Werkstatt-Palette (Cream · Navy · Holz) ──────────────────────── */
:root {
  --bg:            #FAF7F1;
  --bg-warm:       #F6F1E6;
  --bg-section:    #EFE7D5;
  --bg-dark:       #0A1238;
  --text:          #1E3A8A;
  --text-light:    #3B4A6B;
  --text-muted:    #7A8198;
  --primary:       #1E3A8A;
  --primary-dark:  #0E1E5C;
  --primary-light: #E5EBF7;
  --accent:        #C8965A;
  --accent-dark:   #8B6033;
  --accent-light:  #F0E4D0;
  --border:        #DDD4C2;
  --border-light:  #EAE3D6;
  --success:       #2A9D5C;
  --danger:        #D44040;
  --warn:          #E8A020;
  --radius:        10px;
  --radius-lg:     18px;
  --radius-xl:     24px;
  --shadow-xs:     0 1px 4px rgba(30,58,138,.06);
  --shadow-sm:     0 2px 10px rgba(30,58,138,.09);
  --shadow-md:     0 6px 24px rgba(30,58,138,.12);
  --shadow-lg:     0 16px 48px rgba(30,58,138,.16);
  --max-w:         1100px;
  --nav-h:         68px;
  --transition:    .2s ease;
}

/* ── DARK MODE ──────────────────────────────────────────────────────────────────────── */
[data-theme="dark"] {
  --bg:            #0F1422;
  --bg-warm:       #141B2E;
  --bg-section:    #192238;
  --bg-dark:       #06080F;
  --text:          #E2E8FA;
  --text-light:    #9AAAD4;
  --text-muted:    #5C70A8;
  --primary:       #5C78E8;
  --primary-dark:  #3A58C8;
  --primary-light: #1A2448;
  --accent:        #E8B87A;
  --accent-dark:   #C89858;
  --accent-light:  #2A1E10;
  --border:        #2A3660;
  --border-light:  #1E2A48;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0F1422; --bg-warm: #141B2E; --bg-section: #192238; --bg-dark: #06080F;
    --text: #E2E8FA; --text-light: #9AAAD4; --text-muted: #5C70A8;
    --primary: #5C78E8; --primary-dark: #3A58C8; --primary-light: #1A2448;
    --accent: #E8B87A; --accent-dark: #C89858; --accent-light: #2A1E10;
    --border: #2A3660; --border-light: #1E2A48;
  }
}
[data-theme="dark"] .nav-logo-img,
:root:not([data-theme="light"]) .nav-logo-img { filter: brightness(0) invert(1) opacity(.85); }

/* Dark mode table overrides */
[data-theme="dark"] .data-table,
:root:not([data-theme="light"]) .data-table {
  background: var(--bg-warm);
}
[data-theme="dark"] .data-table td,
:root:not([data-theme="light"]) .data-table td {
  color: var(--text);
  border-bottom-color: var(--border);
}
[data-theme="dark"] .data-table tr:last-child td,
:root:not([data-theme="light"]) .data-table tr:last-child td {
  border: none;
}

.skip-link { position:absolute;top:-100%;left:1rem;padding:.5rem 1rem;background:var(--primary);color:#fff;border-radius:var(--radius);font-weight:600;text-decoration:none;z-index:9999;transition:top .2s; }
.skip-link:focus { top:1rem; }

.btn-theme-toggle {
  background: none; border: none; cursor: pointer; font-size: 1.1rem;
  padding: 6px 8px; border-radius: var(--radius); line-height: 1;
  color: var(--text); transition: background var(--transition);
  display: inline-flex; align-items: center; justify-content: center;
}
.btn-theme-toggle:hover { background: var(--primary-light); }
.btn-theme-mobile { width: 100%; text-align: left; padding: .75rem 1rem; font-size: 1rem; }

/* ── RESET ──────────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 16px; font-weight: 400;
  color: var(--text); background: var(--bg);
  line-height: 1.65; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ── TYPOGRAPHY ───────────────────────────────────────────────────────────────────── */
h1 { font-family: 'Fraunces', Georgia, serif; font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 600; line-height: 1.05; letter-spacing: -.03em; }
h2 { font-family: 'Fraunces', Georgia, serif; font-size: clamp(1.6rem, 3.5vw, 2.5rem); font-weight: 600; line-height: 1.1; letter-spacing: -.025em; }
h3 { font-size: 1.25rem; font-weight: 700; line-height: 1.3; }
h4 { font-size: 1rem; font-weight: 600; line-height: 1.4; }
p  { color: var(--text-light); line-height: 1.75; }

.eyebrow {
  display: inline-block;
  font-size: .72rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-dark); margin-bottom: .6rem;
}

/* ── LAYOUT ──────────────────────────────────────────────────────────────────────── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.section    { padding: 88px 0; }
.section-sm { padding: 56px 0; }
.section-alt  { background: var(--bg-warm); }
.section-dark { background: var(--bg-dark); color: #fff; }
.section-dark p { color: rgba(255,255,255,.65); }

.section-header { margin-bottom: 52px; }
.section-header p { max-width: 540px; margin: 12px auto 0; font-size: 1.05rem; }
.text-center { text-align: center; }

/* ── BUTTONS ──────────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 28px; border-radius: var(--radius);
  font-size: .88rem; font-weight: 600; letter-spacing: .01em;
  border: 2px solid transparent;
  transition: all var(--transition); white-space: nowrap;
}
.btn-lg  { padding: 16px 40px; font-size: .95rem; }
.btn-sm  { padding: 9px 18px; font-size: .8rem; }
.btn-icon{ padding: 11px; }

.btn-primary  { background: var(--primary); color: #fff; box-shadow: 0 3px 14px rgba(40,64,168,.28); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 5px 18px rgba(40,64,168,.38); }

.btn-accent   { background: var(--accent); color: #fff; box-shadow: 0 3px 14px rgba(107,133,212,.30); }
.btn-accent:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-outline  { border-color: var(--primary); color: var(--primary); background: transparent; }
.btn-outline:hover { background: var(--primary); color: #fff; }

.btn-ghost    { background: transparent; color: var(--text-light); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

.btn-danger   { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b83030; }

.btn-success  { background: var(--success); color: #fff; }

/* ── NAVIGATION ───────────────────────────────────────────────────────────────────── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h);
  background: rgba(250,247,241,.96);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-light);
  transition: box-shadow var(--transition);
}
.nav.scrolled { box-shadow: var(--shadow-sm); }
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--nav-h); gap: 16px;
}
.nav-logo {
  display: flex; align-items: center;
  flex-shrink: 0;
}
.nav-logo-img {
  height: 38px; width: auto;
  /* SVG has dark text – invert to white on dark nav backgrounds if needed */
}
/* Fallback for older span-based logo */
.nav-logo span { color: var(--accent); }

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
  padding: 7px 14px; border-radius: 8px;
  font-size: .875rem; font-weight: 500; color: var(--text-light);
  transition: all var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--primary); background: var(--primary-light); }

.nav-cta { margin-left: 8px; flex-shrink: 0; }
.nav-hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; padding: 8px;
}
.nav-hamburger span {
  display: block; width: 22px; height: 2px;
  background: var(--text); border-radius: 2px;
  transition: all .3s;
}
/* Mobile menu */
.mobile-nav {
  display: none; position: fixed;
  top: var(--nav-h); left: 0; right: 0; z-index: 999;
  background: #fff; padding: 16px 24px 24px;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.mobile-nav.open { display: flex; flex-direction: column; gap: 4px; }
.mobile-nav a {
  padding: 12px 16px; border-radius: var(--radius);
  font-weight: 500; color: var(--text);
  transition: background var(--transition);
}
.mobile-nav a:hover { background: var(--primary-light); color: var(--primary); }
.mobile-nav a.active { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.mobile-nav .btn { margin-top: 8px; justify-content: center; color: #fff; }

/* ── PAGE HEADER (Seitentitel) ──────────────────────────────────────────────────────── */
.page-header {
  padding: calc(var(--nav-h) + 56px) 0 56px;
  background: linear-gradient(135deg, var(--bg-warm) 0%, var(--primary-light) 100%);
  border-bottom: 1px solid var(--border-light);
}
.page-header h1 { margin-bottom: 12px; }
.page-header p { max-width: 560px; font-size: 1.05rem; }

/* ── CARDS ──────────────────────────────────────────────────────────────────────── */
.card {
  background: #fff; border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  transition: all .25s ease;
  overflow: hidden;
}
.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--accent-light);
  transform: translateY(-3px);
}
.card-body { padding: 24px; }

/* ── FORMS ──────────────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-label {
  display: block; font-size: .8rem; font-weight: 600;
  color: var(--text-light); margin-bottom: 6px; letter-spacing: .01em;
}
.form-control {
  width: 100%; padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius); background: #fff;
  font-size: .9rem; color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(40,64,168,.12);
}
.form-control::placeholder { color: var(--text-muted); }
textarea.form-control { resize: vertical; min-height: 96px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-hint { font-size: .76rem; color: var(--text-muted); margin-top: 5px; }
.form-error{ font-size: .76rem; color: var(--danger); margin-top: 5px; }

/* ── BADGES & TAGS ──────────────────────────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center;
  padding: 3px 10px; border-radius: 20px;
  font-size: .72rem; font-weight: 700;
}
.badge-primary { background: var(--primary-light); color: var(--primary); }
.badge-accent  { background: var(--accent-light); color: var(--accent-dark); }
.badge-success { background: #e6f7ee; color: var(--success); }
.badge-warn    { background: #fdf3e0; color: #a06010; }
.badge-danger  { background: #fde8e8; color: var(--danger); }

/* ── IMAGE PLACEHOLDERS ─────────────────────────────────────────────────────────────────── */
.img-ph {
  position: relative;          /* Enthält position:absolute Kinder (Produktbilder etc.) */
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 8px;
  font-size: .78rem; font-weight: 500;
  color: rgba(255,255,255,.7);
}
.ph-bar     { background: linear-gradient(140deg,#1E3A8A,#0E1E5C); }
.ph-candy   { background: linear-gradient(140deg,#C8965A,#8B6033); }
.ph-photo   { background: linear-gradient(140deg,#3B4A6B,#1E3A8A); }
.ph-green   { background: linear-gradient(140deg,#6B8A4A,#3A5A20); }
.ph-amber   { background: linear-gradient(140deg,#C8965A,#E8B87A); }
.ph-dark    { background: linear-gradient(140deg,#0A1238,#1E3A8A); }

/* ── ALERTS ──────────────────────────────────────────────────────────────────────── */
.alert {
  padding: 14px 18px; border-radius: var(--radius);
  font-size: .88rem; display: flex; align-items: flex-start; gap: 10px;
  margin-bottom: 16px;
}
.alert-info    { background: var(--primary-light); color: var(--primary-dark); border-left: 4px solid var(--primary); }
.alert-success { background: #e6f7ee; color: #1a6638; border-left: 4px solid var(--success); }
.alert-warn    { background: #fdf3e0; color: #6b3d00; border-left: 4px solid var(--warn); }
.alert-danger  { background: #fde8e8; color: #8b1a1a; border-left: 4px solid var(--danger); }

/* ── DIVIDER ──────────────────────────────────────────────────────────────────────── */
.divider { height: 1px; background: var(--border-light); margin: 24px 0; }

/* ── SCROLL ANIMATIONS ──────────────────────────────────────────────────────────────────── */
.fade-up {
  opacity: 0; transform: translateY(24px);
  transition: opacity .55s ease, transform .55s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* ── FOOTER ──────────────────────────────────────────────────────────────────────── */
.footer { background: var(--bg-dark); color: rgba(255,255,255,.75); padding: 64px 0 28px; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px; margin-bottom: 48px;
}
.footer-logo { margin-bottom: 12px; }
.footer-logo-img { height: 36px; width: auto; filter: brightness(0) invert(1); opacity: .9; }
/* Fallback */
.footer-logo span { color: var(--accent); }
.footer-desc { font-size: .86rem; color: rgba(255,255,255,.5); line-height: 1.7; margin-bottom: 20px; }
.footer-col h4 {
  font-size: .72rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: rgba(255,255,255,.4);
  margin-bottom: 16px;
}
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul a { font-size: .875rem; color: rgba(255,255,255,.6); transition: color var(--transition); }
.footer-col ul a:hover { color: var(--accent); }
.footer-bottom {
  padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
}
.footer-bottom p { font-size: .78rem; color: rgba(255,255,255,.35); margin: 0; }
.footer-legal { display: flex; gap: 20px; }
.footer-legal a { font-size: .78rem; color: rgba(255,255,255,.35); transition: color var(--transition); }
.footer-legal a:hover { color: rgba(255,255,255,.7); }

/* ── USP-BAR ──────────────────────────────────────────────────────────────────────── */
.usp-bar { background: var(--primary); padding: 22px 0; }
.usp-bar-inner {
  display: flex; align-items: center; justify-content: center;
  gap: 48px; flex-wrap: wrap;
}
.usp-item { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,.9); }
.usp-item svg { color: var(--accent-light); flex-shrink: 0; }
.usp-item span { font-size: .875rem; font-weight: 500; }

/* ── STEP PROGRESS ──────────────────────────────────────────────────────────────────────── */
.step-progress { display: flex; align-items: center; justify-content: center; gap: 0; margin-bottom: 48px; }
.step-item {
  display: flex; flex-direction: column; align-items: center;
  gap: 8px; position: relative; flex: 1; max-width: 180px;
}
.step-item:not(:last-child)::after {
  content: '';
  position: absolute; top: 20px; left: calc(50% + 24px);
  width: calc(100% - 48px); height: 2px;
  background: var(--border);
  transition: background .4s;
}
.step-item.done::after,
.step-item.active::after { background: var(--primary); }
.step-dot {
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--border-light); color: var(--text-muted);
  font-size: .8rem; font-weight: 700;
  border: 2px solid var(--border);
  transition: all .3s; z-index: 1;
}
.step-item.active .step-dot { background: var(--primary); color: #fff; border-color: var(--primary); }
.step-item.done .step-dot   { background: var(--success); color: #fff; border-color: var(--success); }
.step-label { font-size: .75rem; font-weight: 600; color: var(--text-muted); text-align: center; }
.step-item.active .step-label { color: var(--primary); }
.step-item.done .step-label   { color: var(--success); }

/* ── CALENDAR ──────────────────────────────────────────────────────────────────────── */
.calendar { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.cal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; background: var(--primary); color: #fff;
}
.cal-header h3 { font-size: 1rem; font-weight: 700; }
.cal-nav { background: none; border: none; color: #fff; padding: 4px 8px; border-radius: 6px; cursor: pointer; }
.cal-nav:hover { background: rgba(255,255,255,.15); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal-day-name {
  padding: 10px 0; text-align: center;
  font-size: .72rem; font-weight: 700;
  color: var(--text-muted); letter-spacing: .06em; text-transform: uppercase;
}
.cal-day {
  padding: 10px 0; text-align: center;
  font-size: .88rem; cursor: pointer;
  border-radius: 8px; margin: 2px;
  transition: all var(--transition);
  position: relative;
}
.cal-day:hover:not(.blocked):not(.past) { background: var(--primary-light); color: var(--primary); }
.cal-day.today { font-weight: 700; color: var(--accent); }
.cal-day.selected { background: var(--primary); color: #fff; font-weight: 700; }
.cal-day.blocked { background: #fde8e8; color: var(--danger); text-decoration: line-through; cursor: not-allowed; }
.cal-day.product-booked { background: #fef3c7; color: #92400e; cursor: pointer; }
.cal-day.product-booked:hover { background: #fde68a; }
.cal-day.past { color: var(--text-muted); cursor: not-allowed; opacity: .4; }
.cal-day.wrong-weekday { color: var(--text-muted); cursor: not-allowed; opacity: .35; }
.cal-day.empty { cursor: default; }

/* ── SUMMARY SIDEBAR ───────────────────────────────────────────────────────────────────── */
.booking-summary {
  background: var(--bg-warm); border: 1px solid var(--border-light);
  border-radius: var(--radius-lg); padding: 24px; position: sticky; top: calc(var(--nav-h) + 20px);
}
.booking-summary h3 { margin-bottom: 16px; font-size: 1rem; }
.summary-item {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: 10px 0; border-bottom: 1px solid var(--border-light);
  font-size: .875rem; gap: 12px;
}
.summary-item:last-of-type { border: none; }
.summary-item .label { color: var(--text-light); }
.summary-item .value { font-weight: 600; text-align: right; }
.summary-total {
  display: flex; justify-content: space-between;
  padding-top: 14px; margin-top: 4px;
  border-top: 2px solid var(--border);
  font-weight: 700; font-size: 1.1rem; color: var(--primary);
}

/* ── ADMIN ──────────────────────────────────────────────────────────────═─────────── */
.admin-layout { display: grid; grid-template-columns: 220px 1fr; min-height: calc(100vh - var(--nav-h)); }
.admin-sidebar {
  background: var(--bg-dark); padding: 28px 16px;
  position: sticky; top: var(--nav-h); height: calc(100vh - var(--nav-h)); overflow-y: auto;
}
.admin-sidebar h3 { font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.35); margin-bottom: 8px; padding: 0 12px; }
.admin-nav-link {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: var(--radius);
  font-size: .875rem; font-weight: 500; color: rgba(255,255,255,.65);
  transition: all var(--transition); margin-bottom: 2px; cursor: pointer;
  border: none; background: transparent; width: 100%; text-align: left;
}
.admin-nav-link:hover   { background: rgba(255,255,255,.1); color: #fff; }
.admin-nav-link.active  { background: var(--primary); color: #fff; }
.admin-content { padding: 32px; background: var(--bg-warm); }
.admin-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.admin-header h2 { font-size: 1.5rem; }

/* Data table */
.data-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-xs); }
.data-table th {
  padding: 12px 16px; text-align: left;
  font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: var(--primary); color: #fff;
}
.data-table td { padding: 12px 16px; border-bottom: 1px solid var(--border-light); font-size: .875rem; vertical-align: middle; }
.data-table tr:last-child td { border: none; }
.data-table tr:hover td { background: var(--bg-warm); }

/* ── SCROLL-WRAPPER FÜR STICKY THEAD (FEAT-13) ───────────────────── */
.table-scroll-wrap {
  overflow-y: auto;
  max-height: calc(100vh - var(--nav-h) - 180px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.table-scroll-wrap::-webkit-scrollbar        { width: 6px; }
.table-scroll-wrap::-webkit-scrollbar-track  { background: transparent; }
.table-scroll-wrap::-webkit-scrollbar-thumb  { background: var(--border); border-radius: 3px; }
.table-scroll-wrap .data-table { overflow: visible; border-radius: 0; box-shadow: none; }
.table-scroll-wrap .data-table thead th { position: sticky; top: 0; z-index: 10; }
.table-scroll-wrap .data-table thead tr th:first-child { border-radius: var(--radius-lg) 0 0 0; }
.table-scroll-wrap .data-table thead tr th:last-child  { border-radius: 0 var(--radius-lg) 0 0; }

.td-actions { display: flex; gap: 8px; }

/* Modal */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 2000;
  background: rgba(15,27,80,.60); backdrop-filter: blur(4px);
  align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal {
  background: #fff; border-radius: var(--radius-xl);
  padding: 36px; width: 90%; max-width: 560px;
  max-height: 90vh; overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: modalIn .2s ease;
}
@keyframes modalIn { from { opacity:0; transform:scale(.95); } to { opacity:1; transform:scale(1); } }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.modal-header h3 { font-size: 1.25rem; }
.modal-close { background: none; border: none; font-size: 1.4rem; color: var(--text-muted); line-height: 1; padding: 4px; }
.modal-close:hover { color: var(--text); }
.modal-footer {
  display: flex; gap: 10px; justify-content: flex-end;
  margin-top: 24px; padding-top: 20px;
  border-top: 1px solid var(--border-light);
  position: sticky; bottom: -36px;
  background: #fff; margin-left: -36px; margin-right: -36px;
  padding-left: 36px; padding-right: 36px; padding-bottom: 24px;
  z-index: 1;
}

/* ── RESPONSIVE ──────────────────────────────────────────────────────────────────────── */
@media (max-width: 960px) {
  .section, .section-sm { padding: 64px 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 900px) {
  .nav-links, .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
}
@media (max-width: 640px) {
  .section { padding: 48px 0; }
  .section-sm { padding: 36px 0; }
  .container { padding: 0 16px; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .usp-bar-inner { flex-direction: column; align-items: flex-start; padding: 0 16px; gap: 14px; }
  .step-label { display: none; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { display: none; }
  /* Touch targets: Buttons mindestens 44px hoch */
  .btn { min-height: 44px; }
  /* Kalender-Tage: sicherere Tap-Fläche */
  .cal-day { min-height: 38px; display: flex; align-items: center; justify-content: center; }
  /* Cards: weniger Außenabstand */
  .card-body { padding: 18px; }
  /* Modal volle Breite auf kleinen Screens */
  .modal { padding: 24px; border-radius: var(--radius-lg); }
  .modal-footer { margin-left: -24px; margin-right: -24px; padding-left: 24px; padding-right: 24px; bottom: -24px; }
  /* Page-Header kompakter */
  .page-header { padding: calc(var(--nav-h) + 36px) 0 36px; }
}

/* ── Sticky CTA Mobile (FEAT-21) ────────────────────────────────────── */
.cta-sticky { display: none; }
@media (max-width: 768px) {
  body { padding-bottom: 72px; }
  .cta-sticky {
    display: block;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    z-index: 100;
    padding: 1rem;
    background: var(--bg);
    border-top: 1px solid var(--border-light);
    box-shadow: 0 -4px 16px oklch(0.2 0 0 / 0.08);
    transition: opacity 0.2s;
  }
  .cta-sticky a {
    display: block;
    width: 100%;
    text-align: center;
    padding: .875rem 1.5rem;
    background: var(--primary);
    color: #fff;
    border-radius: .5rem;
    font-weight: 600;
    text-decoration: none;
    font-size: 1rem;
  }
  .cta-sticky a:hover { background: var(--primary-dark); }
}

/* ── Accessibility ──────────────────────────────────────────────────────── */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ── Skip-Link (Accessibility) ──────────────────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  padding: .5rem 1rem;
  background: var(--primary);
  color: #fff;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  z-index: 9999;
  transition: top .2s;
}
.skip-link:focus { top: 1rem; }

/* ── Buchungsstatus: Vertrag-Link ────────────────────────────────────────── */
.contract-view-link {
  display: inline-block;
  margin-top: 5px;
  font-size: .82rem;
  color: var(--text-muted);
  text-decoration: none;
  opacity: .75;
}
.contract-view-link:hover { opacity: 1; text-decoration: underline; }

/* ── Admin: Dokument-Aktionen-Dropdown ───────────────────────────────────── */
.doc-list { display: flex; flex-direction: column; gap: 5px; }
.doc-row  { display: flex; align-items: center; gap: 6px; flex-wrap: nowrap; }
.doc-row-label {
  font-size: .72rem; font-weight: 700; min-width: 78px;
  color: var(--text-light); white-space: nowrap;
}
.doc-dropdown-wrap { position: relative; }
.doc-dropdown-btn {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: .72rem; padding: 3px 8px; cursor: pointer;
  background: var(--bg-warm); border: 1px solid var(--border);
  border-radius: 6px; color: var(--text-light); white-space: nowrap;
  line-height: 1.4;
}
.doc-dropdown-btn:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }
.doc-dropdown-menu {
  display: none; position: absolute; right: 0; top: calc(100% + 3px);
  background: var(--bg-warm); border: 1px solid var(--border);
  border-radius: 8px; box-shadow: var(--shadow-md);
  min-width: 190px; z-index: 200; overflow: hidden;
}
.doc-dropdown-menu.open { display: block; }
.doc-dropdown-menu a,
.doc-dropdown-menu button {
  display: block; width: 100%; text-align: left;
  padding: 8px 14px; font-size: .78rem;
  color: var(--text); background: none; border: none;
  border-bottom: 1px solid var(--border-light);
  cursor: pointer; text-decoration: none; line-height: 1.4;
}
.doc-dropdown-menu a:last-child,
.doc-dropdown-menu button:last-child { border-bottom: none; }
.doc-dropdown-menu a:hover,
.doc-dropdown-menu button:hover:not([disabled]) {
  background: var(--primary-light); color: var(--primary);
}
.doc-dropdown-menu button.dd-danger { color: var(--danger); }
.doc-dropdown-menu button.dd-danger:hover { background: #fff0f0; color: var(--danger); }
.doc-dropdown-menu button[disabled] {
  opacity: .4; cursor: not-allowed; color: var(--text-muted);
}
.doc-dropdown-menu .dd-sep {
  height: 1px; background: var(--border); margin: 2px 0;
}
:root:not([data-theme="light"]) .doc-dropdown-menu button.dd-danger:hover {
  background: rgba(212,64,64,.15);
}
