/* Babaritmus tesztapp – éjszakai, üveghatású, egykezes felület. */
:root {
  --night: #1C2747;
  --night-2: #2E3D6B;
  --navy: #26335C;
  --coral: #F2765A;
  --peach: #F9B79A;
  --cream: #FFF4E8;
  --lav: #8E9DDB;
  --ink: #FFF4E8;
  --ink-2: rgba(255, 244, 232, .74);
  --ink-3: rgba(255, 244, 232, .58);
  --hair: rgba(255, 255, 255, .12);
  --hair-2: rgba(255, 255, 255, .2);
  --surface: rgba(255, 255, 255, .065);
  --surface-2: rgba(255, 255, 255, .1);
  --r-xl: 28px;
  --r-lg: 22px;
  --r-md: 16px;
  --gutter: 16px;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --dock-h: 150px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--night); }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink); line-height: 1.5; font-size: 16px;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden; -webkit-tap-highlight-color: transparent;
  font-feature-settings: "tnum" 0;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
.center { text-align: center; justify-self: center; }
.soft { font-weight: 300; }
.strong { font-weight: 700; }
.light { font-weight: 400; }

/* ---------- háttér ---------- */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none;
  background: radial-gradient(130% 70% at 50% -10%, #3A4B80 0%, var(--night-2) 28%, var(--night) 62%, #141C36 100%); }
.orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .32; animation: drift 26s ease-in-out infinite; }
.orb.a { width: 340px; height: 340px; background: #5B6FB0; left: -170px; top: -120px; opacity: .45; }
.orb.b { width: 260px; height: 260px; background: var(--coral); right: -150px; top: 30%; opacity: .16; animation-delay: -8s; }
.orb.c { width: 300px; height: 300px; background: #7C6BC2; left: 10%; bottom: -200px; opacity: .2; animation-delay: -14s; }
@keyframes drift { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(-20px, 16px) scale(1.06); } }

/* ---------- üveg ---------- */
.glass, .glass-strong {
  position: relative; border: 1px solid var(--hair);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .1) inset, 0 20px 50px -28px rgba(5, 8, 22, .7);
  -webkit-backdrop-filter: blur(24px) saturate(160%); backdrop-filter: blur(24px) saturate(160%);
}
.glass { background: linear-gradient(180deg, rgba(255, 255, 255, .085), rgba(255, 255, 255, .05)); }
.glass-strong { background: rgba(34, 45, 84, .72); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass { background: #2A3864; }
  .glass-strong { background: #253260; }
}

/* ---------- képernyők ---------- */
.screen { min-height: 100vh; min-height: 100dvh; }
.auth-wrap {
  width: 100%; max-width: 460px; margin: 0 auto; display: grid; gap: 18px; align-content: center;
  min-height: 100vh; min-height: 100dvh;
  padding: calc(var(--safe-t) + 28px) calc(var(--gutter) + var(--safe-r)) calc(var(--safe-b) + 28px) calc(var(--gutter) + var(--safe-l));
}
.auth-hero { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 8px 8px 4px; }
.auth-hero.left { justify-items: start; text-align: left; }
.auth-mark { width: 64px; height: 64px; filter: drop-shadow(0 10px 30px rgba(242, 118, 90, .25)); }
.auth-mark.pulse { animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(.92); opacity: .75; } }
.display { font-size: 40px; line-height: 1.05; font-weight: 700; letter-spacing: -.035em; }
.display.sm { font-size: 32px; }
.lead { font-size: 16px; max-width: 34ch; }
.fine { font-size: 13px; text-align: center; }
.mail-orb { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; color: var(--night);
  background: radial-gradient(circle at 30% 30%, var(--peach), var(--coral)); box-shadow: 0 18px 40px -12px rgba(242, 118, 90, .65); margin-bottom: 6px; }
.mail-orb .ic { width: 34px; height: 34px; }
.email-pill { font-weight: 700; font-size: 17px; padding: 10px 18px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--hair); word-break: break-all; }

.card { border-radius: var(--r-xl); padding: 22px 20px; }
.stack { display: grid; gap: 14px; }
.stack.tight { gap: 8px; }
.btn-col { display: grid; gap: 10px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row > .btn { flex: 1 1 120px; }
.row.two > .btn { flex: 1 1 0; }

/* ---------- űrlap ---------- */
.login-form { display: grid; gap: 18px; }
.form { gap: 18px; }
.field { display: grid; gap: 8px; min-width: 0; }
.label { font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--ink-2); }
.hint { font-size: 13px; color: var(--ink-3); }
input.text, textarea.text, input.dt, .night-form input {
  width: 100%; min-height: 54px; padding: 0 16px; border-radius: var(--r-md);
  border: 1px solid var(--hair-2); background: rgba(10, 16, 40, .28); color: var(--ink);
  font: inherit; font-size: 17px; color-scheme: dark; transition: border-color .2s, box-shadow .2s;
}
textarea.text { padding: 14px 16px; min-height: 140px; resize: vertical; line-height: 1.5; }
input.text::placeholder, textarea.text::placeholder { color: rgba(255, 244, 232, .42); }
input:focus, textarea:focus { outline: none; border-color: var(--peach); box-shadow: 0 0 0 4px rgba(249, 183, 154, .18); }
input[aria-invalid="true"] { border-color: var(--coral); }
input.dt, .night-form input { -webkit-appearance: none; appearance: none; display: block; line-height: 52px; }
input.dt::-webkit-calendar-picker-indicator, .night-form input::-webkit-calendar-picker-indicator { filter: invert(.92); opacity: .6; margin-left: auto; cursor: pointer; }
input.dt::-webkit-datetime-edit, .night-form input::-webkit-datetime-edit { padding: 0; }
.error { color: var(--peach); font-size: 14px; font-weight: 600; }
.error:empty { display: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.consents { display: grid; gap: 14px; }
.consent { display: grid; grid-template-columns: 28px 1fr; gap: 12px; align-items: start; font-size: 14px; line-height: 1.5; cursor: pointer; position: relative; }
.consent input { position: absolute; z-index: 1; opacity: 0; width: 28px; height: 28px; margin: 0; cursor: pointer; }
.consent .box { width: 26px; height: 26px; border-radius: 8px; border: 1.5px solid rgba(255, 244, 232, .45); display: grid; place-items: center; transition: background .2s, border-color .2s; margin-top: -1px; }
.consent .box .ic { width: 16px; height: 16px; opacity: 0; transform: scale(.6); transition: .2s var(--ease); color: var(--night); stroke-width: 3; }
.consent input:checked + .box { background: var(--coral); border-color: var(--coral); }
.consent input:checked + .box .ic { opacity: 1; transform: none; }
.consent input:focus-visible + .box { outline: 3px solid var(--peach); outline-offset: 2px; }
.consent a { color: var(--peach); text-underline-offset: 3px; font-weight: 600; }
.consent.req .ctext::after { content: " *"; color: var(--peach); font-weight: 700; }

.switch { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 48px; cursor: pointer; }
.switch input { appearance: none; -webkit-appearance: none; flex: none; width: 52px; height: 32px; border-radius: 999px; margin: 0; background: rgba(255, 255, 255, .18); border: 1px solid rgba(255, 255, 255, .22); position: relative; cursor: pointer; transition: background .25s var(--ease); }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--cream); transition: transform .25s var(--ease); box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.switch input:checked { background: var(--coral); border-color: var(--coral); }
.switch input:checked::after { transform: translateX(20px); }
.switch .text { font-weight: 600; font-size: 15px; }

/* ---------- gombok ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px; padding: 0 22px; border-radius: 999px; border: 0;
  font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; letter-spacing: -.005em;
  transition: transform .18s var(--ease), box-shadow .2s, background .2s, opacity .2s;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.btn .ic { width: 20px; height: 20px; }
.btn-primary { background: linear-gradient(180deg, #F58669, var(--coral)); color: #1B2140; box-shadow: 0 14px 30px -14px rgba(242, 118, 90, .9), 0 1px 0 rgba(255, 255, 255, .35) inset; }
.btn-ghost { background: var(--surface-2); color: var(--ink); border: 1px solid var(--hair-2); }
.btn-quiet { background: transparent; color: var(--ink-2); }
.btn-danger { background: #E25C4A; color: #fff; }
.danger-text { color: var(--peach); }
.btn-block { width: 100%; }
.btn-xl { min-height: 60px; font-size: 17px; }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 15px; flex: none; }
.linkbtn { background: none; border: 0; padding: 0 4px; min-height: 44px; font-size: 14.5px; font-weight: 600; color: var(--peach); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; text-align: left; }
.linkbtn.center { justify-self: center; text-align: center; }
.iconbtn { flex: none; display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; border: 0; background: none; color: var(--ink); cursor: pointer; }
.iconbtn .ic { width: 22px; height: 22px; }
.iconbtn.round { border-radius: 50%; background: var(--surface-2); border: 1px solid var(--hair); }
.iconbtn:disabled { opacity: .3; cursor: default; }
:focus-visible { outline: 3px solid var(--peach); outline-offset: 3px; }

/* ---------- app-váz ---------- */
.topbar { position: sticky; top: 0; z-index: 20; padding: calc(var(--safe-t) + 8px) calc(var(--gutter) + var(--safe-r)) 8px calc(var(--gutter) + var(--safe-l));
  background: linear-gradient(180deg, rgba(28, 39, 71, .92) 0%, rgba(28, 39, 71, .75) 70%, rgba(28, 39, 71, 0) 100%);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.topbar-inner { max-width: 560px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; }
.who { display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; cursor: pointer; min-height: 44px; min-width: 0; text-align: left; }
.who-mark { width: 34px; height: 34px; flex: none; }
.who-text { display: grid; line-height: 1.15; min-width: 0; }
.who-name { font-weight: 700; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who-age { font-size: 12.5px; color: var(--ink-2); font-weight: 500; }
.top-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.sync-pill { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); background: var(--surface); border: 1px solid var(--hair); white-space: nowrap; }
.sync-pill i { width: 7px; height: 7px; border-radius: 50%; background: #7FD1A8; box-shadow: 0 0 0 3px rgba(127, 209, 168, .18); }
.sync-pill.s-saving i { background: var(--peach); box-shadow: 0 0 0 3px rgba(249, 183, 154, .2); animation: blink 1.2s ease-in-out infinite; }
.sync-pill.s-offline i, .sync-pill.s-error i { background: rgba(255, 244, 232, .5); box-shadow: none; }
.sync-pill.s-auth i { background: var(--coral); }
.sync-pill { font-family: inherit; cursor: default; }
.sync-pill.s-rejected { cursor: pointer; color: var(--peach); border-color: rgba(249, 183, 154, .45); }
.sync-pill.s-rejected i { background: var(--peach); box-shadow: 0 0 0 3px rgba(249, 183, 154, .2); }
.sync-pill:disabled { opacity: 1; }
@keyframes blink { 50% { opacity: .35; } }
#gear-btn[aria-pressed="true"] { background: var(--cream); color: var(--night); }
.offline-line { max-width: 560px; margin: 6px auto 0; font-size: 13px; line-height: 1.4; color: var(--ink); padding: 8px 12px; border-radius: 12px; background: rgba(255, 255, 255, .08); border: 1px solid var(--hair); }

.views { max-width: 560px; margin: 0 auto; padding: 4px calc(var(--gutter) + var(--safe-r)) calc(var(--dock-h) + var(--safe-b) + 24px) calc(var(--gutter) + var(--safe-l)); }
.view { display: grid; gap: 14px; animation: viewIn .25s var(--ease); }
@keyframes viewIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.large-title { font-size: 32px; font-weight: 700; letter-spacing: -.03em; line-height: 1.1; margin-top: 6px; }
.lead { margin-top: -6px; }
.eyebrow { display: block; color: var(--peach); font-weight: 700; font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 6px; }
.notice { padding: 12px 16px; border-radius: 16px; background: rgba(249, 183, 154, .14); border: 1px solid rgba(249, 183, 154, .4); font-size: 14px; }

/* ---------- állapotsáv ---------- */
.strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-radius: var(--r-lg); padding: 14px 4px; }
.tile { display: grid; gap: 2px; padding: 0 12px; min-width: 0; position: relative; }
.tile + .tile::before { content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 1px; background: var(--hair); }
.tile-label { font-size: 12.5px; font-weight: 700; letter-spacing: .01em; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-value { font-size: 21px; font-weight: 300; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; line-height: 1.25; }
.tile-sub { font-size: 12px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile.is-sleeping .tile-label { color: var(--lav); }
.tile.is-sleeping .tile-value { font-weight: 600; color: #C9D1F5; }
.tile.is-active .tile-label { color: var(--peach); }
.tile.is-active .tile-value { font-weight: 600; color: var(--peach); }

/* ---------- javaslatkártya ---------- */
.pred { overflow: hidden; }
.pred::after { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: radial-gradient(circle, rgba(242, 118, 90, .22), transparent 70%); pointer-events: none; }
.pred-title { font-size: 21px; font-weight: 700; line-height: 1.25; }
.pred-time { font-size: 44px; font-weight: 700; letter-spacing: -.035em; line-height: 1.05; margin: 6px 0 12px; font-variant-numeric: tabular-nums; }
.pred-time .kb { font-weight: 300; font-size: 26px; letter-spacing: -.01em; color: var(--ink-2); }
.pred-time.running { font-weight: 300; color: #C9D1F5; }
.pred p + p { margin-top: 10px; }
.pred .conf { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; color: var(--ink); }
.pred .conf::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: 7px; border-radius: 50%; background: var(--peach); box-shadow: 0 0 0 4px rgba(249, 183, 154, .2); }
.notes { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.notes li { font-size: 14px; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .07); }
.foot { margin-top: 16px !important; padding-top: 14px; border-top: 1px solid var(--hair); font-size: 13px; color: var(--ink-3); }
.foot-note { font-size: 13px; color: var(--ink-3); text-align: center; padding: 4px 12px 8px; }

.quick .night-form { margin-top: 16px; }
.night-form { display: grid; gap: 14px; }
.night-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.night-form input { padding: 0 12px; }
.quick-links { margin-top: 8px; display: grid; justify-items: start; }
.nudge { border-radius: var(--r-lg); padding: 14px 16px; display: grid; gap: 14px; }
.nudge-row { display: flex; align-items: center; gap: 12px; }
.nudge-row p { flex: 1; font-size: 14.5px; line-height: 1.45; }
.banner { border-radius: var(--r-lg); padding: 14px 16px; display: flex; gap: 12px; align-items: center; }
.banner p { flex: 1; font-size: 14px; line-height: 1.45; }
.banner.warn { border-color: rgba(242, 118, 90, .5); background: linear-gradient(180deg, rgba(242, 118, 90, .18), rgba(242, 118, 90, .1)); }
.hint { display: flex; align-items: center; gap: 12px; border-radius: var(--r-lg); padding: 10px 6px 10px 16px; }
.hint p { flex: 1; font-size: 13.5px; color: var(--ink-2); }
.hint-ic .ic { width: 22px; height: 22px; color: var(--peach); }

/* ---------- élő szoptatás ---------- */
.feedlive { display: grid; gap: 6px; justify-items: center; text-align: center; }
.feedlive.card { border-color: rgba(249, 183, 154, .35); }
.feedlive .eyebrow { justify-self: start; }
.feed-timer .big { font-size: 64px; font-weight: 300; letter-spacing: -.04em; font-variant-numeric: tabular-nums; line-height: 1.05; }
.feed-side { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; color: var(--peach); font-variant-numeric: tabular-nums; margin-bottom: 12px; }
.side-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--peach); animation: blink 1.6s ease-in-out infinite; }
.feedlive .row { width: 100%; }

/* ---------- dokk: műveletsáv + fülek ---------- */
.dock { position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; padding: 0 calc(10px + var(--safe-r)) calc(var(--safe-b) + 2px) calc(10px + var(--safe-l));
  background: linear-gradient(180deg, rgba(20, 28, 54, 0) 0%, rgba(20, 28, 54, .85) 38%, rgba(20, 28, 54, .96) 100%); }
.actionbar { max-width: 540px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) 60px; gap: 6px; padding: 6px; border-radius: 26px; }
body[data-view="heti"] .actionbar, body[data-view="utmutato"] .actionbar, body[data-view="beallitasok"] .actionbar { display: none; }
body[data-view="heti"], body[data-view="utmutato"], body[data-view="beallitasok"] { --dock-h: 70px; }
.act { position: relative; display: grid; justify-items: center; align-content: center; gap: 1px; min-height: 76px; padding: 8px 4px; border-radius: 20px; border: 0; background: rgba(255, 255, 255, .06); cursor: pointer; transition: transform .16s var(--ease), background .25s; min-width: 0; }
.act:active { transform: scale(.95); }
.act-ic .ic { width: 26px; height: 26px; }
.act-label { font-weight: 700; font-size: 15px; line-height: 1.2; white-space: nowrap; }
.act-sub { font-size: 11.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; min-height: 15px; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.act-sleep { background: linear-gradient(180deg, rgba(142, 157, 219, .26), rgba(142, 157, 219, .14)); }
.act-sleep.on { background: linear-gradient(180deg, #F58669, var(--coral)); color: #1B2140; box-shadow: 0 10px 26px -10px rgba(242, 118, 90, .9); }
.act-sleep.on .act-sub { color: rgba(27, 33, 64, .8); font-weight: 700; }
.act.on:not(.act-sleep) { background: linear-gradient(180deg, rgba(249, 183, 154, .95), rgba(249, 183, 154, .8)); color: #1B2140; }
.act.on:not(.act-sleep) .act-sub { color: rgba(27, 33, 64, .8); font-weight: 700; }
.act-sleep.on::after, .act.on::after { content: ""; position: absolute; inset: -3px; border-radius: 23px; border: 2px solid rgba(242, 118, 90, .45); animation: ring 2.4s ease-out infinite; pointer-events: none; }
@keyframes ring { 0% { opacity: .9; transform: scale(.98); } 100% { opacity: 0; transform: scale(1.06); } }
.act-plus { background: var(--cream); color: var(--night); border-radius: 20px; }
.act-plus .ic { width: 28px; height: 28px; stroke-width: 2.2; }

.tabbar { max-width: 540px; margin: 4px auto 0; display: grid; grid-template-columns: repeat(4, 1fr); }
.tab { display: grid; justify-items: center; gap: 1px; padding: 6px 0 4px; min-height: 52px; border: 0; background: none; color: var(--ink-3); font-size: 11px; font-weight: 600; cursor: pointer; }
.tab .ic { width: 24px; height: 24px; }
.tab[aria-current="page"] { color: var(--cream); }
.tab[aria-current="page"] .tab-ic { position: relative; }
.tab[aria-current="page"] .tab-ic::after { content: ""; position: absolute; left: 50%; bottom: -3px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--coral); }

/* ---------- alsó lap ---------- */
.sheet { padding: 0; border: 0; background: transparent; color: var(--ink); width: 100%; max-width: 560px; max-height: 94vh; max-height: 94dvh; margin: auto auto 0; overflow: visible; }
.sheet::backdrop { background: rgba(8, 12, 28, .55); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); animation: fadeIn .25s ease; }
.sheet[open] .sheet-panel { animation: sheetUp .38s var(--ease); }
.sheet.closing .sheet-panel { animation: sheetDown .18s ease-in forwards; }
.sheet.closing::backdrop { opacity: 0; transition: opacity .18s; }
.sheet-panel { border-radius: 30px 30px 0 0; border-bottom: 0; padding: 8px calc(20px + var(--safe-r)) calc(var(--safe-b) + 20px) calc(20px + var(--safe-l)); max-height: 94vh; max-height: 94dvh; overflow-y: auto; overscroll-behavior: contain; background: rgba(36, 48, 90, .88); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .sheet-panel { background: #26335C; } }
.grabber { width: 40px; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, .28); margin: 2px auto 8px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.sheet-title { font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.sheet-head .close { background: var(--surface-2); border-radius: 50%; width: 36px; height: 36px; }
.sheet-head .close .ic { width: 18px; height: 18px; }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes sheetDown { to { transform: translateY(100%); } }
@keyframes fadeIn { from { opacity: 0; } }

.option { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 76px; padding: 12px 16px; border-radius: 22px; border: 1px solid var(--hair); background: var(--surface); cursor: pointer; text-align: left; transition: transform .16s var(--ease), background .2s; }
.option:active { transform: scale(.98); }
.option.selected { background: var(--surface-2); border-color: var(--hair-2); }
.option.primary { background: linear-gradient(180deg, rgba(249, 183, 154, .22), rgba(249, 183, 154, .12)); border-color: rgba(249, 183, 154, .4); min-height: 88px; }
.opt-ic { flex: none; width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: rgba(255, 255, 255, .1); }
.option.primary .opt-ic { background: var(--peach); color: var(--night); }
.opt-ic .ic { width: 26px; height: 26px; }
.opt-text { flex: 1; display: grid; min-width: 0; }
.opt-title { font-weight: 700; font-size: 18px; }
.opt-sub { font-size: 14px; color: var(--ink-2); }
.option.primary .opt-sub { color: var(--peach); font-weight: 600; }
.opt-go { flex: none; padding: 10px 16px; border-radius: 999px; background: var(--coral); color: #1B2140; font-weight: 800; font-size: 15px; }
.group-label { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin: 10px 4px -4px; }
.bottle-form { display: grid; gap: 16px; padding: 4px 2px 6px; }

.stepper { display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; gap: 8px; padding: 6px; border-radius: 22px; background: rgba(10, 16, 40, .25); border: 1px solid var(--hair); }
.step-btn { height: 56px; border-radius: 18px; border: 0; background: var(--surface-2); font-size: 28px; font-weight: 300; cursor: pointer; }
.step-btn:active { transform: scale(.95); }
.ml-val { text-align: center; font-variant-numeric: tabular-nums; }
.ml-val .num { font-size: 36px; font-weight: 700; letter-spacing: -.03em; }
.ml-val .unit { font-size: 18px; font-weight: 300; color: var(--ink-2); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 2px 20px; scroll-padding: 20px; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip { flex: none; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--hair-2); background: var(--surface); font-size: 15px; font-weight: 600; cursor: pointer; white-space: nowrap; transition: background .2s, color .2s, border-color .2s; }
.chip[aria-checked="true"] { background: var(--cream); color: var(--night); border-color: var(--cream); }
.chip.soft { font-weight: 500; }
.chips.big .chip { flex: 1 1 0; min-height: 56px; font-size: 16px; }
.exact { margin-top: 2px; }

.big3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.bigbtn { display: grid; justify-items: center; align-content: center; gap: 10px; min-height: 124px; border-radius: 24px; border: 1px solid var(--hair); background: var(--surface); font-weight: 700; font-size: 16px; cursor: pointer; transition: transform .16s var(--ease), background .2s; }
.bigbtn:active { transform: scale(.95); background: var(--surface-2); }
.bb-emoji { width: 40px; height: 40px; border-radius: 50%; display: block; position: relative; }
.bb-emoji.drop { background: radial-gradient(circle at 35% 35%, #FFE7A8, #F2C45A); }
.bb-emoji.dot { background: radial-gradient(circle at 35% 35%, #E2B48A, #A97A52); }
.bb-emoji.both { background: linear-gradient(90deg, #F2C45A 50%, #A97A52 50%); }

/* ---------- toast ---------- */
.toast { position: fixed; z-index: 60; left: 0; right: 0; bottom: calc(var(--dock-h) + var(--safe-b) + 10px); display: flex; justify-content: center; padding: 0 12px; pointer-events: none; }
.sheet-open .toast { bottom: auto; top: calc(var(--safe-t) + 12px); }
.toast-inner { pointer-events: auto; width: 100%; max-width: 520px; display: flex; align-items: center; gap: 6px; padding: 8px 8px 8px 18px; border-radius: 22px; background: rgba(250, 240, 228, .96); color: #1B2140; border-color: rgba(255, 255, 255, .6);
  box-shadow: 0 18px 40px -16px rgba(0, 0, 0, .6); transform: translateY(16px); opacity: 0; transition: transform .3s var(--ease), opacity .25s; }
.toast.show .toast-inner { transform: none; opacity: 1; }
.toast-msg { flex: 1; font-size: 14px; font-weight: 600; line-height: 1.35; padding: 6px 0; }
.toast-actions { display: flex; gap: 2px; flex: none; }
.toast-btn { min-height: 44px; padding: 0 12px; border-radius: 14px; border: 0; background: transparent; color: #C4472C; font-weight: 800; font-size: 14px; cursor: pointer; }
.toast-btn:active { background: rgba(196, 71, 44, .1); }

/* ---------- napló ---------- */
.dayhead { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: 8px; }
.daytitle { text-align: center; }
.daytitle .large-title { margin: 0; font-size: 28px; }
.summary { display: grid; grid-template-columns: repeat(3, 1fr); border-radius: var(--r-lg); padding: 14px 0; }
.sum-cell { display: grid; justify-items: center; gap: 0; position: relative; }
.sum-cell + .sum-cell::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 1px; background: var(--hair); }
.sum-val { font-size: 22px; font-weight: 300; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.sum-lbl { font-size: 12px; font-weight: 600; color: var(--ink-2); text-transform: uppercase; letter-spacing: .06em; }
.timeline { list-style: none; margin: 0; padding: 6px; border-radius: var(--r-lg); }
.timeline li + li { border-top: 1px solid rgba(255, 255, 255, .06); }
.entry { width: 100%; display: grid; grid-template-columns: 46px 40px 1fr 18px; align-items: center; gap: 10px; min-height: 64px; padding: 8px 8px 8px 10px; border: 0; background: none; border-radius: 16px; text-align: left; cursor: pointer; }
.entry:active { background: rgba(255, 255, 255, .06); }
.entry-time { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.entry-ic { width: 40px; height: 40px; border-radius: 14px; display: grid; place-items: center; background: rgba(255, 255, 255, .08); flex: none; }
.entry-ic .ic { width: 22px; height: 22px; }
.t-alvas .entry-ic { background: rgba(142, 157, 219, .22); color: #C9D1F5; }
.t-etetes .entry-ic { background: rgba(249, 183, 154, .2); color: var(--peach); }
.t-pelenka .entry-ic { background: rgba(255, 244, 232, .14); color: var(--cream); }
.t-etel .entry-ic { background: rgba(242, 118, 90, .2); color: #FFB09C; }
.entry-main { display: grid; min-width: 0; }
.entry-title { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entry-meta { font-size: 13.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.entry.running .entry-meta { color: var(--peach); }
.chev { color: var(--ink-3); }
.chev .ic { width: 18px; height: 18px; }
.empty { border-radius: var(--r-lg); padding: 28px 20px; text-align: center; display: grid; gap: 6px; }

/* ---------- heti ---------- */
.chart-card { padding: 18px 16px 16px; }
.chart-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 4px; }
.chart-title { font-size: 17px; font-weight: 700; }
.unit { font-size: 12.5px; }
.chart { width: 100%; height: auto; overflow: visible; }
.chart .grid { stroke: rgba(255, 255, 255, .08); stroke-width: 1; stroke-dasharray: 3 4; }
.chart .axis { stroke: rgba(255, 255, 255, .18); stroke-width: 1; }
.chart .val { fill: var(--ink); font-size: 11.5px; font-weight: 700; font-family: inherit; }
.chart .lbl { fill: var(--ink-3); font-size: 12px; font-weight: 600; font-family: inherit; }
.chart .lbl.today { fill: var(--cream); font-weight: 800; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 8px; font-size: 13px; color: var(--ink-2); }
.lg { display: inline-flex; align-items: center; gap: 7px; }
.lg i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* ---------- útmutató ---------- */
.kvs { display: grid; gap: 2px; margin-top: 14px; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 0 12px; padding: 12px 0; border-top: 1px solid var(--hair); }
.kv .k { font-weight: 600; font-size: 15px; }
.kv .v { font-weight: 700; font-size: 16px; text-align: right; font-variant-numeric: tabular-nums; }
.kv .s { grid-column: 1 / -1; font-size: 12.5px; color: var(--ink-3); }
.guide.next .pred-title { margin-bottom: 8px; }
ul.plain { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 8px; font-size: 14.5px; color: var(--ink-2); }

/* ---------- beállítások ---------- */
.group { border-radius: var(--r-lg); overflow: hidden; }
.setrow, .acc-row { width: 100%; display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 10px 14px; border: 0; background: none; text-align: left; cursor: pointer; text-decoration: none; }
.setrow + .setrow { border-top: 1px solid rgba(255, 255, 255, .07); }
.setrow:active { background: rgba(255, 255, 255, .06); }
.set-ic { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: rgba(255, 255, 255, .1); }
.set-ic .ic { width: 20px; height: 20px; }
.set-text { flex: 1; display: grid; min-width: 0; }
.set-title { font-weight: 600; font-size: 16px; overflow-wrap: anywhere; }
.set-sub { font-size: 13px; color: var(--ink-2); }
.sync-saved::before { content: "● "; color: #7FD1A8; }
.setrow.danger .set-title { color: #FF9E87; }
.setrow.danger .set-ic { background: rgba(242, 118, 90, .2); color: #FF9E87; }
.badge { flex: none; display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700; letter-spacing: .04em; color: var(--night); background: var(--peach); }
.version { text-align: center; font-size: 13px; padding: 6px 0 4px; display: flex; gap: 8px; justify-content: center; align-items: center; }
.hint-row { display: flex; gap: 14px; align-items: center; padding: 12px 14px; }
.trash-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.trash-list li { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 12px; padding: 10px 10px 10px 12px; border-radius: 18px; background: var(--surface); }
.empty-state { text-align: center; padding: 18px 0 8px; display: grid; gap: 6px; }

/* ---------- közös napló ---------- */
.setrow:disabled { cursor: default; }
.setrow:disabled .set-title { color: var(--ink-3); }
.setrow:disabled:active { background: none; }
.set-ic.accent { background: rgba(242, 118, 90, .2); color: var(--peach); }
.share-intro { padding: 14px 16px 4px; line-height: 1.45; }
.share-head { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 12px 14px; border-bottom: 1px solid rgba(255, 255, 255, .07); }
.person { display: flex; align-items: flex-start; gap: 12px; min-height: 64px; padding: 12px 14px; }
.person + .person, .person + .setrow, .share-head + .person { border-top: 1px solid rgba(255, 255, 255, .07); }
.share-head + .person { border-top: 0; }
.mono { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; color: var(--night); background: var(--peach); }
.mono.self { background: var(--cream); font-size: 12px; letter-spacing: -.01em; }
.mono.invited { background: transparent; color: var(--ink-2); border: 1.5px dashed rgba(255, 244, 232, .4); }
.mono.former { background: rgba(255, 255, 255, .14); color: var(--ink-2); }
.person .set-title { font-size: 15.5px; }
.person .mono { margin-top: 2px; }
.person-acts { display: flex; gap: 8px; margin-top: 8px; }
.person-act { min-height: 40px; padding: 0 16px; font-size: 14px; }
.chips.grid2 { display: grid; grid-template-columns: 1fr 1fr; }
.chips.grid2 .chip { min-height: 56px; }
.btn-wrap { height: auto; padding-top: 10px; padding-bottom: 10px; line-height: 1.25; text-align: center; white-space: normal; }
.btn-two { display: grid; gap: 2px; }
.btn-sub { font-size: 13px; font-weight: 600; opacity: .85; }
/* szerző- és átfedés-jel a naplóban */
.entry-sub { display: flex; align-items: center; gap: 6px; min-width: 0; }
.entry-sub .entry-meta { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who-chip { flex: none; display: inline-grid; place-items: center; height: 20px; padding: 0 7px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .01em; line-height: 1; color: var(--ink-2); background: rgba(255, 255, 255, .09); }
.who-chip.k-other { color: var(--peach); background: rgba(249, 183, 154, .15); }
.who-chip.k-owner { color: var(--night); background: var(--peach); }
.who-chip.mono-chip { width: 20px; padding: 0; }
.who-chip.k-former { color: var(--ink-3); background: transparent; border: 1px solid var(--hair-2); }
.overlap-chip { flex: none; display: inline-grid; place-items: center; height: 20px; padding: 0 7px; border-radius: 999px; font-size: 11px; font-weight: 800; color: #FFB09C; background: rgba(242, 118, 90, .2); border: 1px solid rgba(242, 118, 90, .6); }
.ed-info { display: grid; gap: 10px; margin-top: -6px; }
.rec-by { font-size: 14px; color: var(--ink-2); }
.rec-by strong { color: var(--ink); font-weight: 700; }
/* meghívó elfogadása */
.inv-panel .sheet-head { margin-bottom: 4px; }
.inv-hero { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 4px 4px 2px; }
.inv-mark { width: 56px; height: 56px; filter: drop-shadow(0 10px 30px rgba(242, 118, 90, .25)); }
.inv-lead { font-size: 19px; line-height: 1.4; font-weight: 500; max-width: 30ch; }
.inv-lead strong { font-weight: 800; overflow-wrap: anywhere; }
.inv-role { display: inline-flex; gap: 6px; align-items: center; padding: 6px 14px; border-radius: 999px; font-size: 14px; color: var(--ink-2); background: var(--surface-2); border: 1px solid var(--hair); }
.inv-role strong { color: var(--peach); font-weight: 800; }
.inv-have { font-weight: 700; font-size: 16px; padding: 0 4px; }
.inv-later { margin-top: 2px; }
.invite-note { line-height: 1.45; }

/* ---------- mozgás ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media (max-width: 370px) {
  .act-label { font-size: 14px; }
  .tile { padding: 0 9px; }
  .tile-value { font-size: 19px; }
  .pred-time { font-size: 38px; }
  .display { font-size: 36px; }
  .actionbar { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) 52px; }
}

/* ---------- belépési kód ---------- */
.code-box { display: grid; gap: 10px; justify-items: stretch; }
.label.center { text-align: center; }
.hint.center { text-align: center; }
.code-input {
  width: 100%; min-height: 72px; padding: 0 0 0 .6em; border-radius: 20px; text-align: center;
  border: 1px solid var(--hair-2); background: rgba(10, 16, 40, .32); color: var(--ink);
  font: inherit; font-size: 36px; font-weight: 700; letter-spacing: .6em; font-variant-numeric: tabular-nums;
  caret-color: var(--coral);
}
.code-input::placeholder { color: rgba(255, 244, 232, .25); letter-spacing: .6em; }
.code-input:disabled { opacity: .6; }
.code-box .error { text-align: center; }
@media (max-width: 370px) { .code-input { font-size: 30px; letter-spacing: .5em; } }
.rejected-note { width: 100%; display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 12px 14px; border-radius: var(--r-lg); text-align: left; cursor: pointer; border-color: rgba(249, 183, 154, .45); background: linear-gradient(180deg, rgba(249, 183, 154, .16), rgba(249, 183, 154, .08)); }
.rejected-note .set-title { font-size: 15px; }
body:has(.s-rejected) .offline-line { cursor: pointer; }

/* ---------- telepítés a kezdőképernyőre ---------- */
.ig { display: grid; gap: 12px; }
.ig-panel .sheet-head { margin-bottom: 8px; }
.ig-panel .sheet-head .close { position: relative; }
.ig-panel .sheet-head .close::before { content: ""; position: absolute; inset: -6px; }   /* 48 px-es érintési felület */
.ig-why { font-size: 15px; line-height: 1.45; color: var(--ink-2); margin-top: -2px; }
.ig-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: none; }
.ig-step { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 12px 12px 12px 12px; border-radius: 20px; background: var(--surface); border: 1px solid var(--hair); }
.ig-num { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; align-self: start; margin-top: 1px; font-weight: 800; font-size: 15px; color: #1B2140; background: linear-gradient(180deg, #F58669, var(--coral)); box-shadow: 0 8px 18px -10px rgba(242, 118, 90, .9); }
.ig-text { display: grid; gap: 6px; min-width: 0; }
.ig-line { font-size: 16px; line-height: 1.35; font-weight: 500; color: var(--ink); }
.ig-line b { font-weight: 800; color: var(--cream); }
.ig-sub { font-size: 13px; line-height: 1.35; color: var(--ink-3); }
.ig-sub.center { text-align: center; }
/* a böngésző valódi elemeit utánzó mini ikonok (világos iOS-felület, kék jel) */
.ig-glyph { width: 22px; height: 22px; flex: none; }
.ig-key { flex: none; width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; color: #0A84FF; background: #F5F5F8; box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .5), 0 0 0 1px rgba(255, 255, 255, .5) inset; }
.ig-key .ig-glyph { width: 24px; height: 24px; }
.ig-menurow { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 40px; padding: 0 12px 0 14px; border-radius: 12px; background: #F5F5F8; color: #1C1C1E; font-size: 14.5px; font-weight: 600; box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .5); }
.ig-menurow .ig-glyph { color: #1C1C1E; }
.ig-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 40px; padding: 0 4px 0 14px; border-radius: 999px; background: #F5F5F8; color: #3A3A3C; font-size: 13.5px; font-weight: 500; box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .5); }
.ig-bar-url { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ig-bar-hit { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #0A84FF; background: #fff; box-shadow: 0 0 0 2px var(--coral); }
.ig-line .ig-pill { display: inline-block; padding: 0 9px; border-radius: 9px; line-height: 1.6; background: #F5F5F8; color: #0A84FF; font-weight: 800; box-shadow: 0 4px 12px -6px rgba(0, 0, 0, .5); }
.ig-panel .sheet-title:focus { outline: none; }
.ig-after { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 18px; font-size: 14.5px; line-height: 1.4; font-weight: 600; color: var(--cream); background: linear-gradient(180deg, rgba(249, 183, 154, .16), rgba(249, 183, 154, .08)); border: 1px solid rgba(249, 183, 154, .35); }
.ig-after-ic { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--peach); color: #1B2140; margin-top: 0; }
.ig-after-ic .ic { width: 14px; height: 14px; stroke-width: 3; }
.ig .btn-xl .ig-glyph { width: 22px; height: 22px; }
.ig-later { min-height: 52px; color: var(--ink-2); }
.ig-copy { display: grid; gap: 6px; }
.ig-copy .btn.done { border-color: rgba(127, 209, 168, .6); color: #BFF0D6; }
.ig-copy-status { font-size: 13px; text-align: center; color: var(--ink-2); min-height: 0; }
.ig-copy-status:empty { display: none; }
.ig-copy-buf { position: fixed; top: 0; left: 0; width: 1px; height: 1px; opacity: 0; }
.ig-link { margin-top: -8px; }
/* animált nyíl a böngésző Megosztás gombja felé */
.ig-arrow { color: var(--coral); pointer-events: none; }
.ig-arrow svg { width: 100%; height: 100%; filter: drop-shadow(0 6px 14px rgba(242, 118, 90, .55)); }
.ig-arrow.down { justify-self: center; width: 34px; height: 34px; margin: -6px 0 -10px; animation: igBounceDown 1.4s var(--ease) infinite; }
.ig-arrow.upright { position: fixed; z-index: 2; top: calc(var(--safe-t) + 10px); right: calc(var(--safe-r) + 14px); width: 46px; height: 46px; animation: igBounceUp 1.4s var(--ease) infinite; }
@keyframes igBounceDown { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(7px); } }
@keyframes igBounceUp { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(5px, -5px); } }
@media (prefers-reduced-motion: reduce) { .ig-arrow { animation: none !important; } }
@media (max-height: 680px) {
  .ig { gap: 8px; }
  .ig-steps { gap: 6px; }
  .ig-step { padding: 9px 10px 9px 11px; gap: 10px; }
  .ig-text { gap: 5px; }
  .ig-line { font-size: 15px; }
  .ig-why { font-size: 14px; }
  .ig-menurow { min-height: 36px; }
  .ig-after { padding: 9px 12px; font-size: 14px; }
  .ig-later { min-height: 48px; }
  .ig-copy .btn { min-height: 48px; }
  .ig-panel .sheet-head { margin-bottom: 4px; }
  .ig-sub { font-size: 12.5px; }
  .ig-arrow.down { width: 28px; height: 28px; margin: -8px 0 -12px; }
}
