:root {
  --bg: #fbf7f4; --card: #ffffff; --ink: #2b2226; --muted: #7a6c72; --line: #ecdfe2;
  --accent: #b4536b; --accent-ink: #ffffff; --soft: #f6e7eb; --ok: #3f8a5c; --warn: #b7791f; --danger: #b3261e;
  --serif: 'Cormorant Garamond', Georgia, serif; --sans: Inter, system-ui, -apple-system, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #17131a; --card: #221c24; --ink: #f3eaee; --muted: #b3a3ab; --line: #3a2f38; --soft: #3a2630; --accent: #e08aa0; --accent-ink: #1b1216; }
}
.theme-sage { --accent: #5d8466; --soft: #e5efe6; } .theme-navy { --accent: #34507a; --soft: #e3e9f3; } .theme-gold { --accent: #a77d2c; --soft: #f5ecd9; }
@media (prefers-color-scheme: dark) { .theme-sage { --accent: #8fbf99; --soft: #26332a; } .theme-navy { --accent: #8eaedc; --soft: #232c3c; } .theme-gold { --accent: #dcb465; --soft: #3a3020; } }

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 var(--sans); }
a { color: var(--accent); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2.2rem, 6vw, 3.6rem); } h2 { font-size: 1.8rem; } h3 { font-size: 1.3rem; }
.loading { text-align: center; padding: 4rem; color: var(--muted); }
.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 640px; }
header.top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 14px 16px; max-width: 980px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: .5rem; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; color: var(--ink); text-decoration: none; }
.brand img { width: 32px; height: 32px; }
.hero { text-align: center; padding: 3rem 0 2rem; }
.hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 620px; margin: 0 auto 1.5rem; }
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.card.soft { background: var(--soft); border-color: transparent; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; border: 0; border-radius: 999px; padding: .7rem 1.3rem;
  background: var(--accent); color: var(--accent-ink); font: 600 1rem var(--sans); cursor: pointer; text-decoration: none; }
.btn.ghost { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
.btn.small { padding: .35rem .8rem; font-size: .88rem; }
.btn.danger { background: var(--danger); color: #fff; }
.btn:disabled { opacity: .5; cursor: default; }
.link { background: none; border: 0; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }
label { display: block; font-size: .88rem; color: var(--muted); margin: .7rem 0 .25rem; }
input, select, textarea { width: 100%; font: inherit; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: .6rem .7rem; }
input[type=checkbox] { width: auto; accent-color: var(--accent); transform: scale(1.2); }
textarea { min-height: 90px; resize: vertical; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row > * { flex: 1 1 160px; }
.row > .btn, .row > .shrink { flex: 0 0 auto; }
.muted { color: var(--muted); } .small { font-size: .88rem; } .center { text-align: center; }
.badge { display: inline-block; padding: .1rem .55rem; border-radius: 999px; font-size: .78rem; font-weight: 600; background: var(--soft); color: var(--accent); }
.badge.ok { background: #e2f1e7; color: var(--ok); } .badge.no { background: #f6e1e0; color: var(--danger); } .badge.warn { background: #f8eedb; color: var(--warn); }
@media (prefers-color-scheme: dark) { .badge.ok { background: #1f3326; } .badge.no { background: #3a1f1e; } .badge.warn { background: #3a2f1c; } }
.notice { background: var(--soft); border-radius: 12px; padding: 12px 14px; margin: 12px 0; }
.error { color: var(--danger); }

/* správa */
.layout { display: grid; grid-template-columns: 220px 1fr; gap: 20px; max-width: 1100px; margin: 0 auto; padding: 0 16px 60px; }
nav.side { position: sticky; top: 10px; align-self: start; display: flex; flex-direction: column; gap: 2px; }
nav.side button { text-align: left; background: none; border: 0; padding: .6rem .8rem; border-radius: 10px; font: 500 .98rem var(--sans); color: var(--ink); cursor: pointer; }
nav.side button.on { background: var(--soft); color: var(--accent); }
@media (max-width: 760px) {
  .layout { grid-template-columns: 1fr; }
  nav.side { position: static; flex-direction: row; overflow-x: auto; gap: 4px; padding-bottom: 4px; }
  nav.side button { white-space: nowrap; flex: 0 0 auto; }
}
.list { display: flex; flex-direction: column; gap: 8px; }
.item { display: flex; gap: 10px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.item .grow { flex: 1; min-width: 0; }
.item .title { font-weight: 600; overflow-wrap: anywhere; }
.item.done .title { text-decoration: line-through; color: var(--muted); }
.stat { font-family: var(--serif); font-size: 2.6rem; font-weight: 600; color: var(--accent); line-height: 1; }
.progress { height: 8px; background: var(--line); border-radius: 99px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--accent); }
dialog { border: 0; border-radius: 18px; padding: 20px; width: min(560px, 94vw); background: var(--card); color: var(--ink); }
dialog::backdrop { background: rgba(20, 10, 15, .45); }
.table { width: 100%; border-collapse: collapse; font-size: .94rem; }
.table th, .table td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.scroll-x { overflow-x: auto; }
.copy { font-family: ui-monospace, monospace; font-size: .8rem; background: var(--soft); border-radius: 8px; padding: 6px 8px; overflow-wrap: anywhere; }

/* svatební web */
.w-hero { text-align: center; padding: 4rem 16px 2.5rem; background: linear-gradient(180deg, var(--soft), transparent); }
.w-hero .names { font-family: var(--serif); font-size: clamp(2.6rem, 9vw, 5rem); font-weight: 600; line-height: 1.05; }
.w-hero .date { letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-top: .8rem; }
.countdown { display: flex; justify-content: center; gap: 22px; margin-top: 1.5rem; }
.countdown div { text-align: center; } .countdown b { display: block; font-family: var(--serif); font-size: 2.4rem; color: var(--accent); }
section.w { padding: 2rem 0; border-top: 1px solid var(--line); }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { display: grid; grid-template-columns: 70px 1fr; gap: 12px; padding: 8px 0; }
.timeline .t { font-family: var(--serif); font-size: 1.3rem; color: var(--accent); font-weight: 600; }
.gift { display: flex; flex-direction: column; gap: 6px; }
.gift.taken { opacity: .6; }
footer.foot { text-align: center; color: var(--muted); font-size: .85rem; padding: 2rem 16px 3rem; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: .6rem 1rem; border-radius: 999px; z-index: 10; }
