/* ============================================================
   FaceMatch Pro Enterprise v2.1 - COGNITIO Biometric Theme
   Official Cognitio Brand Palette (Radiant Gold & Deep Navy)
   Clean, High-Contrast Executive Security Command Center UI
   ============================================================ */

:root {
  /* Background Palette (Deep Obsidian Navy) */
  --bg-main: #070c16;
  --bg-surface: #0c1424;
  --bg-card: #101a2e;
  --bg-card-inner: #090f1c;
  --bg-input: #080d18;
  --bg-glass: rgba(12, 20, 36, 0.92);
  
  --border-subtle: #1c2b44;
  --border-card: #203352;
  --border-active: #ea9d31;
  --border-focus: rgba(234, 157, 49, 0.5);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-subtle: #475569;

  /* Official Cognitio Brand Accents */
  --cognitio-gold: #ea9d31;
  --cognitio-gold-light: #fbbf24;
  --cognitio-gold-dark: #d97706;
  --cognitio-gold-glow: rgba(234, 157, 49, 0.4);

  --cognitio-navy: #1e3a8a;
  --cognitio-navy-dark: #0f1d38;
  --cognitio-blue: #2563eb;
  --cognitio-blue-glow: rgba(37, 99, 235, 0.35);

  --primary-blue: #2563eb;
  --primary-blue-hover: #1d4ed8;
  --primary-glow: var(--cognitio-gold-glow);

  /* Biometric Verdict Accents */
  --accent-pass: #10b981;
  --accent-pass-dark: #064e3b;
  --accent-pass-text: #6ee7b7;
  --accent-pass-glow: rgba(16, 185, 129, 0.25);

  --accent-fail: #ef4444;
  --accent-fail-dark: #7f1d1d;
  --accent-fail-text: #fca5a5;
  --accent-fail-glow: rgba(239, 68, 68, 0.25);

  --accent-warn: #f59e0b;
  --accent-warn-dark: #78350f;
  --accent-warn-text: #fcd34d;

  --accent-azure: #0284c7;
  --accent-azure-glow: rgba(2, 132, 199, 0.25);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 18px;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --shadow-card: 0 4px 20px -2px rgba(0, 0, 0, 0.5), 0 0 0 1px var(--border-card);
  --shadow-active: 0 0 25px var(--cognitio-gold-glow);
}

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

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ------------------------------------------------------------
   TOP HEADER NAVIGATION BAR
   ------------------------------------------------------------ */
.header {
  background: var(--bg-glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 0.65rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 0.95rem;
  min-width: 290px;
}

/* Official Cognitio Logo Wrap */
.brand-logo-wrap {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
}

.brand-logo-img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(234, 157, 49, 0.5));
  transition: transform 0.3s ease;
}

.brand-logo-img:hover {
  transform: scale(1.06) rotate(2deg);
}

.brand-titles {
  display: flex;
  flex-direction: column;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  background: linear-gradient(90deg, #ffffff 15%, #fbbf24 60%, #ea9d31 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-pill {
  font-size: 0.65rem;
  font-weight: 800;
  background: linear-gradient(135deg, #d97706, #ea9d31);
  color: #0b111c;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-sm);
  letter-spacing: 0.05em;
  box-shadow: 0 0 10px var(--cognitio-gold-glow);
}

.brand-subtitle {
  font-size: 0.75rem;
  color: var(--text-secondary);
  white-space: nowrap;
}

.brand-subtitle strong, .brand-subtitle span {
  color: var(--cognitio-gold-light);
  font-weight: 700;
}

/* Nav Tabs */
.nav-tabs {
  display: flex;
  gap: 0.4rem;
  background: var(--bg-card-inner);
  padding: 0.3rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
}

.nav-tab {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 0.5rem 0.95rem;
  font-size: 0.825rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-family: inherit;
  outline: none;
}

.nav-tab svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
  transition: transform 0.2s ease;
}

.nav-tab:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.nav-tab.active {
  color: #ffffff;
  background: linear-gradient(135deg, #1b3a6b 0%, #2563eb 100%);
  box-shadow: 0 2px 14px rgba(234, 157, 49, 0.3);
  border-bottom: 2px solid var(--cognitio-gold);
}

.nav-tab.active svg {
  transform: scale(1.1);
  color: var(--cognitio-gold-light);
}

/* Header Right Badges */
.header-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
}

.badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  border: 1px solid transparent;
}

.badge-thresh {
  background: #141f33;
  color: var(--cognitio-gold-light);
  border-color: rgba(234, 157, 49, 0.35);
}

.badge-thresh strong {
  color: #ffffff;
}

.badge-engine {
  background: rgba(6, 78, 59, 0.5);
  color: #6ee7b7;
  border-color: #047857;
}

.badge-azure {
  background: rgba(2, 132, 199, 0.15);
  color: #38bdf8;
  border-color: rgba(2, 132, 199, 0.4);
}

.pulse-dot {
  width: 7px;
  height: 7px;
  background-color: var(--accent-pass);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-pass);
  animation: pulse-ring 2s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

@keyframes pulse-ring {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* ------------------------------------------------------------
   MAIN CONTAINER & TABS SYSTEM
   ------------------------------------------------------------ */
.main-container {
  flex: 1;
  max-width: 1540px;
  width: 100%;
  margin: 0 auto;
  padding: 1.25rem 1.5rem 5rem 1.5rem;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.25s ease-in-out;
}

.tab-pane.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Card Styling */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-card);
  padding: 1.25rem;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.card-header-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card-header-title .icon {
  font-size: 1.1rem;
}

.sub-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  background: rgba(234, 157, 49, 0.15);
  color: var(--cognitio-gold-light);
  border: 1px solid rgba(234, 157, 49, 0.35);
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sub-badge-live {
  background: rgba(16, 185, 129, 0.15);
  color: #6ee7b7;
  border-color: rgba(16, 185, 129, 0.3);
}

.sub-badge-azure {
  background: rgba(2, 132, 199, 0.15);
  color: #38bdf8;
  border-color: rgba(2, 132, 199, 0.3);
}

/* ------------------------------------------------------------
   TAB 1: 1-to-1 SINGLE MATCH (3-COLUMN ERGONOMIC GRID)
   ------------------------------------------------------------ */
.single-grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr 1fr;
  gap: 1.15rem;
  align-items: start;
}

/* Slot Card & Selection Ring (Cognitio Gold Accent) */
.slot-card {
  position: relative;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  cursor: default;
}

.slot-card.active-target {
  border-color: var(--cognitio-gold);
  box-shadow: 0 0 24px var(--cognitio-gold-glow), var(--shadow-card);
}

/* Viewport Box (Image Dropzone) */
.viewport-box {
  background: var(--bg-card-inner);
  border: 1.5px dashed var(--border-subtle);
  border-radius: var(--radius-md);
  height: 310px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.viewport-box:hover {
  border-color: var(--cognitio-gold);
  background: rgba(234, 157, 49, 0.04);
}

.viewport-box.dragover {
  border-color: var(--cognitio-gold-light);
  background: rgba(234, 157, 49, 0.1);
  border-style: solid;
}

.hidden-input {
  display: none;
}

.viewport-placeholder {
  text-align: center;
  padding: 1.5rem;
  pointer-events: none;
}

.viewport-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 0.75rem auto;
  border-radius: 50%;
  background: rgba(234, 157, 49, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cognitio-gold);
  border: 1px solid rgba(234, 157, 49, 0.2);
}

.viewport-icon svg {
  width: 26px;
  height: 26px;
}

.viewport-primary-text {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.viewport-sub-text {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
}

.viewport-sub-text strong {
  color: var(--cognitio-gold-light);
}

.viewport-tag {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.preview-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #05080e;
}

.preview-layer img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

/* Status Line */
.slot-status {
  margin: 0.65rem 0 0.5rem 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--text-muted);
}

.slot-status.detected .status-indicator {
  background-color: var(--accent-pass);
  box-shadow: 0 0 8px var(--accent-pass);
}

.slot-status.detected {
  color: #a7f3d0;
}

.slot-status.noface .status-indicator {
  background-color: var(--accent-fail);
}

.slot-status.noface {
  color: #fca5a5;
}

/* Quality Assessment Card */
.quality-card {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.85rem;
}

.quality-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}

.quality-score-badge {
  font-size: 0.65rem;
  padding: 0.1rem 0.4rem;
  border-radius: var(--radius-sm);
  background: #141f33;
  color: #94a3b8;
}

.quality-score-badge.good {
  background: var(--accent-pass-dark);
  color: #6ee7b7;
}

.quality-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.4rem;
  text-align: center;
}

.qual-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  padding: 0.35rem 0.2rem;
  border-radius: var(--radius-sm);
}

.qual-label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-muted);
}

.qual-val {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--cognitio-gold-light);
  font-family: var(--font-mono);
}

/* Slot Action Buttons */
.slot-actions {
  display: flex;
  gap: 0.45rem;
}

/* ------------------------------------------------------------
   CENTER VERDICT HUB CARD
   ------------------------------------------------------------ */
.verdict-hub-card {
  background: var(--bg-card);
  border-color: #273956;
  box-shadow: 0 8px 30px -4px rgba(0, 0, 0, 0.7), 0 0 0 1px #273956;
  display: flex;
  flex-direction: column;
}

.verdict-header {
  text-align: center;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(234, 157, 49, 0.15);
}

.verdict-header-title {
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--cognitio-gold-light);
}

.verdict-header-sub {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

/* Gauge Score Card */
.gauge-card {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1rem 0.75rem 0.85rem 0.75rem;
  margin-bottom: 0.85rem;
  text-align: center;
}

.gauge-svg-wrap {
  position: relative;
  width: 150px;
  height: 150px;
  margin: 0 auto;
}

.radial-gauge {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.gauge-track {
  fill: none;
  stroke: #16243b;
  stroke-width: 10;
}

.gauge-bar {
  fill: none;
  stroke: var(--cognitio-gold);
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 440;
  stroke-dashoffset: 440;
  transition: stroke-dashoffset 0.8s cubic-bezier(0.4, 0, 0.2, 1), stroke 0.4s ease;
}

.gauge-center-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  width: 100%;
}

.gauge-pct {
  font-size: 1.85rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--text-primary);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.gauge-caption {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--cognitio-gold-light);
  letter-spacing: 0.08em;
  margin-top: 0.2rem;
}

/* Linear Bar */
.linear-bar-wrap {
  width: 90%;
  height: 6px;
  background: #16243b;
  border-radius: 999px;
  margin: 0.75rem auto 0 auto;
  overflow: hidden;
}

.linear-bar {
  width: 0%;
  height: 100%;
  background: var(--cognitio-gold);
  border-radius: 999px;
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.4s ease;
}

/* Verdict Badge Box */
.verdict-badge-box {
  background: #141f33;
  border: 1px solid #273956;
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-bottom: 0.85rem;
  transition: all 0.3s ease;
}

.verdict-icon {
  font-size: 1.15rem;
}

.verdict-label {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

/* Verdict States */
.verdict-badge-box.verdict-pass {
  background: var(--accent-pass-dark);
  border-color: #059669;
  box-shadow: 0 0 20px var(--accent-pass-glow);
}
.verdict-badge-box.verdict-pass .verdict-label {
  color: #6ee7b7;
}

.verdict-badge-box.verdict-fail {
  background: var(--accent-fail-dark);
  border-color: #dc2626;
  box-shadow: 0 0 20px var(--accent-fail-glow);
}
.verdict-badge-box.verdict-fail .verdict-label {
  color: #fca5a5;
}

.verdict-badge-box.verdict-warn {
  background: var(--accent-warn-dark);
  border-color: #d97706;
}
.verdict-badge-box.verdict-warn .verdict-label {
  color: #fcd34d;
}

/* Candidate Input Box */
.candidate-input-box {
  margin-bottom: 0.85rem;
}

.input-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.35rem;
}

.input-with-clear {
  position: relative;
  display: flex;
  align-items: center;
}

.form-input {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.85rem;
  padding: 0.55rem 0.75rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  font-family: inherit;
}

.form-input:focus {
  border-color: var(--cognitio-gold);
  box-shadow: 0 0 0 2px var(--border-focus);
}

.btn-input-clear {
  position: absolute;
  right: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0 0.25rem;
}

.btn-input-clear:hover {
  color: var(--cognitio-gold-light);
}

/* Primary Match Button (Cognitio Gold Gradient) */
.btn-match {
  width: 100%;
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  background: linear-gradient(135deg, #d97706 0%, #ea9d31 50%, #f59e0b 100%);
  color: #070c14;
  border-radius: var(--radius-md);
  margin-bottom: 0.85rem;
  box-shadow: 0 4px 18px var(--cognitio-gold-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.25s ease;
}

.btn-match:hover:not(:disabled) {
  background: linear-gradient(135deg, #ea9d31 0%, #fbbf24 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(234, 157, 49, 0.55);
}

.btn-match:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* Deep Audit Breakdown Box */
.audit-box {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.85rem;
}

.audit-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.45rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.audit-badge {
  font-size: 0.65rem;
  color: var(--cognitio-gold-light);
  font-weight: 700;
}

.audit-grid {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.audit-item {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
}

.audit-key {
  color: var(--text-secondary);
}

.audit-val {
  font-weight: 600;
  color: var(--cognitio-gold-light);
  font-family: var(--font-mono);
}

/* Export Section */
.export-section {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.export-radios {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 0.25rem;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.radio-label input {
  accent-color: var(--cognitio-gold);
  cursor: pointer;
}

.btn-export {
  width: 100%;
  padding: 0.65rem 1rem;
  font-size: 0.825rem;
  font-weight: 700;
  background: linear-gradient(135deg, #1b3a6b 0%, #2563eb 100%);
  color: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid #3b82f6;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.btn-export:hover:not(:disabled) {
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  box-shadow: 0 4px 15px rgba(37, 99, 235, 0.4);
}

.btn-export:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  border-color: #273956;
}

.btn-view-report {
  width: 100%;
  padding: 0.5rem 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--bg-card-inner);
  color: var(--cognitio-gold-light);
  border: 1px solid var(--cognitio-gold-dark);
  border-radius: var(--radius-md);
  text-align: center;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.btn-view-report:hover {
  background: #141f33;
  color: #ffffff;
}

.btn-reset {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.75rem;
  padding: 0.4rem;
  cursor: pointer;
  text-align: center;
  transition: color 0.2s ease;
}

.btn-reset:hover {
  color: var(--cognitio-gold-light);
}

/* ------------------------------------------------------------
   BUTTON UTILITIES
   ------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  border: none;
  outline: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.btn svg {
  width: 16px;
  height: 16px;
}

.btn-primary {
  background: linear-gradient(135deg, #d97706 0%, #ea9d31 100%);
  color: #070c14;
  font-weight: 700;
  padding: 0.55rem 1rem;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #ea9d31 0%, #fbbf24 100%);
}

.btn-secondary {
  background: #141f33;
  color: var(--text-primary);
  border: 1px solid #273956;
  padding: 0.55rem 0.85rem;
  font-size: 0.8rem;
  flex: 1;
}

.btn-secondary:hover {
  background: #1c2b44;
  border-color: #3b5278;
}

.btn-camera {
  background: #065f46;
  color: #a7f3d0;
  border: 1px solid #047857;
  padding: 0.55rem 0.85rem;
  font-size: 0.8rem;
  flex: 1;
}

.btn-camera:hover {
  background: #047857;
  color: #ffffff;
}

.btn-icon {
  width: 36px;
  height: 36px;
  padding: 0;
  flex-shrink: 0;
}

.btn-clear {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid #1c2b44;
  font-size: 0.9rem;
}

.btn-clear:hover {
  background: #141f33;
  color: #ffffff;
}

.btn-success {
  background: #059669;
  color: #ffffff;
  padding: 0.6rem 1.15rem;
}
.btn-success:hover {
  background: #047857;
}

.btn-danger {
  background: #dc2626;
  color: #ffffff;
  padding: 0.6rem 1.15rem;
}
.btn-danger:hover {
  background: #b91c1c;
}

.btn-sm {
  font-size: 0.75rem;
  padding: 0.35rem 0.65rem;
}

/* ------------------------------------------------------------
   TAB 2: BATCH FOLDER PROCESS
   ------------------------------------------------------------ */
.batch-config-card {
  margin-bottom: 1.15rem;
}

.mode-switcher {
  display: flex;
  gap: 0.35rem;
  background: var(--bg-card-inner);
  padding: 0.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.mode-pill {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
}

.mode-pill input {
  display: none;
}

.mode-pill.active {
  background: #141f33;
  color: var(--cognitio-gold-light);
  border: 1px solid rgba(234, 157, 49, 0.3);
}

.batch-mode-content {
  display: none;
  padding: 0.5rem 0;
}

.batch-mode-content.active {
  display: block;
}

.batch-inputs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.15rem;
}

.form-group {
  margin-bottom: 0.75rem;
}

.form-group .req {
  color: var(--accent-fail);
}

.file-drop-box {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
}

.file-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
}

.file-selection-badge {
  margin-top: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--cognitio-gold-light);
  background: rgba(234, 157, 49, 0.15);
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
}

/* Batch Control Strip */
.batch-ctrl-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.825rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.checkbox-label input {
  accent-color: var(--cognitio-gold);
  width: 16px;
  height: 16px;
}

.batch-btn-group {
  display: flex;
  gap: 0.6rem;
}

.btn-start {
  padding: 0.65rem 1.4rem;
  font-size: 0.875rem;
  font-weight: 800;
  background: linear-gradient(135deg, #d97706 0%, #ea9d31 100%);
  color: #070c14;
  box-shadow: 0 4px 15px var(--cognitio-gold-glow);
  gap: 0.5rem;
}

.btn-start:hover:not(:disabled) {
  background: linear-gradient(135deg, #ea9d31 0%, #fbbf24 100%);
}

.btn-stop {
  padding: 0.65rem 1.15rem;
  font-size: 0.875rem;
  font-weight: 700;
  gap: 0.45rem;
}

.btn-stop:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Executive KPI Dashboard */
.kpi-dashboard {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.85rem;
  margin-bottom: 1.15rem;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.kpi-card-header {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.kpi-card-num {
  font-size: 1.75rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--text-primary);
  line-height: 1.2;
}

.kpi-card-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
}

.bar-total { background: var(--cognitio-gold); }
.bar-pass  { background: var(--accent-pass); }
.bar-fail  { background: var(--accent-fail); }
.bar-skip  { background: var(--accent-warn); }
.bar-rate  { background: var(--cognitio-gold-light); }

.kpi-total .kpi-card-num { color: var(--cognitio-gold-light); }
.kpi-pass .kpi-card-num  { color: #34d399; }
.kpi-fail .kpi-card-num  { color: #f87171; }
.kpi-skip .kpi-card-num  { color: #fbbf24; }
.kpi-rate .kpi-card-num  { color: var(--cognitio-gold); }

/* Real-Time Progress Card */
.batch-progress-card {
  margin-bottom: 1.15rem;
}

.progress-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.progress-status-msg {
  font-size: 0.825rem;
  font-weight: 500;
  color: var(--cognitio-gold-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.progress-pct-num {
  font-size: 0.95rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: #ffffff;
}

.progress-track {
  width: 100%;
  height: 8px;
  background: var(--bg-card-inner);
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.progress-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #d97706, #ea9d31, #fbbf24);
  border-radius: 999px;
  transition: width 0.25s ease;
}

/* Download Actions Bar */
.batch-downloads-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.downloads-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: #a7f3d0;
}

.downloads-btns {
  display: flex;
  gap: 0.6rem;
}

/* Filter & Search Bar */
.batch-table-card {
  padding: 1rem;
}

.table-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.85rem;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.filter-pills {
  display: flex;
  gap: 0.35rem;
}

.filter-pill {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.7rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-pill:hover {
  background: #141f33;
  color: #ffffff;
}

.filter-pill.active {
  background: linear-gradient(135deg, #1b3a6b, #2563eb);
  color: #ffffff;
  border-color: var(--cognitio-gold);
}

.filter-pill.pill-pass.active {
  background: var(--accent-pass-dark);
  border-color: #059669;
  color: #6ee7b7;
}

.filter-pill.pill-fail.active {
  background: var(--accent-fail-dark);
  border-color: #dc2626;
  color: #fca5a5;
}

.filter-pill.pill-skip.active {
  background: var(--accent-warn-dark);
  border-color: #d97706;
  color: #fcd34d;
}

.search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.search-wrap svg {
  position: absolute;
  left: 10px;
  width: 15px;
  height: 15px;
  color: var(--text-muted);
}

.search-input {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.8rem;
  padding: 0.45rem 0.75rem 0.45rem 2.1rem;
  width: 240px;
  outline: none;
}

.search-input:focus {
  border-color: var(--cognitio-gold);
}

/* Interactive Data Table */
.table-responsive {
  max-height: 480px;
  overflow-y: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-card-inner);
}

.batch-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.825rem;
  text-align: left;
}

.batch-data-table thead th {
  background: #0d1526;
  color: var(--cognitio-gold-light);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 10;
}

.batch-data-table tbody td {
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  vertical-align: middle;
}

.batch-data-table tbody tr:hover {
  background: rgba(234, 157, 49, 0.04);
}

.table-empty-hint {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--text-muted);
}

.table-empty-hint svg {
  width: 40px;
  height: 40px;
  margin-bottom: 0.5rem;
  color: var(--text-subtle);
}

/* Status Tags in Table */
.status-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  text-align: center;
}

.status-tag.tag-pass {
  background: rgba(16, 185, 129, 0.15);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-tag.tag-fail {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-tag.tag-warn {
  background: rgba(245, 158, 11, 0.15);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* ------------------------------------------------------------
   TAB 3: SYSTEM SETTINGS
   ------------------------------------------------------------ */
.settings-wrap {
  max-width: 800px;
  margin: 0 auto;
}

.settings-card {
  padding: 1.5rem;
}

.input-help {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  line-height: 1.4;
}

.slider-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.highlight-val {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--cognitio-gold-light);
  font-family: var(--font-mono);
}

.threshold-presets {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.btn-preset {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-preset:hover {
  background: #141f33;
  color: #ffffff;
}

.btn-preset.active {
  background: #141f33;
  border-color: var(--cognitio-gold);
  color: var(--cognitio-gold-light);
}

.slider-control-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.slider-limit {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.styled-slider {
  flex: 1;
  accent-color: var(--cognitio-gold);
  height: 6px;
  cursor: pointer;
}

.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 0.5rem 0;
}

.switch-label-wrap {
  display: flex;
  flex-direction: column;
}

.switch-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.switch-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.custom-switch {
  width: 20px;
  height: 20px;
  accent-color: var(--cognitio-gold);
  cursor: pointer;
}

.settings-btn-row {
  margin-top: 1.5rem;
  display: flex;
  justify-content: flex-end;
}

.btn-save-settings {
  padding: 0.65rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 700;
  gap: 0.5rem;
}

/* ------------------------------------------------------------
   TAB 4: AZURE CLOUD & REST API
   ------------------------------------------------------------ */
.azure-api-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.15rem;
  align-items: start;
}

.azure-intro {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.steps-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.step-item {
  display: flex;
  gap: 0.85rem;
}

.step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cognitio-gold);
  color: #070c14;
  font-weight: 800;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-content {
  flex: 1;
}

.step-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.25rem;
}

.step-desc {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 0.45rem;
}

.code-block {
  background: #060a12;
  border: 1px solid #16243b;
  border-radius: var(--radius-sm);
  padding: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #93c5fd;
  overflow-x: auto;
  line-height: 1.5;
}

.code-header {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin: 0.75rem 0 0.35rem 0;
}

.api-endpoint-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.75rem;
  margin-bottom: 0.5rem;
}

.method-post {
  background: var(--cognitio-gold);
  color: #070c14;
  font-weight: 800;
  font-size: 0.68rem;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-sm);
}

.endpoint-desc {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ------------------------------------------------------------
   WEBCAM MODAL
   ------------------------------------------------------------ */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(3, 7, 18, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-overlay.open {
  display: flex;
}

.modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width: 100%;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
  animation: modalScale 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalScale {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-title {
  font-size: 0.95rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--cognitio-gold-light);
}

.modal-title svg {
  width: 18px;
  height: 18px;
  color: var(--cognitio-gold);
}

.btn-close-modal {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.4rem;
  cursor: pointer;
}

.btn-close-modal:hover {
  color: var(--text-primary);
}

.camera-viewport-wrap {
  position: relative;
  width: 100%;
  height: 400px;
  background: #000000;
  overflow: hidden;
}

#camera-video-elem {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
}

/* Biometric Oval Guide */
.biometric-oval-guide {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 220px;
  height: 290px;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 1.5rem;
}

.oval-border {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 2px dashed rgba(234, 157, 49, 0.85);
  border-radius: 50% / 60% 60% 40% 40%;
  box-shadow: 0 0 25px rgba(234, 157, 49, 0.3);
  animation: pulse-border 2s infinite ease-in-out;
}

@keyframes pulse-border {
  0%, 100% { border-color: rgba(234, 157, 49, 0.9); }
  50% { border-color: rgba(37, 99, 235, 0.9); }
}

.oval-instruction {
  background: rgba(12, 20, 36, 0.9);
  color: var(--cognitio-gold-light);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(234, 157, 49, 0.4);
  letter-spacing: 0.03em;
  z-index: 2;
}

.modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 1.25rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-card-inner);
}

.btn-capture {
  padding: 0.65rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 700;
  background: linear-gradient(135deg, #d97706, #ea9d31);
  color: #070c14;
  gap: 0.5rem;
}

.btn-capture:hover {
  background: linear-gradient(135deg, #ea9d31, #fbbf24);
}

/* ------------------------------------------------------------
   BOTTOM SYSTEM STATUSBAR & COLLAPSIBLE ACTIVITY CONSOLE
   ------------------------------------------------------------ */
.system-statusbar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #060a12;
  border-top: 1px solid var(--border-subtle);
  z-index: 90;
}

.statusbar-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 1.5rem;
  font-size: 0.75rem;
}

.statusbar-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
}

.status-dot-emerald {
  color: var(--accent-pass);
  font-size: 0.85rem;
}

.statusbar-center {
  flex: 1;
  text-align: center;
  color: var(--cognitio-gold-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 1rem;
}

.statusbar-right {
  display: flex;
  align-items: center;
}

.btn-toggle-logs {
  background: transparent;
  border: 1px solid #16243b;
  color: var(--text-secondary);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.btn-toggle-logs:hover {
  background: #141f33;
  color: var(--text-primary);
}

.logs-drawer {
  display: none;
  max-height: 140px;
  background: #04070e;
  border-top: 1px solid #16243b;
  padding: 0.65rem 1.5rem;
  overflow-y: auto;
}

.logs-drawer.open {
  display: block;
}

.logs-console {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.log-entry {
  color: #94a3b8;
}

.log-entry .log-time {
  color: #64748b;
  margin-right: 0.4rem;
}

.log-entry-pass { color: #6ee7b7; }
.log-entry-fail { color: #fca5a5; }
.log-entry-sys  { color: var(--cognitio-gold-light); }

/* ------------------------------------------------------------
   TOAST NOTIFICATION SYSTEM
   ------------------------------------------------------------ */
.toast-container {
  position: fixed;
  bottom: 45px;
  right: 20px;
  z-index: 1100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 0.75rem 1.15rem;
  font-size: 0.8rem;
  color: var(--text-primary);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  animation: toastIn 0.25s ease-out;
  pointer-events: auto;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.toast.toast-success {
  border-left: 4px solid var(--accent-pass);
}

.toast.toast-error {
  border-left: 4px solid var(--accent-fail);
}

.toast.toast-info {
  border-left: 4px solid var(--cognitio-gold);
}

/* ------------------------------------------------------------
   RESPONSIVE DESIGN (Tablets & Mobile)
   ------------------------------------------------------------ */
@media (max-width: 1200px) {
  .single-grid {
    grid-template-columns: 1fr;
  }
  .verdict-hub-card {
    order: 2;
  }
  #slot-card-1 {
    order: 1;
  }
  #slot-card-2 {
    order: 3;
  }
  .kpi-dashboard {
    grid-template-columns: repeat(3, 1fr);
  }
  .azure-api-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .header {
    flex-direction: column;
    align-items: stretch;
    padding: 0.75rem 1rem;
  }
  .header-left, .header-right {
    justify-content: space-between;
  }
  .nav-tabs {
    overflow-x: auto;
    padding: 0.25rem;
  }
  .nav-tab {
    padding: 0.45rem 0.65rem;
    font-size: 0.75rem;
    white-space: nowrap;
  }
  .kpi-dashboard {
    grid-template-columns: 1fr 1fr;
  }
  .batch-inputs-grid {
    grid-template-columns: 1fr;
  }
  .statusbar-center {
    display: none;
  }
}

/* ------------------------------------------------------------
   SECURITY PASSKEY & TERMINAL LOCK STYLES
   ------------------------------------------------------------ */
.btn-lock-terminal {
  background: rgba(234, 157, 49, 0.1);
  border: 1px solid rgba(234, 157, 49, 0.35);
  color: var(--cognitio-gold-light);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

.btn-lock-terminal:hover {
  background: rgba(234, 157, 49, 0.22);
  border-color: var(--cognitio-gold);
  transform: translateY(-1px);
}

.settings-security-box {
  background: var(--bg-card-inner);
  border: 1px solid rgba(234, 157, 49, 0.25);
  border-radius: var(--radius-md);
  padding: 1rem 1.15rem;
  margin: 1.25rem 0;
  box-shadow: inset 0 0 15px rgba(234, 157, 49, 0.04);
}

.security-box-header {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--cognitio-gold-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Fullscreen Auth Gate Overlay */
.auth-gate-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(4, 8, 16, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  animation: authFadeIn 0.3s ease-out;
}

@keyframes authFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.auth-gate-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-top: 3px solid var(--cognitio-gold);
  border-radius: var(--radius-xl);
  max-width: 440px;
  width: 100%;
  padding: 2.25rem 2rem;
  text-align: center;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.8), 0 0 35px rgba(234, 157, 49, 0.2);
  position: relative;
  overflow: hidden;
}

.auth-gate-card.shake {
  animation: shakeCard 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes shakeCard {
  10%, 90% { transform: translate3d(-2px, 0, 0); }
  20%, 80% { transform: translate3d(4px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-6px, 0, 0); }
  40%, 60% { transform: translate3d(6px, 0, 0); }
}

.auth-logo-wrap {
  width: 68px;
  height: 68px;
  margin: 0 auto 0.75rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-logo-img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  filter: drop-shadow(0 0 16px var(--cognitio-gold-glow));
}

.auth-brand-name {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  background: linear-gradient(90deg, #ffffff 15%, #fbbf24 60%, #ea9d31 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
}

.auth-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.auth-subtitle {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-bottom: 1.75rem;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.auth-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: left;
  margin-bottom: 0.45rem;
}

.auth-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.auth-key-icon {
  position: absolute;
  left: 12px;
  font-size: 1.1rem;
  pointer-events: none;
}

.auth-input {
  width: 100%;
  background: var(--bg-card-inner);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 0.95rem;
  padding: 0.75rem 2.85rem 0.75rem 2.75rem;
  outline: none;
  font-family: inherit;
  transition: all 0.2s ease;
}

.auth-input:focus {
  border-color: var(--cognitio-gold);
  box-shadow: 0 0 0 3px var(--border-focus);
}

.btn-toggle-pw {
  position: absolute;
  right: 10px;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 0.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.btn-toggle-pw:hover {
  color: var(--cognitio-gold-light);
  background: rgba(234, 157, 49, 0.1);
}

.eye-svg {
  width: 19px;
  height: 19px;
  pointer-events: none;
}

.input-with-actions {
  position: relative;
  display: flex;
  align-items: center;
}

.input-with-actions .form-input {
  padding-right: 175px;
}

.input-action-buttons {
  position: absolute;
  right: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-input-action {
  background: var(--bg-card-inner);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.76rem;
  font-weight: 600;
  padding: 0.3rem 0.65rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn-input-action:hover {
  border-color: var(--cognitio-gold);
  color: var(--cognitio-gold-light);
  background: rgba(234, 157, 49, 0.08);
}

.auth-error-msg {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-fail);
  text-align: left;
  margin-top: 0.45rem;
  min-height: 18px;
}

.btn-unlock {
  width: 100%;
  padding: 0.85rem;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  background: linear-gradient(135deg, #d97706 0%, #ea9d31 50%, #f59e0b 100%);
  color: #070c14;
  box-shadow: 0 4px 18px var(--cognitio-gold-glow);
}

.btn-unlock:hover {
  background: linear-gradient(135deg, #ea9d31 0%, #fbbf24 100%);
  box-shadow: 0 6px 24px rgba(234, 157, 49, 0.55);
}

.auth-card-footer {
  margin-top: 1.5rem;
  padding-top: 1.15rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: center;
}

.badge-offline {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--cognitio-gold-light);
}

.auth-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.auth-hint code {
  color: var(--cognitio-gold-light);
  background: rgba(234, 157, 49, 0.1);
  padding: 0.15rem 0.35rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
}
