@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700&display=swap');

*,*::before,*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Softer, more modern dark mode palette */
  --bg: #0f1117;
  --bg2: rgba(22, 25, 33, 0.7); 
  --bg3: #1a1e28;
  --bg4: #222733;
  --bg5: #2c3342;
  
  /* Borders and dividers */
  --border: rgba(255, 255, 255, 0.08);
  --b2: rgba(255, 255, 255, 0.12);
  --b3: rgba(255, 255, 255, 0.16);
  
  /* Typography colors */
  --t1: #f8fafc;
  --t2: #cbd5e1;
  --t3: #94a3b8;
  
  /* Accent colors with glassmorphism touches */
  --gold: #fbcfe8; /* Softer accent, maybe changed to a vibrant peach or amber, let's keep amber/gold */
  --gold: #fbbf24;
  --gbg: rgba(251, 191, 36, 0.12);
  --gbrd: rgba(251, 191, 36, 0.25);
  
  --grn: #34d399;
  --grnbg: rgba(52, 211, 153, 0.12);
  --grnbrd: rgba(52, 211, 153, 0.25);
  
  --red: #fb7185;
  --rbg: rgba(251, 113, 133, 0.12);
  --rbrd: rgba(251, 113, 133, 0.25);
  
  --blue: #60a5fa;
  --bbg: rgba(96, 165, 250, 0.12);
  --bbrd: rgba(96, 165, 250, 0.25);
  
  --prp: #a78bfa;
  --pbg: rgba(167, 139, 250, 0.12);
  --pbrd: rgba(167, 139, 250, 0.25);
  
  --org: #fb923c;
  --obg: rgba(251, 146, 60, 0.12);
  --obrd: rgba(251, 146, 60, 0.25);
  
  --teal: #2dd4bf;
  --telbg: rgba(45, 212, 191, 0.12);
  
  /* Modern fonts */
  --mono: 'Outfit', sans-serif; /* Replaced mono with a sleek geometric sans for headers/accents */
  --sans: 'Inter', sans-serif;
  
  /* Radii for that softened look */
  --r: 16px;
  --r-sm: 8px;
  --r-lg: 20px;
  
  /* Shadows for depth */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.2), 0 2px 4px -1px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
  --shadow-glow: 0 0 20px rgba(251, 191, 36, 0.15);
}

html, body {
  height: 100%;
  background: var(--bg);
  background-image: radial-gradient(circle at top right, rgba(96, 165, 250, 0.05), transparent 40%),
                    radial-gradient(circle at bottom left, rgba(251, 191, 36, 0.05), transparent 40%);
  color: var(--t1);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

button, select, input, textarea {
  font-family: var(--sans);
  transition: all 0.2s ease-in-out;
}

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg4); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--t3); }

/* ─── LAYOUT ─── */
.app { display: flex; height: 100vh; overflow: hidden; }
.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; position: relative; }
.content { flex: 1; overflow-y: auto; padding: 24px 32px; }

/* ─── SIDEBAR ─── */
.sb {
  width: 260px;
  min-width: 260px;
  background: var(--bg2);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.1);
  z-index: 10;
}
.sb-logo { padding: 24px 20px 20px; border-bottom: 1px solid var(--border); }
.sb-brand { font-family: var(--mono); font-size: 11px; color: var(--gold); letter-spacing: 2px; text-transform: uppercase; margin-bottom: 8px; font-weight: 600; }
.sb-name { font-family: var(--mono); font-size: 18px; font-weight: 700; color: var(--t1); line-height: 1.2; letter-spacing: -0.5px; }
.sb-user { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 12px; color: var(--t3); font-weight: 500; }
.sb-pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--grn); box-shadow: 0 0 8px var(--grn); animation: pulseGlow 2s ease-in-out infinite; flex-shrink: 0; }

@keyframes pulseGlow { 0%, 100% { box-shadow: 0 0 5px var(--grn); } 50% { box-shadow: 0 0 10px var(--grn), 0 0 20px rgba(52, 211, 153, 0.4); } }

.sb-nav { flex: 1; padding: 16px 12px; overflow-y: auto; }
.sb-grp { font-family: var(--mono); font-size: 10px; font-weight: 600; color: var(--t3); letter-spacing: 1.5px; text-transform: uppercase; padding: 0 12px; display: block; margin: 20px 0 8px; }
.nb {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--r-sm);
  cursor: pointer;
  color: var(--t2);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.25s ease;
  margin-bottom: 4px;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}
.nb:hover { background: var(--bg3); color: var(--t1); transform: translateX(4px); }
.nb.on { background: linear-gradient(90deg, var(--gbg), transparent); color: var(--gold); font-weight: 600; }
.nb.on::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--gold); border-radius: 0 3px 3px 0; }
.nb-ic { font-size: 16px; width: 20px; text-align: center; flex-shrink: 0; opacity: 0.9; }

.sb-foot { padding: 16px 20px; border-top: 1px solid var(--border); font-family: var(--sans); font-size: 11px; color: var(--t3); line-height: 1.8; background: rgba(0,0,0,0.1); }
.sb-foot b { color: var(--gold); font-weight: 600; }
.sf-ok { color: var(--grn); }
.sf-warn { color: var(--red); animation: pulseGlow 2s ease-in-out infinite; }

/* ─── TOPBAR ─── */
.topbar {
  height: 64px;
  background: var(--bg2);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 32px;
  gap: 16px;
  flex-shrink: 0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  z-index: 5;
}
.tb-title { font-family: var(--mono); font-size: 14px; font-weight: 600; color: var(--t1); letter-spacing: 0.5px; }
.tb-right { margin-left: auto; display: flex; gap: 12px; align-items: center; }

/* ─── CHIPS (Modernized Badges) ─── */
.chip { display: inline-flex; align-items: center; font-family: var(--mono); font-size: 11px; font-weight: 600; padding: 4px 10px; border-radius: 20px; border: 1px solid; white-space: nowrap; letter-spacing: 0.5px; gap: 6px; }
.chip-gold { background: var(--gbg); color: var(--gold); border-color: var(--gbrd); }
.chip-dim { background: var(--bg3); color: var(--t3); border-color: var(--b2); }
.chip-red { background: var(--rbg); color: var(--red); border-color: var(--rbrd); animation: pulseGlow 2s ease-in-out infinite; }
.chip-grn { background: var(--grnbg); color: var(--grn); border-color: var(--grnbrd); }
.chip-blue { background: var(--bbg); color: var(--blue); border-color: var(--bbrd); }

/* ─── BUTTONS ─── */
.btn {
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--r-sm);
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn-gold { background: var(--gold); color: #000; box-shadow: var(--shadow-glow); }
.btn-gold:hover { background: #fcd34d; }
.btn-ghost { background: var(--bg3); color: var(--t1); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--bg4); border-color: var(--b2); }
.btn-danger { background: var(--rbg); color: var(--red); border-color: var(--rbrd); }
.btn-danger:hover { background: var(--red); color: #fff; }
.btn-grn { background: var(--grnbg); color: var(--grn); border-color: var(--grnbrd); }
.btn-grn:hover { background: var(--grn); color: #000; }
.btn-sm { padding: 6px 12px; font-size: 11px; border-radius: 6px; }
.btn-lg { padding: 12px 24px; font-size: 14px; border-radius: var(--r); }

/* ─── FORM CONTROLS ─── */
.fsel, .finput {
  background: var(--bg3);
  border: 1px solid var(--b2);
  color: var(--t1);
  font-family: var(--sans);
  font-size: 14px;
  padding: 10px 14px;
  border-radius: var(--r-sm);
  outline: none;
  width: 100%;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.fsel { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394a3b8' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.fsel:focus, .finput:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.15); }
.finput::placeholder { color: var(--t3); }
.flabel { font-family: var(--sans); font-size: 12px; font-weight: 500; color: var(--t2); display: block; margin-bottom: 6px; }
.fgroup { margin-bottom: 20px; }

/* ─── KPIs (Glassy Cards) ─── */
.kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-bottom: 32px; }
.kpi {
  background: linear-gradient(145deg, var(--bg3), var(--bg4));
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-sm);
}
.kpi:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--b2); }
.kpi-ac { position: absolute; left: 0; top: 0; bottom: 0; width: 4px; border-radius: 4px 0 0 4px; }
.kpi-lbl { font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--t3); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 12px; }
.kpi-val { font-family: var(--mono); font-size: 32px; font-weight: 700; line-height: 1; color: var(--t1); }
.kpi-sub { font-size: 12px; color: var(--t3); margin-top: 8px; font-weight: 500; }
.kpi-val-sm { font-family: var(--mono); font-size: 24px; font-weight: 700; line-height: 1; }

/* ─── SECTION ─── */
.sec { margin-bottom: 32px; }
.sec-hdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.sec-ttl { font-family: var(--mono); font-size: 16px; font-weight: 600; color: var(--t1); display: flex; align-items: center; gap: 8px; }
.sec-ttl::before { content:''; display:block; width:8px; height:8px; background:var(--gold); border-radius:50%; box-shadow:0 0 8px var(--gold); }
.sec-cnt { font-family: var(--sans); font-size: 13px; color: var(--t3); }
.sec-r { display: flex; gap: 12px; }

/* ─── FILTER BAR ─── */
.fbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--r);
  margin-bottom: 24px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
}
.fbar-lbl { font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--t2); text-transform: uppercase; white-space: nowrap; }

/* ─── BOX ─── */
.box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}
.box-ttl { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--t3); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 16px; }
.g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media(max-width:960px) { .g2 { grid-template-columns: 1fr; } }

/* ─── TABLE ─── */
.tbl-wrap { border-radius: var(--r-sm); border: 1px solid var(--border); overflow: hidden; box-shadow: var(--shadow-md); background: var(--bg3); }
.tbl-wrap table { width: 100%; border-collapse: collapse; text-align: left; }
.tbl-wrap th {
  font-family: var(--sans); font-size: 12px; font-weight: 600; color: var(--t2); text-transform: uppercase; letter-spacing: 0.5px;
  padding: 14px 16px; border-bottom: 1px solid var(--border); background: var(--bg4); white-space: nowrap; user-select: none;
}
.tbl-wrap td { padding: 14px 16px; border-bottom: 1px solid var(--border); color: var(--t2); font-size: 13px; white-space: nowrap; transition: background 0.2s; }
.tbl-wrap tr:last-child td { border-bottom: none; }
.tbl-wrap tr:hover td { background: var(--bg4); color: var(--t1); }

.td-mono { font-family: var(--mono); font-size: 13px; font-weight: 500; }
.td-bold { font-weight: 600; color: var(--t1); }
.td-r { text-align: right; }
.td-dim { color: var(--t3); }
.td-gold { color: var(--gold); font-weight: 600; }
.td-red { color: var(--red); font-weight: 600; }
.td-grn { color: var(--grn); font-weight: 600; }

/* ─── BADGES ─── */
.badge { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 20px; font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; border: 1px solid; white-space: nowrap; }
.b-A { background: var(--rbg); color: var(--red); border-color: var(--rbrd); }
.b-B { background: var(--bbg); color: var(--blue); border-color: var(--bbrd); }
.b-Bplus, .b-B\+ { background: var(--obg); color: var(--org); border-color: var(--obrd); }
.b-C { background: var(--bg4); color: var(--t3); border-color: var(--b2); }
.b-NOVO { background: var(--bbg); color: var(--blue); border-color: var(--bbrd); }
.b-AUMENTOU { background: var(--rbg); color: var(--red); border-color: var(--rbrd); }
.b-DIMINUIU { background: var(--grnbg); color: var(--grn); border-color: var(--grnbrd); }
.b-REMOVIDO { background: var(--pbg); color: var(--prp); border-color: var(--pbrd); }
.b-CRITICA { background: var(--rbg); color: var(--red); border-color: var(--rbrd); animation: pulseGlow 1.6s ease-in-out infinite; }
.b-Alta { background: var(--rbg); color: var(--red); border-color: var(--rbrd); }
.b-Media { background: var(--obg); color: var(--org); border-color: var(--obrd); }
.b-Baixa { background: var(--bg4); color: var(--t3); border-color: var(--b2); }
.b-admin { background: var(--gbg); color: var(--gold); border-color: var(--gbrd); }
.b-user { background: var(--bg4); color: var(--t3); border-color: var(--b2); }
.b-ativo { background: var(--grnbg); color: var(--grn); border-color: var(--grnbrd); }
.b-inativo { background: var(--bg4); color: var(--t3); border-color: var(--b2); }
.b-daily { background: var(--telbg); color: var(--teal); border-color: rgba(45,212,191,0.2); }
.b-monthly { background: var(--pbg); color: var(--prp); border-color: var(--pbrd); }

/* ─── GANTT ─── */
.gantt-shell { border: 1px solid var(--border); border-radius: var(--r); overflow: auto; background: var(--bg2); max-height: calc(100vh - 280px); box-shadow: var(--shadow-md); }
.gantt-tbl { border-collapse: collapse; white-space: nowrap; min-width: 100%; }
.gc-sticky0 { position: sticky; left: 0; z-index: 8; background: var(--bg3); box-shadow: 2px 0 10px rgba(0,0,0,0.2); }
.gh-mat-info { padding: 12px 16px; border-bottom: 1px solid var(--b2); background: var(--bg4); position: sticky; top: 0; z-index: 9; font-family: var(--sans); font-size: 11px; font-weight: 600; color: var(--t2); text-transform: uppercase; border-right: 1px solid var(--border); }
.gh-sem { font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--t3); text-align: center; padding: 12px 8px; background: var(--bg4); border-bottom: 1px solid var(--b2); border-right: 1px solid var(--border); min-width: 140px; position: sticky; top: 0; z-index: 5; }
.gh-sem.past { background: rgba(239, 68, 68, 0.05); color: var(--red); }
.gr-forn { cursor: pointer; user-select: none; }
.gr-forn td { background: var(--bg3) !important; border-bottom: 1px solid var(--border); padding: 12px 16px; }
.gr-forn:hover td { background: var(--bg4) !important; }
.gr-forn-label { font-family: var(--mono); font-size: 14px; font-weight: 600; color: var(--t1); display: flex; align-items: center; gap: 8px; }
.gr-mat td { border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); padding: 0; vertical-align: top; }
.gr-mat:hover td { background: rgba(255,255,255,0.02) !important; }
.gr-mat td.gc-sticky0 { background: var(--bg2); }
.gr-mat:hover td.gc-sticky0 { background: var(--bg3) !important; }
.mat-cod { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--gold); padding: 10px 16px 4px; }
.mat-desc { font-size: 12px; color: var(--t2); max-width: 240px; overflow: hidden; text-overflow: ellipsis; padding: 0 16px 4px; }
.mat-fam { font-family: var(--sans); font-size: 10px; color: var(--t3); padding: 0 16px 10px; font-weight: 500; text-transform: uppercase; }
.cell-wrap { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 64px; padding: 8px; text-align: center; gap: 4px; }
.cell-empty { color: var(--t3); font-size: 11px; font-family: var(--mono); }
.st-chegou { background: var(--grnbg) !important; border-left: 3px solid var(--grn); }
.st-baixou { background: rgba(16, 185, 129, 0.05) !important; border-left: 3px solid rgba(16, 185, 129, 0.4); }
.st-subiu { background: var(--rbg) !important; border-left: 3px solid var(--red); }
.st-novo { background: var(--bbg) !important; border-left: 3px solid var(--blue); }
.st-saiu { background: var(--pbg) !important; border-left: 3px solid var(--prp); }
.st-igual { background: transparent; }
.cell-arrow { font-family: var(--mono); font-size: 13px; font-weight: 600; color: var(--t1); display: flex; align-items: center; gap: 4px; }
.cell-arrow .ant { color: var(--t3); font-size: 11px; text-decoration: line-through; }
.cell-arrow .seta { color: var(--t2); font-size: 10px; }
.cell-label { font-family: var(--sans); font-size: 9px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; padding: 2px 6px; border-radius: 4px; }
.cl-chegou { background: var(--grn); color: #000; }
.cl-baixou { background: transparent; color: var(--grn); border: 1px solid var(--grn); }
.cl-subiu { background: var(--rbg); color: var(--red); border: 1px solid var(--rbrd); }
.cl-novo { background: var(--bbg); color: var(--blue); border: 1px solid var(--bbrd); }
.cl-saiu { background: var(--pbg); color: var(--prp); border: 1px solid var(--pbrd); }
.cell-cur { font-family: var(--mono); font-size: 14px; font-weight: 600; color: var(--t2); }

/* ─── ALERTS / FLASH ─── */
.alert { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--bg3); border: 1px solid var(--border); border-radius: var(--r-sm); border-left: 4px solid; margin-bottom: 12px; box-shadow: var(--shadow-md); animation: slideIn 0.3s ease; }
@keyframes slideIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
.alert.ar { border-left-color: var(--red); }
.alert.ao { border-left-color: var(--org); }
.alert.ag { border-left-color: var(--gold); }
.alert.ai { border-left-color: var(--blue); }
.alert.as { border-left-color: var(--grn); }
.alert-msg { font-size: 13px; font-weight: 500; color: var(--t1); flex: 1; }
.alert-close { background: none; border: none; color: var(--t3); cursor: pointer; font-size: 18px; padding: 4px; transition: color 0.2s; }
.alert-close:hover { color: var(--t1); }

/* ─── SNAP ITEM  ─── */
.snap-list { display: flex; flex-direction: column; gap: 8px; }
.snap-item { display: flex; align-items: center; gap: 16px; padding: 12px 16px; background: var(--bg3); border: 1px solid var(--border); border-radius: var(--r-sm); transition: transform 0.2s, box-shadow 0.2s; }
.snap-item:hover { transform: translateX(4px); border-color: var(--b2); box-shadow: var(--shadow-sm); }
.snap-date { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--gold); width: 100px; flex-shrink: 0; }
.snap-per { font-family: var(--sans); font-size: 11px; font-weight: 500; color: var(--t3); width: 60px; flex-shrink: 0; }
.snap-name { color: var(--t1); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--sans); font-size: 13px; font-weight: 500; }
.snap-cnt { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--t3); flex-shrink: 0; }
.snap-r { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-shrink: 0; }

/* ─── DROP ZONE ─── */
.dz-full, .dz { background: rgba(255,255,255,0.02); border: 2px dashed var(--b2); border-radius: var(--r); cursor: pointer; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); position: relative; }
.dz-full { padding: 20px 24px; display: flex; align-items: center; gap: 20px; margin-bottom: 16px; }
.dz { padding: 40px 24px; text-align: center; min-height: 160px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.dz-full:hover, .dz-full.drag, .dz:hover, .dz.drag { border-color: var(--gold); background: var(--gbg); transform: scale(1.01); }
.dz-full.done { border-color: var(--grn); background: var(--grnbg); border-style: solid; }
.dz input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; z-index: 2; }
.dz-ic { font-size: 36px; margin-bottom: 12px; filter: drop-shadow(0 4px 6px rgba(0,0,0,0.2)); }
.dz-lbl { font-weight: 600; color: var(--t1); font-size: 15px; margin-bottom: 6px; font-family: var(--mono); }
.dz-sub { font-size: 12px; color: var(--t2); margin-bottom: 12px; }
.dz-tag { font-family: var(--sans); font-size: 10px; font-weight: 600; display: inline-block; padding: 4px 8px; border-radius: 4px; }
.dz-tag.req { background: var(--gbg); color: var(--gold); }
.dz-tag.opt { background: var(--bg4); color: var(--t3); }
.dz-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }

/* ─── CART CARDS ─── */
.cart-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.cart-card { background: var(--bg3); border: 1px solid var(--border); border-radius: var(--r); padding: 20px; cursor: pointer; transition: all 0.3s ease; box-shadow: var(--shadow-sm); position: relative; overflow: hidden; }
.cart-card:hover { border-color: var(--b2); background: var(--bg4); transform: translateY(-4px); box-shadow: var(--shadow-md); }
.cart-card.hd::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--gold); border-radius: 4px 0 0 4px; }
.cart-card.nd { opacity: 0.6; filter: grayscale(50%); }
.cc-name { font-weight: 600; font-size: 15px; color: var(--t1); margin-bottom: 4px; line-height: 1.4; }
.cc-cod { font-family: var(--mono); font-size: 11px; color: var(--t3); margin-bottom: 12px; display: block; }
.cc-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.cc-stats { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; padding-top: 12px; border-top: 1px solid var(--border); }
.ccs-lbl { font-family: var(--sans); font-size: 9px; font-weight: 600; color: var(--t3); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 4px; }
.ccs-val { font-family: var(--mono); font-size: 20px; font-weight: 700; color: var(--t1); }

/* ─── HBar ─── */
.hb { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.hb-lbl { font-family: var(--sans); font-size: 11px; font-weight: 500; color: var(--t2); width: 140px; flex-shrink: 0; overflow: hidden; text-overflow: ellipsis; }
.hb-track { flex: 1; height: 8px; background: var(--bg4); border-radius: 4px; overflow: hidden; }
.hb-fill { height: 100%; border-radius: 4px; min-width: 4px; transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1); }
.hb-val { font-family: var(--mono); font-size: 11px; font-weight: 600; color: var(--t3); width: 40px; text-align: right; flex-shrink: 0; }

/* ─── MISC ─── */
.empty { text-align: center; padding: 60px 20px; color: var(--t3); font-family: var(--sans); font-size: 14px; background: var(--bg2); border-radius: var(--r); border: 1px dashed var(--b2); }
.empty-ic { font-size: 48px; margin-bottom: 16px; opacity: 0.5; }
.spinner { width: 36px; height: 36px; border: 3px solid var(--b2); border-top-color: var(--gold); border-radius: 50%; animation: spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite; margin: 16px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.err-box { background: var(--rbg); border: 1px solid var(--rbrd); border-radius: var(--r-sm); padding: 12px 16px; color: var(--red); font-family: var(--sans); font-size: 13px; font-weight: 500; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.dpos { color: var(--red); font-family: var(--mono); font-size: 12px; font-weight: 600; background: var(--rbg); padding: 2px 6px; border-radius: 4px; }
.dneg { color: var(--grn); font-family: var(--mono); font-size: 12px; font-weight: 600; background: var(--grnbg); padding: 2px 6px; border-radius: 4px; }
.eyebrow { font-family: var(--sans); font-size: 10px; font-weight: 700; color: var(--gold); letter-spacing: 2px; text-transform: uppercase; margin-bottom: 8px; display: inline-block; padding: 4px 8px; background: var(--gbg); border-radius: 4px; }
.page-title { font-family: var(--mono); font-size: 28px; font-weight: 700; color: var(--t1); line-height: 1.2; margin-bottom: 8px; letter-spacing: -0.5px; }
.page-sub { font-size: 14px; color: var(--t2); margin-bottom: 24px; max-width: 600px; line-height: 1.6; }

/* ─── MODAL ─── */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); z-index: 1000; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); animation: fadeIn 0.2s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-box { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 32px; width: 100%; max-width: 520px; max-height: 90vh; overflow-y: auto; box-shadow: 0 24px 64px rgba(0,0,0,0.4); animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1); position: relative; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px) scale(0.95); } to { opacity: 1; transform: translateY(0) scale(1); } }
.modal-title { font-family: var(--mono); font-size: 18px; font-weight: 700; color: var(--t1); margin-bottom: 24px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: 16px; }
.modal-title button { background: var(--bg3); width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border); color: var(--t2); cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.modal-title button:hover { background: var(--bg4); color: var(--t1); transform: rotate(90deg); }

/* ─── LOGIN ─── */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--bg); background-image: radial-gradient(circle at 15% 50%, rgba(251, 191, 36, 0.08), transparent 30%), radial-gradient(circle at 85% 30%, rgba(96, 165, 250, 0.08), transparent 30%); font-family: var(--sans); }
.login-box { width: 100%; max-width: 420px; padding: 48px 40px; background: rgba(22, 25, 33, 0.6); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 24px; box-shadow: 0 24px 64px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.1); position: relative; overflow: hidden; }
.login-box::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, var(--blue), var(--gold)); }
.login-brand { font-family: var(--mono); font-size: 11px; font-weight: 700; color: var(--gold); letter-spacing: 3px; text-transform: uppercase; margin-bottom: 12px; text-align: center; }
.login-title { font-family: var(--mono); font-size: 28px; font-weight: 700; color: var(--t1); text-align: center; margin-bottom: 8px; letter-spacing: -0.5px; }
.login-sub { font-size: 14px; color: var(--t3); text-align: center; margin-bottom: 32px; line-height: 1.5; }

/* ─── LOADING / SKELETON ─── */
.loading-overlay { position: absolute; inset: 0; background: rgba(15, 17, 23, 0.8); backdrop-filter: blur(4px); display: flex; align-items: center; justify-content: center; z-index: 50; border-radius: inherit; }
.pulse { animation: pulseBg 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; }
@keyframes pulseBg { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
