/*
 * CloudPilot.app
 * Production UI / Marketing Design System
 * Version: 1.0.0
 *
 * Design direction:
 *   - Premium SaaS
 *   - Cloud / DevOps focused
 *   - Clean, technical, approachable
 *   - Responsive by default
 */

/* =========================================================
   1. FONTS
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;450;500;550;600;650;700;750;800&display=swap');

/* =========================================================
   2. DESIGN TOKENS
   ========================================================= */

:root {
  /* Brand */
  --cp-primary: #2563eb;
  --cp-primary-hover: #1d4ed8;
  --cp-primary-active: #1e40af;
  --cp-primary-light: #eff6ff;
  --cp-primary-lighter: #f8fbff;

  /* Navy */
  --cp-navy-950: #050b14;
  --cp-navy-900: #07111f;
  --cp-navy-850: #0a1626;
  --cp-navy-800: #0b1728;
  --cp-navy-700: #12233a;
  --cp-navy-600: #1e293b;

  /* Slate */
  --cp-slate-950: #020617;
  --cp-slate-900: #0f172a;
  --cp-slate-800: #1e293b;
  --cp-slate-700: #334155;
  --cp-slate-600: #475569;
  --cp-slate-500: #64748b;
  --cp-slate-400: #94a3b8;
  --cp-slate-300: #cbd5e1;
  --cp-slate-200: #e2e8f0;
  --cp-slate-100: #f1f5f9;
  --cp-slate-50: #f8fafc;

  /* Text */
  --cp-text-primary: #0f172a;
  --cp-text-secondary: #475569;
  --cp-text-muted: #64748b;
  --cp-text-subtle: #94a3b8;
  --cp-text-inverse: #ffffff;

  /* Backgrounds */
  --cp-bg: #ffffff;
  --cp-bg-soft: #f8fafc;
  --cp-bg-muted: #f1f5f9;
  --cp-bg-blue: #f1f7ff;
  --cp-bg-dark: #07111f;
  --cp-bg-dark-soft: #0b1728;

  /* Borders */
  --cp-border: #e2e8f0;
  --cp-border-light: #eef2f7;
  --cp-border-dark: #1e293b;

  /* Status */
  --cp-success: #16a34a;
  --cp-success-bg: #f0fdf4;
  --cp-warning: #d97706;
  --cp-warning-bg: #fffbeb;
  --cp-danger: #dc2626;
  --cp-danger-bg: #fef2f2;
  --cp-info: #2563eb;
  --cp-info-bg: #eff6ff;

  /* Typography */
  --cp-font:
    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --cp-font-mono: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;

  /* Font sizes */
  --cp-text-xs: 12px;
  --cp-text-sm: 14px;
  --cp-text-md: 16px;
  --cp-text-lg: 18px;
  --cp-text-xl: 20px;
  --cp-text-2xl: 24px;
  --cp-text-3xl: 30px;
  --cp-text-4xl: 36px;
  --cp-text-5xl: 48px;
  --cp-text-6xl: 60px;
  --cp-text-7xl: 72px;

  /* Radius */
  --cp-radius-xs: 6px;
  --cp-radius-sm: 8px;
  --cp-radius-md: 10px;
  --cp-radius-lg: 14px;
  --cp-radius-xl: 18px;
  --cp-radius-2xl: 24px;
  --cp-radius-3xl: 32px;
  --cp-radius-full: 9999px;

  /* Shadows */
  --cp-shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --cp-shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.05);
  --cp-shadow-md: 0 12px 30px rgba(15, 23, 42, 0.08);
  --cp-shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.12);
  --cp-shadow-xl: 0 32px 80px rgba(15, 23, 42, 0.16);

  /* Layout */
  --cp-container: 1200px;
  --cp-container-wide: 1280px;
  --cp-container-narrow: 900px;
  --cp-header-height: 72px;
  --cp-sidebar-width: 250px;

  /* Spacing */
  --cp-section-space: 120px;

  /* Transitions */
  --cp-transition-fast: 150ms ease;
  --cp-transition: 200ms ease;
  --cp-transition-slow: 300ms ease;

  /* Z-index */
  --cp-z-dropdown: 1000;
  --cp-z-sticky: 1100;
  --cp-z-header: 1200;
  --cp-z-modal: 1300;
  --cp-z-toast: 1400;
}

/* =========================================================
   3. RESET
   ========================================================= */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--cp-bg);
  color: var(--cp-text-primary);
  font-family: var(--cp-font);
  font-size: var(--cp-text-md);
  font-weight: 400;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0;
}

p {
  margin-bottom: 1rem;
}

ul,
ol {
  margin: 0;
  padding: 0;
}

button,
input,
textarea,
select {
  outline: none;
}

/* =========================================================
   4. ACCESSIBILITY
   ========================================================= */

:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.35);
  outline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* =========================================================
   5. CONTAINERS
   ========================================================= */

.cp-container {
  width: min(100% - 40px, var(--cp-container));
  margin-inline: auto;
}

.cp-container-wide {
  width: min(100% - 40px, var(--cp-container-wide));
  margin-inline: auto;
}

.cp-container-narrow {
  width: min(100% - 40px, var(--cp-container-narrow));
  margin-inline: auto;
}

/* =========================================================
   6. TYPOGRAPHY
   ========================================================= */

.cp-display {
  margin-bottom: 24px;
  font-size: clamp(48px, 6vw, 76px);
  font-weight: 700;
  line-height: 1.03;
  letter-spacing: -0.055em;
}

.cp-h1 {
  font-size: clamp(40px, 5vw, 60px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.cp-h2 {
  font-size: clamp(34px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.cp-h3 {
  font-size: 28px;
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.cp-h4 {
  font-size: 22px;
  font-weight: 650;
  line-height: 1.3;
}

.cp-lead {
  max-width: 700px;
  color: var(--cp-text-secondary);
  font-size: 19px;
  line-height: 1.7;
}

.cp-text-muted {
  color: var(--cp-text-muted);
}

.cp-text-subtle {
  color: var(--cp-text-subtle);
}

.cp-text-primary {
  color: var(--cp-text-primary);
}

.cp-text-inverse {
  color: white;
}

.cp-mono {
  font-family: var(--cp-font-mono);
}

/* =========================================================
   7. HEADER / NAVIGATION
   ========================================================= */

.cp-header {
  position: relative;
  z-index: var(--cp-z-header);
  height: var(--cp-header-height);
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--cp-border-light);
}

.cp-header.sticky {
  position: sticky;
  top: 0;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(255, 255, 255, 0.88);
}

.cp-navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.cp-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--cp-navy-900);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.cp-logo-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: white;
  background: var(--cp-primary);
  border-radius: 10px;
}

.cp-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.cp-nav-link {
  position: relative;
  color: var(--cp-text-secondary);
  font-size: 14px;
  font-weight: 500;
  transition: color var(--cp-transition);
}

.cp-nav-link:hover {
  color: var(--cp-text-primary);
}

.cp-nav-link.active {
  color: var(--cp-primary);
}

.cp-nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cp-mobile-menu-button {
  display: none;
  width: 42px;
  height: 42px;
  color: var(--cp-text-primary);
  background: transparent;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-md);
}

/* =========================================================
   8. BUTTONS
   ========================================================= */

.cp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--cp-radius-md);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  transition:
    background-color var(--cp-transition),
    border-color var(--cp-transition),
    color var(--cp-transition),
    box-shadow var(--cp-transition),
    transform var(--cp-transition);
}

.cp-btn:hover {
  transform: translateY(-1px);
}

.cp-btn:active {
  transform: translateY(0);
}

.cp-btn-primary {
  color: white;
  background: var(--cp-primary);
  box-shadow: 0 2px 5px rgba(37, 99, 235, 0.15);
}

.cp-btn-primary:hover {
  background: var(--cp-primary-hover);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.18);
}

.cp-btn-secondary {
  color: var(--cp-text-primary);
  background: white;
  border-color: var(--cp-border);
}

.cp-btn-secondary:hover {
  background: var(--cp-bg-soft);
}

.cp-btn-dark {
  color: white;
  background: var(--cp-navy-900);
}

.cp-btn-dark:hover {
  background: var(--cp-navy-800);
}

.cp-btn-ghost {
  color: var(--cp-text-secondary);
  background: transparent;
}

.cp-btn-ghost:hover {
  color: var(--cp-text-primary);
  background: var(--cp-bg-soft);
}

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

.cp-btn-sm {
  min-height: 38px;
  padding-inline: 14px;
  font-size: 13px;
}

.cp-btn-lg {
  min-height: 54px;
  padding-inline: 24px;
  font-size: 15px;
}

.cp-btn-xl {
  min-height: 60px;
  padding-inline: 28px;
  font-size: 16px;
}

.cp-btn-full {
  width: 100%;
}

/* =========================================================
   9. HERO
   ========================================================= */

.cp-hero {
  position: relative;
  overflow: hidden;
  padding: 110px 0 90px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(37, 99, 235, 0.08), transparent 42%), var(--cp-bg);
}

.cp-hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin-inline: auto;
}

.cp-hero h1 {
  margin-bottom: 26px;
}

.cp-hero .cp-lead {
  margin-inline: auto;
}

.cp-hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.cp-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  padding: 7px 12px;
  color: var(--cp-primary);
  background: var(--cp-primary-light);
  border: 1px solid #dbeafe;
  border-radius: var(--cp-radius-full);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* =========================================================
   10. SECTIONS
   ========================================================= */

.cp-section {
  padding: var(--cp-section-space) 0;
}

.cp-section-sm {
  padding: 72px 0;
}

.cp-section-lg {
  padding: 150px 0;
}

.cp-section-soft {
  background: var(--cp-bg-soft);
}

.cp-section-blue {
  background: var(--cp-bg-blue);
}

.cp-section-dark {
  color: white;
  background: var(--cp-bg-dark);
}

.cp-section-header {
  max-width: 720px;
  margin-bottom: 60px;
}

.cp-section-header.center {
  margin-inline: auto;
  text-align: center;
}

.cp-section-header.center .cp-lead {
  margin-inline: auto;
}

/* =========================================================
   11. GRID
   ========================================================= */

.cp-grid {
  display: grid;
  gap: 24px;
}

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

.cp-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cp-grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.cp-grid-auto {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* =========================================================
   12. CARDS
   ========================================================= */

.cp-card {
  padding: 28px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-xl);
  box-shadow: var(--cp-shadow-xs);
  transition:
    border-color var(--cp-transition),
    box-shadow var(--cp-transition),
    transform var(--cp-transition);
}

.cp-card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--cp-shadow-md);
  transform: translateY(-2px);
}

.cp-card-flat {
  box-shadow: none;
}

.cp-card-header {
  margin-bottom: 22px;
}

.cp-card-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin-bottom: 22px;
  place-items: center;
  color: var(--cp-primary);
  background: var(--cp-primary-light);
  border-radius: 12px;
}

.cp-card h3 {
  margin-bottom: 10px;
}

.cp-card p {
  margin-bottom: 0;
  color: var(--cp-text-secondary);
}

/* =========================================================
   13. PRODUCT / DASHBOARD PREVIEW
   ========================================================= */

.cp-product-preview {
  position: relative;
  width: min(1100px, calc(100% - 40px));
  margin: 70px auto 0;
  overflow: hidden;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: 20px;
  box-shadow: var(--cp-shadow-xl);
}

.cp-product-toolbar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 46px;
  padding: 0 18px;
  background: var(--cp-bg-soft);
  border-bottom: 1px solid var(--cp-border);
}

.cp-window-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cp-slate-300);
}

.cp-dashboard-preview {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: 520px;
}

.cp-dashboard-preview-sidebar {
  padding: 24px;
  background: var(--cp-navy-900);
  color: var(--cp-slate-300);
}

.cp-dashboard-preview-main {
  padding: 30px;
  background: var(--cp-bg-soft);
}

/* =========================================================
   14. BADGES
   ========================================================= */

.cp-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 0 9px;
  border-radius: var(--cp-radius-full);
  font-size: 12px;
  font-weight: 600;
}

.cp-badge-primary {
  color: var(--cp-primary);
  background: var(--cp-primary-light);
}

.cp-badge-success {
  color: #15803d;
  background: var(--cp-success-bg);
}

.cp-badge-warning {
  color: #a16207;
  background: var(--cp-warning-bg);
}

.cp-badge-danger {
  color: #b91c1c;
  background: var(--cp-danger-bg);
}

.cp-badge-neutral {
  color: var(--cp-slate-600);
  background: var(--cp-slate-100);
}

/* =========================================================
   15. STATUS INDICATORS
   ========================================================= */

.cp-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.cp-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cp-slate-400);
}

.cp-status-dot.success {
  background: var(--cp-success);
}

.cp-status-dot.warning {
  background: var(--cp-warning);
}

.cp-status-dot.danger {
  background: var(--cp-danger);
}

.cp-status-dot.pulse {
  animation: cp-pulse 2s infinite;
}

@keyframes cp-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.35);
  }

  50% {
    box-shadow: 0 0 0 5px rgba(22, 163, 74, 0);
  }
}

/* =========================================================
   16. FORMS
   ========================================================= */

.cp-form-group {
  margin-bottom: 20px;
}

.cp-label {
  display: block;
  margin-bottom: 7px;
  color: var(--cp-text-primary);
  font-size: 14px;
  font-weight: 600;
}

.cp-input,
.cp-select,
.cp-textarea {
  width: 100%;
  padding: 12px 14px;
  color: var(--cp-text-primary);
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-md);
  font-size: 14px;
  transition:
    border-color var(--cp-transition),
    box-shadow var(--cp-transition);
}

.cp-input {
  min-height: 46px;
}

.cp-textarea {
  min-height: 130px;
  resize: vertical;
}

.cp-input::placeholder,
.cp-textarea::placeholder {
  color: var(--cp-text-subtle);
}

.cp-input:hover,
.cp-select:hover,
.cp-textarea:hover {
  border-color: var(--cp-slate-300);
}

.cp-input:focus,
.cp-select:focus,
.cp-textarea:focus {
  border-color: var(--cp-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.cp-form-help {
  margin-top: 6px;
  color: var(--cp-text-muted);
  font-size: 12px;
}

.cp-form-error {
  margin-top: 6px;
  color: var(--cp-danger);
  font-size: 12px;
}

/* =========================================================
   17. TABLES
   ========================================================= */

.cp-table-wrapper {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-lg);
}

.cp-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  font-size: 14px;
}

.cp-table th {
  padding: 13px 16px;
  color: var(--cp-text-muted);
  background: var(--cp-bg-soft);
  border-bottom: 1px solid var(--cp-border);
  font-size: 12px;
  font-weight: 650;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.cp-table td {
  padding: 16px;
  color: var(--cp-text-secondary);
  border-bottom: 1px solid var(--cp-border-light);
}

.cp-table tbody tr:last-child td {
  border-bottom: 0;
}

.cp-table tbody tr:hover {
  background: var(--cp-bg-soft);
}

/* =========================================================
   18. ALERTS
   ========================================================= */

.cp-alert {
  display: flex;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid transparent;
  border-radius: var(--cp-radius-md);
  font-size: 14px;
}

.cp-alert-info {
  color: #1d4ed8;
  background: var(--cp-info-bg);
  border-color: #dbeafe;
}

.cp-alert-success {
  color: #166534;
  background: var(--cp-success-bg);
  border-color: #dcfce7;
}

.cp-alert-warning {
  color: #92400e;
  background: var(--cp-warning-bg);
  border-color: #fef3c7;
}

.cp-alert-danger {
  color: #991b1b;
  background: var(--cp-danger-bg);
  border-color: #fee2e2;
}

/* =========================================================
   19. PRICING
   ========================================================= */

.cp-pricing-card {
  position: relative;
  padding: 34px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-xl);
  box-shadow: var(--cp-shadow-sm);
}

.cp-pricing-card.featured {
  border-color: var(--cp-primary);
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.12);
}

.cp-pricing-popular {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 12px;
  color: white;
  background: var(--cp-primary);
  border-radius: var(--cp-radius-full);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.cp-price {
  margin: 20px 0;
  color: var(--cp-text-primary);
  font-size: 48px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
}

.cp-price span {
  color: var(--cp-text-muted);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0;
}

/* =========================================================
   20. FEATURE LIST
   ========================================================= */

.cp-feature-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 24px 0;
  list-style: none;
}

.cp-feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--cp-text-secondary);
  font-size: 14px;
}

.cp-feature-list li::before {
  content: '✓';
  flex: 0 0 auto;
  color: var(--cp-success);
  font-weight: 700;
}

/* =========================================================
   21. TESTIMONIALS
   ========================================================= */

.cp-testimonial {
  padding: 30px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-xl);
}

.cp-testimonial-quote {
  margin-bottom: 24px;
  color: var(--cp-text-primary);
  font-size: 18px;
  line-height: 1.65;
}

.cp-testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cp-avatar {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: white;
  background: var(--cp-navy-800);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 600;
}

/* =========================================================
   22. LOGO CLOUD
   ========================================================= */

.cp-logo-cloud {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 48px;
  color: var(--cp-slate-400);
}

.cp-logo-cloud-item {
  font-size: 16px;
  font-weight: 650;
}

/* =========================================================
   23. DARK CTA
   ========================================================= */

.cp-cta {
  position: relative;
  overflow: hidden;
  padding: 90px 40px;
  color: white;
  background: var(--cp-navy-900);
  border-radius: var(--cp-radius-3xl);
  text-align: center;
}

.cp-cta::before {
  content: '';
  position: absolute;
  width: 500px;
  height: 500px;
  top: -300px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(37, 99, 235, 0.18);
  border-radius: 50%;
  filter: blur(50px);
}

.cp-cta-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin-inline: auto;
}

/* =========================================================
   24. FOOTER
   ========================================================= */

.cp-footer {
  padding: 80px 0 30px;
  color: var(--cp-slate-400);
  background: var(--cp-navy-950);
}

.cp-footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: 50px;
}

.cp-footer-brand {
  max-width: 300px;
}

.cp-footer-brand .cp-logo {
  color: white;
}

.cp-footer-description {
  margin-top: 18px;
  font-size: 14px;
  line-height: 1.7;
}

.cp-footer-title {
  margin-bottom: 18px;
  color: white;
  font-size: 13px;
  font-weight: 650;
}

.cp-footer-links {
  display: flex;
  flex-direction: column;
  gap: 11px;
  list-style: none;
}

.cp-footer-links a {
  font-size: 13px;
  transition: color var(--cp-transition);
}

.cp-footer-links a:hover {
  color: white;
}

.cp-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 70px;
  padding-top: 25px;
  border-top: 1px solid var(--cp-border-dark);
  font-size: 12px;
}

/* =========================================================
   25. APPLICATION SHELL
   ========================================================= */

.cp-app {
  display: flex;
  min-height: 100vh;
  background: var(--cp-bg-soft);
}

.cp-sidebar {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: var(--cp-sidebar-width);
  overflow-y: auto;
  color: var(--cp-slate-300);
  background: var(--cp-navy-900);
  border-right: 1px solid rgba(255, 255, 255, 0.04);
}

.cp-sidebar-logo {
  display: flex;
  align-items: center;
  height: 72px;
  padding: 0 22px;
  color: white;
  font-size: 19px;
  font-weight: 700;
}

.cp-sidebar-section {
  padding: 20px 12px 0;
}

.cp-sidebar-label {
  padding: 0 12px;
  margin-bottom: 8px;
  color: var(--cp-slate-500);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.cp-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 3px;
  list-style: none;
}

.cp-sidebar-link {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 40px;
  padding: 0 12px;
  color: var(--cp-slate-400);
  border-radius: var(--cp-radius-sm);
  font-size: 13px;
  font-weight: 500;
  transition:
    color var(--cp-transition),
    background var(--cp-transition);
}

.cp-sidebar-link:hover {
  color: white;
  background: rgba(255, 255, 255, 0.05);
}

.cp-sidebar-link.active {
  color: #93c5fd;
  background: rgba(37, 99, 235, 0.15);
}

.cp-app-main {
  width: calc(100% - var(--cp-sidebar-width));
  min-height: 100vh;
  margin-left: var(--cp-sidebar-width);
}

.cp-app-header {
  position: sticky;
  top: 0;
  z-index: var(--cp-z-sticky);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 30px;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid var(--cp-border-light);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.cp-app-content {
  padding: 30px;
}

/* =========================================================
   26. DASHBOARD METRICS
   ========================================================= */

.cp-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.cp-metric {
  padding: 22px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-lg);
}

.cp-metric-label {
  margin-bottom: 8px;
  color: var(--cp-text-muted);
  font-size: 12px;
  font-weight: 500;
}

.cp-metric-value {
  color: var(--cp-text-primary);
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
}

.cp-metric-change {
  margin-top: 10px;
  font-size: 12px;
  font-weight: 600;
}

.cp-metric-change.positive {
  color: var(--cp-success);
}

.cp-metric-change.negative {
  color: var(--cp-danger);
}

/* =========================================================
   27. DROPDOWN
   ========================================================= */

.cp-dropdown {
  position: relative;
}

.cp-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: var(--cp-z-dropdown);
  min-width: 190px;
  padding: 6px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-md);
  box-shadow: var(--cp-shadow-lg);
}

.cp-dropdown-item {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  color: var(--cp-text-secondary);
  border-radius: var(--cp-radius-sm);
  font-size: 13px;
  transition: background var(--cp-transition);
}

.cp-dropdown-item:hover {
  color: var(--cp-text-primary);
  background: var(--cp-bg-soft);
}

/* =========================================================
   28. MODAL
   ========================================================= */

.cp-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: var(--cp-z-modal);
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 6, 23, 0.55);
  backdrop-filter: blur(4px);
}

.cp-modal {
  width: min(100%, 560px);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: 28px;
  background: white;
  border-radius: var(--cp-radius-xl);
  box-shadow: var(--cp-shadow-xl);
}

.cp-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
}

.cp-modal-close {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--cp-text-muted);
  background: transparent;
  border: 0;
  border-radius: var(--cp-radius-sm);
}

.cp-modal-close:hover {
  background: var(--cp-bg-soft);
}

/* =========================================================
   29. TOAST
   ========================================================= */

.cp-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: var(--cp-z-toast);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: min(380px, calc(100vw - 32px));
  padding: 16px;
  background: white;
  border: 1px solid var(--cp-border);
  border-radius: var(--cp-radius-lg);
  box-shadow: var(--cp-shadow-lg);
}

/* =========================================================
   30. DIVIDERS
   ========================================================= */

.cp-divider {
  height: 1px;
  margin: 30px 0;
  background: var(--cp-border);
}

.cp-divider-light {
  background: var(--cp-border-light);
}

/* =========================================================
   31. SPACING UTILITIES
   ========================================================= */

.cp-m-0 {
  margin: 0;
}
.cp-mt-0 {
  margin-top: 0;
}
.cp-mb-0 {
  margin-bottom: 0;
}

.cp-mt-1 {
  margin-top: 8px;
}
.cp-mt-2 {
  margin-top: 16px;
}
.cp-mt-3 {
  margin-top: 24px;
}
.cp-mt-4 {
  margin-top: 32px;
}
.cp-mt-5 {
  margin-top: 48px;
}

.cp-mb-1 {
  margin-bottom: 8px;
}
.cp-mb-2 {
  margin-bottom: 16px;
}
.cp-mb-3 {
  margin-bottom: 24px;
}
.cp-mb-4 {
  margin-bottom: 32px;
}
.cp-mb-5 {
  margin-bottom: 48px;
}

.cp-p-1 {
  padding: 8px;
}
.cp-p-2 {
  padding: 16px;
}
.cp-p-3 {
  padding: 24px;
}
.cp-p-4 {
  padding: 32px;
}
.cp-p-5 {
  padding: 48px;
}

/* =========================================================
   32. FLEX UTILITIES
   ========================================================= */

.cp-flex {
  display: flex;
}

.cp-flex-column {
  display: flex;
  flex-direction: column;
}

.cp-items-center {
  align-items: center;
}

.cp-justify-between {
  justify-content: space-between;
}

.cp-justify-center {
  justify-content: center;
}

.cp-wrap {
  flex-wrap: wrap;
}

.cp-gap-1 {
  gap: 8px;
}
.cp-gap-2 {
  gap: 12px;
}
.cp-gap-3 {
  gap: 16px;
}
.cp-gap-4 {
  gap: 24px;
}
.cp-gap-5 {
  gap: 32px;
}

/* =========================================================
   33. TEXT UTILITIES
   ========================================================= */

.cp-text-center {
  text-align: center;
}

.cp-text-left {
  text-align: left;
}

.cp-text-right {
  text-align: right;
}

.cp-fw-400 {
  font-weight: 400;
}
.cp-fw-500 {
  font-weight: 500;
}
.cp-fw-600 {
  font-weight: 600;
}
.cp-fw-700 {
  font-weight: 700;
}

/* =========================================================
   34. WIDTH UTILITIES
   ========================================================= */

.cp-w-full {
  width: 100%;
}

.cp-max-400 {
  max-width: 400px;
}

.cp-max-600 {
  max-width: 600px;
}

.cp-max-800 {
  max-width: 800px;
}

/* =========================================================
   35. MOBILE NAVIGATION
   ========================================================= */

.cp-mobile-nav {
  display: none;
}

.cp-mobile-nav.open {
  display: block;
  position: fixed;
  top: var(--cp-header-height);
  right: 0;
  left: 0;
  z-index: var(--cp-z-header);
  padding: 20px;
  background: white;
  border-bottom: 1px solid var(--cp-border);
  box-shadow: var(--cp-shadow-md);
}

.cp-mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  list-style: none;
}

.cp-mobile-nav-links a {
  display: block;
  padding: 12px;
  border-radius: var(--cp-radius-sm);
}

.cp-mobile-nav-links a:hover {
  background: var(--cp-bg-soft);
}

/* =========================================================
   36. RESPONSIVE — TABLET
   ========================================================= */

@media (max-width: 1024px) {
  :root {
    --cp-section-space: 90px;
  }

  .cp-nav {
    gap: 20px;
  }

  .cp-grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cp-footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }

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

  .cp-sidebar {
    width: 220px;
  }

  .cp-app-main {
    width: calc(100% - 220px);
    margin-left: 220px;
  }
}

/* =========================================================
   37. RESPONSIVE — MOBILE
   ========================================================= */

@media (max-width: 768px) {
  :root {
    --cp-section-space: 72px;
    --cp-header-height: 64px;
  }

  .cp-container,
  .cp-container-wide,
  .cp-container-narrow {
    width: min(100% - 32px, var(--cp-container));
  }

  .cp-nav,
  .cp-nav-actions {
    display: none;
  }

  .cp-mobile-menu-button {
    display: grid;
    place-items: center;
  }

  .cp-hero {
    padding: 75px 0 60px;
  }

  .cp-display {
    font-size: clamp(40px, 11vw, 56px);
  }

  .cp-lead {
    font-size: 17px;
  }

  .cp-hero-actions {
    flex-direction: column;
  }

  .cp-hero-actions .cp-btn {
    width: 100%;
  }

  .cp-grid-2,
  .cp-grid-3,
  .cp-grid-4 {
    grid-template-columns: 1fr;
  }

  .cp-dashboard-preview {
    grid-template-columns: 1fr;
  }

  .cp-dashboard-preview-sidebar {
    display: none;
  }

  .cp-product-preview {
    width: calc(100% - 24px);
    margin-top: 50px;
  }

  .cp-section-header {
    margin-bottom: 40px;
  }

  .cp-footer {
    padding-top: 60px;
  }

  .cp-footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 25px;
  }

  .cp-footer-brand {
    grid-column: 1 / -1;
  }

  .cp-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    margin-top: 45px;
  }

  .cp-cta {
    padding: 65px 24px;
  }

  /* Dashboard */
  .cp-sidebar {
    display: none;
  }

  .cp-app-main {
    width: 100%;
    margin-left: 0;
  }

  .cp-app-header {
    padding: 0 16px;
  }

  .cp-app-content {
    padding: 20px 16px;
  }

  .cp-metric-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   38. RESPONSIVE — SMALL MOBILE
   ========================================================= */

@media (max-width: 480px) {
  .cp-card,
  .cp-pricing-card,
  .cp-testimonial {
    padding: 22px;
  }

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

  .cp-footer-brand {
    grid-column: auto;
  }

  .cp-btn-lg,
  .cp-btn-xl {
    width: 100%;
  }

  .cp-modal {
    padding: 22px;
  }
}

/* =========================================================
   39. REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* =========================================================
   40. DARK MODE
   ========================================================= */

/*
 * Opt-in dark mode.
 *
 * Add class="cp-dark" to <html> or <body>
 * if you want application-controlled dark mode.
 */

.cp-dark {
  /* Near-black navy surfaces, one cyan accent (the marketing site's theme). */
  --cp-bg: #060b14;
  --cp-bg-soft: #080f1b;
  --cp-bg-muted: #111a29;
  --cp-bg-blue: #071321;
  --cp-surface: #0e1624;
  --cp-surface-raised: #131d2e;
  --cp-text-primary: #f8fafc;
  --cp-text-secondary: #cbd5e1;
  --cp-text-muted: #94a3b8;
  --cp-text-subtle: #64748b;
  --cp-border: #1c2636;
  --cp-border-light: #141d2b;

  --cp-primary: #22d3ee;
  --cp-primary-hover: #67e8f9;
  --cp-primary-active: #06b6d4;
  --cp-primary-light: rgba(34, 211, 238, 0.1);
  --cp-primary-lighter: rgba(34, 211, 238, 0.05);
  --cp-primary-border: rgba(34, 211, 238, 0.35);
  --cp-primary-glow: rgba(34, 211, 238, 0.22);
  /* Text on the cyan accent. */
  --cp-on-primary: #04121a;

  --cp-success: #4ade80;
  --cp-success-bg: rgba(74, 222, 128, 0.12);
  --cp-warning: #fbbf24;
  --cp-warning-bg: rgba(251, 191, 36, 0.12);
  --cp-danger: #f87171;
  --cp-danger-bg: rgba(248, 113, 113, 0.12);
  --cp-info: #22d3ee;
  --cp-info-bg: rgba(34, 211, 238, 0.1);

  --cp-shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.4);
  --cp-shadow-sm: 0 6px 16px rgba(0, 0, 0, 0.35);
  --cp-shadow-md: 0 12px 32px rgba(0, 0, 0, 0.4);
  --cp-shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.45);
  --cp-shadow-xl: 0 30px 80px rgba(0, 0, 0, 0.5);

  /* Translucent header bar over the page. */
  --cp-header-bg: rgba(10, 17, 29, 0.72);

  background: var(--cp-bg);
  color: var(--cp-text-primary);
}

.cp-dark .cp-card,
.cp-dark .cp-pricing-card,
.cp-dark .cp-testimonial,
.cp-dark .cp-table-wrapper,
.cp-dark .cp-modal {
  background: var(--cp-surface);
  border-color: var(--cp-border);
}

.cp-dark .cp-input,
.cp-dark .cp-select,
.cp-dark .cp-textarea {
  color: white;
  background: var(--cp-surface);
  border-color: var(--cp-border);
}

.cp-dark .cp-table {
  background: var(--cp-surface);
}

.cp-dark .cp-table th {
  background: var(--cp-surface-raised);
}

.cp-dark .cp-table td {
  border-color: var(--cp-border);
}

/* =========================================================
   41. PRINT
   ========================================================= */

@media print {
  .cp-header,
  .cp-sidebar,
  .cp-app-header,
  .cp-footer,
  .cp-btn {
    display: none !important;
  }

  body {
    color: black;
    background: white;
  }

  .cp-app-main {
    width: 100%;
    margin: 0;
  }
}
