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

:root {
  --navy: #0A2540;
  --navy-light: #0F3460;
  --blue: #00D4FF;
  --blue-dark: #00A8CC;
  --white: #FFFFFF;
  --gray: #8892B0;
  --gray-light: #CCD6F6;
  --surface: #112240;
  --surface-light: #1A365D;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--navy);
  color: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ─── NAVBAR ─── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 37, 64, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 212, 255, 0.08);
  transition: background 0.3s ease;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--white);
}

.navbar-logo svg {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
}

.navbar-logo span {
  background: linear-gradient(135deg, var(--blue), var(--white));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.navbar-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-light);
  transition: color 0.25s ease;
  position: relative;
}

.navbar-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--blue);
  transition: width 0.3s ease;
}

.navbar-links a:hover,
.navbar-links a.active {
  color: var(--blue);
}

.navbar-links a:hover::after,
.navbar-links a.active::after {
  width: 100%;
}

.navbar-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.navbar-toggle span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--white);
  transition: all 0.3s ease;
  border-radius: 2px;
}

/* ─── HERO ─── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.05) 0%, transparent 70%);
  pointer-events: none;
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-content {
  max-width: 560px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 212, 255, 0.1);
  border: 1px solid rgba(0, 212, 255, 0.2);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue);
  margin-bottom: 24px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.hero-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--blue);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.hero h1 {
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -1px;
}

.hero h1 .highlight {
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.1rem;
  color: var(--gray);
  margin-bottom: 36px;
  max-width: 480px;
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-illustration {
  width: 100%;
  max-width: 500px;
  height: auto;
}

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  font-family: inherit;
}

.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  color: var(--navy);
  box-shadow: 0 4px 20px rgba(0, 212, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 212, 255, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--blue);
  border: 1.5px solid rgba(0, 212, 255, 0.4);
}

.btn-outline:hover {
  background: rgba(0, 212, 255, 0.08);
  border-color: var(--blue);
}

.btn-group {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ─── SECTIONS ─── */
.section {
  padding: 100px 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 64px;
}

.section-header h2 {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.section-header p {
  color: var(--gray);
  font-size: 1.05rem;
}

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--blue);
  margin-bottom: 12px;
}

/* ─── PROBLEM / SOLUTION CARDS ─── */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.card {
  background: var(--surface);
  border-radius: 16px;
  padding: 40px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  transition: all 0.3s ease;
}

.card:hover {
  border-color: rgba(0, 212, 255, 0.15);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.card-icon {
  width: 56px;
  height: 56px;
  background: rgba(0, 212, 255, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.card-icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--blue);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card h3 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.card p {
  color: var(--gray);
  font-size: 0.95rem;
}

/* ─── STATS ─── */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 80px;
}

.stat-item {
  text-align: center;
  padding: 32px;
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid rgba(0, 212, 255, 0.06);
}

.stat-number {
  font-size: 2.8rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--gray);
  margin-top: 8px;
}

/* ─── PROCESS / HOW IT WORKS ─── */
.process-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  position: relative;
}

.process-steps::before {
  content: '';
  position: absolute;
  top: 50px;
  left: 16.66%;
  right: 16.66%;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), rgba(0, 212, 255, 0.2));
}

.step {
  text-align: center;
  position: relative;
  z-index: 1;
}

.step-number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--blue);
}

.step h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.step p {
  color: var(--gray);
  font-size: 0.9rem;
  max-width: 280px;
  margin: 0 auto;
}

/* ─── FEATURES GRID ─── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.feature-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 36px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: rgba(0, 212, 255, 0.15);
  transform: translateY(-3px);
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.feature-card h3 .feature-dot {
  width: 8px;
  height: 8px;
  background: var(--blue);
  border-radius: 50%;
  flex-shrink: 0;
}

.feature-card p {
  color: var(--gray);
  font-size: 0.9rem;
}

/* ─── ABOUT PAGE ─── */
.page-hero {
  padding: 160px 0 80px;
  text-align: center;
  position: relative;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.page-hero h1 {
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 16px;
}

.page-hero p {
  color: var(--gray);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.content-section {
  padding: 80px 0;
}

.content-block {
  max-width: 800px;
  margin: 0 auto;
}

.content-block h2 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.3px;
}

.content-block p {
  color: var(--gray);
  font-size: 1.05rem;
  margin-bottom: 20px;
}

.content-block ul {
  list-style: none;
  padding: 0;
  margin-bottom: 20px;
}

.content-block ul li {
  color: var(--gray);
  font-size: 1rem;
  padding: 8px 0;
  padding-left: 28px;
  position: relative;
}

.content-block ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 16px;
  width: 8px;
  height: 8px;
  background: var(--blue);
  border-radius: 50%;
}

/* ─── TECHNOLOGY PAGE ─── */
.tech-diagram {
  background: var(--surface);
  border-radius: 20px;
  padding: 60px 40px;
  border: 1px solid rgba(0, 212, 255, 0.08);
  margin: 60px 0;
}

.tech-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.tech-node {
  text-align: center;
  padding: 28px 24px;
  background: var(--surface-light);
  border-radius: 16px;
  border: 1px solid rgba(0, 212, 255, 0.1);
  min-width: 180px;
  transition: all 0.3s ease;
}

.tech-node:hover {
  border-color: var(--blue);
  transform: translateY(-3px);
}

.tech-node svg {
  width: 40px;
  height: 40px;
  stroke: var(--blue);
  fill: none;
  stroke-width: 1.5;
  margin-bottom: 12px;
}

.tech-node h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.tech-node p {
  font-size: 0.8rem;
  color: var(--gray);
}

.tech-arrow {
  color: var(--blue);
  font-size: 1.5rem;
  flex-shrink: 0;
}

.accuracy-comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-top: 60px;
}

.accuracy-item {
  background: var(--surface);
  border-radius: 16px;
  padding: 40px;
  border: 1px solid rgba(0, 212, 255, 0.06);
}

.accuracy-item h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.accuracy-bar-container {
  margin: 20px 0;
}

.accuracy-bar {
  height: 12px;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}

.accuracy-bar.before {
  background: rgba(255, 100, 100, 0.2);
  width: 100%;
}

.accuracy-bar.before .fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, #FF6464, #FF4646);
  border-radius: 6px;
  width: 85%;
}

.accuracy-bar.after {
  background: rgba(0, 212, 255, 0.1);
  width: 100%;
}

.accuracy-bar.after .fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), #6C63FF);
  border-radius: 6px;
  width: 15%;
}

.accuracy-value {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--gray);
  margin-top: 8px;
}

/* ─── CONTACT PAGE ─── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-form {
  background: var(--surface);
  border-radius: 20px;
  padding: 48px;
  border: 1px solid rgba(0, 212, 255, 0.06);
}

.form-group {
  margin-bottom: 24px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gray-light);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 18px;
  background: var(--navy);
  border: 1.5px solid rgba(0, 212, 255, 0.1);
  border-radius: 10px;
  color: var(--white);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.3s ease;
  outline: none;
}

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

.form-group textarea {
  resize: vertical;
  min-height: 140px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(136, 146, 176, 0.5);
}

.contact-info {
  padding-top: 12px;
}

.contact-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.contact-info > p {
  color: var(--gray);
  margin-bottom: 40px;
  font-size: 1rem;
}

.info-item {
  display: flex;
  gap: 16px;
  margin-bottom: 32px;
  align-items: flex-start;
}

.info-item .info-icon {
  width: 48px;
  height: 48px;
  background: rgba(0, 212, 255, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-item .info-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--blue);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.info-item h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.info-item p {
  color: var(--gray);
  font-size: 0.9rem;
  line-height: 1.6;
}

.success-message {
  background: rgba(0, 212, 255, 0.1);
  border: 1px solid rgba(0, 212, 255, 0.2);
  border-radius: 12px;
  padding: 16px 20px;
  color: var(--blue);
  font-weight: 600;
  text-align: center;
  margin-bottom: 24px;
  animation: fadeIn 0.5s ease;
}

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

/* ─── CTA SECTION ─── */
.cta-section {
  padding: 100px 0;
  text-align: center;
  position: relative;
}

.cta-box {
  background: linear-gradient(135deg, var(--surface-light), var(--surface));
  border-radius: 24px;
  padding: 80px 60px;
  border: 1px solid rgba(0, 212, 255, 0.1);
  position: relative;
  overflow: hidden;
}

.cta-box::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(0, 212, 255, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

.cta-box h2 {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 16px;
  position: relative;
}

.cta-box p {
  color: var(--gray);
  font-size: 1.1rem;
  margin-bottom: 36px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
}

.cta-box .btn {
  position: relative;
}

/* ─── FOOTER ─── */
.footer {
  background: var(--surface);
  border-top: 1px solid rgba(0, 212, 255, 0.06);
  padding: 60px 0 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand p {
  color: var(--gray);
  font-size: 0.9rem;
  margin-top: 16px;
  max-width: 300px;
  line-height: 1.6;
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-light);
  margin-bottom: 20px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul li a {
  color: var(--gray);
  font-size: 0.9rem;
  transition: color 0.25s ease;
}

.footer-col ul li a:hover {
  color: var(--blue);
}

.footer-bottom {
  border-top: 1px solid rgba(0, 212, 255, 0.06);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p {
  color: var(--gray);
  font-size: 0.8rem;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero p {
    max-width: 100%;
  }

  .hero-visual {
    display: none;
  }

  .btn-group {
    justify-content: center;
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .features-grid {
    grid-template-columns: 1fr 1fr;
  }

  .process-steps {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .process-steps::before {
    display: none;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .accuracy-comparison {
    grid-template-columns: 1fr;
  }

  .tech-flow {
    flex-direction: column;
  }

  .tech-arrow {
    transform: rotate(90deg);
  }
}

@media (max-width: 768px) {
  .navbar-links {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(10, 37, 64, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 32px 24px;
    gap: 24px;
    border-bottom: 1px solid rgba(0, 212, 255, 0.1);
  }

  .navbar-links.open {
    display: flex;
  }

  .navbar-toggle {
    display: flex;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .section-header h2 {
    font-size: 1.8rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .cta-box {
    padding: 48px 24px;
  }

  .cta-box h2 {
    font-size: 1.8rem;
  }

  .contact-form {
    padding: 32px 24px;
  }
}

/* ═══════════════════════════════════════════
   LOGIN PAGE
   ═══════════════════════════════════════════ */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--navy);
  position: relative;
  overflow: hidden;
}

.login-page::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -20%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.login-page::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -15%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(108, 99, 255, 0.05) 0%, transparent 70%);
  pointer-events: none;
}

.login-card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border-radius: 20px;
  padding: 48px 40px;
  border: 1px solid rgba(0, 212, 255, 0.08);
  position: relative;
  z-index: 1;
}

.login-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 8px;
}

.login-logo svg {
  width: 36px;
  height: 36px;
}

.login-logo span {
  font-size: 1.4rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.login-card h2 {
  text-align: center;
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 32px;
  color: var(--gray-light);
}

.login-error {
  background: rgba(255, 100, 100, 0.1);
  border: 1px solid rgba(255, 100, 100, 0.2);
  border-radius: 10px;
  padding: 12px 16px;
  color: #FF6464;
  font-size: 0.85rem;
  text-align: center;
  margin-bottom: 20px;
}

/* ═══════════════════════════════════════════
   DASHBOARD LAYOUT
   ═══════════════════════════════════════════ */
.dash-layout {
  display: flex;
  min-height: 100vh;
  background: var(--navy);
}

.dash-sidebar {
  width: 260px;
  background: var(--surface);
  border-right: 1px solid rgba(0, 212, 255, 0.06);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  transition: transform 0.3s ease;
}

.dash-sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 24px 20px;
  border-bottom: 1px solid rgba(0, 212, 255, 0.06);
}

.dash-sidebar-logo svg {
  width: 32px;
  height: 32px;
}

.dash-sidebar-logo span {
  font-size: 1.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.dash-nav {
  flex: 1;
  padding: 16px 12px;
}

.dash-nav-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--gray);
  padding: 16px 12px 8px;
}

.dash-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  color: var(--gray-light);
  font-size: 0.88rem;
  font-weight: 500;
  transition: all 0.2s ease;
  margin-bottom: 2px;
}

.dash-nav a:hover {
  background: rgba(0, 212, 255, 0.06);
  color: var(--white);
}

.dash-nav a.active {
  background: rgba(0, 212, 255, 0.1);
  color: var(--blue);
}

.dash-nav a svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.dash-sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid rgba(0, 212, 255, 0.06);
}

.dash-sidebar-footer a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  color: var(--gray);
  font-size: 0.88rem;
  transition: all 0.2s ease;
}

.dash-sidebar-footer a:hover {
  color: #FF6464;
  background: rgba(255, 100, 100, 0.06);
}

.dash-sidebar-footer a svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  flex-shrink: 0;
}

.dash-main {
  flex: 1;
  margin-left: 260px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.dash-topbar {
  height: 64px;
  background: rgba(17, 34, 64, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 212, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.dash-topbar h1 {
  font-size: 1.15rem;
  font-weight: 600;
}

.dash-topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.dash-user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--gray-light);
}

.dash-user-badge .avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--navy);
}

.dash-content {
  flex: 1;
  padding: 32px;
}

/* ─── Dashboard KPI Cards ─── */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

.kpi-card {
  background: var(--surface);
  border-radius: 14px;
  padding: 24px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  transition: all 0.2s ease;
}

.kpi-card:hover {
  border-color: rgba(0, 212, 255, 0.12);
}

.kpi-card .kpi-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray);
  margin-bottom: 8px;
}

.kpi-card .kpi-value {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.1;
}

.kpi-card .kpi-value.blue {
  background: linear-gradient(135deg, var(--blue), #6C63FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.kpi-card .kpi-value.green {
  color: #22C55E;
}

.kpi-card .kpi-value.orange {
  color: #F59E0B;
}

.kpi-card .kpi-value.red {
  color: #FF6464;
}

.kpi-card .kpi-sub {
  font-size: 0.78rem;
  color: var(--gray);
  margin-top: 6px;
}

.kpi-card .kpi-sub .up {
  color: #22C55E;
  font-weight: 600;
}

.kpi-card .kpi-sub .down {
  color: #FF6464;
  font-weight: 600;
}

/* ─── Dashboard Tables ─── */
.dash-table-wrap {
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  overflow: hidden;
}

.dash-table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(0, 212, 255, 0.06);
}

.dash-table-header h3 {
  font-size: 1rem;
  font-weight: 600;
}

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

.dash-table thead th {
  text-align: left;
  padding: 12px 16px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gray);
  border-bottom: 1px solid rgba(0, 212, 255, 0.06);
  white-space: nowrap;
}

.dash-table tbody td {
  padding: 14px 16px;
  font-size: 0.85rem;
  color: var(--gray-light);
  border-bottom: 1px solid rgba(0, 212, 255, 0.03);
  white-space: nowrap;
}

.dash-table tbody tr:hover {
  background: rgba(0, 212, 255, 0.02);
}

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

.dash-table .mono {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.82rem;
}

/* ─── Status Badges ─── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-online {
  background: rgba(34, 197, 94, 0.1);
  color: #22C55E;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.badge-offline {
  background: rgba(255, 100, 100, 0.1);
  color: #FF6464;
  border: 1px solid rgba(255, 100, 100, 0.2);
}

.badge-idle {
  background: rgba(245, 158, 11, 0.1);
  color: #F59E0B;
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge-urban {
  background: rgba(0, 212, 255, 0.1);
  color: var(--blue);
  border: 1px solid rgba(0, 212, 255, 0.15);
}

.badge-rural {
  background: rgba(108, 99, 255, 0.1);
  color: #A78BFA;
  border: 1px solid rgba(108, 99, 255, 0.15);
}

.badge-mixed {
  background: rgba(245, 158, 11, 0.1);
  color: #F59E0B;
  border: 1px solid rgba(245, 158, 11, 0.15);
}

.badge-success {
  background: rgba(34, 197, 94, 0.1);
  color: #22C55E;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

/* ─── Dashboard Charts ─── */
.chart-card {
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  padding: 24px;
}

.chart-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.bar-chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 180px;
  padding-top: 20px;
}

.bar-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  height: 100%;
  justify-content: flex-end;
}

.bar-pair {
  display: flex;
  gap: 3px;
  align-items: flex-end;
  width: 100%;
  justify-content: center;
}

.bar {
  width: 14px;
  border-radius: 4px 4px 0 0;
  min-height: 4px;
  transition: height 0.5s ease;
}

.bar.before {
  background: rgba(255, 100, 100, 0.3);
  border: 1px solid rgba(255, 100, 100, 0.2);
}

.bar.after {
  background: linear-gradient(180deg, var(--blue), rgba(0, 212, 255, 0.4));
  border: 1px solid rgba(0, 212, 255, 0.3);
}

.bar-label {
  font-size: 0.6rem;
  color: var(--gray);
  text-align: center;
  white-space: nowrap;
}

/* ─── Analytics Grid ─── */
.analytics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.analytics-full {
  grid-column: 1 / -1;
}

/* ─── AI Engine ─── */
.engine-status {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 12px;
  margin-bottom: 24px;
}

.engine-status .status-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #22C55E;
  animation: pulse-dot 2s ease-in-out infinite;
}

.engine-status h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #22C55E;
}

.engine-status p {
  font-size: 0.85rem;
  color: var(--gray);
  margin-left: auto;
}

.engine-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.engine-card {
  background: var(--surface);
  border-radius: 14px;
  padding: 24px;
  border: 1px solid rgba(0, 212, 255, 0.06);
}

.engine-card .engine-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray);
  margin-bottom: 8px;
}

.engine-card .engine-value {
  font-size: 1.5rem;
  font-weight: 700;
}

.models-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.model-card {
  background: var(--surface);
  border-radius: 14px;
  padding: 20px 24px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.model-card h4 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.model-card .model-meta {
  font-size: 0.78rem;
  color: var(--gray);
}

.model-card .model-acc {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--blue);
}

.run-section {
  background: var(--surface);
  border-radius: 16px;
  padding: 24px;
  border: 1px solid rgba(0, 212, 255, 0.06);
}

.run-section h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.run-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  color: var(--navy);
  border: none;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
}

.run-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 212, 255, 0.3);
}

.run-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.run-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(10, 37, 64, 0.3);
  border-top-color: var(--navy);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.run-results {
  margin-top: 20px;
}

.run-result-summary {
  display: flex;
  gap: 24px;
  padding: 16px;
  background: rgba(0, 212, 255, 0.04);
  border-radius: 10px;
  margin-bottom: 16px;
}

.run-result-summary .rs-item {
  text-align: center;
}

.run-result-summary .rs-item .rs-val {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--blue);
}

.run-result-summary .rs-item .rs-label {
  font-size: 0.72rem;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

/* ─── Pagination ─── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 16px;
}

.pagination a,
.pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--gray-light);
  transition: all 0.2s ease;
}

.pagination a:hover {
  background: rgba(0, 212, 255, 0.06);
  color: var(--white);
}

.pagination .active {
  background: rgba(0, 212, 255, 0.12);
  color: var(--blue);
  font-weight: 600;
}

/* ─── Signal Strength ─── */
.signal-bar {
  display: flex;
  gap: 2px;
  align-items: flex-end;
}

.signal-bar span {
  width: 4px;
  border-radius: 2px;
  background: rgba(0, 212, 255, 0.2);
}

.signal-bar span.active {
  background: var(--blue);
}

.signal-bar span:nth-child(1) { height: 6px; }
.signal-bar span:nth-child(2) { height: 10px; }
.signal-bar span:nth-child(3) { height: 14px; }
.signal-bar span:nth-child(4) { height: 18px; }
.signal-bar span:nth-child(5) { height: 22px; }

/* ─── Devices Grid ─── */
.devices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
}

.device-card {
  background: var(--surface);
  border-radius: 14px;
  padding: 20px 24px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  transition: all 0.2s ease;
}

.device-card:hover {
  border-color: rgba(0, 212, 255, 0.12);
}

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

.device-card-header h4 {
  font-size: 1rem;
  font-weight: 600;
}

.device-card-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.device-field {
  font-size: 0.78rem;
}

.device-field .label {
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-weight: 600;
  font-size: 0.68rem;
  margin-bottom: 2px;
}

.device-field .value {
  color: var(--gray-light);
  font-family: 'SF Mono', monospace;
  font-size: 0.82rem;
}

.device-field .value.accuracy-good {
  color: #22C55E;
  font-weight: 600;
}

.device-field .value.accuracy-bad {
  color: #FF6464;
  font-weight: 600;
}

/* ─── Filter Bar ─── */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.filter-bar select {
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid rgba(0, 212, 255, 0.1);
  border-radius: 8px;
  color: var(--gray-light);
  font-size: 0.85rem;
  font-family: inherit;
  cursor: pointer;
  outline: none;
}

.filter-bar select:focus {
  border-color: var(--blue);
}

.filter-bar .result-count {
  margin-left: auto;
  font-size: 0.85rem;
  color: var(--gray);
}

/* ─── Dashboard Responsive ─── */
@media (max-width: 1024px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .analytics-grid {
    grid-template-columns: 1fr;
  }

  .engine-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .models-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .dash-sidebar {
    transform: translateX(-100%);
  }

  .dash-sidebar.open {
    transform: translateX(0);
  }

  .dash-main {
    margin-left: 0;
  }

  .dash-content {
    padding: 20px 16px;
  }

  .kpi-grid {
    grid-template-columns: 1fr 1fr;
  }

  .devices-grid {
    grid-template-columns: 1fr;
  }

  .engine-grid {
    grid-template-columns: 1fr;
  }

  .login-card {
    margin: 16px;
    padding: 32px 24px;
  }
}

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

/* ═══════════════════════════════════════════
   API DOCS
   ═══════════════════════════════════════════ */
.api-intro {
  background: var(--surface);
  border-radius: 16px;
  padding: 28px 32px;
  border: 1px solid rgba(0, 212, 255, 0.08);
  margin-bottom: 24px;
}

.api-intro h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.api-intro p {
  color: var(--gray);
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.api-intro code,
.api-auth-card code,
.api-endpoint code {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.85rem;
  color: var(--blue);
  background: rgba(0, 212, 255, 0.06);
  padding: 2px 8px;
  border-radius: 4px;
}

.api-auth-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 24px 32px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  margin-bottom: 24px;
}

.api-auth-card h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.api-auth-card p {
  color: var(--gray);
  font-size: 0.85rem;
  margin-bottom: 8px;
}

.api-code-block {
  background: var(--navy);
  border: 1px solid rgba(0, 212, 255, 0.08);
  border-radius: 10px;
  padding: 14px 18px;
  overflow-x: auto;
  margin-top: 8px;
}

.api-code-block code {
  background: none;
  padding: 0;
  font-size: 0.82rem;
  color: var(--blue);
  word-break: break-all;
}

.api-code-json {
  max-height: 420px;
  overflow-y: auto;
}

.api-code-json pre {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.78rem;
  color: var(--gray-light);
  line-height: 1.6;
  white-space: pre-wrap;
  margin: 0;
}

.api-endpoints {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.api-endpoint {
  background: var(--surface);
  border-radius: 14px;
  border: 1px solid rgba(0, 212, 255, 0.06);
  overflow: hidden;
}

.api-endpoint-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.api-endpoint-header:hover {
  background: rgba(0, 212, 255, 0.02);
}

.api-endpoint-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.api-method {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  min-width: 48px;
  text-align: center;
}

.method-get {
  background: rgba(34, 197, 94, 0.12);
  color: #22C55E;
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.method-post {
  background: rgba(0, 212, 255, 0.12);
  color: var(--blue);
  border: 1px solid rgba(0, 212, 255, 0.2);
}

.api-path {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-light);
}

.api-toggle {
  font-size: 0.7rem;
  color: var(--gray);
  transition: transform 0.2s ease;
}

.api-endpoint-body {
  border-top: 1px solid rgba(0, 212, 255, 0.06);
  padding: 20px 24px;
}

.api-desc {
  color: var(--gray);
  font-size: 0.88rem;
  margin-bottom: 16px;
}

.api-section {
  margin-bottom: 16px;
}

.api-section:last-child {
  margin-bottom: 0;
}

.api-section h5 {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.api-status {
  display: inline-block;
  padding: 2px 8px;
  background: rgba(34, 197, 94, 0.1);
  color: #22C55E;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.api-params-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 8px;
}

.api-params-table thead th {
  text-align: left;
  padding: 8px 12px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray);
  border-bottom: 1px solid rgba(0, 212, 255, 0.06);
}

.api-params-table tbody td {
  padding: 10px 12px;
  font-size: 0.82rem;
  color: var(--gray-light);
  border-bottom: 1px solid rgba(0, 212, 255, 0.03);
}

.api-params-table tbody td code {
  font-size: 0.8rem;
}

@media (max-width: 768px) {
  .api-endpoint-title {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .api-auth-card,
  .api-intro {
    padding: 20px;
  }
}
