/* =====================================================
   PORTFOLIO ADMIN DASHBOARD STYLES
   ===================================================== */

:root {
  --bg:        #070f0f;
  --bg-2:      #0d1a1a;
  --bg-3:      #122020;
  --bg-card:   #0f1f1f;
  --sidebar:   #050d0d;
  --gold:      #c9a227;
  --gold-dim:  rgba(201,162,39,.13);
  --gold-glow: rgba(201,162,39,.3);
  --teal:      #00d4c8;
  --teal-dim:  rgba(0,212,200,.1);
  --red:       #f87171;
  --green:     #34d399;
  --text:      #e8f4f4;
  --text-2:    #7a9e9e;
  --text-3:    #3d6060;
  --border:    rgba(0,212,200,.08);
  --border-h:  rgba(0,212,200,.2);
  --ease:      cubic-bezier(0.16,1,.3,1);
  --font:      'Space Grotesk', sans-serif;
  --mono:      'JetBrains Mono', monospace;
  --sidebar-w: 220px;
  --topbar-h:  60px;
}

*,*::before,*::after { box-sizing: border-box; margin:0; padding:0; }
html { font-size: 14px; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  height: 100vh;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
button { font-family: var(--font); cursor: pointer; border: none; background: none; }
input, textarea, select { font-family: var(--font); }
a { text-decoration: none; color: inherit; }
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: var(--bg-2); }
::-webkit-scrollbar-thumb { background: var(--teal-dim); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--teal); }

/* ===== LAYOUT ===== */
.admin-layout {
  display: flex;
  height: 100vh;
}

/* ===== SIDEBAR ===== */
.admin-sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: width .3s var(--ease), transform .3s var(--ease);
  overflow: hidden;
  z-index: 100;
}
.admin-sidebar.collapsed { width: 56px; }

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  height: var(--topbar-h);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.logo-mr {
  font-family: var(--mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
}
.logo-dot { color: var(--gold); }
.logo-label {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--text-3);
  white-space: nowrap;
  overflow: hidden;
}
.admin-sidebar.collapsed .logo-label { opacity: 0; width: 0; }

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 12px 0;
}
.snav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 18px;
  font-size: .82rem;
  font-weight: 500;
  color: var(--text-2);
  border-radius: 0;
  transition: color .2s, background .2s;
  white-space: nowrap;
  text-align: left;
}
.snav-item i { font-size: .88rem; width: 18px; flex-shrink: 0; }
.snav-item span { overflow: hidden; }
.admin-sidebar.collapsed .snav-item span { opacity: 0; width: 0; }
.snav-item:hover { color: var(--text); background: var(--bg-3); }
.snav-item.active {
  color: var(--gold);
  background: var(--gold-dim);
  position: relative;
}
.snav-item.active::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 2px;
  background: var(--gold);
  border-radius: 0 2px 2px 0;
}

.sidebar-footer {
  padding: 12px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.sidebar-reset {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 12px;
  font-size: .78rem;
  color: var(--red);
  border-radius: 8px;
  transition: background .2s;
  white-space: nowrap;
  overflow: hidden;
}
.sidebar-reset:hover { background: rgba(248,113,113,.08); }
.admin-sidebar.collapsed .sidebar-reset span { opacity: 0; width: 0; }

/* ===== MAIN ===== */
.admin-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ===== TOPBAR ===== */
.admin-topbar {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-2);
  flex-shrink: 0;
  gap: 12px;
}
.topbar-left { display: flex; align-items: center; gap: 14px; }
.sidebar-toggle {
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  color: var(--text-2);
  transition: color .2s, background .2s;
}
.sidebar-toggle:hover { color: var(--text); background: var(--bg-3); }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: .78rem; }
.bc-root { color: var(--text-3); }
.bc-sep { color: var(--text-3); font-size: .6rem; }
.bc-current { color: var(--text); font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }

.save-status {
  display: flex; align-items: center; gap: 6px;
  font-size: .72rem; font-family: var(--mono);
  color: var(--green); opacity: 0;
  transition: opacity .3s;
  white-space: nowrap;
  padding: 0 8px;
}
.save-status.show { opacity: 1; }
.save-status.saving { color: var(--text-2); }
.save-status i { font-size: .7rem; }

.btn-import, .btn-export, .btn-save, .btn-view {
  display: flex; align-items: center; gap: 7px;
  padding: 7px 14px; border-radius: 8px;
  font-size: .78rem; font-weight: 600;
  cursor: pointer; white-space: nowrap;
  transition: all .2s;
}
.btn-import {
  color: var(--text-2);
  border: 1px solid var(--border);
  background: transparent;
}
.btn-import:hover { color: var(--text); border-color: var(--border-h); background: var(--bg-3); }
.btn-export {
  color: var(--text-2);
  border: 1px solid var(--border);
  background: transparent;
}
.btn-export:hover { color: var(--teal); border-color: var(--teal); background: var(--teal-dim); }
.btn-save {
  background: var(--gold);
  color: #050f0f;
  border: none;
}
.btn-save:hover { background: #e8be3a; box-shadow: 0 4px 20px var(--gold-glow); }
.btn-view {
  background: var(--teal-dim);
  color: var(--teal);
  border: 1px solid rgba(0,212,200,.2);
}
.btn-view:hover { background: rgba(0,212,200,.18); }

/* ===== CONTENT AREA ===== */
.admin-content {
  flex: 1;
  overflow-y: auto;
  padding: 28px 28px 60px;
}

/* ===== SECTION HEADING ===== */
.section-heading {
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.section-heading h2 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.03em;
  margin-bottom: 4px;
}
.section-heading p { font-size: .8rem; color: var(--text-2); }

/* ===== FORM CARD ===== */
.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 24px;
  margin-bottom: 16px;
  transition: border-color .2s;
}
.form-card:focus-within { border-color: var(--border-h); }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.card-title {
  font-size: .82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--teal);
}
.card-subtitle { font-size: .75rem; color: var(--text-3); margin-top: 2px; }

/* ===== FIELD GROUP ===== */
.field-group {
  margin-bottom: 16px;
}
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 16px;
}
.field-row-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}
.field-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.field-label label {
  font-size: .75rem;
  font-weight: 600;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: .08em;
}
.char-count {
  font-family: var(--mono);
  font-size: .65rem;
  color: var(--text-3);
}
.char-count.warn { color: var(--gold); }
.char-count.over { color: var(--red); }

input[type="text"],
input[type="email"],
input[type="url"],
input[type="number"],
textarea,
select {
  width: 100%;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  font-size: .82rem;
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  resize: vertical;
}
input:focus, textarea:focus, select:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0,212,200,.08);
}
textarea { min-height: 80px; }
input::placeholder, textarea::placeholder { color: var(--text-3); }

/* Icon preview row */
.icon-row {
  display: flex;
  gap: 10px;
  align-items: center;
}
.icon-preview {
  width: 38px; height: 38px;
  background: var(--gold-dim);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 16px;
  flex-shrink: 0;
  transition: background .2s;
}
.icon-preview.teal-prev { background: var(--teal-dim); color: var(--teal); }

/* Level select */
.level-select {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.level-opt {
  padding: 5px 12px;
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 600;
  border: 1px solid var(--border);
  color: var(--text-3);
  cursor: pointer;
  transition: all .2s;
}
.level-opt:hover { border-color: var(--border-h); color: var(--text-2); }
.level-opt.sel-expert   { border-color: var(--teal); color: var(--teal); background: var(--teal-dim); }
.level-opt.sel-proficient  { border-color: var(--gold); color: var(--gold); background: var(--gold-dim); }
.level-opt.sel-intermediate { border-color: #a78bfa; color: #a78bfa; background: rgba(167,139,250,.1); }

/* ===== ARRAY SECTION ===== */
.array-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.array-title {
  font-size: .9rem;
  font-weight: 700;
  color: var(--text);
}
.array-count {
  font-family: var(--mono);
  font-size: .7rem;
  color: var(--text-3);
  margin-left: 8px;
}

.btn-add {
  display: flex; align-items: center; gap: 7px;
  padding: 7px 14px; border-radius: 8px;
  font-size: .75rem; font-weight: 600;
  color: var(--teal);
  border: 1px solid rgba(0,212,200,.2);
  background: var(--teal-dim);
  transition: all .2s;
}
.btn-add:hover { background: rgba(0,212,200,.18); border-color: var(--teal); }

.btn-remove {
  display: flex; align-items: center; gap: 5px;
  padding: 5px 10px; border-radius: 7px;
  font-size: .72rem; font-weight: 600;
  color: var(--red);
  border: 1px solid rgba(248,113,113,.15);
  background: rgba(248,113,113,.05);
  transition: all .2s;
}
.btn-remove:hover { background: rgba(248,113,113,.12); }

/* Collapsible item card */
.item-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
  transition: border-color .2s;
}
.item-card:focus-within { border-color: var(--border-h); }
.item-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  cursor: pointer;
  user-select: none;
}
.item-card-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .8rem;
  font-weight: 600;
}
.item-num {
  width: 24px; height: 24px;
  border-radius: 6px;
  background: var(--gold-dim);
  color: var(--gold);
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.item-title { color: var(--text); }
.item-subtitle { font-size: .72rem; color: var(--text-3); font-weight: 400; }
.item-card-actions { display: flex; align-items: center; gap: 8px; }
.item-chevron {
  width: 22px; height: 22px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-3); font-size: .7rem;
  transition: transform .2s, color .2s;
}
.item-card.open .item-chevron { transform: rotate(180deg); color: var(--teal); }
.item-card-body {
  padding: 0 16px 16px;
  display: none;
}
.item-card.open .item-card-body { display: block; }

/* ===== CHIP EDITOR ===== */
.chip-editor {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-height: 52px;
  align-items: center;
}
.chip-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px 5px 12px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: .75rem;
  color: var(--text-2);
  cursor: default;
}
.chip-del {
  width: 16px; height: 16px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-3); font-size: .55rem;
  cursor: pointer;
  transition: color .2s, background .2s;
}
.chip-del:hover { color: var(--red); background: rgba(248,113,113,.12); }
.chip-add-wrap {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
}
.chip-input {
  flex: 1;
  padding: 7px 10px !important;
  font-size: .78rem !important;
}
.chip-add-btn {
  padding: 7px 12px;
  border-radius: 7px;
  font-size: .75rem; font-weight: 600;
  color: var(--teal);
  border: 1px solid rgba(0,212,200,.2);
  background: var(--teal-dim);
  transition: all .2s;
  white-space: nowrap;
}
.chip-add-btn:hover { background: rgba(0,212,200,.18); }

/* ===== FEATURE LIST ===== */
.feature-list { display: flex; flex-direction: column; gap: 8px; }
.feature-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.feature-toggle {
  width: 32px; height: 18px;
  border-radius: 9px;
  position: relative;
  flex-shrink: 0;
  cursor: pointer;
  transition: background .2s;
  background: var(--bg-3);
  border: 1px solid var(--border);
}
.feature-toggle.on { background: var(--teal); border-color: var(--teal); }
.feature-toggle::after {
  content: '';
  position: absolute;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: white;
  top: 2px; left: 2px;
  transition: transform .2s;
}
.feature-toggle.on::after { transform: translateX(14px); }
.feature-text {
  flex: 1;
  font-size: .78rem;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: var(--font);
}
.feature-text::placeholder { color: var(--text-3); }
.feature-del { color: var(--text-3); font-size: .7rem; cursor: pointer; padding: 2px 6px; transition: color .2s; }
.feature-del:hover { color: var(--red); }
.feature-add {
  display: flex; align-items: center; gap: 6px;
  margin-top: 8px;
  color: var(--text-3); font-size: .76rem;
  cursor: pointer; padding: 6px 8px;
  border-radius: 7px;
  transition: color .2s, background .2s;
  border: 1px dashed var(--border);
  width: 100%;
}
.feature-add:hover { color: var(--teal); border-color: rgba(0,212,200,.3); background: var(--teal-dim); }

/* Mockup selector */
.mockup-selector { display: flex; gap: 10px; }
.mockup-opt {
  flex: 1;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  text-align: center;
  font-size: .75rem;
  font-weight: 600;
  color: var(--text-3);
  cursor: pointer;
  transition: all .2s;
}
.mockup-opt.sel { border-color: var(--teal); color: var(--teal); background: var(--teal-dim); }
.mockup-opt:hover { border-color: var(--border-h); color: var(--text-2); }

/* Tech tags editor */
.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  min-height: 48px;
  align-items: center;
}
.tech-tag {
  display: flex; align-items: center; gap: 5px;
  padding: 4px 9px 4px 10px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-family: var(--mono);
  font-size: .68rem;
  color: var(--text-2);
}
.tech-tag button { color: var(--text-3); font-size: .55rem; cursor: pointer; transition: color .2s; }
.tech-tag button:hover { color: var(--red); }
.tech-add-row { display: flex; gap: 8px; margin-top: 8px; }
.tech-input { font-size: .78rem !important; }
.tech-add-btn { padding: 7px 12px; border-radius: 7px; font-size: .75rem; font-weight: 600; color: var(--teal); border: 1px solid rgba(0,212,200,.2); background: var(--teal-dim); transition: all .2s; white-space: nowrap; }
.tech-add-btn:hover { background: rgba(0,212,200,.18); }

/* Achievement color selector */
.color-selector { display: flex; gap: 8px; }
.color-opt {
  width: 32px; height: 32px;
  border-radius: 8px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all .2s;
  display: flex; align-items: center; justify-content: center;
}
.color-opt[data-color="gold"]   { background: var(--gold-dim); color: var(--gold); }
.color-opt[data-color="teal"]   { background: var(--teal-dim); color: var(--teal); }
.color-opt[data-color="purple"] { background: rgba(167,139,250,.1); color: #a78bfa; }
.color-opt.sel[data-color="gold"]   { border-color: var(--gold); }
.color-opt.sel[data-color="teal"]   { border-color: var(--teal); }
.color-opt.sel[data-color="purple"] { border-color: #a78bfa; }
.color-opt i { font-size: .75rem; }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-3);
  font-size: .8rem;
}
.empty-state i { font-size: 2rem; color: var(--border-h); display: block; margin-bottom: 10px; }

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: .82rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 8px 32px rgba(0,0,0,.4);
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all .35s var(--ease);
  z-index: 9999;
  max-width: 320px;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { background: #0f2a1e; border: 1px solid rgba(52,211,153,.25); color: var(--green); }
.toast.error   { background: #2a0f0f; border: 1px solid rgba(248,113,113,.25); color: var(--red); }
.toast.info    { background: var(--bg-3); border: 1px solid var(--border-h); color: var(--teal); }

/* ===== CONFIRM MODAL ===== */
.confirm-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.7);
  display: flex; align-items: center; justify-content: center;
  z-index: 9000;
  opacity: 0; pointer-events: none;
  transition: opacity .3s;
}
.confirm-overlay.show { opacity: 1; pointer-events: all; }
.confirm-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 36px 32px;
  max-width: 400px;
  text-align: center;
  box-shadow: 0 24px 80px rgba(0,0,0,.5);
  transform: scale(.95);
  transition: transform .3s var(--ease);
}
.confirm-overlay.show .confirm-card { transform: scale(1); }
.confirm-icon { font-size: 2.5rem; color: var(--gold); margin-bottom: 16px; }
.confirm-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; }
.confirm-card p { font-size: .82rem; color: var(--text-2); line-height: 1.6; margin-bottom: 24px; }
.confirm-actions { display: flex; gap: 12px; justify-content: center; }
.confirm-cancel {
  padding: 9px 22px; border-radius: 8px;
  font-size: .82rem; font-weight: 600;
  color: var(--text-2); border: 1px solid var(--border);
  transition: all .2s;
}
.confirm-cancel:hover { color: var(--text); border-color: var(--border-h); background: var(--bg-3); }
.confirm-ok {
  padding: 9px 22px; border-radius: 8px;
  font-size: .82rem; font-weight: 600;
  background: var(--red);
  color: white;
  border: none;
  transition: all .2s;
}
.confirm-ok:hover { background: #ef4444; box-shadow: 0 4px 16px rgba(248,113,113,.3); }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .admin-sidebar { position: fixed; top: 0; left: 0; bottom: 0; transform: translateX(-100%); }
  .admin-sidebar.mobile-open { transform: translateX(0); }
  .admin-main { width: 100%; }
  .topbar-actions .btn-import span,
  .topbar-actions .btn-export span,
  .topbar-actions .btn-view span { display: none; }
  .field-row, .field-row-3 { grid-template-columns: 1fr; }
  .admin-content { padding: 16px 16px 60px; }
}

/* ===== SCREENSHOT UPLOAD ZONE ===== */
.screenshot-upload-group {
  border-top: 1px solid var(--border);
  margin-top: 20px;
  padding-top: 20px;
}

.screenshot-zone {
  width: 100%;
  border: 2px dashed rgba(0,212,200,.25);
  border-radius: 12px;
  background: var(--bg-2);
  cursor: pointer;
  transition: border-color .2s, background .2s;
  overflow: hidden;
  position: relative;
}
.screenshot-zone:hover {
  border-color: var(--teal);
  background: rgba(0,212,200,.04);
}

/* Empty state */
.scz-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 40px 24px;
  pointer-events: none;
}
.scz-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: rgba(0,212,200,.1);
  color: var(--teal);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 4px;
}
.scz-text {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-2);
}
.scz-hint {
  font-size: .72rem;
  color: var(--text-3);
}

/* Preview state */
.scz-preview {
  position: relative;
  width: 100%;
  pointer-events: none;
}
.scz-preview img {
  width: 100%;
  max-height: 240px;
  object-fit: cover;
  object-position: top;
  display: block;
  border-radius: 0;
  border: none;
}
.scz-overlay {
  position: absolute;
  inset: 0;
  background: rgba(5,15,15,.65);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--teal);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .04em;
  opacity: 0;
  transition: opacity .22s ease;
  border-radius: 0;
}
.screenshot-zone:hover .scz-overlay {
  opacity: 1;
}

/* Clear / remove button */
.scz-clear-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  padding: 7px 14px;
  border-radius: 7px;
  font-size: .75rem;
  font-weight: 600;
  background: rgba(248,113,113,.1);
  color: var(--red);
  border: 1px solid rgba(248,113,113,.2);
  cursor: pointer;
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.scz-clear-btn:hover {
  background: rgba(248,113,113,.18);
  border-color: rgba(248,113,113,.4);
  box-shadow: 0 2px 12px rgba(248,113,113,.15);
}

/* Size badge shown in preview bar */
.scz-size-badge {
  position: absolute;
  top: 8px; right: 8px;
  padding: 2px 8px;
  border-radius: 99px;
  background: rgba(0,0,0,.55);
  font-size: .65rem;
  color: var(--text-2);
  pointer-events: none;
}

/* ===== FILE PROTOCOL WARNING ===== */
.protocol-warning {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(201, 162, 39, 0.08);
  border: 1px solid rgba(201, 162, 39, 0.2);
  border-radius: 12px;
  padding: 14px 20px;
  margin: 20px 24px 0;
  color: #fce285;
  font-size: .84rem;
  line-height: 1.6;
}
.protocol-warning strong {
  color: var(--gold);
}
.protocol-warning code {
  font-family: var(--mono);
  background: rgba(0,0,0,.2);
  padding: 2px 5px;
  border-radius: 4px;
}
.protocol-warning a {
  color: var(--teal);
  text-decoration: underline;
  transition: color .2s;
}
.protocol-warning a:hover {
  color: #fff;
}
.pw-icon {
  font-size: 1.3rem;
  color: var(--gold);
  display: flex;
  align-items: center;
}

/* ===== SECURE LOGIN OVERLAY ===== */
.login-overlay {
  position: fixed;
  inset: 0;
  background: rgba(8, 17, 17, 0.91);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}
.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 44px 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.6);
  text-align: center;
}
.login-logo {
  font-family: var(--head);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 24px;
  letter-spacing: .05em;
}
.login-logo span {
  color: var(--gold);
  font-size: 0.95rem;
  font-weight: 600;
  vertical-align: top;
  margin-left: 4px;
  border: 1px solid var(--gold);
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0;
}
.login-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.login-card p {
  font-size: .8rem;
  color: var(--text-2);
  margin-bottom: 28px;
  line-height: 1.5;
}
.login-group {
  text-align: left;
  margin-bottom: 20px;
}
.login-group label {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-2);
  margin-bottom: 8px;
  font-weight: 600;
}
.login-group .input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.login-group .input-wrapper i {
  position: absolute;
  left: 14px;
  color: var(--text-3);
  font-size: 0.9rem;
}
.login-group input {
  width: 100%;
  padding: 12px 14px 12px 40px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.login-group input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 10px rgba(201, 162, 39, 0.15);
}
.login-error {
  color: #f43f5e;
  font-size: 0.8rem;
  margin-bottom: 20px;
  text-align: left;
  min-height: 18px;
  font-weight: 500;
}
.btn-auth-submit {
  width: 100%;
  padding: 13px;
  background: var(--gold);
  color: #0d1f1f;
  font-weight: 700;
  font-size: 0.9rem;
  border: none;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.btn-auth-submit:hover {
  background: #e8be3a;
}
.btn-auth-submit:active {
  transform: scale(0.98);
}

/* Autofill Premium Overrides */
.login-group input:-webkit-autofill,
.login-group input:-webkit-autofill:hover, 
.login-group input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--text) !important;
  -webkit-box-shadow: 0 0 0px 1000px #091717 inset !important;
  transition: background-color 5000s ease-in-out 0s;
}
.btn-logout {
  padding: 8px 16px;
  background: rgba(244, 63, 94, 0.1);
  color: #f43f5e;
  border: 1px solid rgba(244, 63, 94, 0.2);
  border-radius: 8px;
  font-size: .8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-logout:hover {
  background: #f43f5e;
  color: white;
  border-color: #f43f5e;
}


