/* ═══════════════════════════════════════════════════════════════
   AIWI Security — style.css
   Theme: Dark tech  |  Accent: Electric Blue
═══════════════════════════════════════════════════════════════ */

/* === VARIABLES === */
:root {
  --bg:          #0d1117;
  --bg-card:     #161b22;
  --bg-input:    #21262d;
  --bg-hover:    #1c2128;
  --border:      #30363d;
  --border-focus:#2563eb;
  --accent:      #2563eb;
  --accent-h:    #1d4ed8;
  --accent-glow: rgba(37, 99, 235, 0.25);
  --text:        #e6edf3;
  --text-muted:  #8b949e;
  --text-dim:    #484f58;
  --green:       #3fb950;
  --red:         #f85149;
  --yellow:      #d29922;
  --radius:      10px;
  --radius-lg:   16px;
  --shadow:      0 8px 32px rgba(0,0,0,0.4);
  --font-mono:   'JetBrains Mono', 'Courier New', monospace;
  --nav-h:       64px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }

body {
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 100% 60% at 50% 0%,   rgba(37, 99, 235, 0.07) 0%, transparent 60%),
    radial-gradient(ellipse 60%  40% at 80% 60%,  rgba(37, 99, 235, 0.04) 0%, transparent 55%),
    radial-gradient(ellipse 80%  50% at 20% 100%, rgba(14, 30, 60,  0.5)  0%, transparent 60%);
  color: var(--text);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { list-style: none; }
code {
  font-family: var(--font-mono);
  font-size: 0.82em;
  background: var(--bg-input);
  padding: 2px 6px;
  border-radius: 4px;
  color: #79c0ff;
}

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

.accent { color: var(--accent); }

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover:not(:disabled) {
  background: var(--accent-h);
  text-decoration: none;
  box-shadow: 0 4px 16px var(--accent-glow);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  border-color: var(--text-muted);
  background: var(--bg-card);
  text-decoration: none;
}
.btn-full { width: 100%; justify-content: center; padding: 13px; font-size: 15px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-link {
  background: none; border: none; color: var(--accent);
  font-size: 13px; cursor: pointer; font-family: inherit;
  padding: 0; text-decoration: underline;
}
.btn-link:hover { color: var(--text); }
.btn-nav {
  background: var(--accent);
  color: #fff !important;
  padding: 7px 16px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 13px;
  transition: background 0.2s;
}
.btn-nav:hover { background: var(--accent-h) !important; text-decoration: none; }

/* === SECTION HEADER === */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}
.section-header h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
  margin-bottom: 10px;
}
.section-header p {
  color: var(--text-muted);
  font-size: 15px;
  max-width: 520px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════ NAV */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  transition: background 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(13, 17, 23, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--border);
}
.nav-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  font-size: 18px;
  font-weight: 800;
  color: var(--text) !important;
  text-decoration: none !important;
  letter-spacing: -0.5px;
}
.nav-logo span { color: var(--accent); margin-left: 2px; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-links a {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  padding: 6px 10px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  text-decoration: none;
}
.nav-links a:hover { color: var(--text); background: var(--bg-hover); }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

/* ═══════════════════════════════════════════════════════════ HERO */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 40px) 0 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 60% 40%, rgba(37,99,235,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
}
.hero-text { flex: 1; max-width: 580px; }
.hero-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(37,99,235,0.1);
  border: 1px solid rgba(37,99,235,0.3);
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 20px;
  font-family: var(--font-mono);
}
.hero-text h1 {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -1.5px;
  margin-bottom: 12px;
}
.hero-tagline {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: var(--text-muted);
  font-weight: 400;
  margin-bottom: 20px;
}
.hero-desc {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 480px;
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}
.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
}
.hero-image {
  position: relative;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
}
.hero-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(37,99,235,0.2) 0%, transparent 65%);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border-radius: 50%;
}
.hero-image img { position: relative; z-index: 1; filter: drop-shadow(0 20px 60px rgba(0,0,0,0.6)); }

/* ═══════════════════════════════════════════════════════════ FEATURES */
.features {
  padding: 96px 0;
  border-top: 1px solid var(--border);
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  transition: border-color 0.2s, transform 0.2s;
}
.feature-card:hover {
  border-color: rgba(37,99,235,0.5);
  transform: translateY(-2px);
}
.feature-icon {
  width: 48px;
  height: 48px;
  background: rgba(37,99,235,0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--accent);
}
.feature-icon svg { width: 24px; height: 24px; }
.feature-card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ═══════════════════════════════════════════════════════════ PRODUCTS */
.products {
  padding: 96px 0;
  border-top: 1px solid var(--border);
}
.products-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: relative;
  transition: border-color 0.2s;
}
.product-card--featured {
  border-color: rgba(37,99,235,0.5);
  box-shadow: 0 0 0 1px rgba(37,99,235,0.2), inset 0 0 40px rgba(37,99,235,0.03);
}
.product-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text-muted);
  letter-spacing: 0.5px;
}
.product-badge--featured {
  background: rgba(37,99,235,0.15);
  border-color: rgba(37,99,235,0.4);
  color: var(--accent);
}
.product-image {
  display: flex;
  justify-content: center;
  padding: 8px 0;
}
.product-image img { filter: drop-shadow(0 8px 24px rgba(0,0,0,0.5)); }
.product-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}
.product-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
}
.product-specs {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.product-specs li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
}
.product-specs li:last-child { border-bottom: none; }
.product-specs li span { color: var(--text-muted); }

/* Bundle selector */
.bundle-selector {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
}
.bundle-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 6px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}
.bundle-btn span {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  font-family: var(--font-mono);
}
.bundle-btn:hover { border-color: var(--text-muted); color: var(--text); }
.bundle-btn.active {
  background: rgba(37,99,235,0.12);
  border-color: var(--accent);
  color: var(--text);
}
.bundle-btn.active span { color: var(--accent); }

.price-display {
  text-align: center;
  margin-bottom: 16px;
  min-height: 40px;
}
.price-main {
  font-size: 1.8rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--text);
}
.price-per {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}
.btn-order {
  width: 100%;
  justify-content: center;
  padding: 11px;
  background: var(--bg-input);
  color: var(--text);
  border: 1px solid var(--border);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.2s;
}
.btn-order:hover, .btn-primary.btn-order:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 4px 16px var(--accent-glow);
  text-decoration: none;
}
.btn-primary.btn-order {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.products-note {
  text-align: center;
  font-size: 12px;
  color: var(--text-dim);
}

/* ═══════════════════════════════════════════════════════════ CHECKOUT */
.checkout-section {
  padding: 96px 0;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, var(--bg) 0%, rgba(37,99,235,0.03) 100%);
}
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
  align-items: start;
}
.checkout-main {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
}

/* Step indicator */
.step-indicator {
  display: flex;
  align-items: center;
  margin-bottom: 28px;
  gap: 0;
}
.step-item {
  display: flex;
  align-items: center;
  gap: 10px;
}
.step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-input);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: all 0.3s;
}
.step-label { font-size: 13px; color: var(--text-muted); font-weight: 500; transition: color 0.3s; }
.step-item.active .step-num { background: var(--accent); border-color: var(--accent); color: #fff; }
.step-item.active .step-label { color: var(--text); }
.step-item.done .step-num { background: var(--green); border-color: var(--green); color: #fff; }
.step-line {
  flex: 1;
  height: 1px;
  background: var(--border);
  margin: 0 12px;
}

/* Form */
.checkout-form { display: flex; flex-direction: column; gap: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
}
.req { color: var(--red); }
.form-group input {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  padding: 10px 12px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  width: 100%;
}
.form-group input::placeholder { color: var(--text-dim); }
.form-group input:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}
.form-group input.invalid { border-color: var(--red); }
.form-error {
  font-size: 13px;
  color: var(--red);
  min-height: 18px;
}

/* Shipping review (step 2) */
.shipping-review {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 20px;
}
.shipping-review-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  flex-shrink: 0;
  padding-top: 1px;
}
.shipping-review-text { font-size: 13px; line-height: 1.5; flex: 1; }
.shipping-review .btn-link { flex-shrink: 0; font-size: 12px; }

/* Stripe Elements */
#payment-element { margin-bottom: 20px; }

/* Loading */
.checkout-loading {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  color: var(--text-muted);
  font-size: 14px;
}
.spinner {
  width: 20px; height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Order summary */
.order-summary {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  position: sticky;
  top: calc(var(--nav-h) + 16px);
}
.order-summary h3 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}
.summary-no-selection {
  font-size: 13px;
  color: var(--text-dim);
  text-align: center;
  padding: 16px 0;
}
.summary-product { min-height: 60px; }
.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
}
.summary-item-name { font-weight: 500; }
.summary-item-qty { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.summary-item-price { font-weight: 600; font-family: var(--font-mono); white-space: nowrap; }
.summary-divider { height: 1px; background: var(--border); margin: 16px 0; }
.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text-muted);
}
.summary-total {
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
}
.summary-total span:last-child { font-family: var(--font-mono); color: var(--accent); }
.summary-change { margin-top: 14px; text-align: center; }

/* ═══════════════════════════════════════════════════════════ DOCS */
.docs {
  padding: 96px 0;
  border-top: 1px solid var(--border);
}
.docs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.docs-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.docs-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  color: var(--accent);
}
.docs-card-header h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}
.docs-list { display: flex; flex-direction: column; gap: 4px; }
.docs-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: all 0.2s;
  color: var(--text);
  text-decoration: none;
}
.docs-list a:hover {
  background: var(--bg-input);
  border-color: var(--border);
}
.doc-name { font-size: 14px; font-weight: 500; }
.doc-sub { font-size: 12px; color: var(--text-muted); margin-left: 6px; }
.doc-tag {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--bg-input);
  color: var(--text-muted);
  border: 1px solid var(--border);
  font-family: var(--font-mono);
}
.doc-tag--dl {
  background: rgba(37,99,235,0.1);
  color: var(--accent);
  border-color: rgba(37,99,235,0.3);
}

/* ═══════════════════════════════════════════════════════════ FOOTER */
.footer {
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-logo {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}
.footer-tagline {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.footer-desc { font-size: 13px; color: var(--text-dim); line-height: 1.6; }
.footer-col h4 {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 8px; }
.footer-col a {
  font-size: 13px;
  color: var(--text-dim);
  transition: color 0.2s;
  text-decoration: none;
}
.footer-col a:hover { color: var(--text); }
.footer-contact li { font-size: 13px; color: var(--text-dim); line-height: 1.6; }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-dim);
}

/* ═══════════════════════════════════════════════════════════ RESPONSIVE */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .checkout-layout { grid-template-columns: 1fr; }
  .order-summary { position: static; }
}

@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0; right: 0;
    background: rgba(13,17,23,0.98);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 12px 24px 20px;
    gap: 4px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 10px; width: 100%; }
  .nav-links .btn-nav { margin-top: 8px; text-align: center; }

  .hero { min-height: auto; padding: calc(var(--nav-h) + 60px) 0 60px; }
  .hero-content { flex-direction: column-reverse; gap: 40px; }
  .hero-image img { width: 260px; }
  .hero-glow { width: 260px; height: 260px; }

  .products-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .docs-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 480px) {
  .features-grid { grid-template-columns: 1fr; }
  .bundle-selector { flex-direction: column; }
  .checkout-main { padding: 20px; }
}
