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

:root {
  /* Soft Professional Palette */
  --bg: #f4f6fb;
  --bg2: #eef1f8;
  --card: #ffffff;
  --card-hover: #f8f9fd;
  --border: #e2e6f0;
  --border-light: #d0d5e3;
  --text: #1e2a3a;
  --text-dim: #5a6577;
  --text-muted: #8892a4;
  --primary: #4f6ef7;
  --primary-light: #7b93fa;
  --primary-bg: #eef2ff;
  --green: #22b573;
  --green-bg: #ecfdf5;
  --red: #e74c5e;
  --red-bg: #fef2f2;
  --orange: #f5a623;
  --orange-bg: #fffbeb;
  --blue: #3b82f6;
  --blue-bg: #eff6ff;
  --purple: #8b5cf6;
  --purple-bg: #f5f3ff;
  --pink: #ec4899;
  --pink-bg: #fdf2f8;
  --radius: 12px;
  --radius-sm: 8px;
  --transition: all 0.2s ease;
  --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 16px rgba(0,0,0,0.04);
  --shadow-lg: 0 4px 12px rgba(0,0,0,0.08), 0 16px 40px rgba(0,0,0,0.06);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--border-light); }

/* ========== LOGIN SCREEN ========== */
.login-screen {
  min-height: 100vh;
  display: flex;
  background: var(--bg);
  position: relative;
  overflow: hidden;
}

/* Animated Background */
.login-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.login-bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
}

.orb-1 {
  width: 500px;
  height: 500px;
  background: var(--primary-light);
  top: -200px;
  left: -100px;
  animation: orbFloat1 15s ease-in-out infinite;
  opacity: 0.15;
}

.orb-2 {
  width: 400px;
  height: 400px;
  background: var(--green);
  bottom: -150px;
  right: -100px;
  animation: orbFloat2 12s ease-in-out infinite;
  opacity: 0.1;
}

.orb-3 {
  width: 300px;
  height: 300px;
  background: var(--pink);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: orbFloat3 18s ease-in-out infinite;
}

.login-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 60px 60px;
}

@keyframes orbFloat1 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(80px, 60px); }
}

@keyframes orbFloat2 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-60px, -80px); }
}

@keyframes orbFloat3 {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50% { transform: translate(-50%, -50%) scale(1.2); }
}

/* Login Wrapper */
.login-wrapper {
  display: flex;
  width: 100%;
  min-height: 100vh;
  position: relative;
  z-index: 1;
  align-items: center;
}

/* Left Panel - Branding */
.login-branding {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 80px;
  position: relative;
  background: linear-gradient(135deg, #1a1f36 0%, #0f1629 50%, #151d35 100%);
  overflow: hidden;
}

.branding-content {
  max-width: 500px;
  width: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 48px;
}

.brand-logo-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--green), #00d9a7);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
  box-shadow: 0 8px 30px rgba(0, 184, 148, 0.3);
}

.brand-logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
}

.brand-logo-text span { color: var(--green); }

.brand-headline {
  font-size: 3.2rem;
  font-weight: 700;
  color: white;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -1px;
}

.brand-tagline {
  font-size: 1.15rem;
  color: var(--text-dim);
  line-height: 1.7;
  margin-bottom: 40px;
}

.brand-features {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 48px;
}

.brand-feature {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.95rem;
  color: var(--text-dim);
}

.feature-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 12px rgba(0, 184, 148, 0.5);
  flex-shrink: 0;
}

.brand-stats {
  display: flex;
  gap: 40px;
}

.brand-stat strong {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  color: white;
}

.brand-stat span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Right Panel - Form */
.login-form-panel {
  width: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
  min-height: 100vh;
  overflow-y: auto;
}

.login-form-panel::before {
  content: '';
  position: absolute;
  top: 40px;
  bottom: 40px;
  left: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 24px;
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

.login-card-v2 {
  width: 100%;
  max-width: 380px;
  position: relative;
  z-index: 1;
}

.login-card-top {
  text-align: center;
  margin-bottom: 36px;
}

.login-card-top h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: white;
  margin-bottom: 8px;
}

.login-card-top p {
  font-size: 0.9rem;
  color: var(--text-dim);
}

/* Form Styles */
.login-form-v2 {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.input-group-v2 label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-dim);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-wrapper-v2 {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrapper-v2 i {
  position: absolute;
  left: 16px;
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: var(--transition);
}

.input-wrapper-v2 input {
  width: 100%;
  padding: 14px 16px 14px 46px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.input-wrapper-v2 input::placeholder {
  color: var(--text-muted);
}

.input-wrapper-v2 input:focus {
  border-color: var(--primary);
  background: var(--card);
  box-shadow: 0 0 0 3px rgba(79, 110, 247, 0.1);
}

.input-wrapper-v2 input:focus + i,
.input-wrapper-v2 input:focus ~ i {
  color: var(--green);
}

.toggle-pass {
  position: absolute;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.toggle-pass:hover { color: var(--text); }

.login-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.remember-me {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-dim);
  cursor: pointer;
}

.remember-me input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--green);
  cursor: pointer;
}

.forgot-pass {
  font-size: 0.85rem;
  color: var(--green);
  font-weight: 500;
  transition: var(--transition);
}

.forgot-pass:hover { color: #00d9a7; }

.login-error {
  display: none;
  padding: 12px 16px;
  background: rgba(225, 112, 85, 0.1);
  border: 1px solid rgba(225, 112, 85, 0.3);
  color: var(--red);
  border-radius: 10px;
  font-size: 0.85rem;
  align-items: center;
  gap: 8px;
}

.login-error.show { display: flex; }

.btn-login-v2 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 15px;
  background: var(--primary);
  border: none;
  border-radius: 12px;
  color: white;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-login-v2:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(79, 110, 247, 0.3);
}

.btn-login-v2 i {
  font-size: 0.85rem;
  transition: transform 0.3s ease;
}

.btn-login-v2:hover i {
  transform: translateX(4px);
}

.login-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 28px 0;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.login-divider span {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.social-login {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.social-btn {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-dim);
  font-size: 1.2rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-btn:hover {
  border-color: var(--border-light);
  background: rgba(255, 255, 255, 0.06);
  color: white;
  transform: translateY(-2px);
}

.login-card-bottom {
  text-align: center;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.login-card-bottom p {
  font-size: 0.9rem;
  color: var(--text-dim);
}

.login-card-bottom a {
  color: var(--green);
  font-weight: 600;
  transition: var(--transition);
}

.login-card-bottom a:hover { color: #00d9a7; }

.login-hint-v2 {
  text-align: center;
  margin-top: 16px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.login-hint-v2 strong {
  color: var(--text-dim);
}

/* ========== AUTH SCREEN (LOGIN / SIGNUP) ========== */
.auth-screen {
  min-height: 100vh;
  display: flex;
  background: var(--bg);
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
}

.auth-wrapper {
  display: flex;
  width: 100%;
  min-height: 100vh;
  position: relative;
  z-index: 1;
  align-items: center;
}

.auth-container {
  width: 100%;
  max-width: 420px;
  position: relative;
  z-index: 1;
}

/* Auth Choice */
.auth-choice {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.auth-choice-top {
  text-align: center;
}

.auth-welcome-icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.auth-choice-top h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.auth-choice-top p {
  font-size: 0.9rem;
  color: var(--text-dim);
}

.auth-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-option-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
  color: var(--text);
  box-shadow: var(--shadow);
}

.auth-option-card:hover {
  border-color: var(--primary);
  background: var(--primary-bg);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.auth-option-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.auth-option-icon.login-icon {
  background: var(--green-bg);
  color: var(--green);
  border: 1px solid rgba(34, 181, 115, 0.2);
}

.auth-option-icon.signup-icon {
  background: var(--primary-bg);
  color: var(--primary);
  border: 1px solid rgba(79, 110, 247, 0.2);
}

.auth-option-info {
  flex: 1;
}

.auth-option-info h3 {
  font-size: 1rem;
  font-weight: 600;
  color: white;
  margin-bottom: 4px;
}

.auth-option-info p {
  font-size: 0.8rem;
  color: var(--text-dim);
  line-height: 1.4;
}

.auth-option-arrow {
  color: var(--text-muted);
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.auth-option-card:hover .auth-option-arrow {
  color: white;
  transform: translateX(4px);
}

.auth-choice-admin {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.auth-choice-admin a {
  color: var(--primary);
  font-weight: 500;
  transition: color 0.2s;
}

.auth-choice-admin a:hover {
  color: var(--primary-light);
}

/* Auth Form Wrapper */
.auth-form-wrap {
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: authSlideIn 0.35s ease;
}

@keyframes authSlideIn {
  from { opacity: 0; transform: translateX(30px); }
  to { opacity: 1; transform: translateX(0); }
}

.auth-back {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  margin-bottom: -12px;
  width: fit-content;
  transition: color 0.2s;
}

.auth-back:hover { color: var(--primary); }

.auth-form-header {
  text-align: center;
}

.auth-form-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin: 0 auto 16px;
}

.auth-form-icon.login-icon {
  background: var(--green-bg);
  color: var(--green);
  border: 1px solid rgba(34, 181, 115, 0.2);
}

.auth-form-icon.signup-icon {
  background: var(--primary-bg);
  color: var(--primary);
  border: 1px solid rgba(79, 110, 247, 0.2);
}

.auth-form-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  margin-bottom: 6px;
}

.auth-form-header p {
  font-size: 0.85rem;
  color: var(--text-dim);
}

/* Category Grid for Signup */
.auth-category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  background: var(--bg);
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.auth-category-grid .ob-option {
  padding: 10px 8px;
  font-size: 0.78rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--card);
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.auth-category-grid .ob-option:hover {
  border-color: var(--primary);
  color: var(--text);
  background: var(--primary-bg);
}

.auth-category-grid .ob-option.selected {
  border-color: var(--primary);
  background: var(--primary-bg);
  color: var(--primary);
  font-weight: 500;
}

.btn-login-v2.signup-btn {
  background: var(--green);
}

.btn-login-v2.signup-btn:hover {
  box-shadow: 0 8px 30px rgba(34, 181, 115, 0.3);
}

/* Success */
.auth-success {
  text-align: center;
  padding: 40px 20px;
  animation: authSlideIn 0.4s ease;
}

.auth-success h2 {
  font-size: 1.8rem;
  font-weight: 700;
  color: white;
  margin: 16px 0 8px;
}

.auth-success p {
  font-size: 0.9rem;
  color: var(--text-dim);
  margin-bottom: 32px;
}

.auth-success .complete-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  font-size: 2rem;
  color: white;
  box-shadow: 0 10px 40px rgba(34, 181, 115, 0.3);
  animation: successPop 0.5s ease 0.2s both;
}

@keyframes successPop {
  from { transform: scale(0.5); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ========== ONBOARDING PARTICLES ========== */
.onboarding-particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.ob-particle {
  position: absolute;
  border-radius: 50%;
  background: rgba(0, 184, 148, 0.15);
  animation: obFloat linear infinite;
}

@keyframes obFloat {
  0% { transform: translateY(100vh) scale(0); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(-10vh) scale(1); opacity: 0; }
}

/* ========== ONBOARDING FLOW ========== */
.onboarding {
  position: fixed;
  inset: 0;
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at center, #e8edf5 0%, #dfe5f0 50%, #d0d8e8 100%);
}

.onboard-step {
  display: none;
  width: 100%;
  max-width: 580px;
  padding: 20px;
  animation: onboardFadeIn 0.5s ease;
}

.onboard-step.active { display: block; }

@keyframes onboardFadeIn {
  from { opacity: 0; transform: translateY(30px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.onboard-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 48px 40px;
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow-xl);
  position: relative;
  overflow: hidden;
}

.onboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

/* ========== WELCOME CARD ========== */
.welcome-card {
  text-align: center;
}

.welcome-title {
  font-size: 3rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  letter-spacing: -1px;
}

.welcome-sub {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 40px;
  line-height: 1.6;
}

.btn-get-started {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 36px;
  background: var(--primary);
  border: 1px solid var(--primary);
  border-radius: 14px;
  color: white;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-get-started:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(79, 110, 247, 0.3);
}

.btn-get-started i {
  font-size: 0.85rem;
  transform: rotate(45deg);
  transition: transform 0.3s ease;
}

.btn-get-started:hover i {
  transform: rotate(45deg) translate(2px, -2px);
}

/* ========== PROGRESS BAR ========== */
.onboard-progress {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
  padding: 0 8px;
}

.progress-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--green);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.progress-label i { font-size: 0.75rem; }

.progress-track {
  flex: 1;
  height: 6px;
  background: var(--bg2);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--green);
  border-radius: 3px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-pct {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-dim);
  min-width: 36px;
  text-align: right;
}

/* ========== QUESTION CARD ========== */
.onboard-question {
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--text);
  padding: 18px 22px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-bottom: 20px;
}

.onboard-input-wrap {
  display: flex;
  gap: 12px;
  align-items: center;
}

.onboard-input {
  flex: 1;
  padding: 16px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  font-size: 1rem;
  outline: none;
  transition: all 0.3s ease;
}

.onboard-input::placeholder { color: var(--text-muted); }

.onboard-input:focus {
  border-color: var(--primary);
  background: var(--card);
  box-shadow: 0 0 0 3px rgba(79, 110, 247, 0.1);
}

.onboard-next {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: none;
  background: var(--primary);
  color: white;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.onboard-next:hover {
  background: var(--primary);
  transform: scale(1.08);
  box-shadow: 0 4px 20px rgba(79, 110, 247, 0.3);
}

.onboard-hint {
  margin-top: 12px;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

.onboard-hint.error { color: var(--red); }
.onboard-hint.success { color: var(--green); }

/* ========== FORGOT PASSWORD MODAL ========== */
.forgot-form {
  padding: 24px 28px;
}

.forgot-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--primary-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 1.8rem;
  color: var(--primary);
}

.forgot-icon.success {
  background: var(--green-bg);
  color: var(--green);
}

.forgot-desc {
  text-align: center;
  color: var(--text-dim);
  font-size: 0.9rem;
  margin-bottom: 24px;
  line-height: 1.6;
}

/* ========== CATEGORY OPTIONS ========== */
.onboard-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.ob-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text-dim);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.ob-option i { font-size: 1rem; width: 20px; text-align: center; }

.ob-option:hover {
  background: var(--green-bg);
  border-color: rgba(34, 181, 115, 0.3);
  color: var(--text);
  transform: translateY(-2px);
}

.ob-option.selected {
  background: var(--green-bg);
  border-color: var(--green);
  color: var(--green);
  box-shadow: 0 4px 20px rgba(34, 181, 115, 0.15);
}

/* ========== COMPLETE CARD ========== */
.complete-card { text-align: center; }

.complete-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--green-bg);
  border: 2px solid var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 28px;
  font-size: 2rem;
  color: var(--green);
  animation: completePulse 2s ease-in-out infinite;
}

@keyframes completePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0, 184, 148, 0.2); }
  50% { box-shadow: 0 0 0 15px rgba(0, 184, 148, 0); }
}

/* ========== RESPONSIVE ========== */
@media (max-width: 600px) {
  .onboard-card { padding: 36px 24px; }
  .welcome-title { font-size: 2.2rem; }
  .onboard-options { grid-template-columns: 1fr; }
  .onboard-input { padding: 14px 16px; }
}

/* ========== FORM ELEMENTS ========== */
.form-group { margin-bottom: 16px; }

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-dim);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--primary);
}

.form-group select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238888a0'%3E%3Cpath d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  font-size: 0.85rem;
  border: none;
  transition: var(--transition);
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover { background: #5a4bd1; }

.btn-danger {
  background: var(--red);
  color: white;
}

.btn-danger:hover { background: #d63031; }

.btn-ghost {
  background: transparent;
  color: var(--text-dim);
  border: 1px solid var(--border);
}

.btn-ghost:hover { border-color: var(--text-dim); color: var(--text); }

.btn-full { width: 100%; justify-content: center; }

/* ========== ADMIN DASHBOARD LAYOUT ========== */
.admin-dashboard {
  display: flex;
  min-height: 100vh;
}

/* ========== SIDEBAR ========== */
.sidebar {
  width: 240px;
  background: var(--card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
  transition: var(--transition);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.brand-avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: white;
  flex-shrink: 0;
}

.brand-info { flex: 1; min-width: 0; }
.brand-name { display: block; font-weight: 600; font-size: 0.9rem; white-space: nowrap; }
.brand-status { display: block; font-size: 0.75rem; color: var(--green); }

.sidebar-collapse {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  transition: var(--transition);
}

.sidebar-collapse:hover { border-color: var(--text-dim); color: var(--text); }

.sidebar-section { flex: 1; padding: 16px 12px; overflow-y: auto; }

.sidebar-label {
  display: block;
  padding: 0 8px 8px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-dim);
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--transition);
}

.nav-item:hover {
  background: var(--bg2);
  color: var(--text);
}

.nav-item.active {
  background: var(--primary-bg);
  color: var(--primary);
  font-weight: 600;
}

.nav-item i { width: 18px; text-align: center; font-size: 0.9rem; }

.sidebar-footer {
  padding: 12px;
  border-top: 1px solid var(--border);
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-dim);
  font-size: 0.85rem;
  transition: var(--transition);
}

.sidebar-link:hover { background: var(--bg2); color: var(--text); }

/* ========== MAIN CONTENT ========== */
.admin-main {
  flex: 1;
  margin-left: 240px;
  min-height: 100vh;
}

/* ========== TOPBAR ========== */
.admin-topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--card);
  position: sticky;
  top: 0;
  z-index: 50;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.2rem;
}

.topbar-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  padding-right: 16px;
  border-right: 1px solid var(--border);
}

.logo-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: white;
}

.topbar-tabs {
  display: flex;
  gap: 4px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 3px;
}

.topbar-tab {
  padding: 6px 14px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: var(--text-dim);
  font-size: 0.8rem;
  font-weight: 500;
  transition: var(--transition);
}

.topbar-tab:hover { color: var(--text); }
.topbar-tab.active { background: var(--card); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,0.2); }

.topbar-search {
  flex: 1;
  max-width: 320px;
  position: relative;
  display: flex;
  align-items: center;
}

.topbar-search i { position: absolute; left: 12px; color: var(--text-muted); font-size: 0.85rem; }

.topbar-search input {
  width: 100%;
  padding: 8px 12px 8px 36px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  outline: none;
  transition: var(--transition);
}

.topbar-search input:focus { border-color: var(--primary); }

.topbar-search kbd {
  position: absolute;
  right: 8px;
  padding: 2px 6px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.65rem;
  color: var(--text-muted);
}

.topbar-actions { display: flex; align-items: center; gap: 8px; }

.topbar-icon-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  position: relative;
}

.topbar-icon-btn:hover { border-color: var(--text-dim); color: var(--text); }

.topbar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--pink));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.85rem;
  color: white;
}

/* ========== ADMIN CONTENT ========== */
.admin-content {
  padding: 24px;
}

.admin-tab { display: none; }
.admin-tab.active { display: block; animation: fadeIn 0.3s ease; }

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

/* ========== STATS GRID ========== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: var(--transition);
  box-shadow: var(--shadow);
}

.stat-card:hover { border-color: var(--primary); box-shadow: var(--shadow-lg); transform: translateY(-2px); }

.stat-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.stat-card-title {
  font-size: 0.85rem;
  color: var(--text-dim);
  font-weight: 500;
}

.stat-card-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

.stat-card-value {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 4px;
}

.stat-card-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ========== CARDS ========== */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.card-header h3 { font-size: 1rem; font-weight: 600; }
.card-sub { font-size: 0.8rem; color: var(--text-muted); margin-top: 2px; }

/* ========== DASHBOARD ROW ========== */
.dashboard-row {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 16px;
  margin-bottom: 20px;
}

/* ========== AGENDA ========== */
.agenda-nav { display: flex; gap: 4px; }

.agenda-nav-btn {
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  font-size: 0.8rem;
  font-weight: 500;
  transition: var(--transition);
}

.agenda-nav-btn:hover { border-color: var(--text-dim); color: var(--text); }
.agenda-nav-btn.agenda-today { border-color: var(--primary); color: var(--primary-light); }

.agenda-list { display: flex; flex-direction: column; gap: 8px; }

.agenda-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.agenda-item:hover { border-color: var(--border-light); }

.agenda-time {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
  min-width: 100px;
}

.agenda-badge {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: capitalize;
}

.badge-meeting { background: var(--primary-bg); color: var(--primary); }
.badge-call { background: var(--green-bg); color: var(--green); }
.badge-deadline { background: var(--red-bg); color: var(--red); }

.agenda-text { font-size: 0.85rem; font-weight: 500; }

/* ========== TASKS OVERVIEW ========== */
.tasks-progress { margin-top: 12px; }

.progress-bar {
  height: 10px;
  background: var(--bg);
  border-radius: 5px;
  display: flex;
  overflow: hidden;
  margin-bottom: 20px;
}

.progress-fill { height: 100%; transition: width 0.6s ease; }
.progress-open { background: var(--blue); }
.progress-done { background: var(--green); }

.progress-legend { display: flex; flex-direction: column; gap: 12px; }

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-dim);
}

.legend-item strong { color: var(--text); margin-left: auto; }
.legend-pct { color: var(--text-muted); font-size: 0.8rem; min-width: 32px; text-align: right; }

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dot-open { background: var(--blue); }
.dot-done { background: var(--green); }
.dot-overdue { background: var(--red); }

/* ========== ACTIVITY LIST ========== */
.activity-list { display: flex; flex-direction: column; }

.activity-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.activity-item:last-child { border-bottom: none; }
.activity-item:hover { background: var(--bg); padding-left: 8px; margin-left: -8px; margin-right: -8px; padding-right: 8px; border-radius: var(--radius-sm); }

.activity-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.activity-icon.icon-shop { background: var(--primary-bg); color: var(--primary); }
.activity-icon.icon-inquiry { background: var(--green-bg); color: var(--green); }
.activity-icon.icon-review { background: var(--orange-bg); color: var(--orange); }
.activity-icon.icon-task { background: var(--blue-bg); color: var(--blue); }
.activity-icon.icon-note { background: var(--pink-bg); color: var(--pink); }

.activity-info { flex: 1; min-width: 0; }
.activity-title { font-size: 0.85rem; font-weight: 500; }
.activity-desc { font-size: 0.78rem; color: var(--text-muted); margin-top: 2px; }

.activity-badge {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  white-space: nowrap;
}

.badge-open { background: rgba(116, 185, 255, 0.15); color: var(--blue); }
.badge-complete { background: rgba(0, 184, 148, 0.15); color: var(--green); }
.badge-pending { background: rgba(253, 203, 110, 0.15); color: var(--orange); }
.badge-new { background: rgba(108, 92, 231, 0.15); color: var(--primary-light); }

.activity-time { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; }

/* ========== TABLE ========== */
.tab-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.tab-header h2 { font-size: 1.2rem; font-weight: 600; }

.search-filter-bar {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.search-bar-sm {
  position: relative;
  flex: 1;
  max-width: 320px;
}

.search-bar-sm i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.85rem;
}

.search-bar-sm input {
  width: 100%;
  padding: 10px 12px 10px 36px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  outline: none;
  transition: var(--transition);
}

.search-bar-sm input:focus { border-color: var(--primary); }

.filter-select {
  padding: 10px 32px 10px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  outline: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238888a0'%3E%3Cpath d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.table-wrapper { overflow-x: auto; }

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border);
}

.admin-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 0.85rem;
}

.admin-table tr:last-child td { border-bottom: none; }

.admin-table tr:hover td { background: var(--bg); }

.status-badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.status-active { background: var(--green-bg); color: var(--green); }
.status-pending { background: var(--orange-bg); color: var(--orange); }
.status-inactive { background: var(--red-bg); color: var(--red); }

.table-actions { display: flex; gap: 6px; }

.table-actions button {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  transition: var(--transition);
}

.table-actions .btn-edit:hover { border-color: var(--primary); color: var(--primary-light); background: rgba(108, 92, 231, 0.1); }
.table-actions .btn-delete:hover { border-color: var(--red); color: var(--red); background: rgba(225, 112, 85, 0.1); }
.table-actions .btn-view:hover { border-color: var(--green); color: var(--green); background: rgba(0, 184, 148, 0.1); }

/* ========== CATEGORIES GRID ========== */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.category-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  transition: var(--transition);
  position: relative;
}

.category-card:hover { border-color: var(--border-light); transform: translateY(-2px); }

.category-card .cat-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(108, 92, 231, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  color: var(--primary-light);
  font-size: 1.2rem;
}

.category-card h4 { font-size: 0.9rem; margin-bottom: 4px; }
.category-card .cat-count { font-size: 0.8rem; color: var(--text-muted); }

.category-card .cat-actions {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: var(--transition);
}

.category-card:hover .cat-actions { opacity: 1; }

.category-card .cat-actions button {
  width: 26px;
  height: 26px;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}

/* ========== ANALYTICS ========== */
.analytics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.analytics-list { display: flex; flex-direction: column; gap: 10px; }

.analytics-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.analytics-row:last-child { border-bottom: none; }

.analytics-label { flex: 1; font-size: 0.85rem; }

.analytics-bar-wrap {
  width: 120px;
  height: 8px;
  background: var(--bg2);
  border-radius: 4px;
  overflow: hidden;
}

.analytics-bar {
  height: 100%;
  border-radius: 3px;
  background: var(--primary);
  transition: width 0.6s ease;
}

.analytics-count { font-size: 0.85rem; font-weight: 600; min-width: 24px; text-align: right; }

/* ========== TASKS ========== */
.tasks-list { display: flex; flex-direction: column; gap: 8px; }

.task-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: var(--transition);
  box-shadow: var(--shadow);
}

.task-item:hover { border-color: var(--primary); box-shadow: var(--shadow-lg); }

.task-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border-light);
  background: var(--card);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  flex-shrink: 0;
}

.task-check:hover { border-color: var(--green); }
.task-check.done { border-color: var(--green); background: var(--green); color: white; font-size: 0.7rem; }

.task-info { flex: 1; }
.task-title { font-size: 0.9rem; font-weight: 500; }
.task-title.done { text-decoration: line-through; color: var(--text-muted); }
.task-meta { font-size: 0.78rem; color: var(--text-muted); margin-top: 2px; }

.task-priority {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
}

.priority-high { background: var(--red-bg); color: var(--red); }
.priority-medium { background: var(--orange-bg); color: var(--orange); }
.priority-low { background: var(--blue-bg); color: var(--blue); }

/* ========== CALENDAR ========== */
.calendar-month {
  font-size: 1.1rem;
  font-weight: 600;
  min-width: 180px;
  text-align: center;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-header {
  padding: 10px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}

.cal-day {
  padding: 12px;
  text-align: center;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  color: var(--text-dim);
  background: var(--card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: var(--transition);
  min-height: 60px;
}

.cal-day:hover { border-color: var(--border-light); }
.cal-day.today { border-color: var(--primary); color: var(--primary-light); font-weight: 600; }
.cal-day.empty { background: transparent; border-color: transparent; }
.cal-day .cal-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--primary); margin: 4px auto 0; }

/* ========== NOTES ========== */
.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}

.note-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: var(--transition);
  position: relative;
}

.note-card:hover { border-color: var(--border-light); transform: translateY(-2px); }

.note-card .note-stripe {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: var(--radius) var(--radius) 0 0;
}

.note-card h4 { font-size: 0.95rem; margin-bottom: 8px; }
.note-card p { font-size: 0.82rem; color: var(--text-dim); line-height: 1.6; }
.note-card .note-date { font-size: 0.72rem; color: var(--text-muted); margin-top: 12px; }

.note-card .note-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: var(--transition);
}

.note-card:hover .note-actions { opacity: 1; }

.note-card .note-actions button {
  width: 26px;
  height: 26px;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}

.color-picker { display: flex; gap: 8px; }

.color-opt input { display: none; }

.color-opt span {
  display: block;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  border: 3px solid transparent;
  transition: var(--transition);
}

.color-opt input:checked + span { border-color: white; transform: scale(1.1); }

/* ========== SETTINGS ========== */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.settings-card h3 {
  font-size: 1rem;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.settings-card h3 i { color: var(--primary-light); }
.settings-card p { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 16px; }
.settings-card.danger { border-color: rgba(225, 112, 85, 0.3); }

/* ========== MODALS ========== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  padding: 20px;
}

.modal-overlay.active { opacity: 1; visibility: visible; }

.modal {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.95) translateY(10px);
  transition: var(--transition);
}

.modal-overlay.active .modal { transform: scale(1) translateY(0); }
.modal-lg { max-width: 640px; }
.modal-sm { max-width: 400px; }

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

.modal-header h2 { font-size: 1.15rem; font-weight: 600; }

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.modal-close:hover { border-color: var(--red); color: var(--red); }

.modal form { padding: 24px 28px; }

.form-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* ========== CONFIRM MODAL ========== */
.confirm-modal {
  text-align: center;
  padding: 40px;
}

.confirm-icon {
  width: 64px;
  height: 64px;
  background: rgba(225, 112, 85, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 1.5rem;
  color: var(--red);
}

.confirm-modal h3 { font-size: 1.15rem; margin-bottom: 8px; }
.confirm-modal p { color: var(--text-dim); font-size: 0.9rem; margin-bottom: 24px; }

.confirm-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

/* ========== TOAST ========== */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  color: white;
  font-weight: 500;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: slideInRight 0.3s ease;
  box-shadow: var(--shadow);
  min-width: 260px;
}

.toast-success { background: var(--green); color: white; }
.toast-error { background: var(--red); color: white; }
.toast-info { background: var(--primary); color: white; }

.toast.fade-out { animation: fadeOut 0.3s ease forwards; }

@keyframes slideInRight { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
@keyframes fadeOut { to { opacity: 0; transform: translateX(20px); } }

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-row { grid-template-columns: 1fr; }
  .analytics-grid { grid-template-columns: 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
  .login-branding { padding: 40px; }
  .brand-headline { font-size: 2.5rem; }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
    z-index: 200;
    width: 260px;
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
  }
  .sidebar.active {
    transform: translateX(0);
  }
  .sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 199;
  }
  .sidebar-overlay.active { display: block; }
  .admin-main { margin-left: 0; }
  .menu-toggle { display: block; }
  .admin-content { padding: 12px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat-card { padding: 14px; }
  .stat-card-value { font-size: 1.5rem; }
  .topbar-tabs { display: none; }
  .topbar-search kbd { display: none; }
  .topbar-search { max-width: 160px; }
  .topbar-search input { padding: 6px 8px 6px 32px; font-size: 0.8rem; }
  .admin-topbar { padding: 10px 12px; gap: 8px; }
  .topbar-logo span { display: none; }
  .topbar-actions { gap: 4px; }
  .form-row { grid-template-columns: 1fr; }
  .tab-header { flex-direction: column; gap: 10px; align-items: stretch; }
  .search-filter-bar { flex-direction: column; }
  .search-bar-sm { max-width: 100%; }
  .filter-select { width: 100%; }
  .table-wrapper { margin: 0 -12px; padding: 0 12px; }
  .admin-table { min-width: 600px; }
  .dashboard-row { grid-template-columns: 1fr; }
  .agenda-nav { flex-wrap: wrap; }
  .notes-grid { grid-template-columns: 1fr; }
  .categories-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .calendar-grid { gap: 2px; }
  .cal-day { padding: 8px 4px; min-height: 44px; font-size: 0.8rem; }
  .cal-header { font-size: 0.65rem; padding: 6px 2px; }
  .settings-grid { grid-template-columns: 1fr; }
  .modal form { padding: 16px; }
  .modal-header { padding: 16px; }

  /* Auth Responsive */
  .auth-wrapper { flex-direction: column; }
  .login-branding {
    width: 100%;
    padding: 24px 24px 16px;
    min-height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .branding-content { max-width: 400px; }
  .brand-headline { font-size: 1.8rem; }
  .brand-tagline { font-size: 0.95rem; margin-bottom: 20px; }
  .brand-features { gap: 10px; margin-bottom: 20px; }
  .brand-feature { font-size: 0.85rem; }
  .brand-stats { gap: 20px; }
  .brand-stat strong { font-size: 1.3rem; }
  .login-form-panel {
    width: 100%;
    padding: 20px 16px;
    min-height: auto;
  }
  .login-form-panel::before {
    top: 10px;
    bottom: 10px;
    left: 8px;
    right: 8px;
    border-radius: 16px;
  }
  .login-card-v2 { max-width: 100%; }
  .auth-container { max-width: 100%; padding: 0 4px; }
  .auth-form-wrap { gap: 16px; }
  .auth-back { margin-bottom: -8px; }
  .auth-form-header h2 { font-size: 1.3rem; }
  .auth-form-header p { font-size: 0.8rem; }
  .auth-form-icon { width: 48px; height: 48px; font-size: 1.1rem; margin-bottom: 12px; }
  .login-form-v2 { gap: 14px; }
  .input-wrapper-v2 input { padding: 12px 14px 12px 42px; font-size: 0.9rem; }
  .input-wrapper-v2 i { left: 14px; font-size: 0.85rem; }
  .btn-login-v2 { padding: 13px; font-size: 0.9rem; }
  .auth-option-card { padding: 14px 16px; }
  .auth-option-icon { width: 40px; height: 40px; font-size: 1rem; border-radius: 10px; }
  .auth-option-info h3 { font-size: 0.85rem; }
  .auth-option-info p { font-size: 0.7rem; }
  .auth-option-card { gap: 12px; }
  .login-options { font-size: 0.8rem; }
  .auth-category-grid { gap: 8px; }
  .ob-option { padding: 10px 12px; font-size: 0.8rem; }

  /* Login Responsive (for admin.html) */
  .login-wrapper { flex-direction: column; }
  .login-wrapper .login-branding {
    width: 100%;
    padding: 30px 24px;
    min-height: auto;
  }
  .login-wrapper .login-branding .brand-headline { font-size: 1.8rem; }
  .login-wrapper .login-branding .brand-tagline { font-size: 0.95rem; }
  .login-wrapper .login-branding .brand-features { gap: 10px; margin-bottom: 20px; }
  .login-wrapper .login-branding .brand-stats { gap: 20px; }
  .login-wrapper .login-form-panel {
    width: 100%;
    padding: 16px;
    min-height: auto;
  }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 6px; }
  .stat-card { padding: 12px; }
  .stat-card-value { font-size: 1.3rem; }
  .stat-card-sub { font-size: 0.7rem; }
  .admin-content { padding: 8px; }
  .login-branding { display: none; }
  .login-form-panel { padding: 12px 8px; }
  .login-form-panel::before { top: 4px; bottom: 4px; left: 4px; right: 4px; border-radius: 12px; }
  .auth-container { padding: 0; }
  .brand-headline { font-size: 1.5rem; }
  .brand-logo { margin-bottom: 24px; }
  .brand-features { gap: 8px; }
  .brand-feature { font-size: 0.8rem; gap: 10px; }
  .brand-stats { gap: 16px; flex-wrap: wrap; justify-content: center; }
  .brand-stat strong { font-size: 1.1rem; }
  .auth-option-card { padding: 12px; gap: 10px; border-radius: 12px; }
  .auth-option-icon { width: 36px; height: 36px; font-size: 0.9rem; border-radius: 8px; }
  .auth-option-info h3 { font-size: 0.8rem; }
  .auth-option-info p { font-size: 0.65rem; line-height: 1.3; }
  .auth-back { font-size: 0.8rem; }
  .auth-form-header h2 { font-size: 1.15rem; }
  .auth-form-header p { font-size: 0.75rem; }
  .auth-form-icon { width: 42px; height: 42px; font-size: 1rem; margin-bottom: 10px; border-radius: 12px; }
  .input-wrapper-v2 input { padding: 11px 12px 11px 38px; font-size: 0.85rem; border-radius: 10px; }
  .input-wrapper-v2 i { left: 12px; font-size: 0.8rem; }
  .btn-login-v2 { padding: 12px; font-size: 0.85rem; border-radius: 10px; }
  .auth-category-grid { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .ob-option { padding: 8px 10px; font-size: 0.75rem; }
  .auth-divider { margin: 12px 0; }
  .btn-google-signin { padding: 10px 16px; font-size: 0.85rem; }
  .auth-choice-top h2 { font-size: 1.3rem; }
  .auth-welcome-icon { font-size: 2rem; margin-bottom: 8px; }
}

/* Google Sign-In Button */
.auth-divider {
  text-align: center;
  margin: 16px 0;
  position: relative;
}
.auth-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border);
}
.auth-divider span {
  background: var(--card);
  padding: 0 12px;
  position: relative;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.btn-google-signin {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-google-signin:hover {
  background: var(--bg2);
  border-color: var(--border-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.btn-google-signin i {
  font-size: 1.1rem;
  color: #ea4335;
}

/* ========== DISCORD TESTER ========== */
.discord-test-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.discord-test-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.discord-test-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.discord-test-card h4 {
  font-size: 0.9rem;
  color: var(--text);
  margin: 0;
}

.discord-test-card p {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
}

.dtc-header {
  display: flex;
  justify-content: flex-start;
}

.discord-test-card .badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
}

.discord-test-card .badge.create { background: #d1fae5; color: #065f46; }
.discord-test-card .badge.update { background: #ede9fe; color: #5b21b6; }
.discord-test-card .badge.delete { background: #fee2e2; color: #991b1b; }

.discord-announce-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  min-width: 300px;
}

.discord-log {
  margin-top: 20px;
  background: #0d1b2a;
  border-radius: 10px;
  padding: 14px;
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  max-height: 200px;
  overflow-y: auto;
  color: #94a3b8;
  display: none;
}

.discord-log .ok { color: #34d399; }
.discord-log .fail { color: #f87171; }

@media (max-width: 768px) {
  .discord-test-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .discord-test-grid { grid-template-columns: 1fr; }
}
