@font-face { font-family:'Archivo'; font-style:normal; font-weight:100 900; font-display:swap; src:url("fonts/archivo-variable.3084864834b6.ttf") format('truetype'); }
@font-face { font-family:'Anton'; font-style:normal; font-weight:400; font-display:swap; src:url("fonts/anton-regular.da0af4e9427a.ttf") format('truetype'); }
@font-face { font-family:'DM Sans'; font-style:normal; font-weight:400; font-display:swap; src:url("fonts/dm-sans-400.c26dd178864e.ttf") format('truetype'); }
@font-face { font-family:'DM Sans'; font-style:normal; font-weight:500; font-display:swap; src:url("fonts/dm-sans-500.a165d87fb7ee.ttf") format('truetype'); }
@font-face { font-family:'DM Sans'; font-style:normal; font-weight:600; font-display:swap; src:url("fonts/dm-sans-600.e783b4d0a9b7.ttf") format('truetype'); }
@font-face { font-family:'DM Sans'; font-style:normal; font-weight:700; font-display:swap; src:url("fonts/dm-sans-700.411346eea6cd.ttf") format('truetype'); }
@font-face { font-family:'Outfit'; font-style:normal; font-weight:600; font-display:swap; src:url("fonts/outfit-600.5d10e8605771.ttf") format('truetype'); }
@font-face { font-family:'Outfit'; font-style:normal; font-weight:700; font-display:swap; src:url("fonts/outfit-700.4fa2a7180a00.ttf") format('truetype'); }
@font-face { font-family:'Outfit'; font-style:normal; font-weight:800; font-display:swap; src:url("fonts/outfit-800.fbc3a040af83.ttf") format('truetype'); }
:root {
  color-scheme:light;
  --ink:#181113;
  --muted:#75686d;
  --line:#eee0e2;
  --paper:#f7f3f3;
  --surface:#ffffff;
  --raised:#f5edef;
  --brand:#d61f27;
  --link:#a61821;
  --gold:#e8b53a;
  --display:'Archivo',sans-serif;
  font-family:'Archivo',sans-serif;
  color:var(--ink);
  font-size:16px;
  line-height:1.6;
}
* { box-sizing:border-box; }
body { margin:0; background:var(--paper); -webkit-font-smoothing:antialiased; }
a { color:var(--link); text-decoration:none; }
a:hover { color:#ffbbc0; }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
button:disabled { opacity:.6; cursor:wait; }
:focus-visible { outline:3px solid var(--gold); outline-offset:4px; }
h1,h2,h3,p { margin:0 0 16px; }
h1,h2,h3 { font-family:var(--display); font-weight:600; text-wrap:balance; }
h1 { font-size:clamp(30px,2.8vw,42px); line-height:1.15; letter-spacing:-1px; overflow-wrap:anywhere; }
h2 { font-size:24px; line-height:1.25; letter-spacing:-.4px; }
h3 { font-size:21px; line-height:1.3; }
small,.muted { color:var(--muted); }
small { font-size:14px; }
strong { font-weight:700; }
.shell { display:grid; grid-template-columns:260px minmax(0,1fr); min-height:100dvh; }
.side { background:#111013; border-right:1px solid var(--line); padding:20px 14px; position:sticky; top:0; height:100dvh; display:flex; flex-direction:column; }
.brand { display:flex; align-items:center; gap:6px; color:var(--ink); flex-shrink:0; padding:0 8px 20px; }
.brand:hover { color:white; }
.brand-logo { width:64px; height:64px; object-fit:contain; flex:none; }
.brand-name { font-family:var(--display); font-size:31px; font-weight:600; letter-spacing:-.6px; line-height:1.1; }
.brand-title { display:block; color:#dbbf72; background:linear-gradient(120deg,#f7e5b8 0%,#dbbf72 45%,#c8a55a 75%,#9e8240 100%); background-clip:text; -webkit-background-clip:text; -webkit-text-fill-color:transparent; }
.brand-platform { display:block; margin-top:7px; font-size:14px; letter-spacing:2.8px; line-height:1.2; font-weight:500; text-transform:uppercase; color:#d6c3a1; }
@media (forced-colors:active) { .brand-title { background:none; -webkit-text-fill-color:currentColor; } }
.nav { display:flex; flex-direction:column; gap:4px; overflow-y:auto; min-height:0; padding:4px; scrollbar-width:thin; }
.nav a { display:flex; align-items:center; gap:12px; padding:11px 12px; min-height:46px; border-radius:8px; color:var(--muted); font-size:16px; line-height:1.4; }
.nav a:hover { background:var(--raised); color:white; }
.nav a.on { color:#ffadb2; background:#401e26; box-shadow:inset 3px 0 var(--brand); font-weight:600; }
.ico { font-size:20px; width:22px; text-align:center; flex:none; }
.badge { margin-left:auto; background:#b92132; color:white; border-radius:20px; font-size:14px; padding:1px 8px; }
.who { margin-top:auto; border-top:1px solid var(--line); padding:16px 4px 0; display:flex; gap:10px; align-items:center; flex-shrink:0; }
.who>div { min-width:0; }
.who strong { font-size:15px; display:block; overflow-wrap:anywhere; }
.who small { font-size:14px; }
.who form { margin-left:auto; }
.avatar { width:38px; height:38px; flex:none; border:1px solid #79333e; border-radius:50%; background:#401e26; display:grid; place-items:center; color:#ffb1b7; font-weight:700; }
.out { color:var(--muted); border:0; border-radius:8px; background:transparent; font-size:24px; width:44px; height:44px; }
.out:hover { background:var(--raised); color:white; }
.main { padding:0 40px 48px; min-width:0; max-width:1740px; width:100%; margin:0 auto; }
.topbar { display:flex; align-items:center; justify-content:flex-end; gap:16px; min-height:84px; margin-bottom:32px; border-bottom:1px solid var(--line); }
.notification-link { display:flex; align-items:center; gap:10px; color:var(--muted); font-size:14px; min-height:44px; }
.notification-link>span:first-child { color:var(--link); }
.page-heading { display:flex; justify-content:space-between; align-items:center; gap:20px; margin-bottom:28px; }
.page-heading h1 { margin:0; }
.page-heading p { margin:12px 0 0; color:var(--muted); }
.page-heading>div { min-width:0; }
.hero { position:relative; overflow:hidden; border:1px solid #79303b; border-radius:20px; padding:44px 48px; background:linear-gradient(110deg,#291116 0%,#6e1521 55%,#bc2130 100%); margin-bottom:28px; }
.hero h2 { font-family:var(--display); font-size:clamp(44px,4.8vw,72px); font-weight:700; line-height:1.03; letter-spacing:-2px; color:white; margin-bottom:24px; }
.hero p { color:#f3dce0; font-size:18px; line-height:1.65; max-width:640px; margin-bottom:28px; }
.btn { display:inline-flex; align-items:center; justify-content:center; gap:16px; min-height:48px; padding:12px 20px; border:1px solid transparent; border-radius:9px; font-weight:600; font-size:16px; line-height:1.4; text-align:center; transition:background .15s,border-color .15s; }
.primary { background:#c72b39; color:white; border-color:#e24956; }
.primary:hover { background:#d42e3d; color:white; }
.gold-button { background:var(--gold); color:#251d0a; border-color:#f5d98a; }
.gold-button:hover { background:#f8d888; color:#251d0a; }
.gold-button span { font-size:23px; margin-left:16px; }
.ghost { background:var(--raised); border-color:#826977; color:var(--ink); }
.ghost:hover { border-color:#ba6672; background:#30242b; color:white; }
.full { width:100%; }
.pill { display:inline-flex; align-items:center; justify-content:center; padding:5px 11px; border-radius:6px; font-size:14px; line-height:1.4; font-weight:600; color:var(--ink); background:#302b31; border:1px solid #51434e; text-align:center; }
.pill.gold,.pill.final,.pill.review { background:#382d18; color:#f0d48d; border-color:#6a5530; }
.pill.ready,.pill.approved { background:#182e26; color:#a1e2bb; border-color:#335c47; }
.pill.quoted,.pill.supplier { background:#282740; color:#c3c3f7; border-color:#494970; }
.pill.production { background:#3e222a; color:#ffb3ba; border-color:#763640; }
.pill.rejected,.pill.auto_rejected { background:#3b2024; color:#ffadb4; border-color:#7a3641; }
.stats { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; margin-bottom:28px; }
.stats.three { grid-template-columns:repeat(3,minmax(0,1fr)); }
.card { background:var(--surface); border:1px solid var(--line); border-radius:14px; padding:26px; min-width:0; }
.stat { display:flex; flex-direction:column; align-items:flex-start; gap:8px; padding:22px; color:var(--ink); }
a.stat:hover { background:var(--raised); border-color:#7c3b47; color:white; }
.stat>span { color:var(--muted); font-size:15px; }
.stat strong { font-family:var(--display); font-weight:600; font-size:38px; line-height:1.2; letter-spacing:-1px; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; }
.stats.three .stat strong { font-size:clamp(24px,2.3vw,36px); }
.content-grid { display:grid; grid-template-columns:minmax(0,1.8fr) minmax(300px,1fr); gap:24px; align-items:start; }
.section-head { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:20px; flex-wrap:wrap; }
.section-head h2 { margin:0; }
.section-head a { font-size:15px; min-height:44px; display:inline-flex; align-items:center; }
.product-row { display:flex; align-items:center; gap:16px; padding:20px 0; border-top:1px solid var(--line); color:var(--ink); }
.product-row:hover { color:var(--link); }
.product-row>span:nth-child(2) { flex:1; min-width:0; }
.product-row strong { display:block; font-size:16px; overflow-wrap:anywhere; }
.product-row small { display:block; margin-top:4px; }
.product-icon { flex:none; width:46px; height:46px; display:inline-grid; place-items:center; border-radius:11px; background:var(--raised); font-size:23px; }
.rule-card { background:linear-gradient(145deg,#231a1e,#171619); border-color:#50313c; }
.rule-card>p { margin:20px 0; color:var(--muted); }
.rule-card>a { min-height:44px; display:inline-flex; align-items:center; }
.kv { display:flex; justify-content:space-between; align-items:baseline; gap:16px; padding:13px 0; border-bottom:1px solid var(--line); font-size:15px; }
.kv span { color:var(--muted); }
.kv strong { text-align:right; overflow-wrap:anywhere; min-width:0; }
.empty { padding:44px 20px; text-align:center; }
.empty>span { color:var(--link); display:block; font-size:32px; margin-bottom:16px; }
.empty p { color:var(--muted); max-width:500px; margin:0 auto 20px; }
.filters { display:flex; align-items:flex-end; flex-wrap:wrap; gap:16px; margin-bottom:24px; }
.filters label { flex:1; min-width:180px; margin:0; }
label { display:block; color:var(--ink); font-size:16px; font-weight:500; margin-bottom:8px; }
input,select,textarea { width:100%; min-width:0; background:#100f12; color:var(--ink); border:1px solid #806976; border-radius:8px; padding:12px 14px; min-height:48px; margin-top:7px; font-size:16px; line-height:1.5; }
input::placeholder,textarea::placeholder { color:#a79aa2; opacity:1; }
textarea { min-height:130px; resize:vertical; }
input[type=checkbox] { width:20px; min-height:20px; accent-color:var(--brand); }
input[type=file] { padding:10px; overflow:hidden; }
input::file-selector-button { background:var(--raised); color:var(--ink); border:1px solid var(--line); padding:7px 10px; border-radius:5px; margin-right:12px; font:inherit; }
.helptext { display:block; color:var(--muted); font-size:14px; margin-top:7px; }
.helptext ul { padding-left:22px; }
.errorlist { color:#ffabb4; font-size:15px; padding-left:22px; }
.form-layout { display:grid; grid-template-columns:minmax(0,1.7fr) minmax(300px,1fr); gap:24px; align-items:start; }
.form-card { max-width:920px; }
.form-card form>p,.login-form form>p { margin-bottom:24px; }
.intro { color:var(--muted); margin-bottom:28px; }
.form-guide { background:#20171c; border-color:#57323e; }
.form-guide ol { padding-left:24px; }
.form-guide li { padding-left:8px; margin-bottom:24px; }
.form-guide li::marker { color:var(--link); font-family:var(--display); font-weight:600; }
.form-guide p { margin:8px 0 0; color:var(--muted); font-size:15px; }
.actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:28px; }
.password-welcome { position:fixed; inset:0; margin:auto; width:min(560px,calc(100% - 32px)); max-height:calc(100dvh - 32px); overflow:auto; padding:clamp(24px,5vw,40px); background:var(--surface); color:var(--ink); border:1px solid #70404a; border-top:3px solid var(--brand); border-radius:16px; box-shadow:0 24px 90px #0008; }
.password-welcome::backdrop { background:#050407cc; }
.password-welcome h2 { margin-bottom:20px; }
.password-welcome p { margin-bottom:16px; }
.password-welcome .actions form { display:flex; }
.password-welcome .actions form .btn { width:100%; }
.notice { border:1px solid #624b2e; border-left:3px solid var(--gold); background:#292219; color:#e8d5af; padding:18px 22px; border-radius:8px; margin-bottom:24px; overflow-wrap:anywhere; }
.notice.error { background:#321c22; border-color:#974350; color:#ffc1c7; }
.notice.success { background:#1a2b23; border-color:#456e54; color:#bce4c9; }
.table-card { padding:0; overflow:hidden; }
.table-scroll { overflow-x:auto; }
table { width:100%; border-collapse:collapse; font-size:15px; text-align:left; }
th { background:#201d21; color:var(--muted); font-size:14px; font-weight:500; padding:18px 20px; white-space:nowrap; }
td { border-top:1px solid var(--line); padding:20px; vertical-align:middle; }
td .btn { padding:10px 14px; }
.product-title { display:flex; align-items:center; gap:14px; color:var(--ink); min-width:170px; }
.product-title strong { display:block; }
.product-title small { display:block; margin-top:4px; }
.table-link { display:inline-flex; align-items:center; min-height:44px; white-space:nowrap; }
.pagination { display:flex; align-items:center; justify-content:center; gap:20px; margin-top:24px; flex-wrap:wrap; }
.pagination a { padding:10px; }
.back { display:inline-flex; min-height:44px; align-items:center; margin-bottom:12px; }
.detail-grid { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(320px,1fr); gap:24px; align-items:start; }
.stack { display:flex; flex-direction:column; gap:24px; min-width:0; }
.evidence-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-top:24px; }
.evidence-grid img { width:100%; height:140px; object-fit:contain; border-radius:8px; background:#242126; }
.evidence-grid span { display:block; margin-top:7px; font-size:14px; }
.metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:22px 0; }
.metrics>div { background:var(--raised); border-radius:8px; padding:16px; min-width:0; }
.metrics span { display:block; color:var(--muted); font-size:14px; margin-bottom:8px; }
.metrics strong { font-family:var(--display); font-weight:600; display:block; font-size:24px; line-height:1.3; overflow-wrap:anywhere; font-variant-numeric:tabular-nums; }
.quote-price { border-color:#81404b; background:linear-gradient(130deg,#371b23,#20161b); }
.price-label { color:#e9bbc3; font-size:16px; }
.quote-price h2 { font-size:34px; }
.quote-price h2 small { font-family:'Archivo',sans-serif; font-weight:400; font-size:15px; }
.timeline { list-style:none; padding:0 0 0 18px; margin:24px 0 0; border-left:1px solid #69414d; }
.timeline li { position:relative; padding:0 0 24px 5px; }
.timeline li::before { position:absolute; content:''; left:-24px; top:8px; width:9px; height:9px; border-radius:50%; background:#ee7b89; }
.timeline li:last-child { padding-bottom:0; }
.timeline strong { font-weight:500; font-size:15px; display:block; }
.timeline small { display:block; margin-top:6px; }
.logistics { margin:0; }
.logistics dt { color:var(--muted); font-size:14px; }
.logistics dd { margin:2px 0 16px; overflow-wrap:anywhere; }
.chat-body { max-height:440px; overflow-y:auto; padding:10px 0; }
.bubble { padding:16px; margin:0 32px 14px 0; background:#262129; border:1px solid #453a49; border-radius:12px 12px 12px 2px; overflow-wrap:anywhere; }
.bubble.mine { background:#371e29; border-color:#663441; margin:0 0 14px 32px; border-radius:12px 12px 2px 12px; }
.bubble strong { color:#d5c2d1; font-size:14px; }
.bubble p { margin:8px 0; }
.bubble time { font-size:14px; color:var(--muted); }
.chat-note { font-size:14px; color:var(--muted); margin:16px 0; }
.chat-input { display:flex; align-items:stretch; gap:10px; }
.chat-input input { margin:0; }
.chat-input .btn { flex:none; }
.empty-chat { color:var(--muted); padding:20px 0; }
.stages { list-style:none; padding:0; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-bottom:0; }
.stages li { color:var(--muted); background:var(--raised); padding:12px; border-radius:7px; font-size:14px; }
.stages li::before { content:'○ '; }
.stages li.done { color:#bce4c9; background:#1b3027; }
.stages li.done::before { content:'✓ '; }
progress { width:100%; height:8px; accent-color:var(--brand); border:0; border-radius:6px; background:var(--raised); margin:20px 0; overflow:hidden; }
progress::-webkit-progress-bar { background:var(--raised); }
progress::-webkit-progress-value { background:var(--brand); border-radius:6px; }
progress::-moz-progress-bar { background:var(--brand); }
.catalog-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; margin-bottom:24px; }
.format { position:relative; }
.format-emoji { display:block; font-size:42px; margin-bottom:24px; }
.format>.pill { position:absolute; right:20px; top:28px; }
.format p { color:var(--muted); }
.disabled-format { background:#141316; border-style:dashed; }
.profile-heading { display:flex; gap:20px; align-items:center; margin-bottom:32px; }
.profile-heading h2 { margin-bottom:6px; }
.profile-heading p { margin-bottom:12px; color:var(--muted); overflow-wrap:anywhere; }
.profile-avatar { width:72px; height:72px; flex:none; background:#43232c; border:1px solid #80404f; color:#ffb4be; border-radius:50%; display:grid; place-items:center; font-size:32px; font-family:var(--display); }
details { border-bottom:1px solid var(--line); padding:16px 0; }
details:last-child { border-bottom:0; }
summary { cursor:pointer; font-weight:600; padding:10px 0; min-height:44px; }
details p { margin:12px 0; color:var(--muted); }
.compact { padding:32px; }
.compact h2 { font-size:clamp(32px,4vw,52px); overflow-wrap:anywhere; }
.compact p { margin-bottom:0; }
.login-wrap { min-height:100dvh; display:grid; grid-template-columns:minmax(0,1.05fr) minmax(0,1fr); }
.login-brand { padding:40px 56px; display:flex; flex-direction:column; background:linear-gradient(150deg,#171013,#5b1521 65%,#ad1f2f); }
.login-brand .brand { align-self:flex-start; padding:0; }
.login-hero { margin:auto 0; padding:60px 0; }
.login-hero h1 { font-size:clamp(48px,5.5vw,84px); line-height:1.05; letter-spacing:-2px; max-width:600px; font-weight:700; }
.login-hero h1 em { font-style:normal; color:#f2c5cb; }
.login-hero p { max-width:470px; font-size:20px; color:#ead4da; }
.login-feats p { font-size:15px; color:#ead4da; margin-bottom:12px; }
.login-form { align-self:center; padding:56px; width:100%; max-width:560px; justify-self:center; }
.login-form h2 { font-size:36px; }
.login-form>p { color:var(--muted); }
.login-form form { margin-top:32px; }
.login-foot { margin:28px 0 0; font-size:14px; line-height:1.8; }
.mobile-toggle { display:none; }
.skip { position:fixed; left:16px; top:-100px; background:var(--gold); color:#171013; padding:12px; z-index:100; border-radius:6px; }
.skip:focus { top:16px; }
.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; }
.card form+form { margin-top:16px; }
@media (max-width:1350px) {
  .main { padding-left:28px; padding-right:28px; }
  .content-grid,.detail-grid,.form-layout { grid-template-columns:minmax(0,1.4fr) minmax(290px,1fr); }
  .card { padding:22px; }
  .table-card { padding:0; }
  .metrics { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .product-row { flex-wrap:wrap; gap:12px; }
  .product-row>.pill { margin-left:58px; }
  .product-row>.pill+span { margin-left:auto; }
  .stat { padding:18px; }
}
@media (max-width:1100px) {
  .shell { grid-template-columns:232px minmax(0,1fr); }
  .main { padding-left:24px; padding-right:24px; }
  .content-grid,.detail-grid,.form-layout { grid-template-columns:minmax(0,1fr); }
  .hero { padding:36px; }
  .stats { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .catalog-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .metrics { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .login-brand { padding:32px; }
  .login-form { padding:36px; }
}
@media (max-width:900px) {
  .shell { display:block; }
  .side { position:relative; height:auto; padding:10px 20px; border-right:0; border-bottom:1px solid var(--line); display:grid; grid-template-columns:1fr auto; align-items:center; }
  .brand { padding:0; }
  .brand-logo { width:56px; height:56px; }
  .brand-name { font-size:28px; }
  .mobile-toggle { display:block; background:var(--raised); color:var(--ink); border:1px solid #826977; padding:10px 16px; min-height:46px; border-radius:8px; font-size:16px; }
  .nav { display:none; grid-column:1/-1; overflow:visible; padding:16px 0; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; }
  .nav.expanded { display:grid; }
  .who { display:none; grid-column:1/-1; margin:0 0 10px; }
  .nav.expanded+.who { display:flex; }
  .main { padding:0 24px 32px; }
  .topbar { min-height:68px; margin-bottom:28px; }
  .stats { grid-template-columns:repeat(4,minmax(0,1fr)); }
  .hero h2 { font-size:60px; }
  .login-wrap { grid-template-columns:1fr; }
  .login-brand { padding:20px 28px 32px; }
  .login-hero { padding:32px 0 0; }
  .login-hero h1 { font-size:46px; max-width:600px; }
  .login-hero h1 br { display:none; }
  .login-hero p { font-size:17px; margin-bottom:0; }
  .login-feats { display:none; }
  .login-form { max-width:600px; padding:36px 28px; }
}
@media (max-width:650px) {
  .side { padding:8px 16px; }
  .main { padding:0 16px 32px; }
  .topbar { min-height:64px; margin-bottom:24px; gap:10px; }
  .notification-link { font-size:14px; }
  .page-heading { align-items:flex-start; flex-direction:column; gap:16px; margin-bottom:24px; }
  .page-heading>.btn,.page-heading>form,.page-heading>form>.btn { width:100%; }
  h1 { font-size:32px; }
  h2 { font-size:23px; }
  .hero { padding:30px 24px; border-radius:14px; margin-bottom:20px; }
  .hero h2 { font-size:46px; letter-spacing:-1.5px; margin-bottom:20px; }
  .hero p { font-size:17px; margin-bottom:24px; }
  .hero p br { display:none; }
  .hero .btn { width:100%; justify-content:space-between; padding:14px 18px; }
  .stats,.stats.three { grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-bottom:24px; }
  .stats.three>.stat:last-child { grid-column:1/-1; }
  .stat { padding:18px 16px; }
  .stat strong { font-size:34px; }
  .stat small { line-height:1.5; }
  .stat>span { font-size:14px; }
  .card { padding:22px 20px; }
  .table-card { padding:0; }
  .section-head { gap:8px; margin-bottom:12px; }
  .product-row { gap:12px; }
  .product-row>span:nth-child(2) { min-width:calc(100% - 62px); }
  .product-row>.pill { margin-left:58px; }
  .product-row>strong { margin-left:58px; }
  .content-grid,.detail-grid,.form-layout,.stack { gap:20px; }
  .filters { gap:12px; }
  .filters label { min-width:100%; }
  .filters .btn { width:100%; }
  .table-scroll { overflow:visible; }
  .responsive-table,.responsive-table tbody { display:block; width:100%; }
  .responsive-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); }
  .responsive-table tr { display:block; padding:20px; border-bottom:1px solid var(--line); }
  .responsive-table tr:last-child { border-bottom:0; }
  .responsive-table td { display:flex; justify-content:space-between; align-items:center; gap:18px; padding:9px 0; border:0; overflow-wrap:anywhere; }
  .responsive-table td:first-child { padding:0 0 18px; }
  .responsive-table td[data-label]::before { content:attr(data-label); color:var(--muted); font-size:14px; flex:none; }
  .responsive-table td:last-child { padding:14px 0 0; }
  .responsive-table .table-link { width:100%; justify-content:center; border:1px solid #826977; border-radius:8px; background:var(--raised); }
  .responsive-table .empty { width:100%; }
  .product-title { min-width:0; }
  .people-table td { flex-wrap:wrap; }
  .metrics { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .metrics>div { padding:14px; }
  .metrics strong { font-size:23px; }
  .evidence-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .evidence-grid img { height:130px; }
  .kv { font-size:15px; gap:12px; }
  .kv strong { max-width:58%; }
  .catalog-grid { grid-template-columns:minmax(0,1fr); gap:16px; }
  .chat-input { flex-wrap:wrap; }
  .chat-input .btn { width:100%; }
  .bubble { margin-right:16px; }
  .bubble.mine { margin-left:16px; }
  .profile-heading { gap:14px; align-items:flex-start; }
  .profile-avatar { width:52px; height:52px; font-size:26px; }
  .profile-heading>div { min-width:0; }
  .actions { flex-direction:column; }
  .notice { padding:16px; }
  .compact h2 { font-size:34px; }
  .nav { grid-template-columns:minmax(0,1fr); max-height:60dvh; overflow-y:auto; }
  .nav a { font-size:16px; padding:12px; gap:12px; }
  .login-brand { padding:16px 24px 28px; }
  .login-hero h1 { font-size:40px; }
  .login-form { padding:32px 24px; }
  .login-form h2 { font-size:30px; }
}
@media (prefers-reduced-motion:reduce) { *,*::before,*::after { scroll-behavior:auto!important; transition:none!important; } }

/* Product sections retain the quote and available actions alongside the active panel. */
.product-tabs { display:flex; flex-wrap:wrap; gap:8px; padding:6px; margin-bottom:24px; background:var(--surface); border:1px solid var(--line); border-radius:12px; }
.product-tabs a { display:flex; align-items:center; justify-content:center; min-height:48px; padding:10px 22px; border-radius:7px; color:var(--muted); font-size:16px; font-weight:500; }
.product-tabs a:hover { background:var(--raised); color:var(--ink); }
.product-tabs a[aria-selected=true] { color:#ffb3ba; background:#401e26; box-shadow:inset 0 -2px var(--brand); }
.product-content { min-width:0; }
.product-panel { scroll-margin-top:100px; }
.product-panel[hidden] { display:none; }
.product-workspace:not(.tabs-ready) .product-panel { margin-bottom:24px; }
.product-section-select { display:none; margin:0 0 20px; }
@media (max-width:650px) {
  .tabs-ready .product-tabs { display:none; }
  .tabs-ready .product-section-select { display:block; min-height:52px; background:var(--surface); border-color:#826977; color:var(--ink); font-weight:600; }
}

.text-button { border:0; background:transparent; color:var(--link); min-height:44px; padding:8px 0; font-size:15px; }
.text-button:hover { color:#ffbbc0; }

.password-field { display:block; position:relative; margin-top:7px; }
.password-field input { margin-top:0; padding-right:100px; }
.password-toggle { position:absolute; top:3px; right:3px; bottom:3px; min-height:44px; min-width:90px; padding:6px 10px; background:transparent; border:0; border-radius:6px; color:var(--link); font-size:16px; font-weight:600; }
.password-toggle:hover { background:var(--raised); color:#ffbbc0; }

/* Error pages deliberately render without the authenticated application shell. */
.error-layout { min-height:100dvh; display:flex; flex-direction:column; }
.error-header { width:min(1120px,100%); margin:0 auto; padding:28px 32px; border-bottom:1px solid var(--line); }
.error-header .brand { width:fit-content; padding:0; }
.error-main { flex:1; display:grid; place-items:center; padding:48px 24px 72px; }
.error-card { width:min(680px,100%); padding:clamp(28px,5vw,56px); background:var(--surface); border:1px solid var(--line); border-top:3px solid var(--brand); border-radius:16px; }
.error-code { font-family:var(--display); font-size:clamp(56px,8vw,88px); font-weight:700; line-height:1; letter-spacing:-3px; color:var(--link); margin-bottom:28px; }
.error-card h1 { font-size:clamp(28px,4vw,40px); margin-bottom:20px; }
.error-description { font-size:18px; color:var(--muted); line-height:1.7; }
.error-guidance { color:var(--muted); margin-top:20px; }
.error-reference { margin:32px 0 0; padding-top:24px; border-top:1px solid var(--line); color:var(--muted); font-size:14px; overflow-wrap:anywhere; }
.error-reference strong { color:var(--ink); white-space:nowrap; }
@media(max-width:650px) {
  .error-header { padding:20px; }
  .error-main { padding:28px 16px; }
  .error-card .actions a { width:100%; text-align:center; justify-content:center; }
}

/* Personal identity shares the platform's red actions and restrained gold accents. */
.who { flex-wrap:wrap; }
.who>div:not(.account-controls) { flex:1 140px; }
.who .account-controls { display:flex; align-items:center; gap:4px; margin-left:auto; flex:none; }
.who .account-controls form { margin:0; }
.account-controls .out { display:grid; place-items:center; width:44px; height:44px; padding:8px; border-radius:8px; }
.settings-link.on { color:var(--gold); background:var(--raised); }
.avatar { overflow:hidden; }
.avatar img { width:100%; height:100%; object-fit:cover; }
.avatar.avatar-large { width:80px; height:80px; font-size:32px; }
.person-preview { display:inline-flex; gap:10px; align-items:center; vertical-align:middle; max-width:100%; }
.person-preview .avatar { width:30px; height:30px; font-size:14px; }
.person-preview>span:last-child { min-width:0; overflow-wrap:break-word; word-break:normal; }
.settings-layout { max-width:820px; }
.settings-tabs { display:flex; gap:8px; border-bottom:1px solid var(--line); margin-bottom:28px; }
.settings-tabs a { min-height:52px; padding:12px 20px; color:var(--muted); border-bottom:3px solid transparent; }
.settings-tabs a:hover { color:var(--ink); }
.settings-tabs a[aria-selected=true] { color:var(--link); border-bottom-color:var(--brand); }
.settings-panel { margin-bottom:24px; padding:32px; scroll-margin-top:24px; }
.settings-panel[hidden] { display:none; }
.settings-panel h2 { font-size:26px; }
.identity-preview { display:flex; gap:20px; align-items:center; padding:24px 0; margin-bottom:12px; }
.identity-preview>div { min-width:0; }
.identity-preview strong { display:block; font-family:var(--display); font-size:26px; overflow-wrap:anywhere; }
.identity-preview small { display:block; color:var(--muted); margin-top:4px; }
.locked-name { display:flex; gap:14px; border-top:1px solid var(--line); padding:24px 0; margin-top:24px; }
.locked-name>span { color:var(--gold); }
.locked-name p { margin:6px 0; overflow-wrap:anywhere; }
.locked-name small { color:var(--muted); }
.confirm-dialog, .password-welcome { margin:auto; inset:0; width:min(520px,calc(100% - 32px)); max-height:calc(100dvh - 32px); overflow:auto; padding:32px; background:var(--surface); color:var(--ink); border:1px solid var(--line); border-top:3px solid var(--brand); border-radius:16px; box-shadow:0 16px 60px #0005; }
.confirm-dialog::backdrop, .password-welcome::backdrop { background:#09090bbd; backdrop-filter:blur(5px); }
.confirm-dialog h2 { font-size:28px; }
.confirm-dialog p { color:var(--muted); line-height:1.7; }
.confirm-dialog .actions { justify-content:flex-end; }
.dialog-mark { color:var(--gold); font-size:32px; margin-bottom:12px; }
.waiting-overlay { position:fixed; inset:0; z-index:1000; display:grid; place-items:center; padding:24px; background:#09090bbd; backdrop-filter:blur(5px); }
.waiting-overlay[hidden] { display:none; }
.waiting-card { max-width:380px; width:100%; padding:32px; text-align:center; background:var(--surface); border:1px solid var(--line); border-radius:16px; }
.waiting-card p { margin:20px 0 8px; font-size:18px; }
.waiting-card small { color:var(--muted); }
.emaster-orbit { width:72px; height:72px; position:relative; margin:0 auto; display:grid; place-items:center; border:1px solid var(--line); border-radius:50%; }
.emaster-orbit span { color:var(--gold); font-size:32px; animation:emaster-glow 1.8s ease-in-out infinite; }
.emaster-orbit i { position:absolute; inset:-1px; border:2px solid transparent; border-top-color:var(--brand); border-radius:50%; animation:emaster-orbit 1.8s linear infinite; }
.emaster-orbit i:nth-of-type(2) { inset:7px; border-top-color:var(--gold); animation-direction:reverse; animation-duration:2.4s; }
.emaster-orbit i:nth-of-type(3) { display:none; }
@keyframes emaster-orbit { to { transform:rotate(360deg); } }
@keyframes emaster-glow { 50% { opacity:.45; transform:scale(.85); } }
@media(max-width:650px) {
  .settings-tabs { gap:0; }
  .settings-tabs a { flex:1; padding:12px 8px; text-align:center; font-size:16px; }
  .settings-panel { padding:24px 20px; }
  .identity-preview { gap:16px; }
  .identity-preview strong { font-size:24px; }
  .confirm-dialog, .password-welcome { padding:24px; }
  .confirm-dialog .actions { display:grid; grid-template-columns:1fr 1fr; }
  .confirm-dialog .actions button { padding:12px 8px; }
}
@media(prefers-reduced-motion:reduce) { .emaster-orbit *, .emaster-orbit { animation:none!important; } }
.check-row { display:flex; gap:12px; align-items:center; min-height:44px; cursor:pointer; }
.check-row input[type=checkbox] { margin:0; width:20px; height:20px; flex:none; }
.chat-history-nav { display:flex; flex-wrap:wrap; gap:16px; justify-content:space-between; }
.chat-sync { font-size:14px; min-height:24px; margin:8px 0 16px; }
.chat [hidden] { display:none!important; }
.bubble { overflow-wrap:anywhere; }

/* Approved EMASTER mockup: charcoal navigation, warm paper, red and gold. */
:root { --brand-contrast:#fff; --gold-contrast:#181113; --dark:#120e11; --green:#087d39; --amber:#985b00; }
[hidden] { display:none!important; }
h1,h2,h3 { font-weight:800; }
h1 { font-size:clamp(28px,2.6vw,40px); letter-spacing:-.8px; }
h2 { font-size:22px; }
a:hover { color:var(--brand); }
button:disabled { opacity:.65; }
.shell { grid-template-columns:260px minmax(0,1fr); }
.side { background:var(--dark); border-color:#241c20; padding:24px 12px 16px; color:#fff; }
.side .brand { padding:0 10px 22px; gap:12px; }
.brand-logo { width:42px; height:58px; }
.brand-name { max-width:170px; overflow-wrap:anywhere; }
.brand-title { font-family:'Anton',sans-serif; text-transform:uppercase; font-size:24px; letter-spacing:.5px; line-height:1.15; font-weight:400; background:none; color:#fff; -webkit-text-fill-color:currentColor; }
.brand-platform { font-family:'Archivo',sans-serif; font-size:10px; color:var(--gold); letter-spacing:3px; font-weight:700; margin-top:6px; }
.nav { padding:0; gap:3px; }
.nav-label { color:#9e9097; font-size:11px; font-weight:700; letter-spacing:1.3px; padding:18px 12px 8px; }
.nav a { color:#d0c4ca; border-radius:11px; padding:11px 13px; gap:12px; min-height:48px; font-size:15px; }
.nav a.on { color:#ff727c; background:#39161c; box-shadow:none; }
.nav a:hover { background:#241c20; color:#fff; }
.ico { font-size:21px; width:25px; }
.badge { background:var(--brand); color:var(--brand-contrast); font-size:12px; }
.who { border-color:#30252c; color:#fff; }
.who small { color:#c0b3ba; }
.who .out { color:#c0b3ba; }
.who .out:hover { background:#30252c; color:#fff; }
.who .settings-link.on { background:#39161c; color:#ff727c; }
.avatar,.profile-avatar { background:var(--brand); color:var(--brand-contrast); border:0; }
.main { max-width:1900px; padding:0 36px 48px; }
.topbar { min-height:65px; margin:0 0 4px; border:0; justify-content:space-between; }
.role-eyebrow { font-size:14px; color:var(--muted); }
.header-actions { display:flex; align-items:center; gap:12px; }
.global-search { display:flex; align-items:center; gap:8px; padding:0 14px; background:#fff; border:1px solid var(--line); border-radius:12px; }
.global-search input { margin:0; padding:10px 0; width:220px; border:0; background:transparent; }
.notification-link { position:relative; display:grid; place-items:center; width:48px; height:48px; border:1px solid var(--line); border-radius:12px; background:#fff; }
.notification-link>span:first-child { font-size:24px; }
.notification-link .badge { position:absolute; right:-5px; top:-5px; }
.page-heading { margin-bottom:28px; min-height:44px; }
.page-heading p { font-size:16px; }
.hero { border:1px solid #49252c; background:linear-gradient(110deg,#110c0e 0%,#3b0d12 57%,#9f1620 100%); border-radius:22px; }
.home-hero { display:flex; gap:24px; align-items:center; padding:32px; min-height:172px; margin-bottom:24px; }
.home-hero::after { content:''; position:absolute; right:34px; bottom:26px; width:40px; height:40px; transform:rotate(45deg); background:#e8b53a20; pointer-events:none; }
.hero-copy { flex:1; min-width:0; z-index:1; }
.hero-icon { font-size:38px; z-index:1; }
.hero .eyebrow { color:#f8dd7f; font-size:12px; letter-spacing:2px; font-weight:800; display:block; margin-bottom:14px; }
.hero h2,.mini-hero h3 { font-family:'Anton',sans-serif; text-transform:uppercase; font-size:clamp(29px,2.6vw,44px); font-weight:400; letter-spacing:.3px; line-height:1.15; margin-bottom:10px; }
.home-hero p { font-size:16px; line-height:1.5; margin:0; max-width:660px; color:#e1d0d3; }
.home-hero .gold-button { flex-shrink:0; z-index:1; max-width:260px; }
.hero-photo { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:.2; }
.btn { border-radius:10px; font-weight:700; }
.primary { background:var(--brand); border-color:var(--brand); color:var(--brand-contrast); }
.primary:hover { background:var(--brand); filter:brightness(.92); color:var(--brand-contrast); }
.gold-button { background:var(--gold); border-color:var(--gold); color:var(--gold-contrast); }
.gold-button:hover { background:var(--gold); color:var(--gold-contrast); }
.ghost { background:#fff; border-color:#decbd1; color:#493a40; }
.ghost:hover { background:#fdf6f7; border-color:var(--brand); color:#181113; }
.card { border-radius:17px; padding:24px; }
.stat { gap:12px; }
.stat>span { display:flex; align-items:center; gap:12px; font-size:14px; font-weight:600; }
.stat strong { font-size:36px; font-weight:800; letter-spacing:-.6px; }
.stat small { color:var(--green); font-size:14px; font-weight:600; }
.stat small.amber-text { color:var(--amber); }
a.stat:hover { background:#fff; color:var(--ink); border-color:#dfb8bf; }
.stat-icon { display:inline-grid; place-items:center; width:36px; height:36px; border-radius:10px; font-size:23px; font-style:normal; }
.blue { background:#e7effe; }.red { background:#fdeaeb; }.amber { background:#fdf2dc; }.green { background:#e5f6ec; }
.content-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.rule-card { background:#fff; border-color:var(--line); }
.rule-card>p { margin:8px 0 20px; }
.rule-card>a { display:flex; justify-content:center; border:1px solid var(--line); border-radius:9px; color:#493a40; font-weight:700; }
.section-head a { padding:0 14px; border:1px solid var(--line); border-radius:9px; color:#493a40; font-weight:700; }
.product-row { padding:18px 0; gap:14px; }
.product-row>.pill { margin-left:0; }
.product-icon { border-radius:13px; background:#fdeaeb; }
.pill { border:0; border-radius:100px; background:#f0ebef; color:#54474d; font-size:12px; padding:7px 10px; }
.pill.gold,.pill.final,.pill.review,.pill.supplier { background:#fdf2dc; color:#925900; }
.pill.ready,.pill.approved,.pill.quoted { background:#e5f6ec; color:#087d39; }
.pill.production { background:#fdeaeb; color:#b31929; }
.pill.rejected { background:#e7effe; color:#1c53ba; }
.pill.auto_rejected { background:#fbe6e8; color:#a81929; }
input,select,textarea { background:#fff; border-color:#decbd1; color:var(--ink); border-radius:10px; }
input::placeholder,textarea::placeholder { color:#81727a; }
input:focus,textarea:focus,select:focus { border-color:var(--brand); }
:focus-visible { outline:3px solid #9a6720; }
.errorlist { color:#af1024; }
.form-guide { background:#fff; border-color:var(--line); }
.notice { background:#fdf2dc; border-color:#efd8a3; color:#714409; }
.notice.error { background:#fbe6e8; border-color:#edb1bb; color:#9c1428; }
.notice.success { background:#e5f6ec; border-color:#b5e0c5; color:#136939; }
.table-card { padding:0; }
th { background:#fcf8f9; font-weight:600; color:#71636a; }
.quote-price { background:#fff; border-color:#e6c1c8; }
.price-label { color:var(--muted); }
.evidence-grid img { background:#f4edef; }
.bubble { background:#f7f3f3; border-color:#eee0e2; }
.bubble.mine { background:#fdeaeb; border-color:#f1cdd2; }
.bubble strong { color:#55434c; }
.stages li.done { background:#e5f6ec; color:#087d39; }
.stages li { background:#f8f3f5; }
progress { height:14px; }
progress::-webkit-progress-value { background:linear-gradient(90deg,#f0353d,var(--brand)); }
.timeline { border-color:#eee0e2; }
.timeline li::before { background:var(--brand); width:12px; height:12px; left:-25px; }
.catalog-grid { grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; }
.format { background:linear-gradient(#fff,#f3fbf7); border-color:#c3e8d2; }
.format h2 { font-size:19px; }
.format p { font-size:15px; margin:0; }
.disabled-format { background:linear-gradient(#fff,#fdf5f6); border-color:#f0cbd2; border-style:solid; }
.format-check { position:absolute; right:20px; top:24px; font-size:21px; }
.catalog-label { font-size:21px; margin-top:28px; }
.allowed { color:#087d39; }.unavailable { color:#b51c2a; }
.faq details { background:#fff; border:1px solid var(--line); border-radius:16px; margin-bottom:14px; padding:10px 22px; }
.faq details[open] { border-color:var(--brand); }
.faq summary { list-style:none; display:flex; justify-content:space-between; gap:16px; font-size:17px; }
.faq summary::-webkit-details-marker { display:none; }
.faq summary::after { content:'+'; color:var(--brand); font-size:24px; line-height:1; }
.faq details[open] summary::after { content:'−'; }
.faq details p { color:#51454a; line-height:1.7; }
.notification-list { display:grid; gap:14px; }
.notification-item { display:flex; gap:20px; align-items:center; color:var(--ink); }
.notification-item.unread { border-left:3px solid var(--brand); background:#fffbfc; }
.notification-item>div { flex:1; min-width:0; }
.notification-item strong { font-size:17px; }
.notification-item p { color:var(--muted); margin:4px 0 0; }
.notification-item time { font-size:13px; color:var(--muted); white-space:nowrap; }
.login-wrap { background:white; }
.login-brand { background:linear-gradient(158deg,#0c0405 0%,#1a0709 32%,#9e0f18 74%,#e01f28 100%); color:#fff; }
.login-hero h1 { font-family:'Anton',sans-serif; text-transform:uppercase; font-weight:400; letter-spacing:.5px; font-size:clamp(42px,4.8vw,68px); }
.login-form h2 { font-size:30px; }
.login-form .brand-title { color:var(--ink); }
.preview-banner { display:flex; flex-wrap:wrap; gap:12px; align-items:center; }
.preview-banner span { flex:1; }
.publish-bar { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:20px; margin-bottom:24px; }
.publish-bar small { display:block; margin-top:5px; }
.publish-bar .actions { margin:0; align-items:center; }
.editor-layout { display:grid; grid-template-columns:minmax(0,1fr) 300px; gap:24px; align-items:start; }
.editor-layout>div { min-width:0; }
.editor-preview { position:sticky; top:24px; }
.editor-preview .eyebrow { font-size:11px; color:var(--muted); letter-spacing:1.4px; }
.editor-preview h2 { margin-top:12px; }
.editor-preview p { font-size:14px; }
.mini-hero { border-radius:12px; background:linear-gradient(120deg,#120e11,#8f0f16); color:white; padding:22px; overflow-wrap:anywhere; }
.mini-hero small { color:#f8dd7f; font-size:10px; letter-spacing:1px; }
.mini-hero h3 { font-size:26px; margin:12px 0; }
.mini-hero p { color:#ecdde2; }
.mini-hero .btn { font-size:13px; padding:10px; }
.preview-tip { margin-top:18px; }
.editor-tabs { display:flex; flex-wrap:wrap; gap:6px; margin-bottom:16px; }
.editor-tabs a { padding:12px 16px; background:#fff; border:1px solid var(--line); border-radius:10px; color:#51434a; font-size:14px; font-weight:600; }
.editor-tabs a[aria-selected=true] { background:var(--brand); color:var(--brand-contrast); border-color:var(--brand); }
.editor-panel { margin-bottom:20px; }
.editor-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.editor-fields label { font-size:14px; }
.editor-fields input[type=color] { padding:5px; cursor:pointer; }
.editor-logo-preview { max-width:120px; max-height:100px; object-fit:contain; display:block; margin-top:12px; background:#20181d; border-radius:8px; }
.editor-banner-preview { width:100%; max-height:120px; object-fit:contain; display:block; margin-top:12px; }
.editor-save { display:flex; gap:16px; align-items:center; flex-wrap:wrap; padding:16px 0; }
.editor-save span { font-size:14px; }
.faq-edit-row { border:1px solid var(--line); border-radius:12px; padding:20px; margin:20px 0; min-width:0; }
.faq-edit-row legend { font-weight:700; }
.faq-edit-row label { font-size:14px; }
.editor-form hr { border:0; border-top:1px solid var(--line); margin:28px 0; }
.production-list { display:grid; gap:24px; }
.production-card .product-row { border:0; padding-top:0; }
.production-card .stages { grid-template-columns:repeat(6,minmax(0,1fr)); }
.production-card .stages li { font-size:12px; text-align:center; padding:12px 8px; }
.production-card .section-head { margin-bottom:12px; }
.inventory-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; }
.inventory-grid .product-row { align-items:flex-start; border:0; padding-top:0; }
@media(max-width:1350px) {
  .main { padding-left:28px; padding-right:28px; }
  .home-hero { gap:16px; padding:28px; }
  .hero-icon { display:none; }
  .home-hero .gold-button { max-width:220px; }
  .catalog-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .editor-layout { grid-template-columns:minmax(0,1fr); }
  .editor-preview { position:static; }
  .editor-preview .card { display:none; }
}
@media(max-width:1100px) {
  .shell { grid-template-columns:232px minmax(0,1fr); }
  .content-grid { grid-template-columns:minmax(0,1fr); }
  .inventory-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .home-hero { flex-wrap:wrap; }
  .home-hero .hero-copy { flex-basis:100%; }
  .catalog-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:900px) {
  .shell { display:block; }
  .side { padding:12px 20px; }
  .side .brand { padding:0; }
  .brand-logo { width:36px; height:46px; }
  .brand-title { font-size:23px; }
  .brand-platform { font-size:9px; }
  .mobile-toggle { color:white; background:#241c20; border-color:#49333e; }
  .main { padding:0 24px 36px; }
  .topbar { margin-bottom:12px; }
  .production-card .stages { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media(max-width:650px) {
  .main { padding:0 16px 32px; }
  .topbar { gap:8px; min-height:70px; }
  .role-eyebrow { font-size:12px; max-width:95px; }
  .header-actions { gap:8px; min-width:0; }
  .global-search { padding:0 9px; }
  .global-search input { width:110px; font-size:16px; }
  .global-search>span { display:none; }
  .notification-link { width:44px; height:44px; }
  .page-heading { flex-wrap:wrap; gap:14px; margin-bottom:22px; }
  .page-heading p { font-size:15px; }
  .home-hero { padding:26px 22px; min-height:0; }
  .home-hero h2 { font-size:31px; }
  .home-hero p { font-size:16px; }
  .hero .eyebrow { font-size:10px; letter-spacing:1.5px; }
  .card { padding:20px; }
  .table-card { padding:0; }
  .stat { padding:16px; gap:10px; }
  .stat>span { font-size:12px; flex-direction:column; align-items:flex-start; gap:8px; }
  .stat strong { font-size:30px; }
  .stat small { font-size:12px; }
  .stats { gap:12px; }
  .catalog-grid { gap:12px; }
  .format { padding:18px 14px; }
  .format h2 { font-size:17px; }
  .format p { font-size:14px; }
  .format-check { right:12px; top:18px; font-size:18px; }
  .format-emoji { font-size:32px; margin-bottom:20px; }
  .notification-item { gap:12px; flex-wrap:wrap; }
  .notification-item time { margin-left:58px; }
  .notification-item strong { font-size:16px; }
  .notification-item p { font-size:14px; }
  .editor-fields { grid-template-columns:minmax(0,1fr); }
  .editor-tabs a { padding:10px 12px; }
  .inventory-grid { grid-template-columns:minmax(0,1fr); }
}

/* White initials always contrast with these persistent, randomly assigned tones. */
.avatar.avatar-tone-0 { background:#85354e; color:#fff; }
.avatar.avatar-tone-1 { background:#335a91; color:#fff; }
.avatar.avatar-tone-2 { background:#376b50; color:#fff; }
.avatar.avatar-tone-3 { background:#715298; color:#fff; }
.avatar.avatar-tone-4 { background:#885119; color:#fff; }
.avatar.avatar-tone-5 { background:#236c73; color:#fff; }
.avatar.avatar-tone-6 { background:#744747; color:#fff; }
.avatar.avatar-tone-7 { background:#4f5773; color:#fff; }
.badge { background:#c91829; color:#fff; }
.dialog-mark { display:grid; place-items:center; width:88px; height:88px; margin:0 auto 22px; border-radius:22px; background:#160f12; }
.dialog-mark img { object-fit:contain; width:72px; height:72px; }
.notification-entry { margin:0; }
.notification-item { width:100%; text-align:left; font:inherit; }
.notification-item:hover { border-color:#d0a2ae; }
.notification-copy { flex:1; min-width:0; }
.notification-copy>span { display:block; margin-top:4px; color:var(--muted); }

/* EMaster membership: metal tones progress into the two signature ranks. */
.rank-bronze { --rank-metal:#b77443; --rank-light:#f4c79e; --rank-ink:#79451e; }
.rank-silver { --rank-metal:#8795a6; --rank-light:#e7eef8; --rank-ink:#49576b; }
.rank-gold { --rank-metal:#c49a29; --rank-light:#ffe6a0; --rank-ink:#755600; }
.rank-platinum { --rank-metal:#4c9c97; --rank-light:#c5eee6; --rank-ink:#236660; }
.rank-diamond { --rank-metal:#459fcc; --rank-light:#cbefff; --rank-ink:#246789; }
.rank-black { --rank-metal:#716685; --rank-light:#ded2ef; --rank-ink:#453958; }
.rank-red { --rank-metal:#e12135; --rank-light:#ffd2d8; --rank-ink:#ac1126; }
.avatar.avatar-ranked { border:3px solid var(--rank-metal); box-shadow:0 0 0 2px var(--rank-light); }
.avatar.avatar-ranked.rank-diamond { box-shadow:0 0 0 2px var(--rank-light),0 0 12px #459fcc35; }
.avatar.avatar-ranked.rank-black { border-color:#1a1423; box-shadow:0 0 0 2px #b6a5cc,0 0 0 4px #211729; }
.avatar.avatar-ranked.rank-red { box-shadow:0 0 0 2px #ffd2d8,0 0 0 4px #99132a,0 0 16px #e1213530; }
.rank-caption { display:block; font-size:12px; font-weight:800; letter-spacing:.14em; }
.member-banner { background:#171216; color:#fff; border:1px solid #34272b; border-bottom:3px solid var(--rank-metal); border-radius:22px; padding:36px; display:flex; align-items:center; justify-content:space-between; gap:24px; margin-bottom:24px; }
.member-identity { display:flex; align-items:center; gap:28px; min-width:0; }
.member-banner .avatar { width:104px; height:104px; flex:none; font-size:38px; }
.member-banner h2 { font-size:36px; margin:8px 0; color:#fff; overflow-wrap:anywhere; }
.member-banner .rank-caption,.member-tier { color:var(--rank-light); }
.member-tier { font-weight:700; }
.member-score { display:flex; flex-direction:column; text-align:right; flex:none; }
.member-score strong { font-family:var(--display); font-size:52px; line-height:1.2; color:var(--rank-light); }
.member-score span { font-size:14px; color:#d0c6ca; }
.member-score a { color:#fff; margin-top:12px; font-size:14px; }
.member-grid { align-items:start; }
.member-journey { display:grid; gap:20px; }
.member-journey .card { margin:0; }
.journey-heading { display:flex; justify-content:space-between; align-items:center; gap:12px; }
.level-progress h2 { color:var(--rank-ink); margin:16px 0 8px; }
.level-progress progress { width:100%; height:12px; margin:12px 0; accent-color:var(--rank-metal); }
.level-progress progress::-webkit-progress-value { background:var(--rank-metal); }
.level-progress progress::-moz-progress-bar { background:var(--rank-metal); }
.progress-labels { display:flex; justify-content:space-between; gap:10px; color:var(--muted); font-size:13px; }
.level-metrics { display:grid; grid-template-columns:1fr 1fr; border:1px solid var(--line); border-radius:14px; margin:22px 0; overflow:hidden; }
.level-metrics>div { padding:20px; display:flex; flex-direction:column; gap:4px; }
.level-metrics>div+div { border-left:1px solid var(--line); }
.level-metrics strong { font-size:36px; color:var(--rank-ink); line-height:1.3; }
.level-metrics span,.level-metrics small { font-size:13px; color:var(--muted); }
.level-benefits h3 { margin-bottom:0; }.level-benefits h3+p { margin-top:6px; }
.rewards-table { width:100%; border-collapse:collapse; font-size:15px; }
.rewards-table th { text-align:left; color:var(--muted); font-size:12px; text-transform:uppercase; letter-spacing:.08em; padding:10px 0; }
.rewards-table td { padding:16px 0; border-top:1px solid var(--line); }
.rewards-table td>span { color:var(--rank-ink); margin-right:6px; }
.rewards-table td small { display:block; font-size:12px; color:var(--muted); margin-top:6px; }
.rewards-table th:last-child,.rewards-table td:last-child { text-align:right; }
.rewards-table td:last-child { font-size:21px; font-weight:800; color:var(--rank-ink); }
.reward-note,.tier-path p { font-size:13px; }
.tier-path ol { list-style:none; margin:0; padding:0; }
.tier-path li { display:flex; justify-content:space-between; gap:12px; padding:12px; border-radius:8px; font-size:14px; }
.tier-path li span { color:var(--muted); }.tier-path .current { background:#f5eff0; color:var(--rank-ink); font-weight:800; }
.ranking-podium { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; margin-bottom:28px; }
.position-1 { --place:#ab8120; --place-light:#faf0d3; }.position-2 { --place:#65748b; --place-light:#edf1f7; }.position-3 { --place:#9d633b; --place-light:#f8eee5; }.position-top-ten { --place:#bc2638; --place-light:#fbecef; }
.podium-card { background:#fff; border:1px solid var(--line); border-top:3px solid var(--place); border-radius:18px; padding:24px; text-align:center; }
.podium-label { display:flex; justify-content:space-between; margin-bottom:24px; color:var(--place); font-size:13px; font-weight:800; letter-spacing:.1em; }
.podium-card .avatar { margin:auto; }.podium-card h2 { font-size:23px; margin:18px 0 6px; overflow-wrap:anywhere; }
.podium-tier { display:block; font-size:13px; color:var(--muted); }
.podium-points { display:block; font-size:40px; color:var(--place); margin-top:12px; }.podium-points small { font-size:14px; font-weight:500; }
.podium-card p { font-size:13px; margin:6px 0 0; color:var(--muted); }
.podium-card.position-1 { background:#1a1413; border-color:#785c2d; color:#fff; }
.podium-card.position-1 h2 { color:#fff; }.podium-card.position-1 .podium-points,.podium-card.position-1 .podium-label { color:#edcc79; }
.podium-card.position-1 .podium-tier,.podium-card.position-1 p { color:#d4c6b5; }
.ranking-board { padding:0; overflow:hidden; }.ranking-board-heading { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:28px; }
.ranking-board-heading h2 { margin:0; }.ranking-board-heading p { margin:8px 0 0; color:var(--muted); font-size:14px; }
.ranking-list { padding:0; margin:0; list-style:none; }
.ranking-head,.ranking-row { display:grid; grid-template-columns:minmax(0,2.2fr) minmax(0,1.2fr) minmax(0,1fr) minmax(0,.8fr); gap:16px; align-items:center; padding:20px 28px; }
.ranking-head { font-size:12px; color:var(--muted); background:#faf7f7; text-transform:uppercase; letter-spacing:.05em; }
.ranking-row { border-top:1px solid var(--line); font-size:15px; }
.ranking-row.ranking-you { background:#fcf6f7; }
.ranking-person { display:flex; align-items:center; gap:16px; min-width:0; }.ranking-person>div { min-width:0; overflow-wrap:anywhere; }
.ranking-person .avatar { flex:none; }.rank-position { display:grid; place-items:center; flex:none; width:30px; height:30px; border-radius:8px; background:var(--place-light,#f4f1f2); color:var(--place,#696067); font-weight:800; font-variant-numeric:tabular-nums; }
.ranking-self { display:block; color:#a31a2c; }.ranking-level small { display:block; color:var(--muted); }.ranking-level span { font-weight:700; }
.ranking-production small { display:none; }.ranking-score { text-align:right; }.ranking-score strong { font-size:22px; }.ranking-score small { display:block; color:var(--muted); font-size:12px; }
.ranking-head>span:last-child { text-align:right; }.ranking-footnote { padding:12px 28px; font-size:12px; }.ranking-board>.actions { padding:0 28px 24px; }
.reward-dialog { border-top:4px solid var(--rank-metal,#b77443); text-align:center; }.reward-dialog .rank-caption { color:var(--rank-ink,#79451e); margin:20px 0 10px; }
.reward-earned { display:flex; flex-direction:column; gap:0; margin:24px 0 16px; }.reward-earned strong { font-family:var(--display); font-size:76px; line-height:1.1; color:var(--rank-ink,#79451e); }.reward-earned span { font-size:14px; color:var(--muted); }
.reward-level { font-weight:800; }.reward-dialog .btn { width:100%; }
@media(max-width:1100px) { .member-grid { grid-template-columns:1fr; }.ranking-head,.ranking-row { gap:12px; padding:18px; }.ranking-person { gap:10px; } }
@media(max-width:650px) {
.member-banner { padding:24px; flex-direction:column; align-items:stretch; }.member-identity { gap:20px; }.member-banner h2 { font-size:28px; }.member-banner .avatar { width:72px; height:72px; font-size:28px; }.member-score { text-align:left; border-top:1px solid #3d3036; padding-top:18px; }.member-score strong { font-size:40px; }
.ranking-podium { grid-template-columns:1fr; gap:12px; }.podium-card { padding:22px; }.podium-card .avatar.avatar-large { width:64px; height:64px; }.podium-label { margin-bottom:12px; }.podium-card h2 { margin-top:12px; }.podium-points { font-size:32px; }
.ranking-board-heading { padding:20px; flex-direction:column; align-items:start; }.ranking-head { display:none; }.ranking-row { grid-template-columns:minmax(0,1fr) auto; gap:12px; }.ranking-person { grid-column:1 / -1; }.ranking-level { padding-left:40px; }.ranking-production { grid-column:1; padding-left:40px; font-size:13px; }.ranking-production small { display:inline; margin-left:5px; }.ranking-score { grid-column:2; grid-row:2 / 4; }.ranking-person strong { font-size:16px; }.level-metrics>div { padding:16px; }.progress-labels { flex-direction:column; }.ranking-footnote { padding:12px 18px; }
}
@media(max-width:1100px) { .member-journey { order:-1; } }

/* Personal access to EMaster: identity, invitation state, then the next action. */
.access-navigation { display:flex; flex-wrap:wrap; gap:12px; margin:0 0 24px; }
.management-tab-list{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 26px;padding:6px;background:var(--surface);border:1px solid var(--line);border-radius:16px;width:fit-content;max-width:100%}
.management-tab-list a{display:inline-flex;align-items:center;justify-content:center;min-height:48px;padding:10px 20px;border-radius:11px;font-weight:750;color:var(--muted);text-decoration:none;transition:background .18s,color .18s,box-shadow .18s}
.management-tab-list a:hover{color:var(--ink);background:var(--raised)}
.management-tab-list a[aria-selected=true]{background:var(--ink);color:var(--surface);box-shadow:inset 0 -3px var(--gold)}
.management-tabs>[data-settings-panel][hidden]{display:none!important}
.manage-user-dialog{width:min(440px,calc(100vw - 32px));max-width:none;text-align:left}
.manage-user-dialog::backdrop{background:rgba(16,8,11,.62)}
.manage-user-dialog h2{margin:0 0 10px}.manage-user-dialog>.muted{margin:0 0 24px;overflow-wrap:anywhere}
.manage-user-actions{display:grid;gap:12px;margin:0 0 20px}.manage-user-actions form{margin:0}.manage-user-actions .btn{width:100%;justify-content:center}
.btn.danger{background:#b91925;color:#fff;border-color:#b91925}.btn.danger:hover{background:#93101b}
.management-tabs .partner-client{display:block;padding:18px 24px;margin-bottom:12px}.management-tabs .partner-client>summary{cursor:pointer;font-weight:800;font-size:18px;list-style:none}.management-tabs .partner-client>summary::after{content:'+';float:right;color:var(--brand)}.management-tabs .partner-client[open]>summary::after{content:'−'}
.management-tabs .partner-client[open]>summary{padding-bottom:20px;margin-bottom:20px;border-bottom:1px solid var(--line)}
.management-tabs .partner-client:not([open])>:not(summary){display:none}
@media(max-width:650px){.management-tab-list{width:100%;gap:4px}.management-tab-list a{flex:1 1 100%;justify-content:flex-start}.manage-user-dialog{padding:24px}.management-tabs .partner-client{padding:18px}}
.invitation-create { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:40px; margin-bottom:28px; scroll-margin-top:24px; }
.invitation-create p { margin-bottom:20px; }
.invitation-create small,.invitation-table small { color:var(--muted); display:block; margin-top:8px; overflow-wrap:anywhere; }
.invitation-create form p { margin-bottom:18px; }
.invitation-table { min-width:1050px; }
.invitation-table td { vertical-align:top; }
.invitation-table td:first-child { min-width:170px; }
.invitation-table form .btn { margin-top:8px; }
.invitation-table .invite-copy input { min-width:220px; width:100%; font-size:14px; margin-bottom:8px; }
.invitation-table .invite-copy .btn { padding:10px 14px; }
.invitation-actions { display:flex; gap:16px; flex-wrap:wrap; margin-top:14px; }
.sent-state { font-weight:700; color:var(--ink); }
.registered-heading { margin:32px 0 18px; }
.signup-form { max-width:660px; }
.invitation-identity { padding:24px; margin:24px 0; border:1px solid var(--line); border-left:4px solid var(--gold); border-radius:16px; background:var(--surface); }
.invitation-identity h3 { font-size:26px; margin:10px 0; overflow-wrap:anywhere; }
.invitation-identity p { margin:16px 0 0; }
.member-welcome .dialog-mark { margin-bottom:20px; }
.member-welcome h2 { margin-top:14px; font-size:clamp(26px,4vw,34px); line-height:1.15; }
.member-welcome .actions { margin-top:24px; flex-wrap:wrap; }
.member-welcome .actions .btn { flex:1; }
.tour-progress { width:100%; height:7px; accent-color:var(--brand); margin:16px 0 8px; }
.tour-location { padding:14px; background:var(--surface); border:1px solid var(--line); border-radius:12px; }
.tour-secondary { display:flex; justify-content:space-between; gap:18px; margin-top:22px; }
.tour-resume { position:fixed; bottom:24px; right:24px; z-index:30; box-shadow:0 8px 30px #0002; }
@media(max-width:900px) {
  .invitation-create { grid-template-columns:1fr; gap:24px; }
  .invitation-table { min-width:0; }
  .invitation-table .invite-copy { width:100%; min-width:0; }
  .invitation-table .invite-copy input { min-width:0; }
  .tour-resume { bottom:16px; right:16px; max-width:calc(100% - 32px); }
}
#invitations > .section-heading { padding:24px; }
#invitations > .section-heading p { margin:12px 0 0; }
.signup-avatar { display:flex; align-items:center; gap:14px; margin:24px 0; color:var(--muted); }
@media(min-width:901px) {
  .signup-layout .login-brand { position:sticky; top:0; height:100dvh; align-self:start; }
}
@media(max-width:650px) {
  .invitation-table td { display:block; }
  .invitation-table td[data-label]::before { display:block; margin-bottom:8px; }
  .signup-layout .login-hero,.signup-layout .login-feats { display:none; }
  .signup-layout .login-brand { padding-bottom:20px; }
}

/* Tables: preserve readable identities; let the region scroll before crushing columns. */
.table-scroll { position:relative; max-width:100%; overscroll-behavior-x:contain; }
.table-scroll:focus-visible { outline-offset:-3px; }
.table-scroll-hint { margin:0; padding:12px 20px; font-size:14px; color:var(--muted); border-bottom:1px solid var(--line); background:var(--surface); }
.responsive-table { table-layout:auto; }
.responsive-table th { white-space:normal; }
.responsive-table .person-preview { display:flex; width:100%; }
.responsive-table .person-preview>span:last-child { overflow-wrap:anywhere; }
.person-preview .avatar { flex-shrink:0; }
.person-cell { min-width:260px; }
.people-table { min-width:920px; }
.people-table .person-cell { min-width:270px; width:30%; }
.people-table .username-cell { min-width:190px; overflow-wrap:anywhere; }
.people-table .role-cell { min-width:170px; }
.people-table .access-cell { min-width:140px; }
.account-identity { display:flex; flex-direction:column; align-items:flex-start; gap:10px; }
.account-identity .person-preview { font-weight:600; }
.name-edit-link { display:inline-flex; align-items:center; gap:8px; min-height:44px; padding:8px 12px; margin-left:40px; border:1px solid var(--line); border-radius:10px; color:var(--link); background:var(--surface); font-size:14px; line-height:1.4; white-space:nowrap; }
.name-edit-link:hover { background:var(--raised); color:var(--link); border-color:var(--link); }
.name-edit-link svg { flex-shrink:0; }
.number-cell { font-variant-numeric:tabular-nums; white-space:nowrap; }
.quotes-table { min-width:740px; }
.quotes-with-client { min-width:960px; }
.quotes-table td:first-child { min-width:260px; width:32%; }
.quotes-table .product-title { min-width:0; }
.quotes-table .product-title>span:last-child { min-width:0; overflow-wrap:break-word; word-break:normal; }
.quotes-table .product-icon { flex-shrink:0; }
.quotes-table .state-cell { min-width:145px; }
.invitation-table { min-width:1120px; }
.invitation-table td:first-child { min-width:240px; }
.invitation-table .role-cell { min-width:150px; }
.invitation-table td:nth-child(3) { min-width:200px; }
.invitation-table td:nth-child(4) { min-width:200px; }
.invitation-table td:last-child { min-width:280px; }
.invitation-table strong { overflow-wrap:break-word; word-break:normal; }
.rewards-table td:first-child { padding-right:20px; overflow-wrap:break-word; }
.rewards-table th:last-child,.rewards-table td:last-child { width:80px; white-space:nowrap; font-variant-numeric:tabular-nums; }
/* The ranking uses a grid, but needs the same space for full names as a table. */
@media(min-width:901px) {
  .ranking-head,.ranking-row { grid-template-columns:minmax(260px,2.2fr) minmax(125px,1.2fr) minmax(100px,1fr) minmax(80px,.8fr); }
}
@media(max-width:1100px) and (min-width:901px) {
  .ranking-head,.ranking-row { grid-template-columns:minmax(235px,2.2fr) minmax(100px,1fr) 85px 75px; gap:10px; padding:18px 14px; }
}
@media(max-width:900px) {
  .ranking-head { display:none; }
  .ranking-row { grid-template-columns:minmax(0,1fr) auto; gap:12px; }
  .ranking-person { grid-column:1 / -1; }
  .ranking-level { padding-left:40px; }
  .ranking-production { grid-column:1; padding-left:40px; font-size:14px; }
  .ranking-production small { display:inline; margin-left:5px; }
  .ranking-score { grid-column:2; grid-row:2 / 4; }
}
@media(max-width:760px) {
  .table-scroll { overflow:visible; }
  .table-scroll-hint { display:none; }
  .responsive-table,.responsive-table tbody { display:block; width:100%; min-width:0; }
  .responsive-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); }
  .responsive-table tr { display:block; padding:20px; border-bottom:1px solid var(--line); }
  .responsive-table tr:last-child { border-bottom:0; }
  .responsive-table td,.responsive-table td:first-child,.responsive-table td:last-child { display:block; width:100%; min-width:0; padding:12px 0; border:0; white-space:normal; overflow-wrap:break-word; word-break:normal; }
  .responsive-table td:first-child { padding-top:0; padding-bottom:16px; }
  .responsive-table td:last-child { padding-bottom:0; }
  .responsive-table td[data-label]::before { content:attr(data-label); display:block; margin:0 0 5px; font-size:13px; font-weight:500; color:var(--muted); }
  .responsive-table .person-preview { max-width:100%; }
  .responsive-table .product-title { min-width:0; }
  .responsive-table .table-link { width:100%; min-height:44px; justify-content:center; border:1px solid var(--line); border-radius:10px; background:var(--surface); }
  .responsive-table .empty { width:100%; }
  .invitation-table .invite-copy input { min-width:0; }
  .name-edit-link { white-space:normal; }
}

/* Deliberate return paths and compact, labelled account controls. */
.page-return { margin:0 0 18px; }
.page-return a { display:inline-flex; gap:10px; align-items:center; min-height:44px; color:var(--muted); font-weight:600; font-size:14px; }
.page-return a:hover { color:var(--link); }
.who { display:grid; grid-template-columns:42px minmax(0,1fr); gap:12px; padding:16px 8px 0; }
.who>.avatar { width:40px; height:40px; }
.who>div:not(.account-controls) { min-width:0; }
.who strong { line-height:1.4; }
.who .account-controls { grid-column:1/-1; display:flex; width:100%; gap:6px; margin:2px 0 0; padding-top:10px; border-top:1px solid #30252c; }
.who .account-controls>a,.who .account-controls>form { flex:1; min-width:0; }
.account-controls .out { width:100%; min-height:54px; height:auto; display:flex; flex-direction:column; justify-content:center; align-items:center; gap:4px; padding:6px; font-size:12px; line-height:1.3; }
.account-controls .out>span:not(.logout-icon) { font:inherit; }
.account-controls .logout-icon { font-size:23px; line-height:24px; }
.who .editor-shortcut { color:#e8c86a; }
.who .editor-shortcut.on { background:#39161c; color:#ff727c; }
.quick-edit-dialog { width:min(580px,calc(100% - 32px)); max-height:calc(100dvh - 32px); margin:auto; padding:32px; border:1px solid var(--line); border-radius:24px; background:var(--surface); color:var(--ink); overflow-y:auto; }
.quick-edit-dialog::backdrop { background:#110b10a6; backdrop-filter:blur(4px); }
.quick-edit-dialog h2 { font-size:26px; overflow-wrap:anywhere; padding-right:12px; }
.quick-edit-dialog .dialog-mark { width:64px; height:64px; margin:0 0 20px; border-radius:16px; }
.quick-edit-dialog .dialog-mark img { width:52px; height:52px; }
.dialog-close { position:absolute; top:16px; right:16px; width:44px; height:44px; border:1px solid var(--line); border-radius:12px; background:var(--surface); color:var(--muted); cursor:pointer; }
.quick-edit-dialog .actions { flex-wrap:wrap; }
.quick-edit-dialog form p { margin:20px 0; }
.quick-edit-dialog .helptext { display:block; }
.quick-edit-dialog[aria-busy=true] .dialog-close { visibility:hidden; }
.editor-steps { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); list-style:none; padding:0; gap:16px; margin:0 0 28px; }
.editor-steps li { display:flex; gap:12px; font-size:14px; color:var(--muted); }
.editor-steps b { display:grid; place-items:center; flex-shrink:0; width:30px; height:30px; border-radius:50%; background:var(--dark); color:var(--gold); }
.editor-steps strong { display:block; margin-bottom:4px; color:var(--ink); }
.editor-explanation { margin:10px 0 26px; color:var(--muted); }
.editor-field small { display:block; margin-top:8px; line-height:1.55; }
.editor-page-group { border-top:1px solid var(--line); }
.editor-page-group summary { min-height:52px; padding:16px 4px; cursor:pointer; font-weight:600; }
.editor-page-group .editor-fields { padding:12px 0 24px; }
.editor-form .editor-fields { grid-template-columns:minmax(0,1fr); }
.editor-save { position:sticky; bottom:12px; z-index:5; background:var(--surface); border:1px solid var(--line); border-radius:16px; padding:16px; }
@media(max-width:900px) {
 .who { display:none; }
 .nav.expanded+.who { display:grid; }
 .editor-steps { grid-template-columns:1fr; gap:14px; }
}
@media(max-width:480px) {
 .quick-edit-dialog { padding:24px 20px; }
 .quick-edit-dialog .actions { flex-direction:column; align-items:stretch; }
 .quick-edit-dialog .actions .btn { width:100%; }
 .editor-save { position:static; }
 .page-heading h1 { overflow-wrap:break-word; }
}

/* Long identities must wrap inside product cards as well as tables. */
.product-row small,.inventory-grid .card>p { overflow-wrap:anywhere; }

/* Section navigation: a quiet progress line, without hiding the current screen. */
.navigation-progress{position:fixed;z-index:10000;inset:0 0 auto;height:3px;background:linear-gradient(90deg,#b30e1c,#eabf58,#b30e1c);background-size:200% 100%;animation:navigation-flow 1.3s linear infinite}
.navigation-status{position:fixed;z-index:10001;right:20px;bottom:20px;max-width:min(440px,calc(100vw - 32px));padding:12px 18px;border:1px solid #e5c8cd;border-radius:14px;background:#fff;color:#291b1e;box-shadow:0 6px 24px #210b151a;font-size:15px}
.navigation-status button{border:0;background:none;color:#ac1221;text-decoration:underline;font:inherit;cursor:pointer;padding:6px}
.navigation-progress[hidden],.navigation-status[hidden]{display:none}
@keyframes navigation-flow{to{background-position:-200% 0}}
@media(prefers-reduced-motion:reduce){.navigation-progress{animation:none}}

/* A visible route from product idea to the E-MASTER review. */
.quote-wizard{display:grid;grid-template-columns:220px minmax(0,1fr);gap:32px;align-items:start}
.wizard-route{position:sticky;top:24px;padding:24px}
.wizard-route h2{font-size:20px;margin:0 0 8px}.wizard-route>p{font-size:14px}
.wizard-route ol{list-style:none;margin:28px 0;padding:0}.wizard-route li{position:relative;padding-bottom:20px}
.wizard-route li:not(:last-child):before{content:"";position:absolute;left:17px;top:34px;bottom:0;width:2px;background:var(--line)}
.wizard-route button{display:flex;align-items:center;gap:12px;text-align:left;padding:0;border:0;background:none;color:var(--muted);font:inherit;cursor:pointer;width:100%}
.wizard-route button b{display:grid;place-items:center;width:36px;height:36px;flex-shrink:0;border:2px solid var(--line);border-radius:50%;background:var(--surface,#fff)}
.wizard-route button strong{display:block;font-size:16px}.wizard-route button small{display:block;font-size:13px;margin-top:4px}
.wizard-route button[aria-current]{color:var(--ink)}.wizard-route button[aria-current] b{background:var(--brand);border-color:var(--brand);color:white;box-shadow:0 0 0 4px #e8b53a33}
.wizard-route button.completed b{border-color:var(--gold);color:var(--ink)}.wizard-route button:disabled{cursor:default;opacity:.65}
.wizard-route-note{border-top:1px solid var(--line);padding-top:16px;font-size:13px;color:var(--muted)}.wizard-route-note strong{color:var(--ink)}.wizard-route>a{display:block;font-size:14px;margin-top:20px}
.wizard-workspace{min-width:0}.wizard-workspace section>h2{font-size:clamp(25px,2.5vw,36px);line-height:1.18;margin:0 0 14px;letter-spacing:-.7px}
.wizard-progress{font-size:14px;color:var(--muted);margin:0 0 18px}.wizard-fields{display:grid;gap:24px}.wizard-field{min-width:0}.wizard-field>label{display:block;font-weight:600;margin-bottom:10px}
.wizard-choices{border:0;padding:0;margin:0;min-width:0}.wizard-choices legend{font-size:16px;font-weight:600;margin-bottom:14px}
.wizard-choice-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.wizard-choice{position:relative;display:flex;align-items:flex-start;gap:14px;border:1px solid var(--line);background:var(--surface,#fff);border-radius:22px;padding:26px;cursor:pointer;transition:border-color .15s,box-shadow .15s}
.wizard-choice input[type=radio]{position:absolute;right:20px;top:20px;width:20px;height:20px;accent-color:var(--brand)}
.wizard-choice:has(input:checked){border-color:var(--brand);box-shadow:0 0 0 1px var(--brand)}.wizard-choice:has(input:focus-visible){outline:3px solid var(--gold);outline-offset:3px}
.choice-copy{display:grid;gap:10px;padding-right:18px;overflow-wrap:anywhere}.choice-title{font-size:20px;line-height:1.3}.choice-copy small{font-size:15px;line-height:1.55;color:var(--muted)}.wizard-choice-icon{display:grid;place-items:center;width:52px;height:52px;border:1px solid var(--line);border-radius:15px;font-size:26px;margin-bottom:12px;background:var(--raised)}
.wizard-actions{display:flex;justify-content:flex-end;gap:14px;margin:32px 0}.wizard-actions [data-wizard-previous]{margin-right:auto}.wizard-actions [hidden],.quote-wizard [data-wizard-step][hidden]{display:none}
.quote-wizard:not(.wizard-ready) [data-wizard-step]{margin-bottom:32px}.wizard-review{padding:24px}.wizard-review dl{margin:0}.wizard-review-group{border-bottom:1px solid var(--line);padding:0 0 24px;margin-bottom:24px}.wizard-review-group:last-child{border:0;margin:0;padding:0}.wizard-review-group h3{margin-top:0}.wizard-review dt{color:var(--muted);font-size:14px;margin-top:14px}.wizard-review dd{margin:4px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}.wizard-review .btn{margin-top:16px;font-size:14px;padding:8px 14px}
@media(max-width:1100px){.quote-wizard{grid-template-columns:180px minmax(0,1fr);gap:20px}.wizard-route{padding:18px}.wizard-choice{padding:22px 18px}.choice-title{font-size:18px}}
@media(max-width:760px){.quote-wizard{grid-template-columns:1fr}.wizard-route{position:static;padding:16px}.wizard-route ol{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:18px 0 0}.wizard-route li{padding:0}.wizard-route li:before{display:none}.wizard-route button{gap:6px;flex-direction:column;text-align:center}.wizard-route button strong{font-size:12px}.wizard-route button small,.wizard-route-note,.wizard-route>a{display:none}.wizard-choice-grid{gap:12px}.wizard-choice{padding:20px 14px}.choice-copy{padding:0}.choice-title{font-size:17px}.choice-copy small{font-size:13px}.wizard-choice-icon{margin-bottom:8px}.wizard-workspace .intro{font-size:16px}.wizard-actions{flex-wrap:wrap}.wizard-actions .btn{font-size:15px;padding:14px 16px}}
/* Partner API access (Admin) */
.partner-client { display:flex; flex-direction:column; gap:16px; margin-bottom:24px; }
.partner-client .section-heading { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:flex-start; gap:12px 24px; }
.partner-client h2 { display:flex; flex-wrap:wrap; align-items:center; gap:10px; margin-bottom:6px; }
.partner-client h3 { margin:8px 0 0; }
.partner-client td small { display:block; }
.partner-issue { display:flex; flex-wrap:wrap; align-items:flex-end; gap:12px 16px; }
.partner-issue p { flex:1 1 260px; margin:0; }
.partner-issue small { flex:1 1 100%; }
.partner-edit summary { cursor:pointer; font-weight:600; }
.partner-edit form { margin-top:12px; }
.partner-new-key { display:flex; flex-direction:column; gap:10px; }
.partner-new-key h2 { margin:0; }
.partner-new-key .invite-copy input { font-family:ui-monospace, Menlo, Consolas, monospace; }
.partner-keys td small { display:block; }
.partner-keys .switch { display:inline-flex; align-items:center; gap:8px; cursor:pointer; white-space:nowrap; }
.partner-keys .switch input { width:20px; height:20px; accent-color:var(--brand); }
.partner-permissions { border:1px solid var(--line); border-radius:8px; padding:10px 14px; display:flex; flex-wrap:wrap; gap:8px 20px; margin:0; flex:1 1 100%; }
.partner-permissions legend { font-weight:600; padding:0 6px; }
.partner-permissions label { display:inline-flex; align-items:center; gap:8px; }
.partner-keys > .section-heading { padding:22px 22px 6px; }

/* Compact actions keep table columns and row heights stable after interaction. */
.table-icon-button { display:inline-flex; align-items:center; justify-content:center; flex:none; width:44px; height:44px; padding:0; border:1px solid var(--line); border-radius:11px; background:var(--surface); color:var(--ink); cursor:pointer; vertical-align:middle; transition:background .18s,border-color .18s,color .18s; }
.table-icon-button svg { width:20px; height:20px; flex:none; }
.table-icon-button:hover,.table-icon-button:focus-visible { background:var(--raised); border-color:var(--brand); color:var(--link); }
.table-icon-button.danger-icon { color:var(--link); }
.table-icon-button.danger-icon:hover,.table-icon-button.danger-icon:focus-visible { background:#3b1b23; color:#fff; }
.table-icon-button.is-copied { border-color:#38a66a; color:#176f40; background:#e6f7ed; }
.table-icon-button.is-copied svg { display:none; }
.table-icon-button.is-copied::after { content:'✓'; font-size:22px; font-weight:800; }
.invitation-table { table-layout:fixed; width:100%; min-width:1120px; }
.invitation-table th:first-child,.invitation-table td:first-child { width:23%; min-width:0; }
.invitation-table th:nth-child(2),.invitation-table td:nth-child(2) { width:15%; min-width:0; }
.invitation-table th:nth-child(3),.invitation-table td:nth-child(3) { width:19%; min-width:0; }
.invitation-table th:nth-child(4),.invitation-table td:nth-child(4) { width:17%; min-width:0; }
.invitation-table th:nth-child(5),.invitation-table td:nth-child(5) { width:26%; min-width:0; }
.invitation-table td { vertical-align:middle; overflow-wrap:break-word; }
.invitation-table .invite-send-row { display:flex; align-items:center; justify-content:space-between; gap:8px; min-width:0; }
.invitation-table .invite-send-form small { margin-top:6px; font-size:13px; }
.invitation-table .invite-copy-table { display:grid; grid-template-columns:minmax(0,1fr) 44px; gap:8px; align-items:center; min-width:0; }
.invitation-table .invite-copy-table input { box-sizing:border-box; min-width:0; width:100%; height:44px; margin:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.invitation-table .invite-copy-table .sr-only { position:absolute; display:block; width:1px; height:1px; margin:-1px; overflow:hidden; }
.invitation-table .invitation-actions { display:flex; align-items:center; justify-content:flex-end; gap:8px; flex-wrap:nowrap; margin-top:8px; }
.invitation-table .invitation-actions form { margin:0; }
.people-table .account-identity { flex-direction:row; align-items:center; justify-content:space-between; gap:10px; }
.people-table .account-identity .person-preview { min-width:0; }
.quotes-table th:last-child,.quotes-table td:last-child { width:84px; text-align:center; }
@media(max-width:760px) {
  .invitation-table { min-width:0; table-layout:auto; }
  .invitation-table th,.invitation-table td,.invitation-table th:first-child,.invitation-table td:first-child,.invitation-table th:nth-child(2),.invitation-table td:nth-child(2),.invitation-table th:nth-child(3),.invitation-table td:nth-child(3),.invitation-table th:nth-child(4),.invitation-table td:nth-child(4),.invitation-table th:nth-child(5),.invitation-table td:nth-child(5) { width:100%; min-width:0; }
  .invitation-table .invite-copy-table { max-width:100%; }
  .invitation-table .invitation-actions { justify-content:flex-start; }
  .people-table .account-identity { flex-wrap:wrap; }
  .quotes-table th:last-child,.quotes-table td:last-child { width:100%; }
  .quotes-table td:last-child .table-icon-button { width:100%; }
}
/* Section changes: the sidebar stays still while the content cross-fades (View Transitions, CSS fallback). */
main#content { view-transition-name: page-content; }
::view-transition-old(root), ::view-transition-new(root) { animation: none; }
::view-transition-old(page-content) { animation: 120ms ease-out both page-fade-out; }
::view-transition-new(page-content) { animation: 220ms cubic-bezier(.2,.7,.3,1) both page-fade-in; }
main#content.page-enter { animation: 220ms cubic-bezier(.2,.7,.3,1) both page-fade-in; }
@keyframes page-fade-out { to { opacity:0; } }
@keyframes page-fade-in { from { opacity:0; transform:translateY(6px); } }
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(page-content), ::view-transition-new(page-content), main#content.page-enter { animation:none; }
}
/* Focus moved by script after navigation is for screen readers only; no visible ring. */
.page-focus:focus, .page-focus:focus-visible { outline:none; }
/* Flash messages: centered dialog with a close button and an "Entendido" action. */
.message-dialog { position:fixed; z-index:60; text-align:center; padding:36px 32px 28px; }
.message-dialog-close { position:absolute; top:12px; right:12px; margin:0; }
.dialog-close { width:40px; height:40px; border-radius:50%; border:1px solid var(--line); background:transparent; color:var(--muted); font-size:18px; line-height:1; display:grid; place-items:center; }
.dialog-close:hover { color:var(--ink); border-color:var(--muted); }
.message-dialog-icon { display:grid; place-items:center; width:56px; height:56px; margin:0 auto 16px; border-radius:50%; font:700 26px/1 var(--display); background:#182e26; color:#a1e2bb; border:1px solid #335c47; }
.message-error { border-top-color:#c0392b; }
.message-error .message-dialog-icon { background:#3b2024; color:#ffadb4; border-color:#7a3641; }
.message-warning { border-top-color:var(--gold); }
.message-warning .message-dialog-icon { background:#382d18; color:#f0d48d; border-color:#6a5530; }
.message-info .message-dialog-icon { background:#282740; color:#c3c3f7; border-color:#494970; }
.message-dialog h2 { margin-bottom:10px; }
.message-dialog #message-dialog-body p, .message-dialog #message-dialog-body li { color:var(--ink); font-size:17px; line-height:1.6; overflow-wrap:anywhere; }
.message-dialog #message-dialog-body ul { text-align:left; display:flex; flex-direction:column; gap:8px; margin:0 0 8px; padding-left:20px; }
.message-dialog .actions { display:flex; justify-content:center; margin:20px 0 0; }
.message-dialog .actions .btn { min-width:180px; }
/* Invitation options: a three-dot button per row opens a symmetric options dialog. */
.invitation-table { min-width:760px; }
.invitation-table .options-col, .invitation-table .options-cell { text-align:center; width:96px; }
.invite-options-dialog { position:fixed; padding-top:40px; }
.invitation-table .invite-options-dialog > .muted { margin:0 0 20px; }
.invitation-table .invite-options-link { display:grid; grid-template-columns:1fr; gap:8px; margin:0 0 16px; }
.invitation-table .invite-options-link label { font-weight:600; font-size:14px; }
.invitation-table .invite-options-link input { width:100%; min-width:0; font-size:14px; }
.invitation-table .invite-options-link .btn { width:100%; justify-content:center; }
.invitation-table .invite-options-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin:0 0 12px; }
.invitation-table .invite-options-grid form { margin:0; display:flex; }
.invitation-table .invite-options-grid form .btn { width:100%; justify-content:center; margin:0; }
.invitation-table .invite-options-grid .span-2 { grid-column:1 / -1; }
.invitation-table .invite-options-dialog .btn.full { width:100%; justify-content:center; }
@media (max-width:520px) { .invitation-table .invite-options-grid { grid-template-columns:1fr; } }
.invite-options-dialog h2 { padding-right:44px; overflow-wrap:anywhere; }
/* Welcome guide: what each menu section is for, in one centered dialog. */
.member-welcome { width:min(760px,calc(100% - 32px)); position:fixed; padding-top:40px; }
.member-welcome .message-dialog-close { position:absolute; top:12px; right:12px; }
.guide-sections { list-style:none; padding:0; margin:18px 0 0; display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.guide-sections li { display:flex; gap:12px; align-items:flex-start; padding:14px; border:1px solid var(--line); border-radius:12px; background:var(--raised); }
.guide-icon { flex:none; width:36px; height:36px; display:grid; place-items:center; font-size:20px; border-radius:10px; background:var(--surface); }
.guide-sections strong { display:block; font-size:16px; line-height:1.3; }
.guide-sections p { margin:4px 0 0; font-size:14px; line-height:1.5; color:var(--muted); }
.guide-footnote { margin:16px 0 0; font-size:14px; color:var(--muted); }
.member-welcome .actions { justify-content:center; }
.member-welcome .actions .btn { flex:0 1 240px; }
@media (max-width:640px) { .guide-sections { grid-template-columns:1fr; } }
/* Quote route: circles sit on top of the connecting line and stay at the top of multi-line steps. */
.wizard-route button { align-items:flex-start; }
.wizard-route button b { position:relative; z-index:1; }
.wizard-route button span, .wizard-route button > div { padding-top:6px; }
.wizard-route li:not(:last-child):before { top:36px; left:17px; }
@media (max-width:760px) { .wizard-route button { align-items:center; } .wizard-route button span { padding-top:0; } }
/* Number fields have no stepper arrows: values are typed. */
input[type="number"] { appearance:textfield; -moz-appearance:textfield; }
input[type="number"]::-webkit-inner-spin-button, input[type="number"]::-webkit-outer-spin-button { -webkit-appearance:none; margin:0; }
input[data-money], input[data-decimal] { font-variant-numeric:tabular-nums; }
/* Chat moderation */
.chat-moderation { margin:0 0 12px; }
.chat-muted { margin:0 0 12px; }
.bubble { position:relative; }
.bubble.deleted { opacity:.75; }
.message-removed { font-style:italic; color:var(--muted); }
.message-edited { font-style:italic; }
.message-tools { position:absolute; top:10px; right:12px; }
.message-tools summary { list-style:none; cursor:pointer; width:32px; height:32px; display:grid; place-items:center; border-radius:8px; color:var(--muted); font-size:20px; line-height:1; }
.message-tools summary::-webkit-details-marker { display:none; }
.message-tools summary:hover, .message-tools[open] summary { background:var(--raised); color:var(--ink); }
.message-tools[open] { position:static; display:grid; gap:10px; margin-top:12px; }
.message-tools[open] summary { position:absolute; top:10px; right:12px; }
.message-edit { display:grid; gap:8px; }
.message-edit textarea { width:100%; }
.message-tools .btn { width:100%; justify-content:center; }
/* Production stages: a rail that fills up to the confirmed stage, with the next stage highlighted. */
.stage-track { position:relative; margin:18px 0 6px; }
.stage-rail { position:absolute; top:17px; left:calc(100% / 12); right:calc(100% / 12); height:6px; border-radius:6px; background:var(--line); overflow:hidden; }
.stage-fill { display:block; height:100%; width:0; border-radius:6px; background:linear-gradient(90deg, #087d39, #2fb36a 60%, var(--gold)); transition:width .6s cubic-bezier(.2,.7,.3,1); }
.stage-0 .stage-fill { width:0; } .stage-1 .stage-fill { width:20%; } .stage-2 .stage-fill { width:40%; }
.stage-3 .stage-fill { width:60%; } .stage-4 .stage-fill { width:80%; } .stage-5 .stage-fill { width:100%; }
.stage-steps { position:relative; list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(6, minmax(0, 1fr)); }
.stage-steps li { display:flex; flex-direction:column; align-items:center; gap:8px; text-align:center; }
.stage-dot { width:40px; height:40px; display:grid; place-items:center; border-radius:50%; font-weight:700; font-size:15px; background:var(--surface); border:2px solid var(--line); color:var(--muted); position:relative; z-index:1; transition:transform .2s; }
.stage-name { font-size:13px; line-height:1.3; color:var(--muted); overflow-wrap:anywhere; }
.stage-steps li.done .stage-dot { background:#087d39; border-color:#087d39; color:#fff; }
.stage-steps li.done .stage-name { color:var(--ink); font-weight:600; }
.stage-steps li.next .stage-dot { border-color:var(--gold); color:var(--ink); box-shadow:0 0 0 5px #e8b53a33; animation:stage-pulse 2.4s ease-in-out infinite; }
.stage-steps li.next .stage-name { color:var(--ink); }
@keyframes stage-pulse { 50% { box-shadow:0 0 0 9px #e8b53a14; } }
@media (prefers-reduced-motion: reduce) { .stage-steps li.next .stage-dot { animation:none; } .stage-fill { transition:none; } }
@media (max-width:640px) { .stage-dot { width:30px; height:30px; font-size:13px; } .stage-rail { top:12px; height:4px; } .stage-name { font-size:11px; } }
.due-date-line { display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; margin:10px 0; color:var(--muted); }
.due-date-line strong { color:var(--ink); }
.due-date-form { display:grid; gap:10px; }
.due-date-form input[type="date"] { width:100%; }
.due-date-dialog .invite-options-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-top:8px; }
.due-date-dialog .invite-options-grid .btn { width:100%; justify-content:center; }
.production-card .actions form { margin:0; }
/* Notifications: who is involved in each update. */
.notification-people { display:flex; flex-wrap:wrap; gap:8px 16px; margin-top:8px; }
.notification-person { display:inline-flex; align-items:center; gap:8px; font-size:14px; color:var(--ink); }
.notification-person .avatar { width:28px; height:28px; font-size:12px; flex:none; }
.notification-person .avatar img { width:28px; height:28px; }
.notification-person b { font-weight:600; }
.notification-person small { display:block; font-size:12px; color:var(--muted); line-height:1.2; }
.notification-item time { white-space:nowrap; }
/* Notifications: clear spacing between the people involved. */
.notification-people { gap:10px 28px; margin-top:12px; }
.notification-person { gap:10px; padding:6px 12px 6px 6px; border-radius:999px; background:var(--raised); border:1px solid var(--line); }
.notification-person > span { line-height:1.25; }
/* Admin lists also show the provider. */
.quotes-with-supplier { min-width:1120px; }
/* Catalog: compact card actions and the new-format dialog. */
.format-actions { display:flex; align-items:center; gap:10px; margin-top:auto; padding-top:12px; }
.format-actions form { margin:0; }
.format-toggle { min-height:40px; padding:8px 14px; border-radius:9px; font-weight:600; font-size:14px; border:1px solid var(--line); background:var(--surface); color:var(--ink); }
.format-toggle.on:hover { border-color:#c0392b; color:#b91925; }
.format-toggle:not(.on) { border-color:#335c47; color:#087d39; }
.add-format-dialog { position:fixed; padding-top:40px; width:min(520px, calc(100% - 32px)); }
.add-format-form { display:grid; gap:4px; }
.add-format-form input:not([type="checkbox"]), .add-format-form textarea, .add-format-form select { width:100%; }
.add-format-dialog .invite-options-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-top:12px; }
.add-format-dialog .invite-options-grid .btn { width:100%; justify-content:center; }
.page-heading > .btn { white-space:nowrap; flex:none; }
/* Date under each reached production stage, and progress by stage. */
.stage-date { font-size:12px; color:var(--muted); font-variant-numeric:tabular-nums; margin-top:-4px; }
.production-progress { display:grid; gap:4px; margin:6px 0 4px; }
.production-progress .kv { margin:0; }
.production-progress small { font-size:13px; }
.deadline-late { font-size:13px; color:#b91925; font-weight:600; }
/* Group invitation links */
.group-invite-create { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:24px 40px; margin-top:28px; padding-top:28px; border-top:1px solid var(--line); grid-column:1 / -1; }
.group-invite-create small { color:var(--muted); display:block; margin-top:8px; }
.group-invite-form input, .group-invite-form select { width:100%; }
@media (max-width:760px) { .group-invite-create { grid-template-columns:1fr; } }
.group-invite-table { min-width:760px; }
.group-invite-table small { display:block; color:var(--muted); margin-top:6px; }
.group-usage { display:grid; gap:6px; min-width:140px; }
.group-usage progress { width:100%; height:8px; accent-color:#087d39; }
.group-invite-table .options-cell, .group-invite-table .options-col { text-align:center; width:96px; }
.group-invite-table .invite-options-link { display:grid; gap:8px; margin:0 0 16px; }
.group-invite-table .invite-options-link input { width:100%; }
.group-invite-table .invite-options-link .btn, .group-invite-table .invite-options-grid form .btn { width:100%; justify-content:center; margin:0; }
.group-invite-table .invite-options-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin:0 0 12px; }
.group-invite-table .invite-options-grid form { display:flex; margin:0; }
.group-invite-table .invite-options-grid .span-2 { grid-column:1 / -1; }
.group-invite-table .invite-options-dialog .btn.full { width:100%; justify-content:center; }
/* Chat attachments */
.chat-input { flex-wrap:wrap; }
.chat-input #chat-text { flex:1 1 220px; }
.chat-attach { position:relative; flex:none; display:grid; place-items:center; width:48px; height:48px; border:1px solid var(--line); border-radius:9px; background:var(--surface); cursor:pointer; font-size:20px; }
.chat-attach:hover, .chat-attach:focus-within { border-color:var(--gold); }
.chat-attach input { position:absolute; inset:0; opacity:0; cursor:pointer; width:100%; }
.chat-file-hint { flex:1 1 100%; color:var(--muted); font-size:13px; }
.chat-file-hint.error { color:#b91925; font-weight:600; }
.chat-file-hint.ready { color:#087d39; font-weight:600; }
.chat-file { display:inline-flex; align-items:center; gap:10px; margin:6px 0; padding:10px 14px; border-radius:10px; border:1px solid var(--line); background:var(--surface); color:var(--ink); max-width:100%; }
.chat-file:hover { border-color:var(--gold); color:var(--ink); }
.chat-file strong { display:block; overflow-wrap:anywhere; font-size:15px; }
.chat-file small { display:block; color:var(--muted); font-size:12px; }
.chat-file-icon { font-size:22px; }
/* Dropi data prompt after the welcome guide */
.logistics-dialog { position:fixed; padding-top:40px; width:min(560px, calc(100% - 32px)); }
.logistics-dialog .notice { margin:12px 0 16px; }
.logistics-form input { width:100%; }
.logistics-actions { display:grid; grid-template-columns:1fr 1fr 1fr; gap:10px; margin-top:12px; }
.logistics-actions .btn { width:100%; justify-content:center; }
@media (max-width:560px) { .logistics-actions { grid-template-columns:1fr; } }
.logistics-required { display:grid; gap:12px; justify-items:start; max-width:640px; }
/* Who and when, on cards and rows that mix several clients and providers */
.quote-people { display:flex; flex-wrap:wrap; gap:8px 16px; margin:8px 0; }
.product-row .quote-people { margin:6px 0 0; }
.quote-dates { display:flex; flex-wrap:wrap; gap:6px 18px; margin:6px 0 10px; font-size:13px; }
.quote-dates div { display:flex; gap:6px; }
.quote-dates dt { color:var(--muted); }
.quote-dates dt::after { content:':'; }
.quote-dates dd { margin:0; font-weight:600; font-variant-numeric:tabular-nums; }
.dates-cell small { display:block; color:var(--muted); white-space:nowrap; }
.quotes-with-client { min-width:1080px; }
.quotes-with-supplier { min-width:1240px; }
/* Student warnings */
.student-warnings-dialog { position:fixed; padding-top:40px; width:min(600px, calc(100% - 32px)); text-align:center; }
.student-warnings-dialog .message-dialog-icon { background:#382d18; color:#f0d48d; border-color:#6a5530; }
.student-warnings { list-style:none; padding:0; margin:16px 0 0; display:grid; gap:12px; text-align:left; }
.student-warnings li { padding:14px 16px; border:1px solid var(--line); border-left:4px solid var(--gold); border-radius:10px; background:var(--raised); }
.student-warnings li.warning-unsold_30, .student-warnings li.warning-stock_0 { border-left-color:#c0392b; }
.student-warnings p { margin:6px 0 8px; color:var(--ink); line-height:1.55; }
.student-warnings-dialog .actions { justify-content:center; margin-top:18px; }
.student-warnings-dialog .actions .btn { min-width:200px; }
/* Delete an account together with its products: second, explicit confirmation */
.btn.danger.outline { background:transparent; color:#b91925; border-color:#b91925; }
.btn.danger.outline:hover { background:#b91925; color:#fff; }
.delete-all-dialog { position:fixed; padding-top:40px; width:min(560px, calc(100% - 32px)); }
.delete-all-dialog .message-dialog-icon { background:#3b2024; color:#ffadb4; border-color:#7a3641; margin:0 0 12px; }
.delete-all-summary { display:grid; gap:8px; padding-left:20px; margin:8px 0 14px; color:var(--ink); line-height:1.5; }
.delete-all-check { display:flex; gap:10px; align-items:flex-start; margin:8px 0 14px; font-weight:600; }
.delete-all-check input { width:20px; height:20px; margin-top:2px; accent-color:#b91925; flex:none; }
.delete-all-dialog .invite-options-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.delete-all-dialog .invite-options-grid .btn { width:100%; justify-content:center; }
/* Quote sent back for adjustments: clear next step for each role */
.adjustments-needed { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:12px 24px; }
.adjustments-needed > div { flex:1 1 320px; display:grid; gap:4px; }
.adjustments-needed p { margin:0; }
.adjustments-needed small { opacity:.85; }
.adjustments-needed form { margin:0; }
/* Provider dashboard */
.provider-kpis { display:grid; grid-template-columns:repeat(6, minmax(0,1fr)); gap:14px; margin-bottom:20px; }
.provider-kpis .stat strong { font-size:34px; }
.provider-kpis .kpi-urgent { border-color:var(--gold); box-shadow:inset 0 3px 0 var(--gold); }
.provider-kpis .kpi-late { border-color:#c0392b; box-shadow:inset 0 3px 0 #c0392b; }
.provider-kpis .kpi-late small { color:#b91925; font-weight:600; }
.provider-value { display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:16px; padding:22px; margin-bottom:20px; }
.provider-value div { display:grid; gap:4px; }
.provider-value span { color:var(--muted); font-size:14px; }
.provider-value strong { font-family:var(--display); font-size:28px; font-variant-numeric:tabular-nums; }
.provider-value small { color:var(--muted); }
.provider-grid { display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:20px; }
.provider-panel .product-row { align-items:center; }
.provider-panel .small-btn { min-height:36px; padding:6px 12px; font-size:14px; flex:none; }
.provider-subhead { font-size:16px; margin:18px 0 6px; }
.due-line { display:block; font-size:13px; color:var(--muted); margin-top:2px; }
.due-line.late { color:#b91925; font-weight:600; }
@media (max-width:1200px) { .provider-kpis { grid-template-columns:repeat(3, minmax(0,1fr)); } }
@media (max-width:900px) { .provider-grid, .provider-value { grid-template-columns:1fr; } }
@media (max-width:560px) { .provider-kpis { grid-template-columns:repeat(2, minmax(0,1fr)); } }
.pill.late-pill { background:#fbe5e7; color:#b91925; border-color:#efb8be; }
/* What each partner's API returns right now */
.partner-visibility { display:grid; gap:8px; padding:14px 16px; border:1px solid var(--line); border-radius:10px; background:var(--raised); }
.partner-visibility h3 { margin:0; font-size:16px; }
.partner-visibility p { margin:0; }
.partner-visibility small { color:var(--muted); }
.partner-states { list-style:none; display:flex; flex-wrap:wrap; gap:8px 14px; padding:0; margin:0; font-weight:600; }
