/* ============================================================
   Smile Center — Ana Stil Dosyası
   Dark theme · Glassmorphism · Medikal-teknoloji estetik
   ============================================================ */

/* ── CSS Değişkenleri ──────────────────────────────────────── */
:root {
  --bg-base:        #050505;
  --bg-surface:     rgba(255, 255, 255, 0.02);
  --bg-card:        rgba(255, 255, 255, 0.02);
  --bg-card-hover:  rgba(255, 255, 255, 0.04);
  --bg-input:       rgba(255, 255, 255, 0.02);
  --bg-input-focus: rgba(59, 126, 255, 0.1);

  --border:         rgba(255, 255, 255, 0.05);
  --border-focus:   rgba(59, 126, 255, 0.4);
  --border-card:    rgba(255, 255, 255, 0.03);

  --text-primary:   #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.5);
  --text-muted:     rgba(255, 255, 255, 0.3);

  --blue:           #3b7eff;
  --blue-dark:      #2563eb;
  --blue-glow:      rgba(59,126,255,0.25);
  --indigo:         #6366f1;
  --purple:         #a855f7;
  --green:          #10b981;
  --teal:           #14b8a6;
  --amber:          #f59e0b;
  --orange:         #f97316;
  --red:            #ef4444;
  --red-dark:       #dc2626;

  --sidebar-width:  240px;
  --topbar-height:  60px;
  --radius-sm:      6px;
  --radius-md:      10px;
  --radius-lg:      16px;
  --radius-xl:      24px;

  --shadow-card:    0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow:    0 0 30px rgba(59,126,255,0.15);
  --transition:     all 0.2s ease;
}

/* ── Light Theme Overrides ─────────────────────────────────── */
[data-theme="light"] {
  --bg-base:        #ffffff; /* Açık gri yerine saf beyaz */
  --bg-surface:     #ffffff;
  --bg-card:        #ffffff;
  --bg-card-hover:  #f8fafc;
  --bg-input:       #ffffff;
  --bg-input-focus: #f1f5f9;

  --border:         #e2e8f0;
  --border-focus:   #3b7eff;
  --border-card:    #cbd5e1;

  --text-primary:   #0f172a;
  --text-secondary: #475569;
  --text-muted:     #94a3b8;

  --shadow-card:    0 4px 20px rgba(0,0,0,0.06);
  --shadow-glow:    0 0 20px rgba(59,126,255,0.2);
}

/* Light mode overrides for sidebar and top-bar to keep them dark navy */
[data-theme="light"] .sidebar,
[data-theme="light"] .top-bar {
  background: #0a0f1c;
  border-color: rgba(255,255,255,0.08);
}
[data-theme="light"] .sidebar .brand-main,
[data-theme="light"] .top-bar .page-heading { color: #e8edf7; }
[data-theme="light"] .sidebar .brand-sub,
[data-theme="light"] .sidebar .nav-item,
[data-theme="light"] .sidebar .user-chip-name { color: #8892b0; }
[data-theme="light"] .sidebar .nav-item:hover { background: rgba(255,255,255,0.07); color: #e8edf7; }
[data-theme="light"] .sidebar .nav-item.active { background: rgba(59,126,255,0.25); color: #3b7eff; }
[data-theme="light"] .sidebar .logout-btn { background: rgba(255,255,255,0.04); color: #8892b0; border-color: rgba(255,255,255,0.08); }
[data-theme="light"] .sidebar .logout-btn:hover { background: rgba(239,68,68,0.15); color: #ef4444; }

[data-theme="light"] .top-bar .sidebar-toggle,
[data-theme="light"] .top-bar #themeToggleBtn { color: #8892b0; }
[data-theme="light"] .top-bar #themeToggleBtn { background: rgba(255,255,255,0.04) !important; border-color: rgba(255,255,255,0.08) !important; }
[data-theme="light"] .top-bar #themeToggleBtn:hover,
[data-theme="light"] .top-bar .sidebar-toggle:hover { color: #e8edf7; background: rgba(255,255,255,0.07) !important; }

[data-theme="light"] .login-form-container {
  background: rgba(255,255,255,0.95);
}

/* Tema değiştirmelerde yumuşak geçiş için */
body, .login-brand-panel { transition: background-color 0.3s ease, color 0.3s ease, background 0.3s ease; }
.card, .sidebar, .top-bar { transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease; }


/* ── Reset & Base ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); text-decoration: none; transition: var(--transition); }
a:hover { color: #60a5fa; }

/* ── Scrollbar ─────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ── App Shell ─────────────────────────────────────────────── */
.app-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ── Draggable Dock (Navbar) ───────────────────────────────── */
@keyframes neon-breathe-drag {
  0% { 
    border-color: rgba(59, 126, 255, 0.8);
    box-shadow: 0 0 15px rgba(59, 126, 255, 0.5), 0 24px 60px rgba(0,0,0,0.4); 
  }
  50% { 
    border-color: rgba(0, 210, 255, 1);
    box-shadow: 0 0 35px rgba(0, 210, 255, 0.9), 0 24px 60px rgba(0,0,0,0.4); 
  }
  100% { 
    border-color: rgba(59, 126, 255, 0.8);
    box-shadow: 0 0 15px rgba(59, 126, 255, 0.5), 0 24px 60px rgba(0,0,0,0.4); 
  }
}

.dock-navbar {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #000000;
  border: 1px solid var(--border);
  box-shadow: 0 15px 40px rgba(0,0,0,0.35); /* Havada duruyor gölgesi */
  border-radius: 999px;
  display: flex;
  align-items: center;
  padding: 8px 12px 8px 8px;
  gap: 12px;
  z-index: 1000;
  backdrop-filter: blur(20px);
  user-select: none;
  transition: all 0.3s ease;
}

.dock-navbar.dragging {
  animation: neon-breathe-drag 1.2s infinite ease-in-out;
  transition: none; /* remove delay while dragging */
}

.dock-grip {
  color: var(--text-muted);
  cursor: grab;
  display: flex; align-items: center; justify-content: center;
  padding: 8px 4px; border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.dock-grip:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }
.dock-grip:active { cursor: grabbing; }

.dock-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--indigo));
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; color: #fff; flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(59,126,255,0.3);
}

.dock-logo .circle-logo-frame {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
}

.dock-divider { width: 1px; height: 24px; background: var(--border); }

.dock-nav { display: flex; align-items: center; gap: 4px; }
.dock-actions { display: flex; align-items: center; gap: 4px; }


  .dock-nav {
    display: flex; align-items: center; gap: 18px; padding-left: 10px; padding-right: 10px;
  }
  
  .nav-item {
    position: relative;
    background: linear-gradient(#2a2a2e 30%, #2a2a2e 30%, #1a1a1c);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 2px solid #333;
    transition: 0.3s;
    box-shadow: 0 4px 4px rgb(0 0 0 / 50%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    cursor: pointer;
    text-decoration: none;
    flex-shrink: 0;
    margin: 0;
  }

  .nav-item::before {
    content: "";
    width: 125%;
    height: 125%;
    background: #232325;
    box-shadow: 0 2px 2px inset #000;
    position: absolute;
    left: -12.5%;
    top: -12.5%;
    z-index: -1;
    border-radius: inherit;
    transition: 0.3s;
  }

  .nav-item:focus,
  .nav-item:hover,
  .nav-item.active {
    box-shadow:
      0 5px 3px rgb(0 0 0 / 50%),
      0 5px 20px rgba(2, 220, 89, 0.5);
    background: linear-gradient(0deg, #2a2a2e 30%, #2a2a2e 30%, #1a1a1c);
    color: #02dc59;
    border-color: rgba(2, 220, 89, 0.4);
  }

  .nav-item:focus::before,
  .nav-item:hover::before,
  .nav-item.active::before {
    box-shadow: 0 2px 2px inset #000;
  }

  .nav-item svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    z-index: 2;
    transition: 0.3s;
  }

  .nav-item span {
    position: absolute;
    top: 135%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.85);
    color: #fff;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transition: 0.2s;
    white-space: nowrap;
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    z-index: 1000;
  }

  .nav-item:hover span {
    opacity: 1;
    top: 125%;
  }
  
  .icon-btn {
  background: transparent; border: none; cursor: pointer;
  color: var(--text-secondary); display: flex; align-items: center; justify-content: center;
  padding: 8px; border-radius: 50%; transition: all 0.2s;
}
.icon-btn:hover { background: rgba(255,255,255,0.08); color: var(--text-primary); }

@keyframes pulse-dot {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

.badge-dot {
  position: absolute; top: 6px; right: 6px;
  width: 8px; height: 8px; background: var(--red);
  border-radius: 50%; border: 2px solid var(--bg-surface);
  animation: pulse-dot 2s infinite;
}

.logout-btn {
  color: var(--text-secondary); display: flex; align-items: center; justify-content: center;
  padding: 8px; border-radius: 50%; transition: all 0.2s;
}
.logout-btn:hover { background: rgba(239,68,68,0.15); color: var(--red); }

[data-theme="light"] .icon-btn { color: #8892b0; }
[data-theme="light"] .icon-btn:hover { background: rgba(255,255,255,0.08); color: #e8edf7; }
[data-theme="light"] .badge-dot { border-color: #0a0f1c; }
[data-theme="light"] .dock-navbar { background: #ffffff; border-color: rgba(255,255,255,0.08); }
[data-theme="light"] .dock-divider { background: rgba(255,255,255,0.08); }
[data-theme="light"] .dock-logo .circle-logo-frame { background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.1); }
[data-theme="light"] .nav-item { color: #8892b0; }
[data-theme="light"] .nav-item:hover { background: rgba(255,255,255,0.07); color: #e8edf7; }
[data-theme="light"] .nav-item.active { background: rgba(59,126,255,0.25); color: #3b7eff; }
[data-theme="light"] .dock-grip { color: #8892b0; }
[data-theme="light"] .dock-grip:hover { color: #fff; background: rgba(255,255,255,0.08); }

/* ── Main Area ─────────────────────────────────────────────── */
.main-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.page-heading { font-size: 16px; font-weight: 700; color: var(--text-primary); margin-bottom: 16px; }

.page-body { padding: 24px; flex: 1; }

/* ── Flash Messages ────────────────────────────────────────── */
.flash-container { padding: 0 24px; margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.flash {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 14px; font-weight: 500;
  animation: slideDown 0.3s ease;
}
.flash-success { background: rgba(16,185,129,0.15); border: 1px solid rgba(16,185,129,0.3); color: #34d399; }
.flash-error   { background: rgba(239,68,68,0.15);  border: 1px solid rgba(239,68,68,0.3);  color: #f87171; }
.flash-info    { background: rgba(59,126,255,0.15); border: 1px solid rgba(59,126,255,0.3); color: #60a5fa; }
.flash-warning { background: rgba(245,158,11,0.15); border: 1px solid rgba(245,158,11,0.3); color: #fbbf24; }
.flash-close { background: none; border: none; color: inherit; cursor: pointer; font-size: 18px; opacity: 0.7; }
.flash-close:hover { opacity: 1; }

@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

/* ── Role Badges ───────────────────────────────────────────── */
.role-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.role-clinic   { background: rgba(59,126,255,0.15); color: var(--blue); border: 1px solid rgba(59,126,255,0.3); }
.role-designer { background: rgba(168,85,247,0.15); color: var(--purple); border: 1px solid rgba(168,85,247,0.3); }
.role-admin    { background: rgba(245,158,11,0.15); color: var(--amber); border: 1px solid rgba(245,158,11,0.3); }

/* ── Cards ─────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  transition: var(--transition);
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}
.card-header h3 { font-size: 15px; font-weight: 700; }
.card-body { padding: 20px; }

/* ── Stats Grid ────────────────────────────────────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.stats-grid-6 { grid-template-columns: repeat(6, 1fr); }
.stats-grid-7 { grid-template-columns: repeat(7, 1fr); }

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  transition: var(--transition);
}
.stat-card:hover { border-color: var(--blue); box-shadow: var(--shadow-glow); }
.stat-card-sm { flex-direction: column; align-items: flex-start; gap: 8px; }
.stat-card-highlight { border-color: rgba(245,158,11,0.3); background: rgba(245,158,11,0.05); }

.stat-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.stat-icon svg { width: 20px; height: 20px; }
.stat-icon-blue   { background: rgba(59,126,255,0.15); color: var(--blue); }
.stat-icon-purple { background: rgba(168,85,247,0.15); color: var(--purple); }
.stat-icon-green  { background: rgba(16,185,129,0.15); color: var(--green); }
.stat-icon-amber  { background: rgba(245,158,11,0.15); color: var(--amber); }
.stat-icon-orange { background: rgba(249,115,22,0.15); color: var(--orange); }
.stat-icon-teal   { background: rgba(20,184,166,0.15); color: var(--teal); }

.stat-body { flex: 1; }
.stat-label { font-size: 12px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
.stat-value { font-size: 28px; font-weight: 800; color: var(--text-primary); line-height: 1; }
.stat-badge {
  position: absolute; top: 12px; right: 12px;
  background: var(--amber); color: #000;
  font-size: 10px; font-weight: 700;
  padding: 3px 8px; border-radius: 99px;
}

/* ── Section Header ────────────────────────────────────────── */
.section-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.section-title { font-size: 16px; font-weight: 700; }

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 18px;
  border-radius: var(--radius-md);
  font-size: 14px; font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary   { background: var(--blue); color: #fff; }
.btn-primary:hover   { background: var(--blue); transform: translateY(-2px); box-shadow: 0 0 20px rgba(59,126,255,0.8), 0 0 40px rgba(59,126,255,0.4); border-color: var(--blue); color: #fff; }

.btn-success   { background: var(--green); color: #fff; }
.btn-success:hover   { background: #059669; transform: translateY(-1px); color: #fff; }

.btn-ghost     { background: var(--bg-card); border-color: var(--border); color: var(--text-secondary); }
.btn-ghost:hover     { background: var(--bg-card-hover); color: var(--text-primary); }

.btn-danger    { border-color: rgba(239,68,68,0.4); }
.btn-danger:hover    { background: rgba(239,68,68,0.1); color: var(--red); }

.btn-sm  { padding: 6px 12px; font-size: 13px; }
.btn-lg  { padding: 12px 28px; font-size: 15px; }
.btn-full { width: 100%; justify-content: center; }

/* ── Badges ────────────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 12px; font-weight: 600;
  letter-spacing: 0.3px;
}
.badge-lg { padding: 5px 14px; font-size: 13px; }
.badge-xs { padding: 2px 6px; font-size: 10px; }

.badge-blue   { background: rgba(59,126,255,0.15); color: var(--blue); border: 1px solid rgba(59,126,255,0.25); }
.badge-purple { background: rgba(168,85,247,0.15); color: var(--purple); border: 1px solid rgba(168,85,247,0.25); }
.badge-amber  { background: rgba(245,158,11,0.15); color: var(--amber); border: 1px solid rgba(245,158,11,0.25); }
.badge-orange { background: rgba(249,115,22,0.15); color: var(--orange); border: 1px solid rgba(249,115,22,0.25); }
.badge-teal   { background: rgba(20,184,166,0.15); color: var(--teal); border: 1px solid rgba(20,184,166,0.25); }
.badge-indigo { background: rgba(99,102,241,0.15); color: var(--indigo); border: 1px solid rgba(99,102,241,0.25); }
.badge-green  { background: rgba(16,185,129,0.15); color: var(--green); border: 1px solid rgba(16,185,129,0.25); }
.badge-red    { background: rgba(239,68,68,0.15);  color: var(--red);   border: 1px solid rgba(239,68,68,0.25); }
.badge-gray   { background: rgba(100,116,139,0.15); color: #64748b; border: 1px solid rgba(100,116,139,0.25); }

/* ── Tables ────────────────────────────────────────────────── */
.table-wrapper { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 11px; font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase; letter-spacing: 0.7px;
  border-bottom: 1px solid var(--border);
}
.table td { padding: 14px 16px; border-bottom: 1px solid rgba(255,255,255,0.04); }
.table-row:hover { background: rgba(255,255,255,0.02); }
.row-urgent { border-left: 3px solid var(--red); }

.order-number-link {
  font-weight: 700; color: var(--blue);
  font-family: 'SF Mono', 'Fira Code', monospace; font-size: 13px;
}
.order-number-link:hover { color: #60a5fa; }

/* ── Form Inputs ───────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.required { color: var(--red); }

.input-wrapper { position: relative; }
.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: inherit; font-size: 14px;
  transition: var(--transition);
  outline: none;
}
.form-input:focus, .form-textarea:focus { border-color: var(--border-focus); background: var(--bg-input-focus); }
.form-input::placeholder, .form-textarea::placeholder { color: var(--text-muted); }
.form-textarea { resize: vertical; min-height: 80px; }
.form-input-sm { padding: 6px 10px; font-size: 13px; }

.input-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  width: 16px; height: 16px; color: var(--text-muted); pointer-events: none;
}
.input-wrapper .form-input { padding-left: 40px; }
.password-toggle {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  background: none; border: none; color: var(--text-secondary); cursor: pointer;
}

.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-check { display: flex; align-items: center; gap: 8px; }
.check-input { width: 16px; height: 16px; accent-color: var(--blue); cursor: pointer; }
.check-label { font-size: 14px; color: var(--text-secondary); cursor: pointer; }

/* ── Empty State ───────────────────────────────────────────── */
.empty-state {
  text-align: center; padding: 64px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
}
.empty-icon { font-size: 48px; margin-bottom: 16px; }
.empty-state h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.empty-state p { color: var(--text-secondary); margin-bottom: 24px; }

/* ── Order Cards Grid (Designer Dashboard) ─────────────────── */
.order-cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.order-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex; flex-direction: column; gap: 8px;
  transition: var(--transition);
  cursor: pointer;
}
.order-card:hover { border-color: var(--blue); box-shadow: var(--shadow-glow); transform: translateY(-2px); color: var(--text-primary); }
.order-card-urgent { border-color: rgba(239,68,68,0.4); background: rgba(239,68,68,0.04); }
.order-card-header { display: flex; align-items: center; justify-content: space-between; }
.order-number-tag { font-weight: 700; font-family: monospace; font-size: 13px; color: var(--blue); }
.order-clinic { font-weight: 600; color: var(--text-primary); }
.order-indication { font-size: 13px; }
.order-material { font-size: 12px; }
.order-teeth { font-size: 12px; color: var(--text-secondary); }
.teeth-label { color: var(--text-muted); }
.order-card-footer { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.deadline { font-size: 12px; color: var(--text-secondary); }
.deadline-warn { color: var(--red); }
.file-count { font-size: 12px; color: var(--text-muted); margin-left: auto; }

/* ── Login Page ─────────────────────────────────────────────── */
.login-page { overflow: hidden; }
.login-bg { position: fixed; inset: 0; overflow: hidden; z-index: 0; }
.orb {
  position: absolute; border-radius: 50%;
  filter: blur(100px); opacity: 0.15;
  animation: pulse 8s ease-in-out infinite;
}
.orb-1 { width: 600px; height: 600px; background: var(--blue); top: -200px; left: -200px; animation-delay: 0s; }
.orb-2 { width: 400px; height: 400px; background: var(--indigo); bottom: -100px; right: -100px; animation-delay: 3s; }
.orb-3 { width: 300px; height: 300px; background: var(--teal); top: 50%; left: 50%; animation-delay: 1.5s; }
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.1); } }

.login-layout {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr 1fr;
  min-height: 100vh;
}

.login-brand-panel {
  background: linear-gradient(135deg, rgba(15,23,42,0.95), rgba(30,58,138,0.4));
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  padding: 48px;
  animation: loginFadeIn 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.brand-content { max-width: 400px; }
.brand-logo { display: flex; align-items: center; gap: 16px; margin-bottom: 48px; }
.brand-title { display: flex; flex-direction: column; }
.brand-name { font-size: 32px; font-weight: 900; color: var(--text-primary); letter-spacing: -1px; }
.brand-tagline { font-size: 13px; color: var(--text-secondary); margin-top: 2px; }
.brand-features { display: flex; flex-direction: column; gap: 24px; }
.feature-item { display: flex; gap: 16px; }
.feature-icon { font-size: 24px; flex-shrink: 0; margin-top: 2px; }
.feature-title { font-weight: 600; color: var(--text-primary); margin-bottom: 4px; }
.feature-desc { font-size: 13px; color: var(--text-secondary); }
.brand-version { margin-top: 48px; font-size: 12px; color: var(--text-muted); }

@keyframes loginFadeUp {
  0% { opacity: 0; transform: translateY(30px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes loginFadeIn {
  0% { opacity: 0; transform: translateX(-30px); }
  100% { opacity: 1; transform: translateX(0); }
}

.login-form-panel {
  display: flex; align-items: center; justify-content: center;
  padding: 48px;
  animation: loginFadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.login-card {
  width: 100%; max-width: 420px;
  background: rgba(14,20,37,0.8);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-card);
}
.login-card-header { margin-bottom: 28px; }
.login-card-header h2 { font-size: 26px; font-weight: 800; color: var(--text-primary); }
.login-card-header p  { color: var(--text-secondary); margin-top: 4px; }
.login-form { display: flex; flex-direction: column; gap: 18px; }
.login-footer-note { text-align: center; font-size: 12px; color: var(--text-muted); margin-top: 20px; }
.mb-16 { margin-bottom: 16px; }

/* ── Priority Selector ─────────────────────────────────────── */
.priority-selector { display: flex; gap: 10px; }
.priority-option { flex: 1; cursor: pointer; }
.priority-option input { display: none; }
.priority-card {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 14px;
  background: var(--bg-input);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
  font-size: 13px; font-weight: 600;
}
.priority-option input:checked + .priority-normal { border-color: var(--blue); background: var(--blue-glow); color: var(--blue); }
.priority-option input:checked + .priority-urgent { border-color: var(--red); background: rgba(239,68,68,0.1); color: var(--red); }
.priority-emoji { font-size: 20px; }

/* ── Option Grid (Indication/Material) ─────────────────────── */
.option-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.option-card { cursor: pointer; }
.option-card input { display: none; }
.option-card-inner {
  display: flex; flex-direction: column; gap: 4px;
  padding: 14px;
  background: var(--bg-input);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
}
.option-card input:checked + .option-card-inner { border-color: var(--blue); background: var(--blue-glow); }
.option-card-inner:hover { border-color: rgba(59,126,255,0.4); }
.option-name { font-weight: 600; font-size: 13px; }
.option-desc { font-size: 12px; color: var(--text-secondary); }
.option-tag { display: inline-block; font-size: 10px; font-weight: 600; text-transform: uppercase; color: var(--text-muted); background: rgba(255,255,255,0.06); padding: 2px 8px; border-radius: 99px; width: fit-content; }

/* ── Tooth Chart ───────────────────────────────────────────── */
.tooth-chart {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 24px;
  background: rgba(0,0,0,0.2);
  border-radius: var(--radius-lg);
}
.jaw-row { display: flex; align-items: center; gap: 0; }
.jaw-upper { margin-bottom: 8px; align-items: flex-end; }
.jaw-lower { margin-top: 8px; align-items: flex-start; }
.jaw-label { font-size: 12px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.jaw-midline { width: 12px; background: rgba(255,255,255,0.1); height: 40px; border-radius: 4px; margin: 0 4px; }
.quadrant { display: flex; }

.tooth {
  display: flex; flex-direction: column; align-items: center;
  gap: 3px; cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  transition: var(--transition);
  width: 38px;
}
.tooth:hover { background: rgba(59,126,255,0.1); }
.tooth.selected .tooth-visual { background: var(--blue); }
.tooth.selected { color: var(--blue); }

.tooth-visual {
  width: 24px; height: 28px;
  border-radius: 4px 4px 8px 8px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  transition: var(--transition);
}
.jaw-lower .tooth-visual { border-radius: 8px 8px 4px 4px; }
.tooth-q1, .tooth-q2 { border-radius: 4px 4px 10px 10px; }
.tooth-q3, .tooth-q4 { border-radius: 10px 10px 4px 4px; }
.tooth-num { font-size: 10px; font-weight: 700; color: var(--text-secondary); }
.tooth.selected .tooth-num { color: var(--blue); }

/* ── Form Steps ────────────────────────────────────────────── */
.form-page { max-width: 900px; }
.steps-bar { display: flex; align-items: center; margin-bottom: 28px; }
.step {
  display: flex; align-items: center; gap: 8px;
  color: var(--text-muted); font-size: 13px; font-weight: 600;
  transition: var(--transition);
}
.step.active { color: var(--blue); }
.step.done { color: var(--green); }
.step-num {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
}
.step.active .step-num { background: var(--blue); border-color: var(--blue); color: #fff; }
.step.done .step-num { background: var(--green); border-color: var(--green); color: #fff; }
.step-divider { flex: 1; height: 2px; background: var(--border); margin: 0 12px; }

.form-step { display: none; }
.form-step.active { display: block; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: translateX(0); } }

.step-actions { display: flex; justify-content: space-between; margin-top: 20px; }

/* ── Detail Layout ─────────────────────────────────────────── */
.detail-layout { display: grid; grid-template-columns: 1fr 1.2fr; gap: 20px; }
.detail-left, .detail-right { display: flex; flex-direction: column; gap: 20px; }

.detail-list { display: flex; flex-direction: column; gap: 0; }
.detail-item {
  display: flex; justify-content: space-between;
  padding: 11px 0; border-bottom: 1px solid rgba(255,255,255,0.04);
}
.detail-item:last-child { border-bottom: none; }
.detail-key { font-size: 13px; color: var(--text-secondary); font-weight: 500; }
.detail-val { font-size: 13px; font-weight: 600; text-align: right; max-width: 55%; }

.notes-box {
  margin-top: 16px;
  padding: 14px;
  background: rgba(59,126,255,0.05);
  border: 1px solid rgba(59,126,255,0.15);
  border-radius: var(--radius-md);
}
.notes-label { font-size: 12px; font-weight: 700; color: var(--blue); margin-bottom: 6px; }
.notes-text { font-size: 13px; color: var(--text-secondary); line-height: 1.6; }

/* Status Timeline */
.status-timeline { display: flex; flex-direction: column; gap: 0; margin-bottom: 16px; }
.timeline-step {
  display: flex; align-items: center; gap: 10px;
  padding: 6px 0; color: var(--text-muted); font-size: 13px;
}
.timeline-step.timeline-done { color: var(--green); }
.timeline-step.timeline-current { color: var(--blue); font-weight: 700; }
.timeline-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--border); flex-shrink: 0;
}
.timeline-done .timeline-dot { background: var(--green); }
.timeline-current .timeline-dot { background: var(--blue); box-shadow: 0 0 8px var(--blue); }
.timeline-line { width: 2px; height: 20px; background: var(--border); margin-left: 4px; }
.timeline-line-done { background: var(--green); }

.approval-actions { margin-top: 16px; padding: 14px; background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.25); border-radius: var(--radius-md); }
.approval-hint { font-size: 13px; color: var(--amber); margin-bottom: 12px; }
.action-row { display: flex; gap: 10px; }

/* ── Files ─────────────────────────────────────────────────── */
.upload-panel { padding: 16px; border-bottom: 1px solid var(--border); }
.upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-md);
  text-align: center; padding: 28px;
  transition: var(--transition);
  cursor: pointer;
}
.upload-zone:hover, .upload-zone.drag-over { border-color: var(--blue); background: var(--blue-glow); }
.upload-zone-content { display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--text-secondary); }
.upload-zone-content svg { color: var(--text-muted); }

.progress-bar { height: 6px; background: var(--bg-input); border-radius: 99px; overflow: hidden; margin-bottom: 8px; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--blue), var(--indigo)); width: 0%; transition: width 0.3s; }
.progress-text { font-size: 12px; color: var(--text-secondary); text-align: center; }

.file-section { margin-bottom: 16px; }
.file-section:last-child { margin-bottom: 0; }
.file-section-title { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); margin-bottom: 10px; }
.file-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px; margin-bottom: 8px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: var(--transition);
}
.file-item:hover { border-color: rgba(59,126,255,0.3); }
.file-item-latest { border-color: rgba(16,185,129,0.3); background: rgba(16,185,129,0.05); }
.file-icon { width: 36px; height: 36px; background: var(--bg-card); border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 800; color: var(--blue); flex-shrink: 0; border: 1px solid var(--border); }
.file-info { flex: 1; min-width: 0; }
.file-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-meta { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.file-actions { display: flex; gap: 6px; flex-shrink: 0; }
.version-badge { display: inline-block; font-size: 10px; font-weight: 700; background: var(--green); color: #000; padding: 1px 6px; border-radius: 99px; margin-left: 4px; }

/* ── Premium Chat UI ───────────────────────────────────────── */
.messages-list {
  max-height: 400px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 12px;
  margin-bottom: 20px;
  padding: 15px;
  background: rgba(10, 10, 15, 0.4);
  border-radius: 16px;
  box-shadow: inset 0 4px 20px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.02);
}
.messages-list::-webkit-scrollbar { width: 6px; }
.messages-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 10px; }

.message-bubble { max-width: 80%; display: flex; flex-direction: column; position: relative; }
.msg-mine { align-self: flex-end; }
.msg-other { align-self: flex-start; }

.msg-header { display: flex; gap: 10px; margin-bottom: 6px; padding: 0 4px; align-items: flex-end; }
.msg-sender { font-size: 11px; font-weight: 700; color: rgba(255,255,255,0.6); text-transform: uppercase; letter-spacing: 0.5px; }
.msg-time { font-size: 10px; color: rgba(255,255,255,0.4); }

.msg-text {
  padding: 12px 18px;
  font-size: 13.5px; line-height: 1.5;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  word-wrap: break-word;
}

/* My Messages (Blue/Purple Gradient) */
.msg-mine .msg-header { flex-direction: row-reverse; }
.msg-mine .msg-text { 
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%); 
  color: #fff; 
  border-radius: 18px 18px 4px 18px; 
  border: 1px solid rgba(255,255,255,0.1);
}

/* Other Messages (Glassmorphism Dark) */
.msg-other .msg-text { 
  background: rgba(255,255,255,0.03); 
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #e2e8f0; 
  border: 1px solid rgba(255,255,255,0.08); 
  border-radius: 18px 18px 18px 4px; 
}

.message-input-row { 
  display: flex; gap: 12px; 
  background: rgba(255,255,255,0.02);
  padding: 10px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.05);
  align-items: center;
}
.msg-input { 
  flex: 1; 
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  resize: none;
  padding: 8px 12px !important;
  color: #fff;
}
.msg-input:focus { outline: none !important; }

.message-input-row .btn-primary {
  border-radius: 50%;
  width: 45px; height: 45px;
  padding: 0;
  display: flex; justify-content: center; align-items: center;
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
  transition: all 0.3s ease;
}
.message-input-row .btn-primary:hover {
  transform: scale(1.05) rotate(5deg);
  box-shadow: 0 6px 20px rgba(139, 92, 246, 0.6);
}

/* ── Activity Log ──────────────────────────────────────────── */
.activity-log { display: flex; flex-direction: column; gap: 0; }
.activity-item { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
.activity-item:last-child { border-bottom: none; }
.activity-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); flex-shrink: 0; margin-top: 5px; }
.activity-content { flex: 1; }
.activity-desc { font-size: 13px; color: var(--text-secondary); }
.activity-time { font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ── Kanban Board ──────────────────────────────────────────── */
.kanban-board {
  display: flex; gap: 16px;
  overflow-x: auto; padding-bottom: 16px;
  min-height: 600px;
}
.kanban-col {
  min-width: 270px; max-width: 270px;
  display: flex; flex-direction: column;
  background: #334155; /* Koyu gri arka plan */
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.kanban-col-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-card); /* Gündüz modunda beyaz, gece modunda kart rengi */
  flex-shrink: 0;
}
.kanban-col-title { color: var(--text-primary); display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; }
.col-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.col-dot-received            { background: var(--blue); }
.col-dot-designing           { background: var(--purple); }
.col-dot-specialist_approval { background: var(--amber); }
.col-dot-clinic_approval     { background: var(--indigo); }
.col-dot-ready_for_production { background: var(--teal); }
.col-dot-completed           { background: var(--green); }

.kanban-col-count { font-size: 12px; font-weight: 700; background: var(--bg-input); padding: 2px 8px; border-radius: 99px; color: var(--text-secondary); }
.kanban-cards { flex: 1; padding: 10px; display: flex; flex-direction: column; gap: 8px; overflow-y: auto; }
.kanban-empty { text-align: center; padding: 24px; color: var(--text-muted); font-size: 13px; border: 2px dashed var(--border); border-radius: var(--radius-md); }

.kanban-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 12px;
  cursor: grab;
  transition: var(--transition);
  display: flex; flex-direction: column; gap: 6px;
}
.kanban-card:hover { border-color: rgba(59,126,255,0.3); box-shadow: 0 4px 16px rgba(0,0,0,0.3); transform: translateY(-1px); }
.kanban-card:active { cursor: grabbing; }
.kanban-card.dragging { opacity: 0.5; }

@keyframes received-neon-breathe {
  0%   { box-shadow: 0 0 8px rgba(59, 126, 255, 0.2); border-color: rgba(59, 126, 255, 0.4); }
  50%  { box-shadow: 0 0 20px rgba(59, 126, 255, 0.6); border-color: rgba(59, 126, 255, 0.9); }
  100% { box-shadow: 0 0 8px rgba(59, 126, 255, 0.2); border-color: rgba(59, 126, 255, 0.4); }
}

@keyframes urgent-neon-breathe {
  0%   { box-shadow: 0 0 8px rgba(239, 68, 68, 0.3); border-color: rgba(239, 68, 68, 0.5); }
  50%  { box-shadow: 0 0 20px rgba(239, 68, 68, 0.8); border-color: rgba(239, 68, 68, 1); }
  100% { box-shadow: 0 0 8px rgba(239, 68, 68, 0.3); border-color: rgba(239, 68, 68, 0.5); }
}

.kanban-col[data-status="received"] .kanban-card {
  animation: received-neon-breathe 2s infinite ease-in-out;
}

.kanban-card-urgent { 
  border-color: rgba(239,68,68,0.4); 
  background: rgba(239,68,68,0.05); 
  animation: urgent-neon-breathe 1.5s infinite ease-in-out !important;
}

.kcard-top { display: flex; align-items: center; justify-content: space-between; }
.kcard-number { font-size: 11px; font-weight: 800; font-family: monospace; color: var(--blue); }
.kcard-clinic { font-weight: 600; font-size: 13px; }
.kcard-indication { font-size: 12px; color: var(--text-secondary); }
.kcard-material { font-size: 11px; color: var(--text-muted); }
.kcard-teeth { font-size: 11px; color: var(--text-muted); }
.kcard-footer { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.kcard-designer {
  width: 24px; height: 24px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--indigo));
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; font-weight: 800; color: #fff;
}
.kcard-assign-btn {
  background: none; border: 1px dashed var(--border); color: var(--text-muted);
  font-size: 11px; padding: 2px 8px; border-radius: 99px; cursor: pointer;
  transition: var(--transition);
}
.kcard-assign-btn:hover { border-color: var(--blue); color: var(--blue); }
.kcard-deadline { font-size: 11px; color: var(--text-secondary); }
.kcard-files { font-size: 11px; color: var(--text-muted); margin-left: auto; }

/* ── Tabs ──────────────────────────────────────────────────── */
.tab-group { display: flex; gap: 4px; background: var(--bg-input); padding: 4px; border-radius: var(--radius-md); }
.tab { padding: 7px 14px; border-radius: 6px; font-size: 13px; font-weight: 600; color: var(--text-secondary); transition: var(--transition); }
.tab:hover { color: var(--text-primary); }
.tab-active { background: var(--bg-card); color: var(--text-primary); box-shadow: 0 1px 4px rgba(0,0,0,0.3); }

/* ── User Management Table ─────────────────────────────────── */
.user-cell { display: flex; align-items: center; gap: 12px; }
.avatar-circle {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--indigo));
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; color: #fff; flex-shrink: 0;
}
.user-full-name { font-weight: 600; font-size: 13px; }
.user-email { font-size: 12px; }
.status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.dot-green { background: var(--green); }
.dot-gray  { background: var(--text-muted); }
.action-group { display: flex; gap: 6px; }
.role-badge-clinic   { background: rgba(59,126,255,0.15); color: var(--blue); border: 1px solid rgba(59,126,255,0.25); }
.role-badge-designer { background: rgba(168,85,247,0.15); color: var(--purple); border: 1px solid rgba(168,85,247,0.25); }
.role-badge-admin    { background: rgba(245,158,11,0.15); color: var(--amber); border: 1px solid rgba(245,158,11,0.25); }

/* ── Modals ────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  animation: fadeIn 0.2s ease;
}
.modal-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  width: 100%; max-width: 520px;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6);
  animation: slideUp 0.3s ease;
  max-height: 90vh; overflow-y: auto;
}
.modal-panel-xl { max-width: 900px; }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px; border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-size: 16px; font-weight: 700; }
.modal-close { background: none; border: none; color: var(--text-secondary); cursor: pointer; font-size: 18px; padding: 4px; }
.modal-close:hover { color: var(--text-primary); }
.modal-body { padding: 24px; }
.modal-footer { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--border); }

/* ── Summary Card ──────────────────────────────────────────── */
.summary-card { border-color: rgba(59,126,255,0.2); background: rgba(59,126,255,0.04); }
.summary-grid { display: flex; flex-direction: column; gap: 8px; }
.summary-row { display: flex; justify-content: space-between; }
.summary-key { font-size: 13px; color: var(--text-muted); }
.summary-val { font-size: 13px; font-weight: 600; }

/* ── Spinner ───────────────────────────────────────────────── */
.spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Text Utilities ────────────────────────────────────────── */
.text-secondary { color: var(--text-secondary) !important; }
.text-muted     { color: var(--text-muted) !important; }
.text-sm        { font-size: 12px; }
.text-mono      { font-family: 'SF Mono', 'Fira Code', monospace; }
.text-center    { text-align: center; }
.text-blue      { color: var(--blue); }
.text-red       { color: var(--red); }
.text-amber     { color: var(--amber); }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 1200px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid-6 { grid-template-columns: repeat(3, 1fr); }
  .stats-grid-7 { grid-template-columns: repeat(4, 1fr); }
  .detail-layout { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .login-layout { grid-template-columns: 1fr; }
  .login-brand-panel { display: none; }
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main-area { margin-left: 0; }
  .sidebar-toggle { display: flex; }
  .form-grid-2 { grid-template-columns: 1fr; }
  .kanban-board { flex-direction: column; }
  .kanban-col { min-width: unset; max-width: unset; }
}

@media (max-width: 600px) {
  .page-body { padding: 16px; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stats-grid-6 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid-7 { grid-template-columns: repeat(2, 1fr); }
  .login-card { padding: 28px 20px; }
}

@keyframes logoNeonBreathe {
  0% { filter: drop-shadow(0 0 8px rgba(59, 126, 255, 0.5)); transform: scale(1); }
  50% { filter: drop-shadow(0 0 20px rgba(0, 210, 255, 0.9)) drop-shadow(0 0 30px rgba(59, 126, 255, 0.6)); transform: scale(1.05); }
  100% { filter: drop-shadow(0 0 8px rgba(59, 126, 255, 0.5)); transform: scale(1); }
}

.logo-neon-breathe {
  animation: logoNeonBreathe 3s ease-in-out infinite;
  border-radius: 20%;
}

/*  Futuristic Analytics Styles  */
.kpi-card { background: rgba(255, 255, 255, 0.03); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, 0.05); border-radius: 2px; box-shadow: inset 0 0 20px rgba(59, 126, 255, 0.05), 0 4px 20px rgba(0,0,0,0.2); transition: all 0.3s ease; }
.kpi-card:hover { box-shadow: inset -2px -2px 20px rgba(59, 126, 255, 0.15), 0 8px 30px rgba(0,0,0,0.3); border-color: rgba(59, 126, 255, 0.3); }
.trend-badge { font-size: 0.75rem; padding: 2px 6px; border-radius: 2px; background: rgba(16, 185, 129, 0.1); color: #10b981; font-weight: 600; letter-spacing: 0.5px; }
.trend-badge.down { background: rgba(239, 68, 68, 0.1); color: #ef4444; }
.datatable-futuristic { border: none !important; }
.datatable-futuristic th, .datatable-futuristic td { border-left: none !important; border-right: none !important; border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important; border-top: none !important; background: transparent !important; color: var(--text-primary); padding: 16px 12px; }
.datatable-futuristic thead th { text-transform: uppercase; font-size: 0.75rem; letter-spacing: 1px; color: var(--text-secondary); border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important; }
.avatar-circle { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--indigo)); color: white; display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 0.9rem; box-shadow: 0 0 10px rgba(59,126,255,0.3); }
.pill-badge { padding: 4px 10px; border-radius: 50rem; font-size: 0.75rem; font-weight: 600; display: inline-block; }
.pill-success { background: rgba(16, 185, 129, 0.15); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.3); }
.pill-warning { background: rgba(245, 158, 11, 0.15); color: #f59e0b; border: 1px solid rgba(245, 158, 11, 0.3); }
.pill-danger { background: rgba(239, 68, 68, 0.15); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.3); }
.pill-info { background: rgba(59, 126, 255, 0.15); color: #3b7eff; border: 1px solid rgba(59, 126, 255, 0.3); }

/* Profile Launch Switch Button */
.profile-switch-wrapper .launch-btn {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.profile-switch-wrapper .launch-btn .input {
  opacity: 0;
  width: 0;
  height: 0;
  display: none;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .spot-shadow {
  transition: 1.7s opacity;
  opacity: 0.9;
  animation: spot-main 1.9s linear infinite;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .mid .spot-main {
  transition: 1.7s opacity;
  opacity: 0.9;
  animation: spot-main 1.9s linear infinite;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .mid .btn .spot-light {
  transition: 1.7s opacity;
  opacity: 0.9;
  animation: spot-main 1.9s linear infinite;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .mid .btn .center .icon .svg {
  filter: brightness(1.5) drop-shadow(0 0 5px #fff);
  stroke: #c6c6c6;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .mid .btn .center .launch {
  color: #333333;
}

.profile-switch-wrapper .launch-btn .input:checked ~ .back .mid .btn .center .launch > div {
  animation: waveText 1.8s calc(var(--i, 1) * -0.13s) infinite;
}

.profile-switch-wrapper .launch-btn:active .back .mid .btn {
  transform: scale(0.94);
  box-shadow:
    0 -1px 2px rgba(255, 255, 255, 0.3),
    inset 0 0 10px rgba(0, 0, 0, 0.24),
    inset 0 -13px 26px rgba(0, 0, 0, 0.8);
}

.profile-switch-wrapper .back {
  z-index: 200;
  width: 188px;
  height: 188px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  background-image: linear-gradient(0, #5e5e61 20%, #212123);
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.3),
    inset 0 3px 5px rgba(255, 255, 255, 0.6),
    inset 0 -6px 2px rgba(255, 255, 255, 0.05),
    inset 0 -3px 0 rgba(0, 0, 0, 0.15),
    inset -2px 5px 0 rgba(0, 0, 0, 0.3),
    inset 2px 5px 0 rgba(0, 0, 0, 0.3),
    0 -11px 22px 2px rgba(255, 255, 255, 0.39),
    0 6px 22px 2px rgba(0, 0, 0, 0.5),
    0 2px 6px #7c7c7c;
  cursor: pointer;
}

.profile-switch-wrapper .back .spot-shadow {
  position: absolute;
  width: 140px;
  height: 40px;
  background: rgba(71, 164, 239, 0.8);
  opacity: 0;
  filter: blur(20px) brightness(1.1);
}

.profile-switch-wrapper .back .mid {
  overflow: hidden;
  position: relative;
  width: 155px;
  height: 155px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  background: #000;
  box-shadow:
    0 0 5px #000,
    0 1px 2px rgba(255, 255, 255, 0.8);
}

.profile-switch-wrapper .back .mid::before {
  content: "";
  position: absolute;
  z-index: 500;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: transparent;
  box-shadow: inset 0 -18px 27px rgba(0, 0, 0, 0.8);
  pointer-events: none;
}

.profile-switch-wrapper .back .mid .spot-main {
  position: absolute;
  width: 160px;
  height: 36px;
  background: #589cf6;
  opacity: 0;
  filter: blur(15px) brightness(1.5);
}

.profile-switch-wrapper .back .mid .btn {
  z-index: 90;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 146px;
  height: 146px;
  border-radius: 50%;
  background: #424242;
  box-shadow:
    0 -1px 2px rgba(255, 255, 255, 0.5),
    inset 0 -13px 26px rgba(0, 0, 0, 0.8);
  transition: 0.2s ease;
}

.profile-switch-wrapper .back .mid .btn .spot-light {
  position: absolute;
  width: 160px;
  height: 40px;
  opacity: 0;
  background: rgba(104, 151, 255, 0.4);
  filter: blur(20px) brightness(1.1);
}

.profile-switch-wrapper .back .mid .btn .center {
  z-index: 100;
  width: 125px;
  height: 125px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-radius: 50%;
  background: #232323;
  cursor: pointer;
}

.profile-switch-wrapper .back .mid .btn .center .icon .svg {
  margin-top: -4px;
  width: 32px;
  transition: 1.5s filter, 1.5s stroke;
}

.profile-switch-wrapper .back .mid .btn .center .launch {
  display: flex;
  margin-top: 4px;
  font-size: 19px;
  color: #595959;
}

@keyframes waveText {
  0% { opacity: 0.7; }
  50% { color: #c6c6c6; opacity: 1; }
  100% { opacity: 0.7; }
}

@keyframes spot-main {
  0% { transform: rotate(0); }
  100% { transform: rotate(360deg); }
}


  /* Light Theme Neumorphic Dock Buttons */
  [data-theme="light"] .nav-item {
    background: linear-gradient(#ffffff 30%, #ffffff 30%, #d6d6d6);
    border-color: #ffffff;
    color: grey;
    box-shadow: 0 4px 4px rgba(18, 18, 18, 0.35);
  }

  [data-theme="light"] .nav-item::before {
    background: rgb(224, 224, 224);
    box-shadow: 0 2px 2px inset #808080;
  }

  [data-theme="light"] .nav-item:focus,
  [data-theme="light"] .nav-item:hover,
  [data-theme="light"] .nav-item.active {
    box-shadow:
      0 5px 3px rgba(18, 18, 18, 0.35),
      0 5px 20px rgba(2, 220, 89, 0.6);
    background: linear-gradient(0deg, #ffffff 30%, #ffffff 30%, #d6d6d6);
    color: #02dc59;
    border-color: rgba(2, 220, 89, 0.4);
  }

  [data-theme="light"] .nav-item:focus::before,
  [data-theme="light"] .nav-item:hover::before,
  [data-theme="light"] .nav-item.active::before {
    box-shadow: 0 2px 2px inset #808080;
  }

  [data-theme="light"] .nav-item span {
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    border-color: rgba(0, 0, 0, 0.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }
