/* AICostManager — overrides on top of Modernize theme
   Only AICM-specific components and tweaks live here.
   The Modernize theme (mtheme/assets/css/styles.css) provides:
   - Bootstrap 5, Plus Jakarta Sans, color themes, dark mode,
   - cards, buttons, dropdowns, forms, alerts, navbar, footer, etc. */

/* ── CSS Variable Aliases ────────────────────────────────────
   Landing-page templates use inline styles with var(--aicm-*).   */
:root {
  --aicm-bg:            #f9fafb;
  --aicm-bg-surface:    #ffffff;
  --aicm-bg-inset:      #f3f4f6;
  --aicm-text:          #111827;
  --aicm-text-heading:  #111827;
  --aicm-text-muted:    #6b7280;
  --aicm-text-faint:    #9ca3af;
  --aicm-border:        #e5e7eb;
  --aicm-border-subtle: #f3f4f6;

  --aicm-blue:    #2563eb;
  --aicm-green:   #10b981;
  --aicm-red:     #ef4444;
  --aicm-orange:  #f59e0b;
  --aicm-yellow:  #eab308;
  --aicm-teal:    #14b8a6;
  --aicm-purple:  #8b5cf6;

  --aicm-font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Consolas,
                    'Liberation Mono', Menlo, monospace;

  --aicm-radius:    0.75rem;
  --aicm-radius-sm: 0.375rem;

  --aicm-shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --aicm-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

/* ── Dark Mode ─────────────────────────────────────────────── */
[data-bs-theme="dark"] {
  --aicm-bg:            #1a1d23;
  --aicm-bg-surface:    #22262e;
  --aicm-bg-inset:      #2a2e36;
  --aicm-text:          #e5e7eb;
  --aicm-text-heading:  #f3f4f6;
  --aicm-text-muted:    #9ca3af;
  --aicm-text-faint:    #6b7280;
  --aicm-border:        #374151;
  --aicm-border-subtle: #2a2e36;
}

/* ── Utilities ──────────────────────────────────────────────── */
.text-gradient {
  background: linear-gradient(135deg, #2563eb, #1e3a8a);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ══════════════════════════════════════════════════════════════
   LANDING PAGE

   Each <section> is full-width (backgrounds fill viewport).
   A .container inside each section constrains the content.
   ══════════════════════════════════════════════════════════════ */

/* ── Hero ──────────────────────────────────────────────────── */
.lp-hero {
  text-align: center;
  padding: 5rem 0 3rem;
  background: var(--aicm-bg-surface);
}

.lp-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--aicm-blue);
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 999px;
  padding: 0.35rem 1rem;
  margin-bottom: 1.5rem;
}

[data-bs-theme="dark"] .lp-hero-badge {
  background: rgba(37, 99, 235, 0.15);
  border-color: rgba(37, 99, 235, 0.3);
}

.lp-hero-title {
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--aicm-text-heading);
  margin-bottom: 1.25rem;
}

.lp-hero-sub {
  font-size: 1.2rem;
  line-height: 1.65;
  color: var(--aicm-text-muted);
  max-width: 620px;
  margin: 0 auto 2rem;
}

.lp-hero-cta {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.lp-hero-note {
  font-size: 0.8rem;
  color: var(--aicm-text-faint);
  margin: 0;
}

/* ── Provider Bar ────────────────────────────────────────── */
.lp-providers {
  text-align: center;
  padding: 2.5rem 0;
  background: var(--aicm-bg-surface);
  border-top: 1px solid var(--aicm-border-subtle);
  border-bottom: 1px solid var(--aicm-border-subtle);
}

.lp-providers-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--aicm-text-faint);
  margin-bottom: 1rem;
}

.lp-providers-row {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.lp-provider {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--aicm-text-muted);
}

.lp-provider i {
  font-size: 1.25rem;
}

.lp-providers-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--aicm-text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.lp-providers-link:hover {
  color: var(--aicm-text-heading);
}

.lp-providers-link i {
  font-size: 1.1rem;
}

/* ── Section Layout ───────────────────────────────────────── */
.lp-section {
  padding: 4.5rem 0;
  background: var(--aicm-bg-surface);
}

.lp-section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.lp-section-title {
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--aicm-text-heading);
  margin-bottom: 0.5rem;
}

.lp-section-sub {
  font-size: 1.05rem;
  color: var(--aicm-text-muted);
  margin: 0;
}

/* ── Section Background Colors ───────────────────────────── */
.lp-bg-light {
  background: #f3f4f6;
}

.lp-bg-accent {
  background: var(--bs-primary-bg-subtle, #cfe2ff);
}

[data-bs-theme="dark"] .lp-bg-light {
  background: #1e2228;
}

[data-bs-theme="dark"] .lp-bg-accent {
  background: #1a2332;
}

/* ── Problem Section ──────────────────────────────────────── */
.lp-problem-text {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--aicm-text-muted);
  margin-bottom: 1.75rem;
}

.lp-problem-points {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.lp-problem-point {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
}

.lp-problem-icon {
  width: 2.25rem;
  height: 2.25rem;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  border-radius: var(--aicm-radius-sm);
  background: var(--aicm-bg-inset);
}

.lp-problem-point strong {
  font-size: 0.95rem;
  color: var(--aicm-text-heading);
  display: block;
  margin-bottom: 0.15rem;
}

.lp-problem-point p {
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--aicm-text-muted);
  margin: 0;
}

/* ── Code Block (Dracula-inspired) ───────────────────────── */
.lp-code-block {
  border-radius: var(--aicm-radius);
  overflow: hidden;
  border: 1px solid #44475a;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  background: #282a36;
}

.lp-code-header {
  background: #44475a;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid #191a21;
}

.lp-code-dots {
  display: flex;
  gap: 6px;
}

.lp-code-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.lp-code-dots span:nth-child(1) { background: #ff5f56; }
.lp-code-dots span:nth-child(2) { background: #ffbd2e; }
.lp-code-dots span:nth-child(3) { background: #27ca3f; }

.lp-code-title {
  font-size: 0.825rem;
  font-weight: 600;
  color: #f8f8f2;
  font-family: var(--aicm-font-mono);
}

/* Code tabs */
.lp-code-block .nav-tabs {
  background: #44475a;
  margin: 0;
  padding: 0 1.25rem;
  border-bottom: 1px solid #191a21;
}

.lp-code-block .nav-tabs .nav-link {
  color: #f8f8f2;
  border: none;
  border-radius: 6px 6px 0 0;
  padding: 0.65rem 1rem;
  font-size: 0.825rem;
  font-weight: 600;
  background: transparent;
  margin-bottom: 0;
  font-family: var(--aicm-font-mono);
  transition: all 0.15s ease;
}

.lp-code-block .nav-tabs .nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.lp-code-block .nav-tabs .nav-link.active {
  background: #282a36;
  color: #50fa7b;
  border-bottom: 2px solid #50fa7b;
}

.lp-code-block .tab-content {
  background: #282a36;
}

.lp-code-body {
  padding: 1.25rem 1.5rem;
  margin: 0;
  overflow-x: auto;
  background: #282a36;
}

.lp-code-body code {
  color: #f8f8f2;
  font-family: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
  font-size: 0.82rem;
  line-height: 1.65;
  background: transparent;
  display: block;
  white-space: pre;
}

/* Dracula syntax tokens */
.c-kw  { color: #ff79c6; }
.c-fn  { color: #bd93f9; }
.c-str { color: #50fa7b; }
.c-cmt { color: #6272a4; font-style: italic; }
.c-var { color: #ffb86c; }
.c-mod { color: #8be9fd; }
.c-op  { color: #ff79c6; }
.c-num { color: #bd93f9; }

/* ── Step Cards (How It Works) ────────────────────────────── */
.lp-step-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 2rem 1.5rem;
  text-align: center;
  height: 100%;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-step-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-step-num {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  color: #fff;
  font-size: 1.1rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.lp-step-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin-bottom: 0.5rem;
}

.lp-step-body {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--aicm-text-muted);
  margin: 0;
}

.lp-step-body code {
  font-family: var(--aicm-font-mono);
  font-size: 0.82rem;
  background: var(--aicm-bg-inset);
  padding: 0.15rem 0.4rem;
  border-radius: var(--aicm-radius-sm);
}

/* ── Feature Cards ────────────────────────────────────────── */
.lp-feature-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 1.75rem 1.5rem;
  height: 100%;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-feature-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-feature-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--aicm-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 1rem;
}

.lp-feature-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin-bottom: 0.4rem;
}

.lp-feature-body {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--aicm-text-muted);
  margin: 0;
}

/* ── Competitive Cards ────────────────────────────────────── */
.lp-competitive-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 1.75rem 1.5rem;
  height: 100%;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-competitive-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-competitive-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.lp-competitive-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--aicm-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.lp-competitive-header h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin: 0;
}

.lp-competitive-header p {
  font-size: 0.8rem;
  color: var(--aicm-text-muted);
  margin: 0;
}

.lp-competitive-body {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--aicm-text-muted);
  margin-bottom: 1rem;
}

.lp-competitive-answer {
  background: rgba(16, 185, 129, 0.08);
  border-radius: var(--aicm-radius-sm);
  padding: 0.75rem 1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--aicm-green);
}

/* ── Pricing Cards ────────────────────────────────────────── */
.lp-price-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-price-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-price-featured {
  border-color: var(--aicm-blue);
  border-width: 2px;
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.1), var(--aicm-shadow-md);
}

.lp-price-badge {
  position: absolute;
  top: -0.65rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--aicm-blue);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.75rem;
  border-radius: 999px;
  white-space: nowrap;
}

.lp-price-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin-bottom: 0.5rem;
}

.lp-price-amount {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
}

.lp-price-dollar {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--aicm-text-heading);
}

.lp-price-period {
  font-size: 0.9rem;
  color: var(--aicm-text-muted);
}

.lp-price-desc {
  font-size: 0.85rem;
  color: var(--aicm-text-muted);
  line-height: 1.5;
  margin-bottom: 1.5rem;
}

.lp-price-features {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  flex: 1;
}

.lp-price-features li {
  font-size: 0.85rem;
  color: var(--aicm-text);
  padding: 0.35rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.lp-price-features li i.ti-check {
  color: var(--aicm-green);
  font-size: 1rem;
  flex-shrink: 0;
}

.lp-price-features li i.ti-x {
  color: var(--aicm-text-faint);
  font-size: 1rem;
  flex-shrink: 0;
}

.lp-price-na {
  color: var(--aicm-text-faint) !important;
}

/* ── FAQ ──────────────────────────────────────────────────── */
.lp-faq {
  max-width: 680px;
  margin: 0 auto;
}

.lp-faq-item {
  border-bottom: 1px solid var(--aicm-border);
  padding: 0;
}

.lp-faq-item:last-child {
  border-bottom: none;
}

.lp-faq-item summary {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--aicm-text-heading);
  cursor: pointer;
  padding: 1rem 0;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.lp-faq-item summary::-webkit-details-marker {
  display: none;
}

.lp-faq-item summary::after {
  content: '+';
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--aicm-text-faint);
  flex-shrink: 0;
  margin-left: 1rem;
  transition: transform 0.2s ease;
}

.lp-faq-item[open] summary::after {
  content: '\2212'; /* minus sign */
}

.lp-faq-item p {
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--aicm-text-muted);
  padding: 0 0 1rem;
  margin: 0;
}

.lp-faq-item code {
  font-family: var(--aicm-font-mono);
  font-size: 0.82rem;
  background: var(--aicm-bg-inset);
  padding: 0.15rem 0.4rem;
  border-radius: var(--aicm-radius-sm);
}

/* ── Final CTA ────────────────────────────────────────────── */
.lp-cta {
  text-align: center;
  padding: 4.5rem 0 3rem;
  background: var(--aicm-bg-surface);
}

.lp-cta-title {
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--aicm-text-heading);
  margin-bottom: 0.5rem;
}

.lp-cta-sub {
  font-size: 1.05rem;
  color: var(--aicm-text-muted);
  margin-bottom: 1.5rem;
}

/* ── Client Cards (MCP public page) ──────────────────────── */
.lp-client-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 1.5rem 1rem;
  text-align: center;
  height: 100%;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-client-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-client-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
}

.lp-client-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin-bottom: 0.2rem;
}

.lp-client-desc {
  font-size: 0.8rem;
  color: var(--aicm-text-muted);
  line-height: 1.4;
  margin: 0;
}

/* ── Tool Category Cards (MCP public page) ───────────────── */
.lp-tool-category-card {
  background: var(--aicm-bg-surface);
  border: 1px solid var(--aicm-border);
  border-radius: var(--aicm-radius);
  padding: 1.25rem 1.25rem 1rem;
  height: 100%;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.lp-tool-category-card:hover {
  box-shadow: var(--aicm-shadow-md);
  transform: translateY(-2px);
}

.lp-tool-category-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.lp-tool-category-header h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--aicm-text-heading);
  margin: 0;
}

.lp-tool-category-icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--aicm-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.lp-tool-category-count {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--aicm-blue);
}

.lp-tool-category-examples {
  font-family: var(--aicm-font-mono);
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--aicm-text-muted);
  margin: 0;
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* Landing page mobile */
  .lp-hero {
    padding: 3rem 0 2rem;
  }
  .lp-hero-title {
    font-size: 2.5rem;
  }
  .lp-hero-sub {
    font-size: 1rem;
  }
  .lp-hero-cta {
    flex-direction: column;
    align-items: center;
  }
  .lp-hero-cta .btn {
    width: 100%;
    max-width: 280px;
  }
  .lp-providers-row {
    gap: 1.25rem;
  }
  .lp-section {
    padding: 3rem 0;
  }
  .lp-section-title {
    font-size: 1.65rem;
  }
  .lp-cta-title {
    font-size: 1.65rem;
  }
  .lp-problem .lp-section-title {
    text-align: center !important;
  }
  .lp-problem-text {
    text-align: center;
  }
  .lp-code-body code {
    font-size: 0.72rem;
  }
}
