/* YAAD Wallet console: the card deck + the live workspace. Phone first; two columns from 900px. */
:root { --page: #0b0907; --surf: #15110c; --surf2: #1d1811; --sep: rgba(255, 236, 200, .08);
  --font: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, "Segoe UI", sans-serif; }
body.cs { background: var(--page); font-family: var(--font); -webkit-font-smoothing: antialiased; overscroll-behavior-y: none; }
.cs .wrap { max-width: 1180px; padding: max(10px, env(safe-area-inset-top)) 16px 56px; }
.cs h1, .cs h2, .cs h3, .cs button, .cs input, .cs select { font-family: var(--font); }

/* top bar + large title */
.cs header.top { margin-bottom: 8px; min-height: 44px; }
.cs .brand { font-size: 13px; letter-spacing: .14em; gap: 8px; }
.cs .brand img { width: 22px; height: 22px; }
.cs nav a { font-size: 14px; font-weight: 500; }
.iconbtn { width: 44px; height: 44px; border-radius: 22px; padding: 0; display: inline-grid; place-items: center; background: var(--surf2); color: var(--text); border: 0;
  transition: transform .2s var(--spring); }
.iconbtn svg { width: 22px; height: 22px; }
.iconbtn.gold { background: var(--gold); color: #1d1404; }
.iconbtn:active { transform: scale(.92); }
.cs .wl-top { display: flex; justify-content: space-between; align-items: flex-end; margin: 4px 0 18px; }
.cs .wl-top .kick { display: block; font-size: 13px; color: var(--muted); letter-spacing: .02em; margin-bottom: 4px; }
.cs .wl-top h1 { font: 800 34px/1 var(--font); letter-spacing: -.025em; margin: 0; }
.open-bar { display: none; justify-content: space-between; align-items: center; height: 44px; margin: 0 0 10px; }
.open-bar b { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.txtbtn { background: none; border: 0; color: var(--gold); font: 600 17px/1 var(--font); padding: 10px 2px; }
.more-menu { display: none; }
.wl-btns { display: flex; gap: 10px; }
.cs .wl-top .kick { text-transform: uppercase; font-size: 12px; font-weight: 700; letter-spacing: .06em; }
.open-pill { background: rgba(255, 236, 200, .09); color: var(--gold-hi); border-radius: 99px; padding: 7px 14px; font-size: 14px; font-weight: 650; text-decoration: none; flex: none; }
.open-pill:active { transform: scale(.95); }
.chev { background: none; border: 0; padding: 8px 2px 8px 6px; color: var(--muted); flex: none; } .chev svg { width: 18px; height: 18px; display: block; }
.menu-list button { color: var(--bad); }

.cs-grid { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 32px; align-items: start; }

/* the deck */
.deck2 { position: relative; }
.wcard { position: absolute; left: 0; top: 0; width: 100%; aspect-ratio: 1.586; will-change: transform; cursor: pointer; outline: none;
  -webkit-tap-highlight-color: transparent; -webkit-touch-callout: none; user-select: none; -webkit-user-select: none; }
.wcard.pinned { position: fixed; }
.face { position: absolute; inset: 0; border-radius: 18px; background: var(--card); color: var(--ink); overflow: hidden; padding: 15px 18px 17px;
  box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .1), inset 0 1px 0 rgba(255, 255, 255, .16), 0 -3px 14px rgba(0, 0, 0, .3), 0 18px 36px -12px rgba(0, 0, 0, .6);
  transition: transform .24s var(--spring), filter .35s ease; }
.face::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(160deg, rgba(255, 255, 255, .17), rgba(255, 255, 255, .035) 30%, transparent 52%), radial-gradient(120% 90% at 100% 115%, rgba(0, 0, 0, .24), transparent 62%); }
.wcard:active .face { transform: scale(.985); }
.wcard:focus-visible .face { box-shadow: 0 0 0 2px var(--page), 0 0 0 4px var(--gold); }
.face .body { position: relative; height: 100%; display: flex; flex-direction: column; }
.face .r1 { display: flex; align-items: center; gap: 9px; height: 28px; }
.face .ic svg { width: 22px; height: 22px; display: block; }
.face .nm { font-size: 17px; font-weight: 700; letter-spacing: -.012em; white-space: nowrap; }
.face .hd { margin-left: auto; text-align: right; min-width: 0; }
.face .k { display: block; font-size: 10px; line-height: 1; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; opacity: .62; margin-bottom: 4px; }
.face .v { display: block; font-size: 15px; line-height: 1.15; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.face .pri { margin-top: 24px; min-width: 0; }
.face .pri .v { font-size: 25px; font-weight: 750; letter-spacing: -.022em; line-height: 1.12; }
.face .r3 { display: flex; gap: 22px; margin-top: auto; min-width: 0; }
.face .r3 > div { min-width: 0; }
.deck-hint { color: var(--muted); font-size: 13px; text-align: center; margin: 16px 0 0; }

/* entrance: the cards are dealt in, once */
.deck2:not(.ready) .wcard { opacity: 0; }
.deck2.ready.dealing .face { animation: deal .75s var(--spring) both; animation-delay: calc(var(--i) * 50ms); }
@keyframes deal { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: none; } }

/* workspace */
.ws { background: var(--surf); border: 1px solid var(--sep); border-radius: 22px; padding: 18px 18px 8px; min-height: 520px; }
.ws-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.ws-head h2 { font: 750 22px/1.1 var(--font); letter-spacing: -.02em; margin: 0; }
.live { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--muted); font-weight: 500; }
.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #5ad19a; box-shadow: 0 0 0 3px rgba(90, 209, 154, .16); animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe { 50% { box-shadow: 0 0 0 6px rgba(90, 209, 154, 0); } }
.sec { margin-top: 24px; }
.sec h3 { font: 600 13px/1 var(--font); letter-spacing: .02em; color: var(--muted); margin: 0 4px 10px; text-transform: none; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.runchip { display: inline-flex; align-items: center; gap: 8px; background: var(--surf2); border-radius: 99px; padding: 7px 13px 7px 10px; font-size: 13px; }
.runchip i { width: 8px; height: 8px; border-radius: 50%; background: var(--warn); animation: pulse 1s infinite alternate; }

/* inset grouped lists (the feed, detail rows) */
.feed, .detail { background: var(--surf2); border-radius: 16px; padding: 2px 14px; border: 0; }
.detail { margin-top: 4px; padding: 6px 14px 10px; }
.feed .ev { display: flex; gap: 12px; align-items: center; padding: 11px 0; border-bottom: .5px solid var(--sep); }
.feed .ev:last-child { border-bottom: 0; }
.feed .ev.new { animation: arrive .55s var(--spring) both; }
@keyframes arrive { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 750; font-size: 13px; flex: none; color: #1d1404; }
.av svg { width: 17px; height: 17px; }
.av.agent { background: #c9bff5; color: #241b4d; } .av.yaad { background: var(--gold); } .av.person { background: #ecdfc4; }
.ev .txt { flex: 1; min-width: 0; font-size: 14.5px; line-height: 1.35; }
.ev .txt > span:last-child { color: var(--muted); font-size: 12.5px; display: block; margin-top: 1px; }
.tag2 { font: 700 10px/1 var(--font); letter-spacing: .04em; padding: 3px 6px; border-radius: 5px; background: rgba(255, 236, 200, .08); color: #d9c79d; margin-left: 6px; vertical-align: 1px; }
.tag2.agent { background: rgba(201, 191, 245, .14); color: #d6cfff; }
.detail .item { padding: 12px 0; border-bottom: .5px solid var(--sep); }
.detail .item:hover { background: transparent; }
.appcard { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: .5px solid var(--sep); margin: 0; background: none; border-radius: 0; }
.appcard .sw { width: 40px; height: 26px; border-radius: 5px; flex: none; box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .14); }
.appcard .mid { flex: 1; min-width: 0; } .appcard .mid b { display: block; font-size: 15.5px; font-weight: 650; }
.appcard .mid span { color: var(--muted); font-size: 12.5px; }
.ico { display: inline-block; vertical-align: -3px; line-height: 0; } .ico svg { width: 15px; height: 15px; }
.stat { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--sep); border-radius: 12px; overflow: hidden; margin: 8px 0; }
.stat div { background: var(--surf2); padding: 12px; } .stat b { display: block; font-size: 24px; font-weight: 750; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12.5px; color: var(--muted); }
.cs .act { background: rgba(255, 236, 200, .08); color: var(--text); border-radius: 99px; font-weight: 600; transition: transform .2s var(--spring); }
.cs .act:active, .cs .cta:active { transform: scale(.97); }
.cs .cta { border-radius: 14px; font-weight: 700; letter-spacing: -.005em; transition: transform .2s var(--spring); }
.tile .ti svg { width: 22px; height: 22px; }
.tile { transition: transform .2s var(--spring), border-color .2s, background .2s; }
.tile:active { transform: scale(.97); }
.menu-list { display: grid; background: var(--surf2); border-radius: 14px; overflow: hidden; margin-top: 6px; }
.menu-list a, .menu-list button { display: flex; justify-content: space-between; align-items: center; padding: 15px 16px; color: var(--text); text-decoration: none; font: 500 16px/1 var(--font);
  background: none; border: 0; border-bottom: .5px solid var(--sep); border-radius: 0; text-align: left; }
.menu-list > :last-child { border-bottom: 0; }
.menu-list svg { width: 16px; height: 16px; color: var(--muted); }

/* phone: one column; the stack, then today's activity. A tapped card lifts and the rest rest at the bottom. */
@media (max-width: 899px) {
  .cs-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .cs nav, .cs header.top { display: none; }
  .more-menu { display: inline-grid; }
  .ws { background: none; border: 0; padding: 0; min-height: 0; margin-top: 26px; }
  body:not(.deck-open) .ws-head, body:not(.deck-open) #detail { display: none; }
  body.deck-open .wl-top, body.deck-open .deck-hint { display: none; }
  body.deck-open .open-bar { display: flex; }
  body.deck-open .ws { margin-top: 22px; opacity: var(--lift, 1); animation: rise .6s var(--spring) both .08s; }
  body.deck-open #main { padding-bottom: 120px; }
  .deck-shade { position: fixed; left: 0; right: 0; bottom: 0; height: 150px; pointer-events: none; z-index: 9; opacity: 0;
    background: linear-gradient(to bottom, rgba(11, 9, 7, 0), var(--page) 62%); transition: opacity .35s ease; }
  body.deck-open .deck-shade { opacity: 1; }
}
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@media (min-width: 900px) {
  .deck-shade { display: none; }
  .wcard:not(.chosen) .face { filter: brightness(.8) saturate(.88); }
  .wcard:not(.chosen):hover .face { filter: none; transform: translateY(-6px); }
  .ws.enter #detail, .ws.enter .ws-head { animation: rise .45s var(--spring) both; }
}
@media (prefers-reduced-motion: reduce) {
  .deck2.ready.dealing .face, .ws, .ws.enter #detail, .ws.enter .ws-head, .feed .ev.new { animation: none !important; }
  .face, .tile, .cs .cta, .cs .act, .iconbtn { transition: none; }
}

/* phones: never let iOS zoom into a field (it zooms when text is under 16px), never scroll sideways */
html, body.cs { overflow-x: clip; }
@media (max-width: 899px) { .cs input, .cs select, .cs textarea { font-size: 16px; } }

/* card type scales with the card, from small Androids to Pro Max */
.wcard { container-type: inline-size; }
@container (max-width: 1000px) {
  .face { padding: 4.3cqi 5cqi 4.6cqi; border-radius: max(14px, 4.8cqi); }
  .face .nm { font-size: clamp(15px, 4.6cqi, 18px); }
  .face .ic svg { width: clamp(19px, 6cqi, 23px); height: clamp(19px, 6cqi, 23px); }
  .face .pri { margin-top: 6.2cqi; }
  .face .pri .v { font-size: clamp(20px, 7cqi, 28px); }
  .face .v { font-size: clamp(13.5px, 4.1cqi, 16px); }
  .face .k { font-size: clamp(9px, 2.7cqi, 10.5px); }
  .face .r3 { gap: 6cqi; }
}

/* welcome: the story before sign-in */
.welcome { max-width: 440px; margin: 0 auto; padding: 8px 0 24px; }
.welcome h1 { font: 800 clamp(34px, 10vw, 46px)/1.02 var(--font); letter-spacing: -.035em; margin: 26px 0 12px; }
.lede2 { color: var(--muted); font-size: 17px; line-height: 1.45; margin: 0 0 26px; text-wrap: pretty; }
.welcome .row { flex-direction: column; align-items: stretch; gap: 10px; }
.welcome input { height: 54px; border-radius: 14px; font-size: 17px; padding: 0 16px; background: var(--surf2); border-color: transparent; flex: none; }
.welcome button { height: 54px; border-radius: 14px; font-size: 17px; }
.welcome #m { font-size: 14px; margin-top: 12px; }
.welcome .fine { color: var(--muted); font-size: 13px; margin: 18px 2px 0; opacity: .8; }
.hero-stack { position: relative; aspect-ratio: 1.149; width: 100%; margin-top: 8px; }
.hcard { position: absolute; left: 0; right: 0; top: calc(var(--i) * 13.8%); aspect-ratio: 1.586; border-radius: 18px; background: var(--card); color: var(--ink); padding: 16px 18px;
  display: flex; align-items: flex-start; gap: 9px; box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .1), inset 0 1px 0 rgba(255, 255, 255, .16), 0 -3px 14px rgba(0, 0, 0, .3), 0 18px 36px -12px rgba(0, 0, 0, .6);
  animation: deal .8s var(--spring) both; animation-delay: calc(var(--i) * 90ms + 100ms); overflow: hidden; }
.hcard::before { content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(255, 255, 255, .17), transparent 50%); pointer-events: none; }
.hcard .ic svg { width: 22px; height: 22px; display: block; } .hcard .nm { font-weight: 700; font-size: 17px; }
.hcard .hv { position: absolute; left: 18px; bottom: 18px; font: 750 26px/1.1 var(--font); letter-spacing: -.02em; }
.hcard .hv i { display: block; font: 700 10px/1 var(--font); font-style: normal; letter-spacing: .09em; text-transform: uppercase; opacity: .62; margin-bottom: 6px; }

.wbrand { display: none; align-items: center; gap: 8px; font-weight: 800; font-size: 13px; letter-spacing: .14em; margin: 6px 0 18px; }
.wbrand img { width: 22px; height: 22px; } .wbrand b { color: var(--gold); }
@media (max-width: 899px) { .wbrand { display: flex; } }

/* first run on the Apps card */
.first h3 { font: 750 19px/1.2 var(--font); letter-spacing: -.015em; margin: 8px 0 12px; }
.steps3 { list-style: none; padding: 0; margin: 0; counter-reset: s; display: grid; gap: 16px; }
.steps3 li { counter-increment: s; position: relative; padding-left: 38px; min-width: 0; }
.steps3 li::before { content: counter(s); position: absolute; left: 0; top: -1px; width: 26px; height: 26px; border-radius: 50%; background: var(--gold); color: #1d1404;
  display: grid; place-items: center; font: 800 13px/1 var(--font); }
.steps3 b { display: block; font-size: 15.5px; } .steps3 li > span { display: block; color: var(--muted); font-size: 14px; margin-top: 2px; }
.cmd { display: flex; gap: 8px; align-items: center; margin-top: 8px; background: #0f0c08; border-radius: 10px; padding: 8px 8px 8px 12px; min-width: 0; }
.cmd code { flex: 1; min-width: 0; font: 12px/1.4 ui-monospace, Menlo, Consolas, monospace; color: var(--gold-hi); overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.cmd .act { padding: 6px 12px; flex: none; }

/* Agents card: status + a Messages-style thread */
.chathead { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; padding: 8px 0 10px; border-bottom: .5px solid var(--sep); }
.chathead b { font-size: 16px; }
.spill { display: inline-flex; align-items: center; gap: 6px; font: 650 12.5px/1 var(--font); padding: 6px 10px; border-radius: 99px; background: rgba(255, 236, 200, .08); white-space: nowrap; }
.spill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.spill.working::before { background: var(--warn); animation: pulse 1s infinite alternate; } .spill.done::before { background: #5ad19a; }
.spill.needs_you { background: rgba(226, 176, 74, .18); color: var(--gold-hi); } .spill.needs_you::before { background: var(--gold); }
.chatlog { display: flex; flex-direction: column; gap: 6px; max-height: min(52vh, 460px); overflow-y: auto; padding: 12px 0; overscroll-behavior: contain; }
.bub { max-width: 82%; padding: 9px 13px; border-radius: 18px; font-size: 15px; line-height: 1.35; white-space: pre-wrap; overflow-wrap: anywhere; animation: arrive .35s var(--spring) both; }
.bub a { color: inherit; text-decoration: underline; text-underline-offset: 2px; font-weight: 600; }
.bub span { display: block; font-size: 11px; opacity: .6; margin-top: 3px; }
.bub.them { align-self: flex-start; background: #2a241b; border-bottom-left-radius: 6px; }
.bub.me { align-self: flex-end; background: var(--gold); color: #1d1404; border-bottom-right-radius: 6px; }
.composer { display: flex; gap: 8px; align-items: center; padding-top: 8px; border-top: .5px solid var(--sep); }
.composer input { flex: 1; height: 42px; border-radius: 21px; background: #0f0c08; border: .5px solid var(--sep); padding: 0 16px; }
.composer button { width: 42px; height: 42px; border-radius: 21px; padding: 0; display: grid; place-items: center; flex: none; }
.composer button svg { width: 20px; height: 20px; }

/* Connections card */
.appr { background: rgba(226, 176, 74, .1); border: .5px solid rgba(226, 176, 74, .35); border-radius: 14px; padding: 12px; margin: 6px 0 10px; }
.appr .mid b { display: block; font-size: 15px; } .appr .mid span { display: block; color: var(--muted); font-size: 12.5px; margin-top: 4px; }
.appr pre { background: #0f0c08; border-radius: 8px; padding: 8px; max-height: 160px; overflow: auto; }
.connect { padding: 12px 0; border-bottom: .5px solid var(--sep); } .connect b { font-size: 15.5px; }
.connect input { font-size: 16px; }

/* Security card (rows share the admin row style) */
.gate { padding: 6px 0 10px; border-bottom: .5px solid var(--sep); } .gate:last-child { border-bottom: 0; }
.row2 { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: .5px solid var(--sep); }
.row2 .mid { flex: 1; min-width: 0; } .row2 .mid b { display: block; font-size: 15px; font-weight: 650; }
.row2 .mid span { display: block; color: var(--muted); font-size: 12.5px; }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--muted); margin-top: 6px; }
.dot.ok { background: #5ad19a; } .dot.bad { background: var(--bad); } .dot.warn { background: var(--warn); }

/* odds and ends */
.cs [hidden] { display: none !important; }
.wcard.static { position: relative; cursor: default; will-change: auto; margin: 2px 0 14px; }
.wcard.static:active .face { transform: none; }
.face .v.icons { display: flex; gap: 10px; margin-top: 4px; } .face .v.icons svg { width: 22px; height: 22px; }
.item .ic { color: #fff8e6; } .item .ic svg { width: 18px; height: 18px; }
@media (max-width: 899px) { .ws-head { display: none !important; } }
