/**
 * Captives SSL Service - Premium Design System
 * Modern, Professional UI with Glass Morphism & Smooth Animations
 */

/* ========================================
   CSS Custom Properties (Design Tokens)
   ======================================== */
:root {
  --primary-50: #eff6ff;
  --primary-100: #dbeafe;
  --primary-200: #bfdbfe;
  --primary-300: #93c5fd;
  --primary-400: #60a5fa;
  --primary-500: #3b82f6;
  --primary-600: #2563eb;
  --primary-700: #1d4ed8;
  --primary-800: #1e40af;
  --primary-900: #1e3a8a;
  --accent-500: #8b5cf6;
  --accent-600: #7c3aed;
  --success-50: #ecfdf5;
  --success-100: #d1fae5;
  --success-500: #10b981;
  --success-600: #059669;
  --success-700: #047857;
  --warning-50: #fffbeb;
  --warning-100: #fef3c7;
  --warning-500: #f59e0b;
  --warning-600: #d97706;
  --error-50: #fef2f2;
  --error-100: #fee2e2;
  --error-500: #ef4444;
  --error-600: #dc2626;
  --info-50: #eff6ff;
  --info-100: #dbeafe;
  --info-500: #3b82f6;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --gray-400: #94a3b8;
  --gray-500: #64748b;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1e293b;
  --gray-900: #0f172a;
  --max-width: 1280px;
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-sm: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -1px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,.1), 0 10px 10px -5px rgba(0,0,0,.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(255, 255, 255, 0.3);
  --glass-blur: blur(20px);
  /* backward compat */
  --primary-color: #2563eb;
  --primary-dark: #1e40af;
  --secondary-color: #64748b;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  --bg-color: #f8fafc;
  --card-bg: #ffffff;
  --text-color: #1e293b;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
}

/* ========================================
   Reset & Base
   ======================================== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-sans);
  background: var(--gray-50);
  color: var(--gray-800);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: var(--primary-600); text-decoration: none; transition: color var(--transition-fast); }
a:hover { color: var(--primary-700); }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.3; color: var(--gray-900); }
h1 { font-size: 2rem; } h2 { font-size: 1.5rem; } h3 { font-size: 1.25rem; }
p { color: var(--gray-600); line-height: 1.7; }
code, pre { font-family: var(--font-mono); }

/* ========================================
   Navbar
   ======================================== */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--gray-200);
  transition: box-shadow var(--transition-base), background var(--transition-base), border-color var(--transition-base);
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
/* Dark navbar on homepage (blends with hero) */
.homepage .navbar,
.navbar.navbar-dark {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom-color: rgba(0,0,0,0.06);
}
.homepage .navbar .nav-link { color: var(--gray-600); }
.homepage .navbar .nav-link:hover { color: var(--primary-600); background: var(--primary-50); }
.homepage .navbar .nav-link.active { color: var(--primary-600); background: var(--primary-50); }
.homepage .navbar .nav-link.active::after { background: var(--primary-500); }
.homepage .navbar .navbar-brand h1 {
  background: linear-gradient(135deg, var(--primary-600), var(--accent-600));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.homepage .navbar .navbar-toggle { color: var(--gray-600); }
.homepage .navbar.scrolled {
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-md);
}
.navbar .container { display: flex; justify-content: space-between; align-items: center; height: 64px; }

.navbar-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.navbar-brand .brand-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 700; font-size: 1.1rem;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}
.navbar-brand h1 {
  font-size: 1.25rem; font-weight: 800;
  background: linear-gradient(135deg, var(--primary-600), var(--accent-600));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; letter-spacing: -0.5px;
}

.navbar-menu { display: flex; align-items: center; gap: 4px; }
.nav-link {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: var(--radius-md);
  color: var(--gray-600); font-weight: 500; font-size: 0.9rem;
  text-decoration: none; transition: all var(--transition-fast);
  position: relative;
}
.nav-link svg { width: 18px; height: 18px; opacity: 0.7; transition: opacity var(--transition-fast); }
.nav-link:hover { color: var(--primary-600); background: var(--primary-50); }
.nav-link:hover svg { opacity: 1; }
.nav-link.active { color: var(--primary-600); background: var(--primary-50); font-weight: 600; }
.nav-link.active::after {
  content: ''; position: absolute; bottom: -1px; left: 16px; right: 16px;
  height: 2px; background: var(--primary-500); border-radius: 2px 2px 0 0;
}
.navbar-toggle {
  display: none; background: none; border: none; padding: 8px;
  cursor: pointer; color: var(--gray-600); border-radius: var(--radius-sm);
}
.navbar-toggle:hover { background: var(--gray-100); }
.navbar-toggle svg { width: 24px; height: 24px; }

/* ========================================
   Container & Layout
   ======================================== */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.main-content { flex: 1; padding: 32px 0; animation: fadeInUp 0.5s ease-out; }
.main-content.homepage { padding-top: 0; }
.page-header { text-align: center; margin-bottom: 40px; }
.page-header h1 { font-size: 2rem; margin-bottom: 8px; display: flex; align-items: center; justify-content: center; gap: 12px; }
.page-header .page-subtitle { color: var(--gray-500); font-size: 1.05rem; }

/* ========================================
   Hero Section
   ======================================== */
.hero {
  position: relative;
  background: #ffffff;
  color: var(--gray-900);
  padding: 80px 0 60px;
  overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 55% at 15% 65%, rgba(59, 130, 246, 0.13) 0%, transparent 70%),
    radial-gradient(ellipse 65% 55% at 85% 25%, rgba(139, 92, 246, 0.11) 0%, transparent 65%),
    radial-gradient(ellipse 55% 45% at 50% 90%, rgba(16, 185, 129, 0.09) 0%, transparent 55%);
  pointer-events: none;
}
.hero::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 80px;
  background: linear-gradient(to top, var(--gray-50), transparent); pointer-events: none;
}
/* Dot pattern overlay */
.hero-mesh {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.35;
  background-image: radial-gradient(circle, rgba(0,0,0,0.07) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, black 0%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, black 0%, transparent 80%);
}
/* Floating gradient blobs */
.hero-orb {
  position: absolute; border-radius: 50%; filter: blur(80px); pointer-events: none;
  animation: orb-float 10s ease-in-out infinite;
}
.hero-orb-1 {
  width: 450px; height: 450px; top: -120px; left: -100px;
  background: rgba(59, 130, 246, 0.18);
  animation-delay: 0s;
}
.hero-orb-2 {
  width: 380px; height: 380px; bottom: -100px; right: -80px;
  background: rgba(139, 92, 246, 0.14);
  animation-delay: -3s;
}
.hero-orb-3 {
  width: 300px; height: 300px; top: 35%; left: 55%;
  background: rgba(16, 185, 129, 0.12);
  animation-delay: -6s;
}
@keyframes orb-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(15px, -20px) scale(1.05); }
  66% { transform: translate(-10px, 10px) scale(0.95); }
}
.hero .container { position: relative; z-index: 1; }
.hero-content { max-width: 720px; margin: 0 auto; text-align: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; background: rgba(59, 130, 246, 0.08);
  border: 1px solid rgba(59, 130, 246, 0.15);
  border-radius: var(--radius-full); font-size: 0.85rem;
  font-weight: 500; color: var(--primary-600); margin-bottom: 24px;
}
.hero-badge svg { width: 16px; height: 16px; }
.hero-title {
  font-size: 3rem; font-weight: 800; line-height: 1.15;
  margin-bottom: 16px; letter-spacing: -1px; color: var(--gray-900);
}
.hero-title .gradient-text {
  background: linear-gradient(135deg, #3b82f6, #8b5cf6, #10b981);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.hero-subtitle { font-size: 1.15rem; color: var(--gray-500); line-height: 1.7; max-width: 560px; margin: 0 auto; }
.hero-particles { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.particle {
  position: absolute; width: 2px; height: 2px;
  background: rgba(59, 130, 246, 0.3); border-radius: 50%;
  animation: float-particle linear infinite;
}
@keyframes float-particle {
  0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
  10% { opacity: 1; } 90% { opacity: 1; }
  100% { transform: translateY(-100px) rotate(720deg); opacity: 0; }
}

/* ========================================
   Cards
   ======================================== */
.card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); padding: 24px;
  transition: all var(--transition-base);
}
.card:hover { box-shadow: var(--shadow-lg); border-color: var(--gray-300); }
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--gray-100);
}
.card-header h2 { display: flex; align-items: center; gap: 10px; font-size: 1.15rem; }
.card-header h2 .icon {
  width: 32px; height: 32px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
}
.card-header h2 .icon svg { width: 18px; height: 18px; }
.card-header h2 .icon.primary { background: var(--primary-100); color: var(--primary-600); }
.card-header h2 .icon.success { background: var(--success-100); color: var(--success-600); }
.card-header h2 .icon.warning { background: var(--warning-100); color: var(--warning-600); }
.card-header h2 .icon.accent { background: #f3e8ff; color: var(--accent-600); }

.info-card, .registration-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); padding: 28px;
  margin-bottom: 24px; transition: all var(--transition-base);
}
.info-card:hover { box-shadow: var(--shadow-md); }
.info-card h2 {
  display: flex; align-items: center; gap: 10px; font-size: 1.2rem;
  margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--gray-100);
}
.card-description { color: var(--gray-500); margin-bottom: 24px; font-size: 0.95rem; }

/* ========================================
   Stats
   ======================================== */
.stats-bar {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px; margin-bottom: 32px;
}
.stat-item {
  background: white; padding: 24px; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); text-align: center;
  transition: all var(--transition-base); position: relative; overflow: hidden;
}
.stat-item::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--primary-500), var(--accent-500));
  opacity: 0; transition: opacity var(--transition-base);
}
.stat-item:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.stat-item:hover::before { opacity: 1; }
.stat-value {
  font-size: 2.5rem; font-weight: 800;
  background: linear-gradient(135deg, var(--primary-600), var(--accent-500));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; line-height: 1.2;
}
.stat-label { color: var(--gray-500); margin-top: 6px; font-size: 0.875rem; font-weight: 500; }

.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px; margin-bottom: 28px;
}
.stat-card {
  background: white; padding: 24px; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); display: flex; align-items: center;
  gap: 16px; transition: all var(--transition-base);
  position: relative; overflow: hidden;
}
.stat-card::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--primary-500), var(--accent-500));
  opacity: 0; transition: opacity var(--transition-base);
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.stat-card:hover::after { opacity: 1; }
.stat-card:nth-child(1)::after { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.stat-card:nth-child(2)::after { background: linear-gradient(90deg, #10b981, #34d399); }
.stat-card:nth-child(3)::after { background: linear-gradient(90deg, #8b5cf6, #a78bfa); }
.stat-card:nth-child(4)::after { background: linear-gradient(90deg, #f59e0b, #fbbf24); }

.stat-icon {
  width: 52px; height: 52px; border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; flex-shrink: 0;
}
.stat-card:nth-child(1) .stat-icon { background: var(--primary-100); color: var(--primary-600); }
.stat-card:nth-child(2) .stat-icon { background: var(--success-100); color: var(--success-600); }
.stat-card:nth-child(3) .stat-icon { background: #f3e8ff; color: var(--accent-600); }
.stat-card:nth-child(4) .stat-icon { background: var(--warning-100); color: var(--warning-600); }

.stat-info { flex: 1; }
.stat-info .stat-value {
  font-size: 1.75rem; background: none;
  -webkit-text-fill-color: var(--gray-900); color: var(--gray-900);
}
.stat-info .stat-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.5px; }

/* ========================================
   Forms
   ======================================== */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; margin-bottom: 6px; font-weight: 600;
  font-size: 0.9rem; color: var(--gray-700);
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 10px 14px;
  border: 2px solid var(--gray-200); border-radius: var(--radius-md);
  font-size: 0.95rem; font-family: var(--font-sans);
  color: var(--gray-800); background: white;
  transition: all var(--transition-fast); outline: none;
}
.form-group input::placeholder { color: var(--gray-400); }
.form-group input:hover { border-color: var(--gray-300); }
.form-group input:focus { border-color: var(--primary-500); box-shadow: 0 0 0 3px rgba(59,130,246,0.1); }
.form-group input.error { border-color: var(--error-500); box-shadow: 0 0 0 3px rgba(239,68,68,0.1); }
.form-group input.success { border-color: var(--success-500); box-shadow: 0 0 0 3px rgba(16,185,129,0.1); }

.input-group { display: flex; align-items: center; gap: 0; }
.input-group input { flex: 1; border-top-right-radius: 0; border-bottom-right-radius: 0; border-right: none; }
.input-suffix {
  padding: 10px 14px; background: var(--gray-100);
  border: 2px solid var(--gray-200); border-left: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  color: var(--gray-500); font-weight: 600; font-size: 0.9rem;
  white-space: nowrap; height: 44px; display: flex; align-items: center;
}
.form-help { display: block; margin-top: 6px; font-size: 0.8rem; color: var(--gray-400); }
.field-status {
  margin-top: 6px; font-size: 0.85rem; font-weight: 600;
  display: flex; align-items: center; gap: 6px;
}
.field-status.success { color: var(--success-600); }
.field-status.error { color: var(--error-600); }

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 20px; border: none; border-radius: var(--radius-md);
  font-size: 0.9rem; font-weight: 600; font-family: var(--font-sans);
  text-decoration: none; cursor: pointer;
  transition: all var(--transition-base); white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary {
  background: linear-gradient(135deg, var(--primary-500), var(--primary-600));
  color: white; box-shadow: 0 2px 8px rgba(59,130,246,0.3);
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-600), var(--primary-700));
  transform: translateY(-1px); box-shadow: 0 4px 12px rgba(59,130,246,0.4); color: white;
}
.btn-secondary {
  background: white; color: var(--gray-700);
  border: 1px solid var(--gray-300); box-shadow: var(--shadow-xs);
}
.btn-secondary:hover { background: var(--gray-50); border-color: var(--gray-400); color: var(--gray-800); }
.btn-outline {
  background: transparent; color: var(--gray-500);
  border: 1px dashed var(--gray-300); font-size: 0.85rem;
  padding: 0.5rem 1rem;
}
.btn-outline:hover { background: var(--gray-50); border-color: var(--gray-400); border-style: solid; color: var(--gray-700); }
.btn-success {
  background: linear-gradient(135deg, var(--success-500), var(--success-600));
  color: white; box-shadow: 0 2px 8px rgba(16,185,129,0.3);
}
.btn-success:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(16,185,129,0.4); color: white; }
.btn-danger {
  background: linear-gradient(135deg, var(--error-500), var(--error-600));
  color: white; box-shadow: 0 2px 8px rgba(239,68,68,0.3);
}
.btn-danger:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(239,68,68,0.4); color: white; }
.btn-warning {
  background: linear-gradient(135deg, var(--warning-500), var(--warning-600));
  color: white; box-shadow: 0 2px 8px rgba(245,158,11,0.3);
}
.btn-warning:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(245,158,11,0.4); color: white; }
.btn-ghost { background: transparent; color: var(--gray-600); padding: 8px 12px; }
.btn-ghost:hover { background: var(--gray-100); color: var(--gray-800); }
.btn-lg { padding: 12px 28px; font-size: 1rem; }
.btn-sm { padding: 6px 14px; font-size: 0.8rem; }
.btn-block { display: flex; width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; box-shadow: none !important; }
.btn .spinner {
  width: 18px; height: 18px; border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white; border-radius: 50%; animation: spin 0.6s linear infinite;
}
.btn-random {
  margin-left: 8px; padding: 10px 14px; border-radius: var(--radius-md);
  background: var(--gray-100); color: var(--gray-600);
  border: 2px solid var(--gray-200); font-size: 0.85rem; height: 44px;
}
.btn-random:hover { background: var(--primary-50); border-color: var(--primary-200); color: var(--primary-600); }

/* ========================================
   Alerts
   ======================================== */
.alert {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 18px; border-radius: var(--radius-md);
  margin-bottom: 20px; font-size: 0.9rem; border: 1px solid;
  animation: fadeInDown 0.3s ease-out;
}
.alert svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; }
.alert-success { background: var(--success-50); color: var(--success-700); border-color: var(--success-100); }
.alert-warning { background: var(--warning-50); color: var(--warning-600); border-color: var(--warning-100); }
.alert-error { background: var(--error-50); color: var(--error-600); border-color: var(--error-100); }
.alert-info { background: var(--info-50); color: var(--primary-800); border-color: var(--info-100); }

.form-message {
  margin-top: 16px; padding: 12px 16px; border-radius: var(--radius-md);
  font-weight: 600; font-size: 0.9rem;
  display: flex; align-items: center; gap: 8px; animation: fadeInUp 0.3s ease-out;
}
.form-message.success { background: var(--success-50); color: var(--success-700); border: 1px solid var(--success-100); }
.form-message.error { background: var(--error-50); color: var(--error-600); border: 1px solid var(--error-100); }

/* ========================================
   Status Badges
   ======================================== */
.status-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 12px; border-radius: var(--radius-full);
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px;
}
.status-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.status-active { background: var(--success-100); color: var(--success-700); }
.status-active::before { background: var(--success-500); box-shadow: 0 0 6px var(--success-500); animation: pulse-dot 2s infinite; }
.status-pending { background: var(--warning-100); color: var(--warning-600); }
.status-pending::before { background: var(--warning-500); }
.status-warning { background: var(--warning-100); color: var(--warning-700); }
.status-warning::before { background: var(--warning-500); animation: pulse-dot 2s infinite; }
.status-expired, .status-error { background: var(--error-100); color: var(--error-600); }
.status-expired::before, .status-error::before { background: var(--error-500); }
.status-deleted { background: var(--gray-100); color: var(--gray-500); }
.status-deleted::before { background: var(--gray-400); }

/* ========================================
   Tables
   ======================================== */
.data-table { width: 100%; border-collapse: separate; border-spacing: 0; }
.data-table th {
  padding: 12px 16px; text-align: left; font-size: 0.75rem;
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--gray-500); background: var(--gray-50);
  border-bottom: 1px solid var(--gray-200);
}
.data-table th:first-child { border-radius: var(--radius-md) 0 0 0; }
.data-table th:last-child { border-radius: 0 var(--radius-md) 0 0; }
.data-table td {
  padding: 14px 16px; border-bottom: 1px solid var(--gray-100);
  font-size: 0.9rem; color: var(--gray-700);
}
.data-table tbody tr { transition: background var(--transition-fast); }
.data-table tbody tr:hover { background: var(--primary-50); }
.data-table tbody tr:last-child td { border-bottom: none; }
.no-data { text-align: center; color: var(--gray-400); padding: 40px 16px !important; font-style: italic; }
.table-footer { padding-top: 16px; text-align: right; }

/* ========================================
   Info Grid
   ======================================== */
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.info-item { display: flex; flex-direction: column; gap: 4px; padding: 12px 0; }
.info-label { font-size: 0.8rem; color: var(--gray-400); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.info-value { font-size: 0.95rem; color: var(--gray-800); font-weight: 500; }

/* ========================================
   Features
   ======================================== */
.features-section { margin-top: 48px; }
.features-section h3 { text-align: center; font-size: 1.5rem; margin-bottom: 32px; }
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px;
}
.feature-item {
  background: white; border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); padding: 28px 24px;
  text-align: center; transition: all var(--transition-base);
}
.feature-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary-200); }
.feature-icon {
  width: 56px; height: 56px; border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px; font-size: 1.5rem;
}
.feature-item:nth-child(1) .feature-icon { background: var(--primary-100); color: var(--primary-600); }
.feature-item:nth-child(2) .feature-icon { background: var(--success-100); color: var(--success-600); }
.feature-item:nth-child(3) .feature-icon { background: #f3e8ff; color: var(--accent-600); }
.feature-item:nth-child(4) .feature-icon { background: var(--warning-100); color: var(--warning-600); }
.feature-item h4 { margin-bottom: 8px; font-size: 1.05rem; }
.feature-item p { font-size: 0.875rem; color: var(--gray-500); }

.info-section { margin-top: 32px; }
.info-section h3 { font-size: 1.25rem; margin-bottom: 20px; }
.features-list {
  list-style: none; display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px;
}
.features-list li {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; background: white;
  border: 1px solid var(--gray-200); border-radius: var(--radius-md);
  font-size: 0.9rem; color: var(--gray-700); transition: all var(--transition-fast);
}
.features-list li:hover { border-color: var(--primary-200); background: var(--primary-50); }
.features-list li svg { width: 20px; height: 20px; color: var(--success-500); flex-shrink: 0; }

/* ========================================
   Client Details
   ======================================== */
.client-details { max-width: 900px; margin: 0 auto; }
.subdomain-display { font-size: 1.3rem; font-family: var(--font-mono); color: var(--primary-600); font-weight: 600; margin-bottom: 8px; }
.download-buttons { display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.installation-instructions { margin-top: 24px; }
.instruction-method {
  margin-top: 16px; padding: 20px; background: var(--gray-50);
  border: 1px solid var(--gray-200); border-radius: var(--radius-md);
}
.instruction-method h4 { margin-bottom: 12px; color: var(--primary-600); }
.instruction-method ol { margin-left: 20px; }
.instruction-method li { margin-bottom: 8px; color: var(--gray-600); }
.pending-message { text-align: center; padding: 48px 24px; }
.pending-icon {
  width: 80px; height: 80px; border-radius: 50%;
  background: var(--primary-100); display: flex; align-items: center;
  justify-content: center; margin: 0 auto 20px; animation: pulse 2s infinite;
}
.pending-icon svg { width: 40px; height: 40px; color: var(--primary-500); animation: spin 3s linear infinite; }

/* ========================================
   Admin
   ======================================== */
.admin-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 28px; }
.admin-header h1 { display: flex; align-items: center; gap: 10px; }
.admin-actions { display: flex; gap: 10px; align-items: center; }
.user-info {
  font-size: 0.875rem; color: var(--gray-500); font-weight: 500;
  padding: 6px 14px; background: var(--gray-100); border-radius: var(--radius-full);
}
.quick-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; margin-bottom: 28px; }
.action-card {
  background: white; border: 1px solid var(--gray-200); padding: 24px;
  border-radius: var(--radius-lg); text-align: center; cursor: pointer;
  transition: all var(--transition-base); text-decoration: none;
  color: var(--gray-800); position: relative; overflow: hidden;
}
.action-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  opacity: 0; transition: opacity var(--transition-base);
}
.action-card:nth-child(1)::before { background: linear-gradient(90deg, var(--primary-500), var(--accent-500)); }
.action-card:nth-child(2)::before { background: linear-gradient(90deg, var(--success-500), #34d399); }
.action-card:nth-child(3)::before { background: linear-gradient(90deg, var(--warning-500), #fbbf24); }
.action-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--gray-300); }
.action-card:hover::before { opacity: 1; }
.action-icon {
  width: 52px; height: 52px; border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px; font-size: 1.5rem;
}
.action-card:nth-child(1) .action-icon { background: var(--primary-100); }
.action-card:nth-child(2) .action-icon { background: var(--success-100); }
.action-card:nth-child(3) .action-icon { background: var(--warning-100); }
.action-card h3 { font-size: 1rem; margin-bottom: 4px; }
.action-card p { font-size: 0.825rem; color: var(--gray-500); }

.cert-details-grid, .cert-info-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px;
}
.cert-detail-item, .cert-info-item {
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px 16px; background: var(--gray-50);
  border-radius: var(--radius-md); border: 1px solid var(--gray-100);
}
.cert-detail-item .label, .cert-info-item .cert-label {
  font-size: 0.75rem; color: var(--gray-400); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.cert-detail-item .value, .cert-info-item .cert-value {
  font-size: 0.9rem; color: var(--gray-800); font-weight: 500;
}
.expiry-warning { color: var(--warning-600) !important; font-weight: 700 !important; }

.logs-container { max-height: 400px; overflow-y: auto; }
.log-entry {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: var(--radius-sm);
  font-size: 0.85rem; border-left: 3px solid transparent;
  transition: background var(--transition-fast);
}
.log-entry:hover { background: var(--gray-50); }
.log-entry.log-info { border-left-color: var(--primary-400); }
.log-entry.log-warning { border-left-color: var(--warning-500); }
.log-entry.log-error { border-left-color: var(--error-500); }
.log-time { color: var(--gray-400); font-size: 0.8rem; font-family: var(--font-mono); white-space: nowrap; }
.log-category { font-weight: 600; color: var(--gray-500); font-size: 0.8rem; }
.log-message { flex: 1; color: var(--gray-700); }

.pagination {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  padding-top: 20px; border-top: 1px solid var(--gray-100); margin-top: 16px;
}
.page-info { color: var(--gray-500); font-size: 0.85rem; font-weight: 500; }

/* ========================================
   Login Page
   ======================================== */
.login-page {
  display: flex; justify-content: center; align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 50%, #7c3aed 100%);
  position: relative; overflow: hidden;
}
.login-page::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 20% 50%, rgba(59,130,246,0.3) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(139,92,246,0.3) 0%, transparent 50%);
  pointer-events: none;
}
.login-container { width: 100%; max-width: 420px; padding: 24px; position: relative; z-index: 1; }
.login-card {
  background: rgba(255,255,255,0.95); backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.3); border-radius: var(--radius-xl);
  padding: 36px 32px; box-shadow: var(--shadow-2xl); animation: fadeInUp 0.5s ease-out;
}
.login-header { text-align: center; margin-bottom: 28px; }
.login-header .login-icon {
  width: 56px; height: 56px; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px; color: white; box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}
.login-header .login-icon svg { width: 28px; height: 28px; }
.login-header h1 { font-size: 1.5rem; margin-bottom: 4px; }
.login-header p { color: var(--gray-500); font-size: 0.9rem; }
.login-footer { text-align: center; margin-top: 24px; }
.login-footer a { color: var(--gray-500); font-size: 0.85rem; font-weight: 500; }
.login-footer a:hover { color: var(--primary-600); }

/* ========================================
   MikroTik Section
   ======================================== */
.mikrotik-section {
  margin-top: 24px; padding: 20px; background: var(--gray-50);
  border: 1px solid var(--gray-200); border-radius: var(--radius-md);
}
.mikrotik-section h4 {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 16px; color: var(--primary-700); font-size: 0.95rem;
}
.dns-preview {
  margin-top: 12px; padding: 14px 18px; background: white;
  border: 1px solid var(--gray-200); border-radius: var(--radius-md); font-size: 0.875rem;
}
.dns-preview .preview-label {
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; color: var(--gray-400); margin-bottom: 8px;
}
.dns-preview .preview-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; color: var(--gray-600); }
.dns-preview .preview-row strong { color: var(--primary-600); font-family: var(--font-mono); font-size: 0.85rem; }
.dns-preview .preview-row .arrow { color: var(--gray-400); }

.certificate-details .cert-actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.no-certificate { text-align: center; padding: 48px 24px; }
.no-certificate h3 { margin-bottom: 8px; color: var(--gray-600); }
.no-certificate p { margin-bottom: 20px; }

/* ========================================
   Status Page
   ======================================== */
.status-grid { display: grid; gap: 12px; margin-top: 16px; }
.status-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 0; border-bottom: 1px solid var(--gray-100);
}
.status-item:last-child { border-bottom: none; }
.status-item .label { color: var(--gray-500); font-weight: 500; font-size: 0.9rem; }
.status-item .value { font-weight: 500; color: var(--gray-800); }
.button-group { display: flex; gap: 10px; flex-wrap: wrap; }

/* ========================================
   Modal
   ======================================== */
.modal {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
  justify-content: center; align-items: center; z-index: 1000;
}
.modal-content {
  background: white; padding: 28px; border-radius: var(--radius-xl);
  max-width: 600px; width: 90%; max-height: 80vh; overflow-y: auto;
  box-shadow: var(--shadow-2xl); animation: modalSlideIn 0.3s ease-out;
}
.modal-close {
  float: right; width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); cursor: pointer; color: var(--gray-400);
  transition: all var(--transition-fast); font-size: 1.5rem;
}
.modal-close:hover { background: var(--gray-100); color: var(--gray-700); }
.progress-steps { margin: 20px 0; }
.progress-step {
  padding: 10px 16px; border-left: 3px solid var(--gray-200);
  margin-bottom: 8px; font-size: 0.9rem; color: var(--gray-500);
}
.progress-step.active {
  border-left-color: var(--primary-500); color: var(--primary-700);
  font-weight: 600; background: var(--primary-50);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.progress-step.done { border-left-color: var(--success-500); color: var(--success-700); }

/* ========================================
   Error Page
   ======================================== */
.error-page { text-align: center; padding: 80px 24px; }
.error-code {
  font-size: 7rem; font-weight: 900;
  background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; line-height: 1; margin-bottom: 12px;
}
.error-page h1 { font-size: 1.5rem; margin-bottom: 8px; }
.error-message { color: var(--gray-500); margin-bottom: 32px; max-width: 500px; margin-left: auto; margin-right: auto; }
.error-details { margin-top: 24px; text-align: left; max-width: 700px; margin-left: auto; margin-right: auto; }
.error-details pre {
  background: var(--gray-900); color: #e2e8f0; padding: 16px;
  border-radius: var(--radius-md); overflow-x: auto; font-size: 0.8rem; line-height: 1.6;
}
.error-actions { display: flex; justify-content: center; gap: 12px; }

/* ========================================
   Maintenance Page
   ======================================== */
.maintenance-page {
  display: flex; justify-content: center; align-items: center; min-height: 100vh;
  background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 50%, #7c3aed 100%);
}
.maintenance-container { text-align: center; color: white; max-width: 500px; padding: 24px; }
.maintenance-icon {
  width: 80px; height: 80px; border-radius: 50%;
  background: rgba(255,255,255,0.15); display: flex;
  align-items: center; justify-content: center;
  margin: 0 auto 24px; animation: pulse 2s infinite;
}
.maintenance-icon svg { width: 40px; height: 40px; }
.maintenance-container h1 { margin-bottom: 12px; color: white; }
.maintenance-container p { color: rgba(255,255,255,0.8); margin-bottom: 8px; }
.maintenance-note { margin-top: 16px; font-size: 0.875rem; }

/* ========================================
   Footer
   ======================================== */
.footer { background: white; border-top: 1px solid var(--gray-200); padding: 24px 0; margin-top: auto; }
.footer .container { display: flex; justify-content: space-between; align-items: center; }
.footer-left p { font-size: 0.85rem; color: var(--gray-500); }
.footer-right { display: flex; align-items: center; gap: 16px; }
.footer-link { font-size: 0.85rem; color: var(--gray-400); }
.footer-link:hover { color: var(--primary-600); }
.footer-divider { width: 1px; height: 16px; background: var(--gray-200); }

/* ========================================
   Loading
   ======================================== */
.loading {
  text-align: center; padding: 32px; color: var(--gray-400);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.loading .spinner {
  width: 32px; height: 32px; border: 3px solid var(--gray-200);
  border-top-color: var(--primary-500); border-radius: 50%; animation: spin 0.8s linear infinite;
}
.skeleton {
  background: linear-gradient(90deg, var(--gray-100) 25%, var(--gray-200) 50%, var(--gray-100) 75%);
  background-size: 200% 100%; animation: skeleton-shimmer 1.5s infinite; border-radius: var(--radius-sm);
}

/* ========================================
   Code
   ======================================== */
code {
  background: var(--gray-100); padding: 2px 8px; border-radius: 4px;
  font-size: 0.85em; color: var(--primary-700);
  border: 1px solid var(--gray-200); font-family: var(--font-mono);
}
pre code {
  display: block; padding: 16px; background: var(--gray-900); color: #e2e8f0;
  border-radius: var(--radius-md); overflow-x: auto; border: none;
  font-size: 0.85rem; line-height: 1.6;
}

/* ========================================
   Animations
   ======================================== */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes slideOut { from { transform: translateX(0); opacity: 1; } to { transform: translateX(100%); opacity: 0; } }
@keyframes modalSlideIn { from { opacity: 0; transform: translateY(-20px) scale(0.95); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes pulse-dot { 0%, 100% { box-shadow: 0 0 0 0 currentColor; } 50% { box-shadow: 0 0 0 4px transparent; } }
@keyframes skeleton-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.reveal { opacity: 0; transform: translateY(20px); transition: all 0.6s ease-out; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ========================================
   Scrollbar
   ======================================== */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--gray-100); }
::-webkit-scrollbar-thumb { background: var(--gray-300); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--gray-400); }

/* ========================================
   Notification Toast
   ======================================== */
.notification {
  position: fixed; top: 20px; right: 20px;
  padding: 14px 20px; border-radius: var(--radius-md);
  color: white; font-weight: 600; font-size: 0.9rem;
  box-shadow: var(--shadow-xl); z-index: 9999;
  animation: slideIn 0.3s ease-out;
  display: flex; align-items: center; gap: 10px; max-width: 380px;
}
.notification-success { background: var(--success-600); }
.notification-error { background: var(--error-600); }
.notification-info { background: var(--primary-600); }

/* ========================================
   Utilities
   ======================================== */
.text-muted { color: var(--gray-500); }
.text-center { text-align: center; }
.text-primary { color: var(--primary-600); }
.font-mono { font-family: var(--font-mono); }
.font-bold { font-weight: 700; }
.full-width { grid-column: 1 / -1; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-2 { margin-bottom: 16px; }

.feature-list h3 { margin-bottom: 12px; font-size: 1rem; }
.feature-list ul { list-style: none; }
.feature-list li { padding: 6px 0; color: var(--gray-600); font-size: 0.9rem; display: flex; align-items: center; gap: 8px; }

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 768px) {
  .container { padding: 0 16px; }
  .navbar .container { height: 56px; }
  .navbar-toggle { display: flex; }
  .navbar-menu {
    display: none; position: absolute; top: 56px; left: 0; right: 0;
    background: white; border-bottom: 1px solid var(--gray-200);
    padding: 8px 16px; flex-direction: column; box-shadow: var(--shadow-lg);
  }
  .navbar-menu.open { display: flex; }
  .nav-link { padding: 12px 16px; width: 100%; }
  .nav-link.active::after { display: none; }
  h1 { font-size: 1.5rem; }
  .hero { padding: 48px 0 40px; }
  .hero-title { font-size: 2rem; }
  .hero-subtitle { font-size: 1rem; }
  .stats-bar, .stats-grid, .quick-actions, .features-grid { grid-template-columns: 1fr; }
  .admin-header { flex-direction: column; gap: 12px; align-items: flex-start; }
  .admin-actions { width: 100%; flex-wrap: wrap; }
  .download-buttons { flex-direction: column; }
  .data-table { display: block; overflow-x: auto; }
  .footer .container { flex-direction: column; gap: 12px; text-align: center; }
  .error-code { font-size: 5rem; }
  .features-list { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; }
  .cert-details-grid, .cert-info-grid { grid-template-columns: 1fr; }
  .input-group { flex-wrap: wrap; }
  .btn-random { width: 100%; margin-left: 0; margin-top: 8px; }
}
@media (max-width: 480px) {
  .hero { padding: 36px 0 32px; }
  .hero-title { font-size: 1.75rem; }
  .stat-value { font-size: 2rem; }
  .login-card { padding: 28px 20px; }
  .button-group { flex-direction: column; }
}

/* ====== Certificate Health Summary (Admin SSL) ====== */
.cert-health-summary {
  display: flex; gap: 16px; margin-bottom: 24px; flex-wrap: wrap;
}
.health-stat {
  flex: 1; min-width: 100px;
  padding: 16px; border-radius: var(--radius-lg);
  background: var(--glass-bg); backdrop-filter: blur(8px);
  text-align: center; border: 1px solid var(--glass-border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.health-stat:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.health-stat.healthy { border-left: 4px solid var(--success-500); }
.health-stat.warning { border-left: 4px solid var(--warning-500); }
.health-stat.expired,
.health-stat.error { border-left: 4px solid var(--error-500); }
.health-label {
  display: block; font-size: 0.8rem; font-weight: 500;
  color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.05em;
  margin-bottom: 4px;
}
.health-value {
  display: block; font-size: 1.75rem; font-weight: 700;
  color: var(--gray-900);
}
.health-stat.healthy .health-value { color: var(--success-600); }
.health-stat.warning .health-value { color: var(--warning-600); }
.health-stat.expired .health-value,
.health-stat.error .health-value { color: var(--error-600); }

.expiry-warning { color: var(--error-500); font-weight: 600; }
.btn-sm {
  padding: 6px 14px; font-size: 0.8rem;
  border-radius: var(--radius-md);
}

/* ====== Table Responsive Wrapper ====== */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius-lg); }

/* ========================================
   Homepage Layout (Redesign)
   ======================================== */
.homepage .hero-compact { padding: 56px 0 44px; }
.hero-stats {
  display: inline-flex; align-items: center; gap: 0;
  margin-top: 32px; padding: 12px 32px;
  background: rgba(255,255,255,0.65); border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg); backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
}
.hero-stat { text-align: center; padding: 0 22px; }
.hero-stat strong {
  display: block; font-size: 1.6rem; font-weight: 800;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  line-height: 1.2;
}
.hero-stat span { font-size: 0.7rem; color: var(--gray-500); font-weight: 600; text-transform: uppercase; letter-spacing: 0.8px; }
.hero-stat-divider { width: 1px; height: 32px; background: var(--gray-200); }

.homepage-layout {
  display: grid; grid-template-columns: 1fr 340px; gap: 32px;
  align-items: start; margin-top: -20px; position: relative; z-index: 2;
}

/* Registration Card */
.reg-card {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); padding: 32px;
  box-shadow: var(--shadow-lg);
}
.reg-card-header { text-align: center; margin-bottom: 28px; }
.reg-icon {
  width: 52px; height: 52px; border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 14px; color: white;
  box-shadow: 0 4px 12px rgba(59,130,246,0.3);
}
.reg-card-header h2 { font-size: 1.35rem; margin-bottom: 6px; }
.reg-card-header p { color: var(--gray-500); font-size: 0.9rem; }

/* Step Indicator */
.step-indicator {
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 28px; padding: 0 8px;
}
.step-indicator .step {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  flex-shrink: 0;
}
.step-circle {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--gray-100); border: 2px solid var(--gray-300);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 700; color: var(--gray-400);
  transition: all var(--transition-base);
}
.step-indicator .step span {
  font-size: 0.7rem; font-weight: 600; color: var(--gray-400);
  transition: color var(--transition-base); white-space: nowrap;
}
.step-indicator .step.active .step-circle {
  background: var(--primary-500); border-color: var(--primary-500); color: white;
  box-shadow: 0 2px 8px rgba(59,130,246,0.3);
}
.step-indicator .step.active span { color: var(--primary-600); }
.step-indicator .step.done .step-circle {
  background: var(--success-500); border-color: var(--success-500); color: white;
}
.step-indicator .step.done span { color: var(--success-600); }

.step-line {
  flex: 1; height: 2px; background: var(--gray-200);
  margin: 0 8px; margin-bottom: 18px;
  transition: background var(--transition-base);
}
.step-line.done { background: var(--success-500); }

/* Form Rows */
.form-row-help {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 6px;
}
.label-optional { color: var(--gray-400); font-weight: 400; font-size: 0.8rem; }
.btn-inline {
  background: none; border: none; color: var(--primary-500);
  font-size: 0.8rem; font-weight: 600; cursor: pointer;
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 8px; border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}
.btn-inline:hover { background: var(--primary-50); color: var(--primary-700); }
.btn-inline:disabled { opacity: 0.5; cursor: not-allowed; }

/* CAPTCHA Box */
.captcha-box {
  background: var(--gray-50); border: 2px solid var(--gray-200);
  border-radius: var(--radius-md); padding: 14px 18px;
  margin-bottom: 20px; transition: all var(--transition-base);
}
.captcha-box.captcha-ok { border-color: var(--success-500); background: var(--success-50); }
.captcha-box.captcha-error { border-color: var(--error-500); background: var(--error-50); }
.captcha-header {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.8rem; font-weight: 600; color: var(--gray-500);
  margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px;
}
.captcha-header svg { width: 14px; height: 14px; }
.captcha-challenge {
  display: flex; align-items: center; gap: 10px;
}
.captcha-question {
  font-size: 1.25rem; font-weight: 700; color: var(--gray-800);
  font-family: var(--font-mono); letter-spacing: 2px;
  min-width: 80px;
}
.captcha-equals {
  font-size: 1.2rem; font-weight: 600; color: var(--gray-400);
}
.captcha-challenge input {
  width: 60px; padding: 8px 12px; text-align: center;
  border: 2px solid var(--gray-300); border-radius: var(--radius-md);
  font-size: 1.1rem; font-weight: 700; font-family: var(--font-mono);
  color: var(--gray-800); outline: none;
  transition: border-color var(--transition-fast);
}
.captcha-challenge input:focus { border-color: var(--primary-500); }
.captcha-ok .captcha-challenge input { border-color: var(--success-500); color: var(--success-700); }
.captcha-error .captcha-challenge input { border-color: var(--error-500); color: var(--error-600); }
.captcha-refresh {
  background: none; border: none; cursor: pointer;
  color: var(--gray-400); padding: 6px; border-radius: var(--radius-sm);
  transition: all var(--transition-fast); margin-left: auto;
}
.captcha-refresh:hover { color: var(--primary-500); background: var(--primary-50); }

/* Email Verification Step */
.verify-prompt { text-align: center; margin-bottom: 28px; }
.verify-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--primary-50); display: flex; align-items: center;
  justify-content: center; margin: 0 auto 14px; color: var(--primary-500);
}
.verify-prompt p { font-size: 0.95rem; color: var(--gray-700); margin-bottom: 4px; }
.verify-prompt small { color: var(--gray-400); font-size: 0.8rem; }

.otp-input-group {
  display: flex; justify-content: center; align-items: center;
  gap: 8px; margin-bottom: 24px;
}
.otp-input {
  width: 44px; height: 52px; text-align: center;
  border: 2px solid var(--gray-300); border-radius: var(--radius-md);
  font-size: 1.3rem; font-weight: 700; font-family: var(--font-mono);
  color: var(--gray-800); outline: none;
  transition: all var(--transition-fast);
}
.otp-input:focus { border-color: var(--primary-500); box-shadow: 0 0 0 3px rgba(59,130,246,0.1); }
.otp-dash { font-size: 1.2rem; color: var(--gray-300); font-weight: 600; }

.verify-actions {
  display: flex; justify-content: center; gap: 16px;
  margin-top: 16px;
}

/* Preview Box */
.preview-box {
  background: var(--gray-50); border: 1px solid var(--gray-200);
  border-radius: var(--radius-md); padding: 16px 20px;
  margin-bottom: 20px;
}
.preview-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.85rem; font-weight: 600; color: var(--gray-600);
  margin-bottom: 12px;
}
.preview-items { display: flex; flex-direction: column; gap: 10px; }
.preview-item {
  display: flex; align-items: center; gap: 12px;
  font-size: 0.85rem;
}
.preview-label {
  min-width: 80px; color: var(--gray-400); font-weight: 600;
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.3px;
}
.preview-value { color: var(--gray-700); font-family: var(--font-mono); font-size: 0.8rem; }

/* How It Works - Sidebar */
.how-it-works {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200); padding: 28px;
  position: sticky; top: 88px;
}
.how-it-works h3 {
  font-size: 1.1rem; margin-bottom: 20px;
  padding-bottom: 12px; border-bottom: 1px solid var(--gray-100);
}
.steps-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; }
.step-item { display: flex; gap: 12px; align-items: flex-start; }
.step-num {
  width: 28px; height: 28px; flex-shrink: 0;
  border-radius: 50%; background: var(--primary-50);
  color: var(--primary-600); font-weight: 700; font-size: 0.8rem;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--primary-100);
}
.step-item h4 { font-size: 0.9rem; margin-bottom: 2px; }
.step-item p { font-size: 0.8rem; color: var(--gray-500); line-height: 1.4; }

.features-compact { margin-top: 4px; }
.features-compact h4 {
  font-size: 0.9rem; margin-bottom: 12px;
  padding-top: 16px; border-top: 1px solid var(--gray-100);
  color: var(--gray-600);
}
.features-compact ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.features-compact li {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.8rem; color: var(--gray-600);
}

/* ========================================
   Homepage Responsive
   ======================================== */
@media (max-width: 900px) {
  .homepage-layout { grid-template-columns: 1fr; }
  .how-it-works { position: static; }
  .hero-stats { flex-wrap: wrap; justify-content: center; padding: 10px 16px; border-radius: var(--radius-md); }
}
@media (max-width: 480px) {
  .reg-card { padding: 20px; }
  .step-indicator .step span { font-size: 0.6rem; }
  .step-circle { width: 28px; height: 28px; font-size: 0.75rem; }
  .otp-input { width: 38px; height: 46px; font-size: 1.1rem; }
  .captcha-question { font-size: 1.1rem; min-width: 60px; }
  .preview-item { flex-direction: column; gap: 2px; }
  .preview-label { min-width: auto; }
}

/* ====== CLI Commands (inside info-card) ====== */
.cli-group {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cli-item {}
.cli-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gray-700);
}
.cli-step {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--primary-50);
  color: var(--primary-600);
  font-size: 0.68rem; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.cli-step--green { background: #ecfdf5; color: #16a34a; }
.cli-step--amber { background: #fffbeb; color: #d97706; }
.cli-step--orange { background: #fff7ed; color: #ea580c; }
.cli-step--red { background: #fef2f2; color: #dc2626; }

.cli-badge {
  font-size: 0.6rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.4px;
  padding: 2px 8px; border-radius: 9999px;
  margin-left: auto;
}
.cli-badge--blue  { background: #eff6ff; color: #2563eb; }
.cli-badge--amber { background: #fffbeb; color: #d97706; }
.cli-badge--orange{ background: #fff7ed; color: #ea580c; }
.cli-badge--red   { background: #fef2f2; color: #dc2626; }

/* The actual terminal box */
.cli-box {
  display: flex;
  align-items: stretch;
  background: #1e1e1e;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #333;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.cli-box:hover {
  border-color: #555;
}
.cli-box.copied {
  border-color: #22c55e;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.15);
}
.cli-box--danger {
  border-color: rgba(220, 38, 38, 0.25);
}
.cli-box--danger:hover {
  border-color: rgba(220, 38, 38, 0.5);
}

/* $ prompt */
.cli-prompt {
  display: flex;
  align-items: center;
  padding: 0 0 0 14px;
  color: #4ec9b0;
  font-family: 'Menlo', 'Monaco', 'Cascadia Code', 'Consolas', 'Liberation Mono', monospace;
  font-weight: 700;
  font-size: 0.78rem;
  user-select: none;
  flex-shrink: 0;
}

/* command text */
.cli-cmd {
  flex: 1;
  display: block;
  padding: 10px 12px;
  color: #d4d4d4;
  font-family: 'Menlo', 'Monaco', 'Cascadia Code', 'Consolas', 'Liberation Mono', monospace;
  font-size: 0.72rem;
  line-height: 1.6;
  word-break: break-all;
  white-space: pre-wrap;
  user-select: all;
}
.cli-cmd--danger { color: #fca5a5; }

/* copy button */
.cli-copy {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  min-width: 38px;
  background: transparent;
  border: none;
  outline: none;
  border-left: 1px solid #333;
  color: #666;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.cli-copy:hover {
  background: #2a2a2a;
  color: #ccc;
}

/* info note */
.cli-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--gray-500);
  padding: 8px 12px;
  background: var(--gray-50);
  border-radius: 6px;
  border: 1px solid var(--gray-100);
}
.cli-note svg { flex-shrink: 0; opacity: 0.5; }

@media (max-width: 600px) {
  .cli-cmd { font-size: 0.64rem; padding: 8px 10px; }
  .cli-prompt { padding-left: 10px; font-size: 0.7rem; }
}
