/* Ozilane Key (web) — brand green band, glass cards, light and dark. */
:root {
  --green: #16A34A;
  --green-deep: #0B6B30;
  --brand: #16A34A;              /* green text on the page */
  --bg: #F6F7F6;
  --ink: #111813;
  --muted: #5B6B61;
  --card: rgba(255, 255, 255, 0.78);
  --card-edge: rgba(22, 163, 74, 0.20);
  --card-shadow: 0 6px 18px rgba(22, 163, 74, 0.10);
  --field: #FFFFFF;
  --line: #DCE5DF;
  --amber: #B45309;
  --amber-edge: rgba(245, 158, 11, 0.55);
  --red: #DC2626;
  --sheet: #FFFFFF;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #4ADE80; --bg: #121014; --ink: #F3F5F4; --muted: #A3B1A8;
    --card: rgba(255, 255, 255, 0.06); --card-edge: rgba(255, 255, 255, 0.12); --card-shadow: none;
    --field: #1C1A20; --line: #2C2A31; --amber: #FCD34D; --sheet: #1A181D; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand: #4ADE80; --bg: #121014; --ink: #F3F5F4; --muted: #A3B1A8;
  --card: rgba(255, 255, 255, 0.06); --card-edge: rgba(255, 255, 255, 0.12); --card-shadow: none;
  --field: #1C1A20; --line: #2C2A31; --amber: #FCD34D; --sheet: #1A181D; color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-tap-highlight-color: transparent; }
button { font: inherit; cursor: pointer; }
[hidden] { display: none !important; }
.wrap { max-width: 520px; margin: 0 auto; }

/* app shell: the green band stays put, only the content below it scrolls */
html, body { height: 100%; overflow: hidden; }
#app { height: 100vh; height: 100dvh; display: flex; flex-direction: column; }
#app > .band { flex: none; position: relative; z-index: 5; }
.scroller { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch; scrollbar-gutter: stable; }

/* home: status, requests and the list's title stay put; only the accounts scroll */
.home { flex: 1; min-height: 0; display: flex; }
.home-grid { flex: 1; min-height: 0; width: 100%; display: flex; flex-direction: column; }
.home-top { flex: none; padding: 16px 16px 0; position: relative; z-index: 2; background: var(--bg); transition: box-shadow .2s; }
.home-top .section { margin-bottom: 8px; }
.home-top.lifted { box-shadow: 0 10px 12px -10px rgba(0,0,0,.18); }
.pending-list { max-height: 25vh; overflow-y: auto; overscroll-behavior: contain; }
.home-scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  padding: 4px 16px calc(env(safe-area-inset-bottom) + 40px); }
/* short screens (a phone turned sideways): no room for a fixed part, so the whole page scrolls */
@media (max-height: 560px) {
  .home { overflow-y: auto; display: block; }
  .home-grid { display: block; }
  .home-top { position: static; box-shadow: none !important; }
  .home-scroll { overflow: visible; }
}

/* splash */
.splash { position: fixed; inset: 0; display: grid; place-content: center; justify-items: center; gap: 6px;
  background: var(--bg); z-index: 50; transition: opacity .35s ease; }
.splash-tile { width: 120px; height: 120px; display: grid; place-items: center; border-radius: 30px;
  background: #fff; border: 1px solid rgba(22,163,74,.18);
  box-shadow: 0 18px 40px -12px rgba(22,163,74,.45), 0 0 60px rgba(22,163,74,.18);
  animation: lift .9s ease-out both; }
.splash-tile img { display: block; }
.splash-name { margin: 14px 0 0; font-size: 28px; font-weight: 800; animation: rise .7s .25s ease-out both; }
.splash-name span, .brand { color: var(--brand); }
.splash-tag { margin: 0; color: var(--muted); animation: rise .7s .4s ease-out both; }
.splash.gone { opacity: 0; pointer-events: none; }
@keyframes lift { from { transform: scale(.85); opacity: .4 } to { transform: none; opacity: 1 } }
@keyframes rise { from { transform: translateY(12px); opacity: 0 } to { transform: none; opacity: 1 } }

/* green band: the only green surface */
.band { background: linear-gradient(135deg, var(--green), var(--green-deep)); color: #fff;
  border-radius: 0 0 26px 26px; padding: calc(env(safe-area-inset-top) + 16px) 18px 20px; }
.band-row { display: flex; align-items: center; gap: 12px; max-width: 520px; margin: 0 auto; }
.logo-tile { width: 50px; height: 50px; border-radius: 15px; background: #fff; padding: 7px; flex: none; }
.logo-tile img { width: 100%; height: 100%; display: block; }
.band h1 { margin: 0; font-size: 23px; font-weight: 800; letter-spacing: .2px; }
.band p { margin: 0; color: rgba(255,255,255,.75); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grow { flex: 1; min-width: 0; }
.theme-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 14px;
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.45); color: #fff; font-weight: 600; font-size: 13px; }
.theme-btn:active { transform: scale(.97); }

/* glass cards, words in green */
.body { padding: 16px 16px 120px; }
.glass { background: var(--card); border: 1px solid var(--card-edge); box-shadow: var(--card-shadow);
  border-radius: 18px; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.info { display: flex; gap: 12px; align-items: center; padding: 12px 14px; color: var(--brand); font-weight: 500; font-size: 13.5px; }
.info .dot { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: color-mix(in srgb, var(--brand) 14%, transparent); }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.stat { padding: 12px 14px; color: var(--brand); position: relative; }
.stat b { display: block; font-size: 26px; line-height: 1.1; font-weight: 800; }
.stat span { font-size: 12.5px; opacity: .85; }
.stat svg { position: absolute; top: 12px; right: 12px; }
.stat.alert { color: var(--amber); border-color: var(--amber-edge); }

.section { margin: 26px 4px 10px; display: flex; justify-content: space-between; color: var(--muted);
  font-size: 12px; font-weight: 700; letter-spacing: 1.1px; text-transform: uppercase; }
.section i { font-style: normal; font-weight: 500; letter-spacing: 0; text-transform: none; }

/* pending request */
.pending { display: flex; align-items: center; gap: 12px; padding: 14px; margin-bottom: 10px; border-radius: 18px;
  background: color-mix(in srgb, #F59E0B 14%, var(--bg)); border: 1px solid var(--amber-edge); color: var(--amber); width: 100%; text-align: left; }
.pending .bell { width: 44px; height: 44px; border-radius: 50%; background: #F59E0B; color: #fff; display: grid; place-items: center; flex: none; }
.pending strong { display: block; }

/* account */
.account { padding: 14px 14px 16px; margin-bottom: 12px; }
.acc-head { display: flex; align-items: center; gap: 12px; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800;
  color: var(--brand); background: color-mix(in srgb, var(--brand) 15%, transparent); }
.acc-head h3 { margin: 0; font-size: 16px; }
.acc-head small { color: var(--muted); }
.icon-btn { margin-left: auto; background: none; border: 0; color: var(--muted); padding: 8px; border-radius: 10px; }
.code-row { margin-top: 12px; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 14px; background: var(--field); }
.code { font-size: 28px; font-weight: 700; letter-spacing: 2px; font-variant-numeric: tabular-nums; color: var(--brand); flex: 1; }
.code.hidden { letter-spacing: 6px; color: var(--muted); }
.code.urgent { color: var(--red); }
.ring { --p: 1; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 600;
  background: conic-gradient(var(--brand) calc(var(--p) * 360deg), var(--line) 0); }
.ring span { width: 26px; height: 26px; border-radius: 50%; background: var(--field); display: grid; place-items: center; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 16px;
  padding: 14px 18px; font-weight: 600; font-size: 15px; transition: transform .1s ease, filter .15s ease; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.btn-block { width: 100%; }
.btn:disabled { opacity: .6; }
.fab { position: fixed; right: 18px; bottom: calc(env(safe-area-inset-bottom) + 20px); box-shadow: 0 8px 24px rgba(22,163,74,.35); }

/* empty state */
.empty { text-align: center; padding: 26px 8px 8px; }
.empty img { width: 84px; }
.empty h2 { margin: 14px 0 4px; font-size: 20px; }
.empty p { margin: 0; color: var(--muted); }
.steps { margin: 20px 0; padding: 16px; text-align: left; display: grid; gap: 12px; }
.step { display: flex; gap: 12px; align-items: flex-start; }
.step b { width: 26px; height: 26px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 13px; flex: none; }

/* sheets */
.scrim { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 40; display: flex; align-items: flex-end; justify-content: center; animation: fade .2s; }
.sheet { background: var(--sheet); width: 100%; max-width: 520px; border-radius: 28px 28px 0 0; padding: 10px 20px calc(env(safe-area-inset-bottom) + 20px); animation: up .25s ease-out; }
.sheet .handle { width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 4px auto 14px; }
.sheet h2 { margin: 0 0 4px; font-size: 20px; }
.sheet .sub { margin: 0 0 16px; color: var(--muted); }
.choice { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px; margin-bottom: 10px; border-radius: 18px;
  background: var(--field); border: 2px solid transparent; color: var(--ink); text-align: left; }
.choice.on { border-color: var(--green); background: color-mix(in srgb, var(--green) 12%, var(--field)); }
.choice small { display: block; color: var(--muted); }
.swatch { width: 44px; height: 56px; border-radius: 10px; overflow: hidden; display: flex; flex: none; border: 1px solid var(--line); }
.swatch i { flex: 1; padding: 5px; } .swatch i::before { content: ""; display: block; height: 8px; border-radius: 2px; background: var(--green); }
.sw-l { background: #F6F7F6; } .sw-d { background: #121014; }
.numbers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 14px 0 16px; }
.numbers button { padding: 22px 0; border-radius: 18px; border: 0; font-size: 30px; font-weight: 800;
  background: color-mix(in srgb, var(--green) 14%, var(--field)); color: var(--ink); }
.numbers button:active { transform: scale(.96); }
.center { text-align: center; }
.muted { color: var(--muted); }
.err { color: var(--red); text-align: center; margin: 0 0 10px; }
input.field { width: 100%; padding: 13px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--field); color: var(--ink); font: inherit; }

/* toasts */
#toasts { position: fixed; left: 0; right: 0; bottom: calc(env(safe-area-inset-bottom) + 24px); display: grid; justify-items: center; z-index: 60; pointer-events: none; padding: 0 14px; }
.toast { pointer-events: auto; width: 100%; max-width: 520px; background: var(--sheet); border: 1px solid var(--edge); border-radius: 18px;
  box-shadow: 0 10px 28px rgba(0,0,0,.2); overflow: hidden; animation: up .25s ease-out; }
.toast-row { display: flex; gap: 12px; align-items: flex-start; padding: 14px 8px 12px 14px; }
.toast .ic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.toast strong { display: block; font-size: 15px; }
.toast p { margin: 2px 0 0; color: var(--muted); font-size: 13.5px; }
.toast .ok { margin-left: auto; background: none; border: 0; font-weight: 700; padding: 8px 10px; }
.toast .bar { height: 3px; transform-origin: left; animation: shrink linear forwards; }
@keyframes shrink { from { transform: scaleX(1) } to { transform: scaleX(0) } }
@keyframes up { from { transform: translateY(24px); opacity: 0 } to { transform: none; opacity: 1 } }
@keyframes fade { from { opacity: 0 } }

.link-card { padding: 20px; margin-top: 8px; }
.install-card { margin-top: 18px; padding: 16px; }
.install-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.install-head .dot { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex: none;
  color: var(--brand); background: color-mix(in srgb, var(--brand) 14%, transparent); }
.install-head strong { display: block; color: var(--brand); font-size: 15px; }
.install-head p { margin: 4px 0 0; color: var(--muted); font-size: 13.5px; }
.install-steps { margin: 0 0 4px; padding-left: 22px; display: grid; gap: 6px; font-size: 14px; }
.sheet .install-steps { gap: 8px; font-size: 14.5px; }
.install-hero { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 12px; }
.install-hero .logo-tile { width: 56px; height: 56px; box-shadow: 0 4px 14px rgba(0,0,0,.12); border: 1px solid var(--line); }
.install-hero h2 { line-height: 1.2; }
.install-hero .sub { margin: 6px 0 0; font-size: 14px; }
.install-why { list-style: none; margin: 0 0 16px; padding: 12px 14px; display: grid; gap: 8px; border-radius: 14px;
  background: color-mix(in srgb, var(--brand) 8%, transparent); color: var(--brand); font-size: 13.5px; font-weight: 500; }
.install-why li { display: flex; gap: 10px; align-items: center; }
.install-why svg { flex: none; }
.install-warn { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; font-size: 13.5px;
  color: var(--ink); background: color-mix(in srgb, #F59E0B 16%, transparent); }
.install-warn svg { flex: none; margin-top: 2px; color: #D97706; }
.install-small { font-size: 12.5px; margin: 10px 0 0; }
.later { display: block; margin: 8px auto 0; background: none; border: 0; color: var(--muted); font-size: 13px; padding: 6px 10px; }

/* typed number matching */
.number-entry { display: block; width: 140px; margin: 16px auto; padding: 12px 0; text-align: center;
  font-size: 40px; font-weight: 800; letter-spacing: 10px; text-indent: 10px; font-variant-numeric: tabular-nums;
  border-radius: 18px; border: 2px solid var(--line); background: var(--field); color: var(--ink); }
.number-entry:focus { outline: none; border-color: var(--green); }

/* account menu, export, lock notice */
.choice .dot { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: color-mix(in srgb, currentColor 12%, transparent); }
.qr { width: min(240px, 70vw); margin: 4px auto 0; border-radius: 12px; overflow: hidden; }
.qr svg { display: block; width: 100%; height: auto; }
.secret { margin: 0 0 12px; text-align: center; font: 600 15px/1.5 ui-monospace, Consolas, monospace; letter-spacing: 1px;
  user-select: all; word-break: break-all; }
.warn-note, .lock-note { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 14px; padding: 10px 12px; border-radius: 12px;
  font-size: 13px; color: var(--amber); background: color-mix(in srgb, #F59E0B 12%, transparent); }
.warn-note svg, .lock-note svg { flex: none; margin-top: 1px; }
.lock-note { margin: 12px 0 0; }

/* backup codes and recovery */
.codes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; margin: 4px 0 14px; padding: 14px; border-radius: 14px;
  background: var(--field); border: 1px solid var(--line); font: 600 16px/1.4 ui-monospace, Consolas, monospace; letter-spacing: 1px; text-align: center; }
.check { display: flex; gap: 10px; align-items: center; margin: 0 0 12px; font-weight: 600; }
.check input { width: 20px; height: 20px; accent-color: var(--green); }
.quote { margin: 0 0 14px; padding: 10px 14px; border-left: 3px solid var(--line); color: var(--muted); font-style: italic; }

/* activity */
.activity { list-style: none; margin: 0 0 12px; padding: 0; max-height: 52vh; overflow-y: auto; }
.activity li { display: grid; gap: 2px; padding: 10px 2px; border-bottom: 1px solid var(--line); }
.activity li:last-child { border-bottom: 0; }
.activity .what { font-weight: 600; font-size: 14px; }
.activity .what small { font-weight: 400; color: var(--muted); }
.activity .when { font-size: 12.5px; color: var(--muted); }
.activity li.bad .what { color: var(--amber); }

/* ── wide screens: use the space instead of a phone-width column ───────── */
.desktop-only { display: none; }
/* ⋮ menu in the band: actions for the whole device */
.more-btn { padding: 8px; }
.menu-scrim { position: fixed; inset: 0; z-index: 40; }
.menu { position: fixed; width: min(300px, calc(100vw - 24px)); padding: 6px; border-radius: 20px;
  background: var(--sheet); border: 1px solid var(--line); box-shadow: 0 18px 40px rgba(0, 0, 0, .18);
  transform-origin: top right; animation: pop .16s ease-out; }
@keyframes pop { from { opacity: 0; transform: scale(.94) translateY(-4px) } to { opacity: 1; transform: none } }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 4px 10px; }
.menu-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px; border: 0; border-radius: 14px;
  background: none; color: var(--ink); text-align: left; }
.menu-item:hover:not([disabled]), .menu-item:focus-visible { background: color-mix(in srgb, var(--green) 9%, transparent); outline: none; }
.menu-item[disabled] { opacity: .45; cursor: default; }
.menu-item strong { display: block; font-size: 14.5px; font-weight: 600; }
.menu-item small { display: block; color: var(--muted); font-size: 12px; line-height: 1.3; margin-top: 1px; }
.mi-ic { width: 38px; height: 38px; flex: none; display: grid; place-items: center; border-radius: 12px;
  color: var(--brand); background: color-mix(in srgb, var(--green) 13%, transparent); }
@media (max-width: 440px) { .band h1 { white-space: nowrap; } .theme-name, .theme-btn:not(.more-btn) svg:last-child { display: none; } }
a.btn { display: flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; }
.side-title { font-weight: 700; font-size: 15px; margin-bottom: 2px; }
@media (min-width: 960px) {
  .wrap { max-width: 1120px; }
  .band-row { max-width: 1070px; } /* lines up with the content inside .body's padding */
  .body { padding: 28px 32px 80px; }
  .cols { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px; align-items: start; }
  /* wide screens: accounts scroll in the left column, the side column scrolls on its own */
  .home-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; grid-template-rows: auto minmax(0, 1fr); column-gap: 28px; padding: 0 32px; }
  .home-top { grid-column: 1; grid-row: 1; padding: 28px 0 0; }
  .home-scroll { display: contents; }
  .acc-list { grid-column: 1; grid-row: 2; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px 4px 48px; margin: 0 -4px; }
  .col-side { grid-column: 2; grid-row: 1 / 3; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
    display: grid; gap: 14px; align-content: start; padding: 28px 0 48px; }
  .col-side .steps { margin: 0; }
  .desktop-only { display: grid; }
  .mobile-only { display: none; }
  .stats { gap: 16px; }
  .stat { padding: 18px 20px; }
  .stat b { font-size: 32px; }
  .acc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
  .acc-grid .account { margin-bottom: 0; }
  .empty { padding: 56px 8px 8px; }
  .empty img { width: 104px; }
  .empty h2 { font-size: 24px; }
  .scrim { align-items: center; }
  .sheet { max-width: 560px; border-radius: 28px; }
}
