/* ==========================================================================
   Ježíškova přání: vzhled podle Applu (iPhone Duo), upravený pro starší lidi
   a lehce vánočně naladěný. Plochý design bez stínů, šedé pozadí #f5f5f7,
   bílé karty 28 px, pilulková tlačítka, systémové písmo SF Pro.
   ========================================================================== */

:root {
  /* Barvy podle Apple (Gallery White, Studio Mist, Ink …) */
  --white: #ffffff;
  --mist: #f5f5f7;
  --frost: #fafafc;
  --control: #e8e8ed;
  --ink: #1d1d1f;
  --slate: #6e6e73;
  --steel: #86868b;
  --blue: #0066cc;            /* odkazy (Apple Blue) */
  --action: #0071e3;          /* plná tlačítka (Pricing Blue) */
  --action-press: #0062c4;
  --orange: #b64400;          /* štítek „velký dárek“ */

  /* Vánoční akcent: jedna sytá červená místo Apple modré u hlavních tlačítek */
  --red: #c4161c;
  --red-press: #a01218;
  --red-tint: #fbeaea;
  --pine: #1e6b45;            /* potvrzení, „domluveno“ */
  --pine-tint: #e7f2ec;
  --gold: #c8962d;            /* hvězdička */

  --font: "SF Pro Text", -apple-system, BlinkMacSystemFont, system-ui, "Helvetica Neue", Inter, Arial, sans-serif;
  --font-display: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, "Helvetica Neue", Inter, Arial, sans-serif;

  --r-card: 28px;
  --r-row: 22px;
  --r-field: 14px;
  --gap: 20px;
  --tap: 52px;                /* větší než u Applu kvůli starším lidem */
  --ease: cubic-bezier(.25, .1, .25, 1);
  --sep: rgba(0, 0, 0, .08);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font: 400 18px/1.47 var(--font);
  letter-spacing: -0.022em;
  -webkit-font-smoothing: antialiased;
}
body.is-in { padding-bottom: calc(92px + env(safe-area-inset-bottom)); }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; color: var(--ink); margin: 0 0 .45em; }
h1 { font-size: 40px; line-height: 1.1; letter-spacing: -0.01em; }
h2 { font-size: 24px; line-height: 1.17; letter-spacing: 0; }
h3 { font-size: 19px; line-height: 1.25; letter-spacing: -0.012em; }
p { margin: 0 0 .75em; }
ul, ol { padding-left: 1.2em; }
code { background: var(--control); padding: .1em .4em; border-radius: 6px; font-size: .88em; }
img { max-width: 100%; }
strong { font-weight: 600; }

:focus-visible { outline: 3px solid rgba(0, 113, 227, .55); outline-offset: 3px; border-radius: 12px; }

.wrap { max-width: 680px; margin: 0 auto; padding: 24px 18px 40px; position: relative; z-index: 1; }
.muted { color: var(--slate); }
.small { font-size: 15px; letter-spacing: -0.01em; }
.center { text-align: center; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* --------------------------------------------------------------------------
   Horní lišta (průsvitná jako v iOS)
   -------------------------------------------------------------------------- */
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 58px; padding: 7px 10px 7px 16px; padding-top: max(7px, env(safe-area-inset-top));
  background: rgba(250, 250, 252, .82);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--sep);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); min-width: 0; }
.brand:hover { text-decoration: none; }
.brand-star {
  flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px;
  background: var(--red); color: #ffd98a; font-size: 19px; line-height: 1;
}
.brand-text { display: grid; font-family: var(--font-display); font-weight: 600; font-size: 19px; letter-spacing: .005em; line-height: 1.15; min-width: 0; }
.who { font-family: var(--font); font-weight: 400; font-size: 14px; color: var(--slate); letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-actions { display: flex; align-items: center; gap: 2px; flex: none; }
.icon-btn {
  position: relative; display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%; border: 0; padding: 0;
  background: transparent; color: var(--ink); cursor: pointer;
  transition: background .2s var(--ease), color .2s var(--ease);
}
.icon-btn svg { width: 25px; height: 25px; }
.icon-btn:hover { background: rgba(0, 0, 0, .05); text-decoration: none; }
.icon-btn[aria-pressed="false"] { color: var(--steel); }
.icon-btn[aria-pressed="false"]::after {           /* přeškrtnutí vypnutého zvuku/hudby */
  content: ""; position: absolute; width: 26px; height: 1.8px; background: currentColor; transform: rotate(-45deg); border-radius: 2px;
}
#btn-music[aria-pressed="true"] { color: var(--red); background: var(--red-tint); }
#btn-music[aria-pressed="true"] svg { animation: sway 2.4s var(--ease) infinite; }
@keyframes sway { 0%, 100% { transform: rotate(-6deg); } 50% { transform: rotate(6deg); } }
.badge {
  position: absolute; top: 3px; right: 1px; min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: 10px; background: var(--red); color: #fff; font-size: 12px; font-weight: 600; line-height: 20px; text-align: center;
}

/* --------------------------------------------------------------------------
   Spodní lišta (tab bar jako v iPhonu)
   -------------------------------------------------------------------------- */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: rgba(250, 250, 252, .86);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--sep);
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom));
}
.tabs a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  min-height: 62px; border-radius: 16px; color: var(--steel); font-size: 13px; font-weight: 500; letter-spacing: 0;
}
.tabs a:hover { text-decoration: none; color: var(--ink); }
.tabs svg { width: 28px; height: 28px; }
.tabs a[aria-current="page"] { color: var(--action); font-weight: 600; }
@media (min-width: 760px) {
  .tabs { left: 50%; right: auto; width: 520px; transform: translateX(-50%); bottom: 14px; border: 1px solid var(--sep); border-radius: 26px; padding: 6px; }
  body.is-in { padding-bottom: 110px; }
}

/* --------------------------------------------------------------------------
   Bloky a karty (bílá na #f5f5f7, žádné stíny)
   -------------------------------------------------------------------------- */
.card { background: var(--white); border-radius: var(--r-card); padding: 26px 24px; margin: 0 0 var(--gap); }
.card > :last-child { margin-bottom: 0; }
.card.center { padding: 34px 24px; }

.hero { padding: 34px 4px 10px; text-align: center; }
.hero h1 { font-size: clamp(44px, 11vw, 80px); line-height: 1.05; letter-spacing: -0.015em; margin-bottom: 16px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px 22px; justify-content: center; align-items: center; margin: 22px 0 0; }
.hero-art { display: block; width: min(320px, 78%); margin: 30px auto 6px; }
.lead { font-size: 21px; line-height: 1.38; color: var(--ink); letter-spacing: .011em; max-width: 28em; margin-inline: auto; }
.kicker { font-family: var(--font-display); font-weight: 600; font-size: 21px; color: var(--ink); margin: 0 0 10px; letter-spacing: .011em; }
.label-new { display: block; font-size: 14px; font-weight: 600; color: var(--orange); letter-spacing: -0.01em; margin-bottom: 6px; }
.more::after { content: " ›"; }
.back { display: inline-flex; align-items: center; min-height: 44px; font-size: 17px; }
.empty { text-align: center; padding: 36px 20px; color: var(--slate); background: var(--white); border-radius: var(--r-card); margin-bottom: var(--gap); }
.empty > :last-child { margin-bottom: 0; }
.note { background: var(--white); border-radius: var(--r-card); padding: 22px 24px; margin: 0 0 var(--gap); }
.note > :last-child { margin-bottom: 0; }
.secret-note {
  display: flex; gap: 10px; align-items: center; font-size: 15px; color: var(--slate);
  padding: 0 4px; margin: -4px 0 var(--gap);
}
.secret-note::before {
  content: ""; flex: none; width: 18px; height: 18px; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3Cpath d='M8 11V8a4 4 0 0 1 8 0v3'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3Cpath d='M8 11V8a4 4 0 0 1 8 0v3'/%3E%3C/svg%3E") center / contain no-repeat;
}
.steps li { margin-bottom: .5em; }
.side-h { margin: 34px 4px 12px; font-family: var(--font-display); font-size: 21px; font-weight: 600; color: var(--ink); letter-spacing: .011em; }

.flash {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--white); border-radius: var(--r-row); padding: 16px 18px; margin: 0 0 var(--gap);
  animation: drop .45s var(--ease);
}
.flash::before { content: "✓"; flex: none; color: var(--pine); font-weight: 700; }
.flash-err { color: var(--red); }
.flash-err::before { content: "!"; color: var(--red); }
@keyframes drop { from { opacity: 0; transform: translateY(-8px) scale(.98); } to { opacity: 1; transform: none; } }

/* --------------------------------------------------------------------------
   Tlačítka (pilulky)
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); padding: 12px 24px;
  font: 400 17px/1.18 var(--font); letter-spacing: -0.022em; text-align: center;
  color: var(--ink); background: transparent;
  border: 1px solid var(--steel); border-radius: 9999px; cursor: pointer; text-decoration: none;
  transition: background .18s var(--ease), border-color .18s var(--ease), transform .12s var(--ease);
}
.btn:hover { background: rgba(0, 0, 0, .04); text-decoration: none; }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--action); border-color: var(--action); color: #fff; }
.btn-primary:hover { background: var(--action-press); border-color: var(--action-press); }
.btn-block { display: flex; width: 100%; }
.btn-small { min-height: 46px; padding: 10px 18px; font-size: 16px; }
.btn-quiet { background: transparent; border-color: transparent; color: var(--blue); font-weight: 400; padding-inline: 8px; }
.btn-quiet:hover { background: transparent; text-decoration: underline; color: var(--red); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.actions form { margin: 0; }

/* --------------------------------------------------------------------------
   Formuláře
   -------------------------------------------------------------------------- */
.form { display: grid; gap: 20px; }
.form label, fieldset { display: grid; gap: 8px; font-weight: 600; font-size: 17px; }
fieldset { border: 0; padding: 0; margin: 0; }
legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
input[type=text], input[type=email], input[type=url], input[type=number], input[type=date], select, textarea {
  width: 100%; min-height: var(--tap); padding: 12px 16px;
  font: 400 18px/1.3 var(--font); letter-spacing: -0.015em; color: var(--ink);
  background: var(--white); border: 1px solid var(--steel); border-radius: 980px; padding-inline: 22px;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
select {
  appearance: none; -webkit-appearance: none; padding-right: 42px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2386868b' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 22px;
}
textarea { min-height: 110px; resize: vertical; border-radius: 22px !important; }
input::placeholder, textarea::placeholder { color: var(--steel); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--action); box-shadow: 0 0 0 4px rgba(0, 113, 227, .16); }
.choice { display: flex !important; align-items: center; gap: 14px; font-weight: 400 !important; min-height: 48px; cursor: pointer; padding: 4px 0; }
.choice input { width: 26px; height: 26px; accent-color: var(--action); flex: none; }
.hint { font-weight: 400; font-size: 15px; color: var(--slate); }
.inline { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 12px 0 0; }
.inline label { flex-basis: 100%; font-weight: 500; }
.inline input, .inline select { flex: 1 1 170px; width: auto; min-width: 0; min-height: 48px; }
.copy { display: flex; gap: 10px; flex-wrap: wrap; }
.copy input { flex: 1 1 220px; font-size: 15px; }
.preview img { max-height: 180px; border-radius: 20px; background: #fff; }

/* --------------------------------------------------------------------------
   Přání
   -------------------------------------------------------------------------- */
.list { list-style: none; padding: 0; margin: 0 0 var(--gap); display: grid; gap: 14px; }
.wish {
  display: flow-root;
  background: var(--white); border-radius: var(--r-card); padding: 20px;
  animation: rise .5s var(--ease) both;
}
.wish:nth-child(2) { animation-delay: .04s; }
.wish:nth-child(3) { animation-delay: .08s; }
.wish:nth-child(4) { animation-delay: .12s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
/* Obrázek vpravo nahoře, text ho obtéká; rezervace a poznámky pak mají celou šířku karty */
.wish .thumb { float: right; width: 92px; height: 92px; margin: 0 0 10px 14px; object-fit: contain; border-radius: 18px; background: var(--white); outline: 1px solid var(--control); }
.claim, .comments, .wish .actions { clear: both; }
.wish h3 { margin-bottom: 6px; overflow-wrap: anywhere; font-size: 20px; }
.wish-body { min-width: 0; }
.star { color: var(--gold); }
.meta { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; font-size: 16px; margin-bottom: 8px; }
.price { font-weight: 600; font-family: var(--font-display); font-size: 18px; }
.note-text { color: var(--slate); font-size: 16px; overflow-wrap: anywhere; }
.links { display: grid; gap: 6px; font-size: 16px; }
.compare { color: var(--slate); }
.compare a { margin-left: 10px; white-space: nowrap; }
.given { font-weight: 600; color: var(--pine); }

/* Štítky: holý barevný text, bez pilulek (podle Apple „Launch label“) */
.tag { display: inline; padding: 0; background: none; font-size: 15px; font-weight: 600; color: var(--slate); letter-spacing: -0.01em; }
.tag-small { color: var(--slate); }
.tag-mid { color: var(--ink); }
.tag-big { color: var(--orange); }
.tag-tip { display: block; color: var(--pine); margin: 0 0 4px; }

/* --------------------------------------------------------------------------
   Rezervace a sbírky
   -------------------------------------------------------------------------- */
.claim { margin-top: 16px; padding: 16px; border-radius: 20px; background: var(--mist); }
.claim-state { margin-bottom: 8px; font-size: 17px; }
.claim-state.free { color: var(--slate); }
.claim-state.taken { color: var(--pine); }
.wish.is-claimed .claim { background: var(--mist); }
.wish.is-claimed .claim-state { color: var(--pine); }
.claim .btn:not(.btn-primary):not(.btn-quiet) { background: var(--white); }
.claim input, .claim select { border-color: var(--hair, #d2d2d7); }
.claim input, .claim select { background-color: var(--white); }
.pool { list-style: none; padding: 0; margin: 8px 0; font-size: 16px; }
.pool li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--sep); }
.pool li.sum { font-weight: 600; border-bottom: 0; }
.comments { margin-top: 14px; font-size: 16px; }
details > summary { cursor: pointer; color: var(--blue); font-weight: 500; min-height: 44px; display: flex; align-items: center; list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details > summary::after { content: "›"; margin-left: 8px; font-size: 22px; line-height: 1; transition: transform .2s var(--ease); }
details[open] > summary::after { transform: rotate(90deg); }
.comment { background: var(--mist); border-radius: 16px; padding: 10px 14px; margin: 8px 0; }

/* --------------------------------------------------------------------------
   Rodina: seskupený seznam jako v Nastavení iPhonu
   -------------------------------------------------------------------------- */
.people { list-style: none; padding: 0; margin: 0 0 8px; background: var(--white); border-radius: var(--r-card); overflow: hidden; }
.people li + li .person { border-top: 1px solid var(--sep); }
.person {
  position: relative; display: grid; gap: 2px; padding: 18px 48px 18px 22px; color: var(--ink);
  transition: background .15s var(--ease);
}
.person:hover { text-decoration: none; background: var(--frost); }
.person::after { content: "›"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font-size: 30px; color: #c7c7cc; }
.pname { font-family: var(--font-display); font-size: 20px; font-weight: 600; }
.pmeta { color: var(--slate); font-size: 16px; }
.status { justify-self: start; margin-top: 6px; font-size: 15px; font-weight: 600; }

.status-warn { color: var(--orange); }
.status-ok { color: var(--pine); }

/* Přepínač profilů (segmentovaný ovladač iOS) */
.switch { display: flex; gap: 4px; overflow-x: auto; margin: 0 0 var(--gap); padding: 4px; background: var(--control); border-radius: 9999px; width: max-content; max-width: 100%; }
.switch a { flex: none; padding: 10px 20px; border-radius: 9999px; color: var(--ink); font-weight: 500; min-height: 44px; display: flex; align-items: center; }
.switch a:hover { text-decoration: none; }
.switch a.on { background: var(--white); font-weight: 600; }

/* Ukazatel */
.progress { height: 8px; background: var(--control); border-radius: 999px; overflow: hidden; margin: 12px 0; }
.progress span { display: block; height: 100%; background: var(--action); border-radius: 999px; transition: width .6s var(--ease); }
.progress.over span { background: var(--orange); }
.summary .big { font-family: var(--font-display); font-size: 48px; font-weight: 600; letter-spacing: -0.03em; line-height: 1.05; margin: 0 0 4px; }
.big-name { font-family: var(--font-display); font-size: 30px; font-weight: 600; letter-spacing: -0.02em; display: block; margin-top: 6px; }

/* Oznámení, menu, správa */
.notes { list-style: none; padding: 0; margin: 0; background: var(--white); border-radius: var(--r-card); overflow: hidden; }
.notes li { padding: 16px 22px; display: grid; gap: 4px; border-top: 1px solid var(--sep); }
.notes li:first-child { border-top: 0; }
.notes li.unread { font-weight: 600; }
.notes li.unread::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--action); margin-bottom: 2px; }
.notes a { color: var(--ink); }
.menu { display: grid; gap: 0; margin: 0 0 var(--gap); list-style: none; padding: 0; background: var(--white); border-radius: var(--r-card); overflow: hidden; }
.menu > a, .menu > li > a { position: relative; display: block; padding: 18px 48px 18px 22px; color: var(--ink); font-weight: 500; border-top: 1px solid var(--sep); }
.menu > a:first-child, .menu > li:first-child > a { border-top: 0; }
.menu a:hover { text-decoration: none; background: var(--frost); }
.menu a::after { content: "›"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font-size: 28px; color: #c7c7cc; }
.admin-members { list-style: none; padding: 0; margin: 0; }
.admin-members li { padding: 14px 0; border-top: 1px solid var(--sep); }
.admin-members li:first-child { border-top: 0; }
.admin-members span { display: block; }
.admin-members form { margin: 8px 0 0; }

/* --------------------------------------------------------------------------
   Vánoční sníh (jen na úvodní stránce, jemně)
   -------------------------------------------------------------------------- */
.snow { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.snow i {
  position: absolute; top: -12px; width: 7px; height: 7px; border-radius: 50%;
  background: #d9e2ec; opacity: .9; animation: fall linear infinite;
}
.snow i:nth-child(3n) { width: 5px; height: 5px; opacity: .7; }
.snow i:nth-child(4n) { width: 9px; height: 9px; opacity: .55; }
.snow i:nth-child(1)  { left: 4%;  animation-duration: 14s; animation-delay: -2s; }
.snow i:nth-child(2)  { left: 11%; animation-duration: 18s; animation-delay: -9s; }
.snow i:nth-child(3)  { left: 17%; animation-duration: 12s; animation-delay: -5s; }
.snow i:nth-child(4)  { left: 24%; animation-duration: 20s; animation-delay: -1s; }
.snow i:nth-child(5)  { left: 30%; animation-duration: 15s; animation-delay: -12s; }
.snow i:nth-child(6)  { left: 37%; animation-duration: 17s; animation-delay: -7s; }
.snow i:nth-child(7)  { left: 43%; animation-duration: 13s; animation-delay: -3s; }
.snow i:nth-child(8)  { left: 50%; animation-duration: 19s; animation-delay: -15s; }
.snow i:nth-child(9)  { left: 56%; animation-duration: 16s; animation-delay: -6s; }
.snow i:nth-child(10) { left: 62%; animation-duration: 12s; animation-delay: -10s; }
.snow i:nth-child(11) { left: 68%; animation-duration: 21s; animation-delay: -4s; }
.snow i:nth-child(12) { left: 74%; animation-duration: 14s; animation-delay: -13s; }
.snow i:nth-child(13) { left: 80%; animation-duration: 18s; animation-delay: -8s; }
.snow i:nth-child(14) { left: 86%; animation-duration: 15s; animation-delay: -2s; }
.snow i:nth-child(15) { left: 91%; animation-duration: 20s; animation-delay: -11s; }
.snow i:nth-child(16) { left: 96%; animation-duration: 13s; animation-delay: -6s; }
.snow i:nth-child(17) { left: 34%; animation-duration: 22s; animation-delay: -17s; }
.snow i:nth-child(18) { left: 72%; animation-duration: 23s; animation-delay: -19s; }
@keyframes fall {
  0%   { transform: translate3d(0, 0, 0); }
  50%  { transform: translate3d(18px, 50vh, 0); }
  100% { transform: translate3d(-10px, 102vh, 0); }
}

/* Drobná radost při stisku */
.pop { animation: pop .4s var(--ease); }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.05); } 100% { transform: scale(1); } }

@media (prefers-reduced-motion: reduce) {
  .snow { display: none; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media (max-width: 420px) {
  h1 { font-size: 32px; }
  .wrap { padding: 18px 14px 32px; }
  .card { padding: 22px 18px; }
  .wish { padding: 18px; }
  .wish .thumb { width: 72px; height: 72px; border-radius: 14px; }
  .actions .btn, .actions form { flex: 1 1 auto; }
  .actions form .btn { width: 100%; }
  .brand-text { font-size: 17px; }
}

/* ==========================================================================
   Srozumitelnost: úvodní věty, kroky, přepínače pohledů, filtry, tabulka dárků
   ========================================================================== */
.lead-left { font-size: 19px; line-height: 1.45; color: var(--slate); margin: -4px 0 20px; letter-spacing: -0.015em; }
.lead-left strong { color: var(--ink); }
.how { font-size: 16px; color: var(--slate); margin: 0 4px 14px; }
.note-title { font-family: var(--font-display); font-weight: 600; font-size: 19px; color: var(--ink); margin: 0 0 6px; }
.switch-label { font-size: 15px; color: var(--slate); margin: 0 0 8px 4px; }
.switch-wide { width: 100%; }
.switch-wide a { flex: 1 1 0; justify-content: center; text-align: center; padding-inline: 8px; white-space: nowrap; font-size: 16px; }
.q-line { display: block; }
.btn-big { min-height: 60px; font-size: 19px; font-weight: 500; }
.label-star { color: var(--gold); font-weight: 600; font-size: 15px; margin: 0 0 4px; }
.kicker-small { font-size: 15px; color: var(--slate); margin: 0 0 4px; }
.pool-big { font-family: var(--font-display); font-size: 26px; font-weight: 600; margin: 6px 0 0; letter-spacing: -0.01em; }
.pool-big .muted { font-size: 17px; font-weight: 400; }

/* Čísla otázek ve formuláři */
.q-num {
  display: inline-grid; place-items: center; width: 26px; height: 26px; margin-right: 8px; border-radius: 50%;
  background: var(--ink); color: #fff; font-size: 14px; font-weight: 600; vertical-align: 1px;
}
fieldset legend .q-num { margin-right: 8px; }

/* Tři kroky na začátku */
.steps-card { background: var(--white); border-radius: var(--r-card); padding: 24px; margin: 0 0 var(--gap); }
.steps-big { list-style: none; counter-reset: s; padding: 0; margin: 10px 0 6px; display: grid; gap: 14px; }
.steps-big li { counter-increment: s; position: relative; padding-left: 50px; display: grid; gap: 2px; color: var(--slate); }
.steps-big li strong { color: var(--ink); font-size: 18px; }
.steps-big li span { font-size: 15px; }
.steps-big li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 600; background: var(--control); color: var(--slate);
}
.steps-big li.now::before { background: var(--action); color: #fff; }
.steps-big li.done::before { content: "✓"; background: var(--pine); color: #fff; }

/* Domácnosti v pohledu Lidé */
.household { margin: 0 0 16px; }
.household-name { font-size: 15px; font-weight: 600; color: var(--slate); margin: 0 6px 8px; }

/* Filtry (čipy) */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; align-items: center; }
.chip {
  display: inline-flex; align-items: center; min-height: 42px; padding: 8px 16px; border-radius: 9999px;
  border: 1px solid var(--steel); color: var(--ink); font-size: 16px; background: transparent;
}
.chip:hover { text-decoration: none; background: rgba(0, 0, 0, .04); }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chips-small .chip { min-height: 36px; padding: 6px 12px; font-size: 15px; }
.chips-label { font-size: 15px; color: var(--slate); margin-left: 4px; }

/* Tabulka dárků: na mobilu karty, na počítači tabulka */
.gtable { display: grid; gap: 10px; margin: 0 0 var(--gap); }
.grow {
  display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; align-items: center;
  background: var(--white); border-radius: 22px; padding: 16px 18px;
  grid-template-areas: "title price" "who who" "state state" "act act";
}
.ghead { display: none; }
.g-title { grid-area: title; font-weight: 600; font-size: 18px; overflow-wrap: anywhere; }
.g-title a { color: var(--ink); }
.g-who { grid-area: who; color: var(--slate); font-size: 16px; }
.g-price { grid-area: price; font-weight: 600; white-space: nowrap; }
.g-state { grid-area: state; font-size: 16px; color: var(--slate); }
.grow.state-free .g-state { color: var(--orange); }
.grow.state-mine .g-state, .grow.state-pool_mine .g-state { color: var(--pine); font-weight: 600; }
.g-act { grid-area: act; margin-top: 6px; }
.g-act form { margin: 0; }
.g-act .btn { width: 100%; }
.grow .tag-tip { display: block; font-size: 13px; }
@media (min-width: 900px) {
  .wrap:has(.gtable) { max-width: 1080px; }
  .gtable { gap: 0; background: var(--white); border-radius: var(--r-card); overflow: hidden; }
  .grow {
    grid-template-columns: minmax(220px, 2.2fr) 1fr 110px 1.6fr 170px; grid-template-areas: none;
    border-radius: 0; padding: 12px 22px; border-top: 1px solid var(--sep); gap: 16px;
  }
  .grow > * { grid-area: auto; }
  .ghead { display: grid; border-top: 0; font-size: 14px; font-weight: 600; color: var(--slate); background: var(--frost); }
  .g-lbl { display: none; }
  .g-price { text-align: right; }
  .g-act { margin: 0; }
  .g-title { font-size: 17px; }
}

/* ==========================================================================
   Správa rodiny
   ========================================================================== */
@media (min-width: 900px) { .wrap:has(.kpis), .wrap:has(.mtable) { max-width: 1080px; } }
.pill-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; margin-left: 6px; border-radius: 11px; background: var(--red); color: #fff; font-size: 13px; font-weight: 600; }

.tasks { display: grid; gap: 12px; margin-bottom: var(--gap); }
.task { background: var(--white); border-radius: var(--r-row); padding: 18px 20px; }
.task-urgent { box-shadow: inset 4px 0 0 var(--orange); }
.task-ok { color: var(--pine); }
.task-title { font-family: var(--font-display); font-weight: 600; font-size: 19px; margin: 0 0 4px; }
.task-text { color: var(--slate); font-size: 16px; margin: 0; }
.task .actions { margin-top: 12px; }

.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: var(--gap); }
@media (min-width: 760px) { .kpis { grid-template-columns: repeat(3, 1fr); } }
.kpis-3 { grid-template-columns: repeat(3, 1fr); }
.kpi { background: var(--white); border-radius: var(--r-row); padding: 18px 18px 16px; display: grid; align-content: start; gap: 2px; }
.kpi-wide { grid-column: 1 / -1; }
.kpi-num { font-family: var(--font-display); font-weight: 600; font-size: 34px; letter-spacing: -0.02em; line-height: 1.1; }
.kpi-num small { font-size: 20px; color: var(--slate); font-weight: 500; }
.kpi-lbl { font-size: 15px; color: var(--slate); }
.kpi-sub { font-size: 14px; color: var(--orange); }
.kpi .progress { margin: 8px 0 0; }
.kpis-3 .kpi-num { font-size: 28px; }

.mini-table { width: 100%; border-collapse: collapse; font-size: 16px; }
.mini-table th { text-align: left; font-size: 14px; color: var(--slate); font-weight: 600; padding: 0 8px 10px 0; }
.mini-table td { padding: 10px 8px 10px 0; border-top: 1px solid var(--sep); vertical-align: middle; }
.bar { height: 6px; background: var(--control); border-radius: 3px; overflow: hidden; margin-bottom: 4px; max-width: 160px; }
.bar span { display: block; height: 100%; background: var(--action); }
.bar-green span { background: var(--pine); }

/* Tabulka členů: na mobilu řádky, na počítači sloupce; klepnutím se rozbalí detail */
.mtable { background: var(--white); border-radius: var(--r-card); overflow: hidden; margin-bottom: var(--gap); }
.mrow { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 14px 20px; cursor: pointer; list-style: none; }
.mrow::-webkit-details-marker { display: none; }
details.mrow-wrap > summary.mrow::after { display: none; }
.mrow-wrap + .mrow-wrap, .mhead + .mrow-wrap { border-top: 1px solid var(--sep); }
.mrow-wrap[open] { background: var(--frost); }
.mhead { display: none; }
.m-name { font-weight: 600; font-size: 18px; color: var(--ink); grid-column: 1 / -1; }
.m-side, .m-seen { font-size: 15px; color: var(--slate); }
.m-letter, .m-gift { font-size: 15px; }
.ok { color: var(--pine); }
.warn { color: var(--orange); }
.m-tag { font-style: normal; font-size: 13px; font-weight: 600; color: var(--slate); margin-left: 8px; }
.m-tag-warn { color: var(--orange); }
.is-pending .m-name { color: var(--orange); }
.m-detail { padding: 0 20px 18px; }
.m-detail .inline input[type=text] { flex: 2 1 220px; }
@media (min-width: 900px) {
  .mrow { grid-template-columns: 1.6fr 1.6fr 1fr 1fr 0.8fr; align-items: center; }
  .mhead { display: grid; cursor: default; font-size: 14px; font-weight: 600; color: var(--slate); background: var(--frost); }
  .m-name { grid-column: auto; }
}

.card-highlight { box-shadow: inset 0 0 0 2px var(--action); }
.notes li.is-off { opacity: .55; }

/* ==========================================================================
   Označení správce
   ========================================================================== */
.admin-badge {
  display: inline-block; padding: 1px 8px; border-radius: 9999px; vertical-align: 1px;
  background: var(--ink); color: #fff; font-size: 12px; font-weight: 600; letter-spacing: .01em; line-height: 18px;
}
.admin-badge-big { font-size: 14px; padding: 3px 12px; margin-bottom: 12px; }
.admin-banner {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: var(--ink); color: #fff; border-radius: var(--r-row); padding: 14px 18px; margin: 0 0 18px;
}
.admin-banner svg { width: 24px; height: 24px; flex: none; color: #ffd98a; }
.admin-banner span { flex: 1 1 200px; font-size: 16px; }
.admin-banner a { color: #8cc3ff; font-size: 16px; }
body.is-admin-area .top { background: rgba(29, 29, 31, .92); border-bottom-color: rgba(255, 255, 255, .08); }
body.is-admin-area .top .brand, body.is-admin-area .top .icon-btn { color: #fff; }
body.is-admin-area .top .who { color: rgba(255, 255, 255, .7); }
body.is-admin-area .top .admin-badge { background: #ffd98a; color: var(--ink); }
.admin-entry {
  display: flex; gap: 16px; align-items: center; background: var(--ink); color: #fff;
  border-radius: var(--r-card); padding: 20px 22px; margin: 0 0 var(--gap);
}
.admin-entry:hover { text-decoration: none; background: #333336; }
.admin-entry strong { display: block; font-size: 19px; }
.admin-entry-sub { display: block; font-size: 15px; color: rgba(255, 255, 255, .72); }
.admin-entry-icon { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: rgba(255, 255, 255, .12); color: #ffd98a; }
.admin-entry-icon svg { width: 26px; height: 26px; }
.admin-only { box-shadow: inset 0 0 0 2px var(--ink); }
.code-form { max-width: 320px; margin: 18px auto 10px; }
.code-input { text-align: center; font-size: 30px !important; letter-spacing: .35em; font-weight: 600; }
