
:root {
  --brand: #2196F3;
  --brand-glow: rgba(33, 150, 243, 0.15);
  --dark: #08080c;
  --dark-card: rgba(20, 20, 31, 0.65);
  --border: rgba(33, 150, 243, 0.25);
  --text: #e8e8f0;
  --muted: #7777aa;
  --red: #ff5252;
  --sidebar-width: 250px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { 
  font-family: 'Inter', sans-serif; 
  background: linear-gradient(45deg, #08080c, #141428, #0e1e38, #08080c);
  background-size: 400% 400%;
  animation: dynamicUserBG 15s ease infinite;
  color: var(--text); 
  display: flex; flex-direction: column; min-height: 100vh; 
}

@keyframes dynamicUserBG {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* If it's a dashboard, we pad left. If it's login, we center. We can control this by checking if nav exists. */
body.dashboard-mode { padding-left: var(--sidebar-width); padding-top: 80px; padding-right: 1rem; }
body.auth-mode { justify-content: center; align-items: center; padding: 1.5rem 1rem; }

.dashboard-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

@media (min-width: 1025px) {
  .desktop-hidden { display: none !important; }
}

/* SIDEBAR STYLING FOR EXISTING <nav> */
nav {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: rgba(8, 8, 12, 0.95);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 1.5rem 1rem;
  z-index: 1000;
  overflow-y: auto;
}
.nav-logo { font-size: 1.5rem; color: var(--brand); margin-bottom: 2rem; text-align: center; font-weight: 700; }
.nav-links { display: flex; flex-direction: column; gap: 0.5rem; width: 100%; }
.nav-links a {
  display: flex; align-items: center; gap: 0.8rem; padding: 0.8rem 1rem;
  color: var(--muted); text-decoration: none; border-radius: 8px;
  font-size: 0.85rem; font-weight: 600; transition: 0.2s;
}
.nav-links a:hover, .nav-links a.active {
  background: rgba(33, 150, 243, 0.1); color: var(--brand);
}

/* Auth Box styling (Login/Register) */
.box {
  background: var(--dark-card); border: 1px solid var(--border); backdrop-filter: blur(12px);
  border-radius: 20px; padding: 2.2rem 1.8rem; width: 100%; max-width: 400px;
  text-align: center; box-shadow: 0 10px 30px var(--brand-glow);
}
.box.large { max-width: 600px; }

/* General Cards & Buttons */
.card, .admin-hero {
  background: rgba(20, 20, 31, 0.85); border: 1px solid var(--border); border-radius: 16px;
  padding: 1.5rem; margin-bottom: 1.5rem; box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  position: relative; overflow: hidden; transition: all 0.3s ease;
}
.card::before, .admin-hero::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
  opacity: 0; transition: opacity 0.3s ease;
}
.card:hover::before { opacity: 1; }
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(0,0,0,0.4); border-color: rgba(33, 150, 243, 0.4); }

button, .btn {
  background: linear-gradient(135deg, #1e88e5, #42a5f5, #00bcd4); color: #fff;
  border: 1px solid rgba(255,255,255,0.1); border-radius: 50px; padding: 0.8rem 1.2rem; font-weight: 800; cursor: pointer;
  transition: all 0.3s ease; font-size: 0.95rem; width: 100%;
  box-shadow: 0 4px 15px rgba(33,150,243,0.3); text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(33,150,243,0.5); border-color: rgba(255,255,255,0.3); }
.btn-small { padding: 0.5rem 1rem; font-size: 0.8rem; width: auto; border-radius: 8px; }

/* Inputs */
.field { margin-bottom: 1.2rem; text-align: left; }
.field label { display: block; font-size: 0.68rem; font-weight: 700; color: var(--muted); text-transform: uppercase; margin-bottom: 0.35rem; }
.field input, .field select, .field textarea {
  width: 100%; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 0.75rem 1rem; color: var(--text); font-size: 0.9rem; outline: none; transition: 0.2s;
}
.field input:focus { border-color: var(--brand); box-shadow: 0 0 10px var(--brand-glow); }
