/* VOICE: a working ledger for a small Egyptian business — calm, exact, no decoration.
   IDEA: a bound invoice book: ruled rows, a stamped status, the printed sheet beside the stub.
   PICTURE: the tool itself — the A4 invoice sheet next to the form, and the list of who owes what.
   COLOUR and TYPE: stone ground, black ink, brick-red accent, white panels; IBM Plex Sans Arabic, tabular figures.
   LAYOUT: black top bar, one column up to 1180px, bottom tab bar on phones, sheets slide over for edit and detail. */
:root{color-scheme:light dark;
--bg:light-dark(#e7e4df,#171513);--panel:light-dark(#fff,#211e1b);--panel2:light-dark(#f3f1ed,#2a2622);
--line:light-dark(#d3cec6,#3a352f);--line2:light-dark(#e8e4de,#2e2a26);
--ink:light-dark(#161412,#efebe5);--muted:light-dark(#5f5850,#b3ab9f);--faint:light-dark(#7d756b,#8f877c);
--acc:light-dark(#c8371e,#f07258);--acc-ink:light-dark(#fff,#1d0b06);--acc-soft:light-dark(#f6dcd5,#3d1c14);
--ok:light-dark(#1d7a47,#62cc92);--ok-soft:light-dark(#dcefe2,#16301f);
--bad:light-dark(#b42318,#f3806f);--bad-soft:light-dark(#f8dedb,#3b1915);
--info:light-dark(#2b5aa6,#8db2f2);--info-soft:light-dark(#dfe7f5,#1a2539);
--warn:light-dark(#8a5a00,#e5b855);--warn-soft:light-dark(#f3e7cc,#352a13);
--font:"IBM Plex Sans Arabic",system-ui,"Segoe UI",Tahoma,sans-serif;--r:10px}
:root[data-theme=light]{color-scheme:light}:root[data-theme=dark]{color-scheme:dark}
*,*::before,*::after{box-sizing:border-box;min-width:0}
[hidden]{display:none!important}
html,body{background:var(--bg);color:var(--ink)}
body{margin:0;font:16px/1.55 var(--font);-webkit-font-smoothing:antialiased;padding-bottom:110px;overflow-x:clip}
a{color:inherit}
h1,h2,h3{margin:0;line-height:1.2;text-wrap:balance}
button,input,select,textarea{font:inherit;color:inherit}
.n,.num{font-variant-numeric:tabular-nums;direction:ltr;unicode-bidi:isolate}
:focus-visible{outline:2px solid var(--acc);outline-offset:2px}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}
.gut{padding-inline:max(16px,env(safe-area-inset-left,0px))}
.wrap{max-width:1180px;margin:0 auto}

.top{position:sticky;top:0;z-index:20;background:#161412;color:#efebe5;padding-top:env(safe-area-inset-top,0px)}
.top-in{display:flex;align-items:center;gap:14px;min-height:60px}
.brand{display:flex;align-items:center;gap:10px;font-weight:700;font-size:18px;white-space:nowrap}
.mark{width:22px;height:26px;border:2px solid #efebe5;border-radius:3px;position:relative;background:repeating-linear-gradient(0deg,transparent 0 5px,#efebe5 5px 6px)}
.mark::after{content:"";position:absolute;inset-inline-end:-6px;top:-6px;width:10px;height:10px;border-radius:50%;background:#e0492c}
.tabs{display:flex;gap:2px;margin-inline-start:10px}
.tab{display:flex;align-items:center;gap:7px;border:0;background:none;padding:8px 12px;border-radius:8px;color:#b9b1a6;cursor:pointer;font-weight:500;min-height:40px}
.tab svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.tab:hover{color:#fff;background:#2a2622}
.tab[aria-current=page]{color:#fff;background:#2e2925}
.top-act{margin-inline-start:auto;display:flex;gap:8px}
.top .btn{background:transparent;color:#efebe5;border-color:#4a443d}
.top .btn:hover{background:#2a2622}
.top .btn-primary{background:#e0492c;border-color:#e0492c;color:#fff}
@media (max-width:820px){
 .tabs{position:fixed;inset:auto 0 0 0;margin:0;z-index:25;background:#161412;justify-content:space-around;gap:0;padding:6px 6px calc(6px + env(safe-area-inset-bottom,0px))}
 .tab{flex-direction:column;gap:2px;font-size:11.5px;padding:6px 2px;flex:1;min-height:52px}
 .tab[aria-current=page]{background:none;color:#ff7a5e}
 .top-act .btn{padding:0 10px;font-size:14px}
}
@media (max-width:460px){.brand span:last-child{display:none}}

.banner{margin-top:12px;padding:10px 14px;border-radius:8px;background:var(--warn-soft);border:1px solid var(--line);font-size:14.5px}
.banner.bad{background:var(--bad-soft);color:var(--ink)}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:0 15px;border-radius:8px;border:1px solid var(--line);background:var(--panel);cursor:pointer;font-weight:500;text-decoration:none;white-space:nowrap;color:var(--ink)}
.btn:hover{background:var(--panel2)}
.btn-primary{background:var(--acc);border-color:var(--acc);color:var(--acc-ink)}
.btn-primary:hover{background:var(--acc);filter:brightness(1.07)}
.btn-ghost{background:none;border-color:transparent}
.btn-danger{color:var(--bad)}
.btn-sm{min-height:36px;padding:0 11px;font-size:14px}
.btn[disabled]{opacity:.5;cursor:default}
.btn svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:none}
.field{display:flex;flex-direction:column;gap:5px}
.field>span{font-size:13.5px;font-weight:600;color:var(--muted)}
.field small{color:var(--faint);font-size:13px;line-height:1.45}
input:where(:not([type=file]):not([type=color]):not([type=checkbox]):not([type=radio])),select,textarea{width:100%;min-height:44px;padding:9px 12px;border-radius:8px;border:1px solid var(--line);background:var(--panel);font-size:16px}
textarea{min-height:80px;resize:vertical;line-height:1.5}
input:focus,select:focus,textarea:focus{outline:none;border-color:var(--acc);box-shadow:0 0 0 3px var(--acc-soft)}
input[readonly]{background:var(--panel2);color:var(--muted)}
.ltr{direction:ltr;text-align:end}
.grid{display:grid;gap:12px}
.g2{grid-template-columns:repeat(2,minmax(0,1fr))}
.g3{grid-template-columns:repeat(3,minmax(0,1fr))}
@media (max-width:640px){.g2,.g3{grid-template-columns:minmax(0,1fr)}.g2.keep,.g3.keep{grid-template-columns:repeat(2,minmax(0,1fr))}}
.card{background:var(--panel);border:1px solid var(--line);border-radius:var(--r);padding:18px}
.card h2{font-size:17px;margin-bottom:12px}
.muted{color:var(--muted)}.faint{color:var(--faint)}
.stack{display:flex;flex-direction:column;gap:16px}
.rw{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.spacer{flex:1}
.note{font-size:14px;color:var(--muted);margin:-4px 0 14px}

.view{padding-block:22px}
.head{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:16px}
.head h1{font-size:clamp(26px,4vw,34px);font-weight:700}
.kicker{font-size:14px;color:var(--faint);margin-bottom:4px}
.kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;background:var(--panel);border:1px solid var(--line);border-radius:var(--r)}
@media (max-width:820px){.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}}
.kpi{padding:16px 18px;display:flex;flex-direction:column;gap:3px;border-inline-start:1px solid var(--line2)}
.kpi:first-child{border-inline-start:0}
@media (max-width:820px){.kpi:nth-child(3){border-inline-start:0}.kpi:nth-child(n+3){border-top:1px solid var(--line2)}}
.kpi-l{font-size:14px;color:var(--muted);font-weight:600}
.kpi-v{font-size:clamp(19px,2.6vw,26px);font-weight:700;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.kpi-s{font-size:13px;color:var(--faint)}
.kpi.bad .kpi-v{color:var(--bad)}.kpi.ok .kpi-v{color:var(--ok)}
.two{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:16px;align-items:start;margin-top:16px}
@media (max-width:940px){.two{grid-template-columns:minmax(0,1fr)}}

.chips{display:flex;gap:6px;overflow-x:auto;padding-bottom:2px;scrollbar-width:none}
.chip{border:1px solid var(--line);background:var(--panel);border-radius:999px;padding:7px 13px;font-size:14px;cursor:pointer;white-space:nowrap;color:var(--muted);min-height:38px}
.chip[aria-pressed=true]{background:var(--ink);color:var(--bg);border-color:var(--ink)}
.chip b{font-weight:600;margin-inline-start:5px;font-size:12.5px}
.toolbar{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin-bottom:12px}
.toolbar .search{flex:1;min-width:200px;max-width:380px}
.list{background:var(--panel);border:1px solid var(--line);border-radius:var(--r);overflow:hidden}
.row{display:flex;align-items:center;gap:14px;width:100%;text-align:start;padding:13px 16px;border:0;border-bottom:1px solid var(--line2);background:none;cursor:pointer;color:var(--ink)}
.row:last-child{border-bottom:0}
.row:hover{background:var(--panel2)}
.rm{display:flex;flex-direction:column;flex:1}
.rt{font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.rs{font-size:13.5px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.re{display:flex;flex-direction:column;align-items:flex-end;gap:4px;flex-shrink:0}
.ra{font-weight:600;font-variant-numeric:tabular-nums;white-space:nowrap;direction:ltr;unicode-bidi:isolate}
.pill{display:inline-flex;align-items:center;gap:6px;font-size:12.5px;font-weight:600;padding:2px 10px;border-radius:999px;background:var(--panel2);color:var(--muted);white-space:nowrap}
.pill::before{content:"";width:6px;height:6px;border-radius:50%;background:currentColor}
.s-draft{background:var(--panel2);color:var(--muted)}
.s-draft::before{background:transparent;border:1.5px solid currentColor;width:7px;height:7px}
.s-open{background:var(--info-soft);color:var(--info)}
.s-part{background:var(--warn-soft);color:var(--warn)}
.s-ok{background:var(--ok-soft);color:var(--ok)}
.s-bad{background:var(--bad-soft);color:var(--bad)}
.s-void{background:var(--panel2);color:var(--faint);text-decoration:line-through}
.empty{padding:32px 20px;text-align:center;color:var(--muted);display:flex;flex-direction:column;align-items:center;gap:12px}
.empty h3{color:var(--ink);font-size:18px}
.attn{display:flex;align-items:center;gap:12px;padding:12px 16px;border-top:1px solid var(--line2);flex-wrap:wrap}
.attn .rm{min-width:160px}
.sr{display:flex;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px solid var(--line2)}
.sr:last-child{border-bottom:0}
.sr b{font-variant-numeric:tabular-nums;font-weight:600;direction:ltr;unicode-bidi:isolate;white-space:nowrap}
.bars{display:flex;flex-direction:column;gap:9px;margin-top:6px}
.bar{display:grid;grid-template-columns:64px minmax(0,1fr) auto;gap:10px;align-items:center;font-size:13.5px}
.bar-t{display:flex;flex-direction:column;gap:3px}
.bar-t i{display:block;height:7px;border-radius:2px;background:light-dark(#bdb6ab,#5a534b)}
.bar-t i.c{background:var(--acc)}
.bar .v{font-variant-numeric:tabular-nums;color:var(--muted);direction:ltr;text-align:end;white-space:nowrap}
.legend{display:flex;gap:14px;font-size:13px;color:var(--muted);margin-top:4px}
.legend span::before{content:"";display:inline-block;width:10px;height:7px;border-radius:2px;margin-inline-end:6px;background:light-dark(#bdb6ab,#5a534b)}
.legend span.c::before{background:var(--acc)}

.sheet{position:fixed;inset:0;z-index:40;background:var(--bg);overflow-y:auto;padding-bottom:calc(40px + env(safe-area-inset-bottom,0px))}
.sbar{position:sticky;top:0;z-index:5;background:var(--panel);border-bottom:1px solid var(--line);padding-top:env(safe-area-inset-top,0px)}
.sbar-in{display:flex;align-items:center;gap:10px;min-height:60px}
.stitle{font-weight:700;font-size:17px;display:flex;align-items:center;gap:10px;flex:1;overflow:hidden}
.stitle .t{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sbody{padding-block:18px}
.ed{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,500px);gap:20px;align-items:start}
.ed-pv{position:sticky;top:80px}
@media (max-width:1100px){.ed{grid-template-columns:minmax(0,1fr)}.ed-pv{display:none;position:static}.ed.pv .ed-pv{display:block}.ed.pv .ed-form{display:none}}
@media (min-width:1101px){.narrow{display:none!important}}
.line{display:grid;grid-template-columns:minmax(0,1fr) 230px;gap:10px;padding:12px;border:1px solid var(--line);border-radius:8px;background:var(--bg)}
.line-m{display:flex;flex-direction:column;gap:8px}
.line-m textarea{min-height:46px}
.line-n{display:grid;grid-template-columns:76px minmax(0,1fr);gap:8px;align-content:start}
.line-t{grid-column:1/-1;text-align:end;font-weight:600;font-variant-numeric:tabular-nums;direction:ltr}
.line-x{grid-column:1/-1;display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}
@media (max-width:640px){.line{grid-template-columns:minmax(0,1fr)}}
.tot{display:flex;flex-direction:column;gap:2px;font-size:15px}
.tot>div{display:flex;justify-content:space-between;gap:10px;padding:4px 0}
.tot b{font-variant-numeric:tabular-nums;direction:ltr;unicode-bidi:isolate}
.tot .g{border-top:1px solid var(--line);margin-top:4px;padding-top:8px;font-size:18px;font-weight:700}
.thumbs{display:flex;flex-wrap:wrap;gap:10px}
.thumb{position:relative;width:104px;height:78px;border-radius:6px;background:var(--panel2) center/cover no-repeat;border:1px solid var(--line)}
.thumb button{position:absolute;top:4px;inset-inline-end:4px;width:28px;height:28px;border-radius:50%;border:0;background:rgba(0,0,0,.65);color:#fff;cursor:pointer;line-height:1}
.logo-box{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin-bottom:14px}
.logo-pv{width:120px;height:72px;border-radius:6px;border:1px dashed var(--line);display:flex;align-items:center;justify-content:center;background:#fff center/contain no-repeat;color:#857d73;font-size:13px}
.sw{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.swatch{width:34px;height:34px;border-radius:50%;border:2px solid var(--panel);box-shadow:0 0 0 1px var(--line);cursor:pointer}
.swatch[aria-pressed=true]{box-shadow:0 0 0 2px var(--ink)}
.tpls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-bottom:14px}
.tpl{border:1px solid var(--line);border-radius:8px;padding:10px;cursor:pointer;background:var(--panel);text-align:start;display:flex;flex-direction:column;gap:6px}
.tpl[aria-pressed=true]{border-color:var(--acc);box-shadow:0 0 0 3px var(--acc-soft)}
.tpl-th{height:54px;border-radius:4px;background:#fff;border:1px solid #e3e0da;position:relative;overflow:hidden}
.tpl-th i{position:absolute;inset-inline:8px;height:4px;border-radius:2px;background:#d7d3cc}
.tpl small{color:var(--faint);font-size:12.5px;line-height:1.35}
.det{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:20px;align-items:start}
@media (max-width:980px){.det{grid-template-columns:minmax(0,1fr)}}
.acts{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:16px}
.pay{display:flex;align-items:center;gap:10px;padding:8px 0;border-bottom:1px solid var(--line2)}
.pay:last-child{border-bottom:0}
.callout{padding:12px 14px;border-radius:8px;background:var(--panel2);border:1px solid var(--line);font-size:14px;color:var(--muted)}
.callout b{color:var(--ink)}

.pf{position:relative;overflow:hidden;direction:ltr;border-radius:4px;box-shadow:0 1px 2px rgba(20,16,12,.06),0 10px 28px rgba(20,16,12,.12);background:#fff}
.ps{width:794px;transform-origin:top left}
.pdf-host{position:fixed;left:-12000px;top:0;width:794px;pointer-events:none;direction:ltr}

.modal{position:fixed;inset:0;z-index:60;background:rgba(12,10,8,.55);display:flex;align-items:center;justify-content:center;padding:20px 16px calc(20px + env(safe-area-inset-bottom,0px))}
.dialog{background:var(--panel);border:1px solid var(--line);border-radius:14px;width:100%;max-width:560px;max-height:calc(100% - 20px);overflow-y:auto;padding:20px;display:flex;flex-direction:column;gap:14px}
.dialog h2{font-size:19px}
.da{display:flex;gap:8px;justify-content:flex-end;flex-wrap:wrap;padding-top:4px}
@media (max-width:640px){.modal{align-items:flex-end;padding-bottom:0}.dialog{border-radius:14px 14px 0 0;max-height:92%;padding-bottom:calc(20px + env(safe-area-inset-bottom,0px))}}
.toast{position:fixed;left:50%;bottom:calc(88px + env(safe-area-inset-bottom,0px));transform:translateX(-50%) translateY(16px);z-index:80;background:var(--ink);color:var(--bg);padding:10px 16px;border-radius:8px;font-size:15px;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s;max-width:calc(100% - 32px);text-align:center}
.toast.show{opacity:1;transform:translateX(-50%) translateY(0)}
.vh{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}

/* ---- responsive layer ---- */
.btn,.chip,.pill,.swatch{flex:none}
.tl{display:inline}.ts{display:none}
.head.sticky{position:sticky;top:calc(60px + env(safe-area-inset-top,0px));z-index:10;background:var(--bg);padding-block:10px;margin-top:-10px}
.det-side{display:flex;flex-direction:column;gap:16px}
.sum-h{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}
.sum-h h2{margin:0}
.pf-wrap{position:relative}
.zoom-btn{position:absolute;top:10px;inset-inline-start:10px;z-index:2;background:rgba(255,255,255,.92);color:#161412;border-color:#d3cec6}
.pf.zoom{overflow:auto;height:72vh!important;-webkit-overflow-scrolling:touch}
.pf.zoom .ps{transform:none!important}
@media (max-width:980px){
 .det{display:flex;flex-direction:column;align-items:stretch}
 .det-side{display:contents}
 .det-sum{order:-1}.det-paper{order:0}.det-more{order:1}
}
@media (max-width:820px){
 .tl{display:none}.ts{display:inline}
 .hide-m{display:none!important}
 .head.sticky{top:calc(60px + env(safe-area-inset-top,0px))}
}
@media (max-width:640px){
 .view{padding-block:16px}
 .acts{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;margin-inline:-16px;padding-inline:16px;padding-bottom:4px;scroll-snap-type:x proximity}
 .acts::-webkit-scrollbar{display:none}
 .acts .btn{min-height:42px;padding:0 13px;scroll-snap-align:start}
 .card{padding:14px}
 .kpi{padding:13px 14px}
 .da .btn{flex:1 1 auto}
 .da .spacer{display:none}
 .sbar .btn{padding:0 11px}
 .head h1{font-size:26px}
}
@media (max-width:480px){
 .stitle .pill{display:none}
 .rt,.rs{white-space:normal}
 .row{align-items:flex-start;gap:10px;padding:12px 14px}
 .attn .rw{width:100%}
 .attn .rw .btn{flex:1}
 .bar{grid-template-columns:52px minmax(0,1fr) auto}
}
@media (min-width:641px){.zoom-btn{display:none}}

/* ---- Laravel additions ---- */
.err{color:var(--bad);font-size:13.5px}
.flash{margin-top:12px;padding:10px 14px;border-radius:8px;background:var(--ok-soft);border:1px solid var(--line);font-size:14.5px}

/* ---- Auth experience ---- */
.auth-body{padding-bottom:0;background:radial-gradient(900px 520px at 85% 0%,light-dark(rgba(200,55,30,.08),rgba(240,114,88,.08)),transparent 60%),var(--bg)}
.auth{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:28px 18px}
.auth-shell{width:100%;max-width:980px;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.02fr);background:var(--panel);border:1px solid var(--line);border-radius:20px;overflow:hidden;box-shadow:0 24px 60px -24px rgba(22,20,18,.22),0 2px 8px rgba(22,20,18,.06);animation:authIn .38s cubic-bezier(.2,.8,.2,1) both}
@keyframes authIn{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}

.auth-main{padding:44px 44px 38px;display:flex;flex-direction:column;justify-content:center;background:var(--panel)}
.auth-form-wrap{width:100%;max-width:380px;margin:0 auto}
.auth-mobile-brand{display:none;margin-bottom:24px}
.auth-mobile-brand .brand{color:var(--ink)}
.auth-mobile-brand .mark{border-color:var(--ink);background:repeating-linear-gradient(0deg,transparent 0 5px,var(--ink) 5px 6px)}

.auth-head{margin-bottom:24px}
.auth-tag{display:inline-flex;align-items:center;gap:6px;padding:4px 11px;border-radius:999px;background:var(--acc-soft);color:var(--acc);font-size:12.5px;font-weight:700;margin-bottom:12px}
.auth-head h1{font-size:clamp(26px,3vw,31px);font-weight:700;letter-spacing:-.01em;margin:0 0 8px}
.auth-sub{margin:0;color:var(--muted);font-size:15px;line-height:1.6}

.auth-alert{display:flex;align-items:flex-start;gap:10px;padding:12px 14px;border-radius:10px;background:var(--bad-soft);border:1px solid color-mix(in srgb,var(--bad) 26%,transparent);color:var(--bad);font-size:14px;font-weight:500;margin-bottom:18px}
.auth-alert svg{width:19px;height:19px;flex:none;margin-top:2px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}

.auth-form{display:flex;flex-direction:column;gap:16px}
.auth-field{gap:7px}
.auth-field>label{font-size:13.5px;font-weight:600;color:var(--ink)}
.auth-input-wrap{position:relative;display:flex;align-items:center}
.auth-input-wrap input{width:100%;min-height:48px;padding:10px 44px 10px 14px;border-radius:10px;border:1.5px solid var(--line);background:var(--panel);transition:border-color .16s ease,box-shadow .16s ease,background-color .16s ease}
.auth-input-wrap.has-end input{padding-left:46px}
.auth-input-wrap input::placeholder{color:var(--faint);opacity:.78}
.auth-input-wrap input:hover:not(:focus){border-color:color-mix(in srgb,var(--ink) 26%,var(--line))}
.auth-input-wrap input:focus{border-color:var(--acc);box-shadow:0 0 0 3.5px var(--acc-soft)}
.auth-input-wrap input:-webkit-autofill,.auth-input-wrap input:-webkit-autofill:hover,.auth-input-wrap input:-webkit-autofill:focus{-webkit-text-fill-color:var(--ink);-webkit-box-shadow:0 0 0 1000px var(--panel2) inset;caret-color:var(--ink);transition:background-color 9999s ease-out 0s}
.auth-input-wrap.is-invalid input{border-color:var(--bad)}
.auth-input-wrap.is-invalid input:focus{box-shadow:0 0 0 3.5px var(--bad-soft)}
.auth-ic{position:absolute;inset-inline-start:13px;z-index:2;display:flex;align-items:center;justify-content:center;color:var(--faint);pointer-events:none;transition:color .16s ease}
.auth-ic svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.auth-input-wrap:focus-within .auth-ic{color:var(--acc)}
.auth-input-wrap.is-invalid .auth-ic{color:var(--bad)}

.pw-toggle{position:absolute;inset-inline-end:6px;z-index:2;width:36px;height:36px;border:0;border-radius:8px;background:transparent;color:var(--faint);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;transition:color .15s,background-color .15s}
.pw-toggle:hover{color:var(--ink);background:var(--panel2)}
.pw-toggle svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.pw-toggle .ic-hide{display:none}
.pw-toggle[aria-pressed=true] .ic-show{display:none}
.pw-toggle[aria-pressed=true] .ic-hide{display:block}

.auth-meta{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:2px}
.check{display:inline-flex;align-items:center;gap:10px;font-size:14.5px;color:var(--muted);cursor:pointer;user-select:none;line-height:1.4}
.check input{width:18px;height:18px;min-height:0;padding:0;margin:0;flex:none;accent-color:var(--acc);cursor:pointer;border-radius:4px}

.auth-submit{width:100%;min-height:48px;border-radius:10px;font-size:16px;font-weight:600;margin-top:4px;box-shadow:0 8px 20px -10px color-mix(in srgb,var(--acc) 75%,transparent);transition:transform .15s ease,filter .15s ease,box-shadow .15s ease}
.auth-submit:hover:not([disabled]){transform:translateY(-1px);filter:brightness(1.05);box-shadow:0 12px 24px -10px color-mix(in srgb,var(--acc) 85%,transparent)}
.auth-submit:active:not([disabled]){transform:translateY(0)}
.auth-submit svg{width:18px;height:18px;transition:transform .18s ease}
.auth-submit:hover:not([disabled]) svg{transform:translateX(-3px)}
.auth-submit.is-loading{opacity:.75;pointer-events:none}

.auth-divider{display:flex;align-items:center;gap:12px;margin:22px 0 18px;color:var(--faint);font-size:13px}
.auth-divider::before,.auth-divider::after{content:"";flex:1;height:1px;background:var(--line2)}
.auth-foot{margin:0;text-align:center;color:var(--muted);font-size:14.5px}
.auth-foot a{color:var(--acc);font-weight:600;text-decoration:none;margin-inline-start:4px}
.auth-foot a:hover{text-decoration:underline;text-underline-offset:4px}

.auth-aside{position:relative;background:#161412;color:#efebe5;padding:42px 38px;display:flex;flex-direction:column;justify-content:space-between;overflow:hidden;border-inline-start:1px solid var(--line2)}
.auth-aside-bg{position:absolute;inset:0;background:radial-gradient(520px 340px at 15% 12%,rgba(224,73,44,.22),transparent 62%),radial-gradient(420px 320px at 90% 92%,rgba(224,73,44,.12),transparent 65%),repeating-linear-gradient(0deg,transparent 0 31px,rgba(239,235,229,.04) 31px 32px);pointer-events:none}
.auth-aside-in{position:relative;z-index:1;display:flex;flex-direction:column;gap:28px;height:100%}
.auth-aside-brand{color:#efebe5;font-size:19px}
.auth-eyebrow{display:inline-block;font-size:12.5px;font-weight:600;color:#ff8a70;letter-spacing:.02em;margin-bottom:10px}
.auth-hero h2{font-size:27px;line-height:1.32;font-weight:700;color:#fff;margin:0 0 10px}
.auth-hero p{margin:0;color:#b9b1a6;font-size:14.5px;line-height:1.68}

.auth-preview{background:#211e1b;border:1px solid rgba(239,235,229,.12);border-radius:14px;padding:18px;box-shadow:0 18px 34px -18px rgba(0,0,0,.65);display:flex;flex-direction:column;gap:14px}
.auth-pv-top{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;padding-bottom:12px;border-bottom:1px solid rgba(239,235,229,.09)}
.auth-pv-label{display:block;font-size:12px;color:#9b9388;margin-bottom:2px}
.auth-pv-num{font-size:15.5px;font-weight:700;color:#fff}
.auth-pv-stamp{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:600;padding:4px 10px;border-radius:999px;background:rgba(98,204,146,.14);color:#62cc92;border:1px solid rgba(98,204,146,.28)}
.auth-pv-stamp::before{content:"";width:6px;height:6px;border-radius:50%;background:#62cc92}
.auth-pv-rows{display:flex;flex-direction:column;gap:9px}
.auth-pv-row{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:13.5px;color:#d6cfc6}
.auth-pv-row b{font-weight:600;color:#efebe5;white-space:nowrap}
.auth-pv-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-top:12px;border-top:1px dashed rgba(239,235,229,.16);font-size:13.5px;color:#b9b1a6}
.auth-pv-foot strong{font-size:17px;font-weight:700;color:#ff8a70}

.auth-perks{list-style:none;margin:auto 0 0;padding:0;display:flex;flex-direction:column;gap:10px}
.auth-perks li{display:flex;align-items:center;gap:9px;font-size:13.5px;color:#c9c1b6}
.auth-perks svg{width:17px;height:17px;flex:none;fill:none;stroke:#ff8a70;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}

@media (max-width:860px){
 .auth{padding:18px 14px}
 .auth-shell{max-width:460px;grid-template-columns:minmax(0,1fr);border-radius:16px}
 .auth-aside{display:none}
 .auth-mobile-brand{display:block}
 .auth-main{padding:28px 22px 26px}
}
@media (max-width:460px){
 .auth-mobile-brand .brand span:last-child{display:inline}
}

.tab{text-decoration:none}
a.row{text-decoration:none}
.doc-item{display:flex;align-items:center;border-bottom:1px solid var(--line2)}
.doc-item:last-child{border-bottom:0}
.doc-item:hover{background:var(--panel2)}
.doc-item>.row{flex:1;border-bottom:0}
.doc-item>.row:hover{background:none}
.doc-del{margin-inline-end:10px;width:36px;padding:0;border-radius:8px;opacity:.78;transition:opacity .15s,background-color .15s}
.doc-del:hover,.doc-del:focus-visible{opacity:1;background:var(--bad-soft)}
.user-menu{display:flex;align-items:center;gap:6px}
@media (max-width:820px){.user-menu .who{display:none}}
[wire\:loading]{display:none}
.busy{opacity:.6;pointer-events:none}
.native-only{display:none}
.is-native .native-only{display:inline}
.is-native .web-only{display:none}
.is-native .top{padding-top:env(safe-area-inset-top,0px)}
