/* ═══════════════════════════════════════════════════════════════
   Vista Brain — Google Ads Suite Stylesheet
   Manus Design System — Pixel-perfect match
   Prefix: .gads-  |  Palette: oklch diverse
   ═══════════════════════════════════════════════════════════════ */

/* ── Design Tokens (Manus palette) ── */
.gads-section {
    /* Legacy tokens (keep for existing badges/alerts) */
    --gads-accent:    oklch(0.55 0.2 260);
    --gads-green:     oklch(0.6 0.17 150);
    --gads-yellow:    oklch(0.8 0.18 85);
    --gads-red:       oklch(0.6 0.22 25);
    --gads-purple:    oklch(0.6 0.2 300);
    --gads-blue-bg:   oklch(0.55 0.2 260 / 0.1);
    --gads-green-bg:  oklch(0.6 0.17 150 / 0.1);
    --gads-yellow-bg: oklch(0.8 0.18 85 / 0.1);
    --gads-red-bg:    oklch(0.6 0.22 25 / 0.1);
    --gads-purple-bg: oklch(0.6 0.2 300 / 0.1);

    /* Manus primary palette */
    --m-teal:    oklch(0.75 0.15 175);
    --m-blue:    oklch(0.65 0.18 250);
    --m-deep:    oklch(0.55 0.2 260);
    --m-amber:   oklch(0.75 0.15 85);
    --m-coral:   oklch(0.65 0.2 25);
    --m-purple:  oklch(0.6 0.15 300);
    --m-green:   oklch(0.72 0.17 155);
    --m-gray:    oklch(0.55 0 0);

    /* Theme-aware inline style tokens */
    --gads-thead-bg:      oklch(0.18 0.02 260);
    --gads-bar-track:     oklch(0.25 0.02 260);
    --gads-bar-track-alt: oklch(0.2 0.02 260);
    --gads-btn-active-bg: oklch(0.22 0.02 260);
    --gads-item-bg:       oklch(0.15 0.02 260);
    --gads-inactive-text: oklch(0.6 0.02 260);
    --gads-border-subtle: oklch(0.3 0.02 260);
    --gads-legend-text:   oklch(0.7 0.02 260);
    --gads-pill-bg:       oklch(0.18 0.02 260);
}


/* ═══════════════════════════════════════════════════════
   M1. Hero Banner (Overview page)
   ═══════════════════════════════════════════════════════ */

.gads-hero {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    height: 130px;
    margin-bottom: 20px;
}

.gads-hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gads-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,0.75), rgba(0,0,0,0.50), rgba(0,0,0,0.20));
}

.gads-hero-content {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
}

.gads-hero-content h1 {
    font-family: 'DM Sans', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    letter-spacing: -0.01em;
}

.gads-hero-content h1 svg,
.gads-hero-content h1 i { color: var(--m-blue); width: 28px; height: 28px; }

.gads-hero-title {
    font-family: 'DM Sans', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    letter-spacing: -0.01em;
}

.gads-hero-subtitle {
    color: rgba(255,255,255,0.6);
    font-size: 14px;
    font-weight: 500;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 10px;
    border-radius: 9999px;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.8);
    font-size: 10px;
    font-weight: 600;
}

/* Legacy alias */
.gads-hero-desc { color: rgba(255,255,255,0.6); font-size: 14px; font-weight: 500; margin-top: 6px; }
.gads-hero-desc .gads-hero-tags {
    display: inline-flex; align-items: center; gap: 4px; margin-left: 8px;
    padding: 2px 10px; border-radius: 9999px;
    background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.8);
    font-size: 10px; font-weight: 600;
}

.gads-hero-stats {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gads-hero-stat {
    text-align: right;
}

.gads-hero-stat__label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.5);
}

.gads-hero-stat__value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 700;
    color: white;
}

.gads-hero-divider {
    width: 1px;
    height: 32px;
    background: rgba(255,255,255,0.15);
}


/* ═══════════════════════════════════════════════════════
   M2. Metric Cards (6-col KPI grid — Manus MetricBox)
   ═══════════════════════════════════════════════════════ */

.gads-kpi-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.gads-kpi-grid--4 { grid-template-columns: repeat(4, 1fr); }
.gads-kpi-grid--3 { grid-template-columns: repeat(3, 1fr); }

.gads-metric-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
    transition: all 0.25s ease;
    cursor: default;
}

.gads-metric-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.gads-metric-top-line {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--card-color, var(--m-teal)), transparent);
}

.gads-metric-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.gads-metric-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: color-mix(in oklch, var(--card-color, var(--m-teal)) 12%, transparent);
    transition: transform 0.25s ease;
}

.gads-metric-card:hover .gads-metric-icon { transform: scale(1.1); }

.gads-metric-icon svg,
.gads-metric-icon i { width: 20px; height: 20px; color: var(--card-color, var(--m-teal)); }

.gads-metric-change {
    font-family: 'DM Sans', sans-serif;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 2px;
}

.gads-metric-change.positive { color: oklch(0.65 0.2 155); }
.gads-metric-change.negative { color: oklch(0.65 0.2 25); }

.gads-metric-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    line-height: 1.2;
}

.gads-metric-label {
    font-family: 'DM Sans', sans-serif;
    font-size: 10px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-top: 4px;
}

.gads-metric-sublabel {
    font-family: 'DM Sans', sans-serif;
    font-size: 9px;
    color: var(--text-muted);
    margin-top: 2px;
    opacity: 0.7;
}

/* BEM __ aliases used by JS */
.gads-metric-card__topline {
    position: absolute; top: 0; left: 0; right: 0; height: 2px;
}
.gads-metric-card__header {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px;
}
.gads-metric-card__icon {
    width: 40px; height: 40px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    transition: transform 0.25s ease;
}
.gads-metric-card:hover .gads-metric-card__icon { transform: scale(1.1); }
.gads-metric-card__icon svg,
.gads-metric-card__icon i { width: 20px; height: 20px; }
.gads-metric-card__change {
    font-family: 'DM Sans', sans-serif; font-size: 12px; font-weight: 600;
    display: flex; align-items: center; gap: 2px;
}
.gads-metric-card__value {
    font-family: 'JetBrains Mono', monospace; font-size: 24px; font-weight: 700;
    letter-spacing: -0.02em; color: var(--text-primary); line-height: 1.2;
}
.gads-metric-card__label {
    font-family: 'DM Sans', sans-serif; font-size: 10px; font-weight: 500;
    color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 4px;
}
.gads-metric-card__sublabel {
    font-family: 'DM Sans', sans-serif; font-size: 9px; color: var(--text-muted); margin-top: 2px;
}


/* ═══════════════════════════════════════════════════════
   M3. 12-Column Grid System
   ═══════════════════════════════════════════════════════ */

.gads-grid-12 {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.gads-col-2 { grid-column: span 2; }
.gads-col-3 { grid-column: span 3; }
.gads-col-4 { grid-column: span 4; }
.gads-col-5 { grid-column: span 5; }
.gads-col-6 { grid-column: span 6; }
.gads-col-7 { grid-column: span 7; }
.gads-col-8 { grid-column: span 8; }
.gads-col-12 { grid-column: span 12; }

/* JS uses gads-col-span-N alias */
.gads-col-span-2 { grid-column: span 2; }
.gads-col-span-3 { grid-column: span 3; }
.gads-col-span-4 { grid-column: span 4; }
.gads-col-span-5 { grid-column: span 5; }
.gads-col-span-6 { grid-column: span 6; }
.gads-col-span-7 { grid-column: span 7; }
.gads-col-span-8 { grid-column: span 8; }
.gads-col-span-12 { grid-column: span 12; }


/* ═══════════════════════════════════════════════════════
   M4. Section Cards (chart/table containers)
   ═══════════════════════════════════════════════════════ */

.gads-section-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    transition: box-shadow 0.25s ease;
}

.gads-section-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

/* BEM __ aliases used by JS */
.gads-section-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.gads-section-card__title-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-section-card__title-row svg,
.gads-section-card__title-row i { width: 15px; height: 15px; flex-shrink: 0; }

.gads-section-card__title {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.gads-section-card__body { /* no special styles needed */ }

/* Legacy aliases */
.gads-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.gads-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-section-title svg,
.gads-section-title i { width: 15px; height: 15px; flex-shrink: 0; }

.gads-section-title h3 {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.gads-section-meta {
    font-size: 10px;
    color: var(--text-muted);
    margin-left: 4px;
}

.gads-section-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.gads-metric-switch {
    display: flex;
    gap: 2px;
    background: var(--bg-primary, rgba(255,255,255,0.04));
    padding: 2px;
    border-radius: 8px;
}

.gads-metric-switch button {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 500;
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
}

.gads-metric-switch button.active {
    background: var(--bg-card);
    color: var(--text-primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}


/* ═══════════════════════════════════════════════════════
   M5. Health Gauge (SVG donut)
   ═══════════════════════════════════════════════════════ */

.gads-health-gauge {
    position: relative;
    width: 144px;
    height: 144px;
    margin: 0 auto 8px;
}

.gads-health-gauge svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.gads-health-gauge .gauge-bg {
    fill: none;
    stroke: var(--border);
    stroke-width: 8;
    opacity: 0.3;
}

.gads-health-gauge .gauge-fill {
    fill: none;
    stroke-width: 8;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s ease-out;
}

.gads-health-gauge-center,
.gads-health-gauge__center {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.gads-health-gauge-number,
.gads-health-gauge__score {
    font-family: 'JetBrains Mono', monospace;
    font-size: 30px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.gads-health-gauge-label,
.gads-health-gauge__label {
    font-family: 'DM Sans', sans-serif;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    margin-top: 4px;
}

.gads-health-gauge__svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.gads-health-gauge__fill {
    fill: none;
    stroke-width: 8;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s ease-out;
}

/* Health progress bars */
.gads-health-bar {
    margin-bottom: 10px;
}

.gads-health-bar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    margin-bottom: 4px;
}

.gads-health-bar-name {
    color: var(--text-primary);
    font-weight: 500;
}

.gads-health-bar-score {
    font-family: 'JetBrains Mono', monospace;
    color: var(--text-muted);
}

.gads-health-bar-track {
    height: 8px;
    border-radius: 9999px;
    background: var(--bg-primary, rgba(255,255,255,0.04));
    overflow: hidden;
}

.gads-health-bar-fill {
    height: 100%;
    border-radius: 9999px;
    transition: width 0.8s ease;
}


/* ═══════════════════════════════════════════════════════
   M6. Conversion Funnel
   ═══════════════════════════════════════════════════════ */

.gads-funnel-step {
    margin-bottom: 16px;
}

.gads-funnel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.gads-funnel-stage {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-primary);
}

.gads-funnel-stage svg,
.gads-funnel-stage i { width: 14px; height: 14px; }

.gads-funnel-values {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gads-funnel-count {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
}

.gads-funnel-pct {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--text-muted);
}

.gads-funnel-bar {
    height: 12px;
    border-radius: 9999px;
    background: rgba(255,255,255,0.04);
    overflow: hidden;
    position: relative;
}

.gads-funnel-bar-fill {
    height: 100%;
    border-radius: 9999px;
    position: relative;
    transition: width 1s ease;
}

.gads-funnel-bar-label {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 8px;
    font-weight: 700;
    color: rgba(255,255,255,0.9);
}

/* BEM __ aliases used by JS */
.gads-funnel-step__header {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px;
}
.gads-funnel-step__label {
    font-size: 12px; font-weight: 500; color: var(--text-primary);
}
.gads-funnel-step__value {
    font-family: 'JetBrains Mono', monospace; font-size: 14px; font-weight: 700; color: var(--text-primary);
}
.gads-funnel-step__drop {
    font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--text-muted);
}
.gads-funnel-bar__fill {
    height: 100%; border-radius: 9999px; position: relative; transition: width 1s ease;
}
.gads-funnel-bar__pct {
    position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
    font-size: 8px; font-weight: 700; color: rgba(255,255,255,0.9);
}

/* Quick stat BEM __ aliases */
.gads-quick-stat__label {
    font-size: 11px; color: var(--text-muted);
}
.gads-quick-stat__value {
    font-family: 'JetBrains Mono', monospace; font-size: 12px; font-weight: 700;
}

/* Metric switch BEM __ aliases */
.gads-metric-switch__btn {
    padding: 4px 10px; border-radius: 6px; font-size: 10px; font-weight: 500;
    border: none; background: transparent; color: var(--text-muted); cursor: pointer; transition: all 0.2s;
}
.gads-metric-switch__btn.active {
    background: var(--bg-card); color: var(--text-primary); box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}


/* ═══════════════════════════════════════════════════════
   M7. Quick Stats List
   ═══════════════════════════════════════════════════════ */

.gads-quick-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}

.gads-quick-stat:last-child { border-bottom: none; }

.gads-quick-stat-label {
    font-size: 11px;
    color: var(--text-muted);
}

.gads-quick-stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    font-weight: 700;
}


/* ═══════════════════════════════════════════════════════
   M8. Alerts & Recommendations
   ═══════════════════════════════════════════════════════ */

.gads-alert-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    background: rgba(255,255,255,0.02);
    margin-bottom: 8px;
    transition: background 0.2s;
}

.gads-alert-item:hover { background: rgba(255,255,255,0.05); }

.gads-alert-item svg,
.gads-alert-item i { width: 14px; height: 14px; flex-shrink: 0; margin-top: 2px; }

.gads-alert-item-body { flex: 1; min-width: 0; }

.gads-alert-item-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-primary);
}

.gads-alert-item-badge {
    font-size: 8px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 9999px;
}

.gads-alert-item-desc {
    font-size: 9px;
    color: var(--text-muted);
    margin-top: 2px;
    line-height: 1.4;
}

.gads-alert-item-impact {
    font-size: 9px;
    font-weight: 600;
    color: var(--m-green);
    margin-top: 4px;
}


/* ═══════════════════════════════════════════════════════
   M9. Campaign Performance List
   ═══════════════════════════════════════════════════════ */

.gads-campaign-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 0;
}

.gads-campaign-dot {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    flex-shrink: 0;
}

.gads-campaign-name {
    flex: 1;
    font-size: 10px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gads-campaign-spend {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--text-muted);
}

.gads-campaign-roas {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    font-weight: 600;
}

.gads-campaign-conv {
    font-size: 10px;
    color: var(--text-muted);
}


/* ═══════════════════════════════════════════════════════
   M10. Device Breakdown
   ═══════════════════════════════════════════════════════ */

.gads-device-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.gads-device-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-device-dot {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
}

.gads-device-icon { color: var(--text-muted); }
.gads-device-icon svg, .gads-device-icon i { width: 12px; height: 12px; }

.gads-device-name {
    font-size: 11px;
    color: var(--text-primary);
}

.gads-device-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gads-device-pct {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-primary);
}

.gads-device-conv {
    font-size: 10px;
    color: var(--text-muted);
}

.gads-device-rate {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
}


/* ═══════════════════════════════════════════════════════
   M11. Ad Preview Cards
   ═══════════════════════════════════════════════════════ */

.gads-ad-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.gads-ad-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.25s ease;
}

.gads-ad-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.15); }

.gads-ad-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 16px;
}

.gads-ad-card-type {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-ad-card-type svg, .gads-ad-card-type i { width: 16px; height: 16px; }

.gads-ad-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.gads-ad-card-id {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

.gads-ad-preview {
    margin: 0 16px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255,255,255,0.02);
}

.gads-ad-preview-url {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.gads-ad-preview-favicon {
    width: 24px;
    height: 24px;
    border-radius: 9999px;
    background: oklch(0.55 0.2 260);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 10px;
    font-weight: 700;
}

.gads-ad-preview-domain { font-size: 13px; color: var(--text-primary); }
.gads-ad-preview-path { font-size: 11px; color: var(--text-muted); }

.gads-ad-preview-headline {
    font-size: 18px;
    font-weight: 500;
    color: oklch(0.6 0.15 250);
    margin-bottom: 4px;
    cursor: pointer;
}

.gads-ad-preview-headline:hover { text-decoration: underline; }

.gads-ad-preview-desc {
    font-size: 13px;
    color: var(--text-primary);
    line-height: 1.5;
}

.gads-ad-strength {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
}

.gads-ad-strength svg, .gads-ad-strength i { width: 16px; height: 16px; }
.gads-ad-strength-label { font-size: 12px; font-weight: 500; }

.gads-ad-metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    padding: 12px 16px 16px;
}

.gads-ad-metrics-item {
    text-align: center;
}

.gads-ad-metrics-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.gads-ad-metrics-label {
    font-size: 9px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}


/* ═══════════════════════════════════════════════════════
   M12. Filter Bar
   ═══════════════════════════════════════════════════════ */

.gads-filter-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.gads-search-input {
    flex: 1;
    min-width: 200px;
    padding: 8px 12px 8px 36px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
    position: relative;
}

.gads-search-input:focus { border-color: var(--m-teal); }

.gads-search-wrapper {
    position: relative;
    flex: 1;
    min-width: 200px;
}

.gads-search-wrapper svg,
.gads-search-wrapper i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    color: var(--text-muted);
    pointer-events: none;
}

.gads-filter-input {
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid oklch(0.25 0.02 260);
    background: oklch(0.13 0.015 260);
    color: oklch(0.9 0.02 260);
    font-size: 12px;
    font-family: 'DM Sans', sans-serif;
    outline: none;
    transition: border-color 0.2s;
}
.gads-filter-input::placeholder { color: oklch(0.45 0.02 260); }
.gads-filter-input:focus { border-color: oklch(0.65 0.18 250); }

.gads-filter-select {
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid oklch(0.25 0.02 260);
    background: oklch(0.13 0.015 260);
    color: oklch(0.9 0.02 260);
    font-size: 12px;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    outline: none;
}
.gads-filter-select:focus { border-color: oklch(0.65 0.18 250); }

.gads-asset-tab { transition: all 0.2s; }
.gads-asset-tab:hover { color: oklch(0.85 0.02 260) !important; }


/* ═══════════════════════════════════════════════════════
   M13. Quality Score Popover
   ═══════════════════════════════════════════════════════ */

.gads-qs-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.gads-qs-dot {
    width: 10px;
    height: 10px;
    border-radius: 9999px;
}

.gads-qs-popover-trigger {
    cursor: pointer;
    color: var(--text-muted);
}

.gads-qs-popover-trigger svg, .gads-qs-popover-trigger i { width: 14px; height: 14px; }

.gads-qs-popover {
    position: absolute;
    z-index: 50;
    width: 256px;
    padding: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    left: 50%;
    transform: translateX(-50%);
    top: 100%;
    margin-top: 8px;
}

.gads-qs-wrapper:hover .gads-qs-popover {
    opacity: 1;
    visibility: visible;
}

.gads-qs-popover-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.gads-qs-popover-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    margin-bottom: 6px;
}

.gads-qs-popover-row-label { color: var(--text-muted); }

.gads-qs-popover-row-value {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-primary);
}


/* ═══════════════════════════════════════════════════════
   M14. Heatmap (Schedule)
   ═══════════════════════════════════════════════════════ */

.gads-heatmap {
    overflow-x: auto;
}

.gads-heatmap table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 2px;
}

.gads-heatmap th {
    font-size: 9px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    padding: 4px;
    text-align: center;
}

.gads-heatmap td {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    text-align: center;
    font-size: 8px;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    cursor: default;
    transition: transform 0.15s;
}

.gads-heatmap td:hover { transform: scale(1.15); }


/* ═══════════════════════════════════════════════════════
   M15. Report Template Grid
   ═══════════════════════════════════════════════════════ */

.gads-report-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.gads-report-template {
    padding: 16px;
    border-radius: 8px;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all 0.2s;
}

.gads-report-template:hover {
    border-color: var(--m-teal);
    background: rgba(255,255,255,0.02);
}

.gads-report-template.selected,
.gads-report-template--selected {
    border-color: var(--m-blue);
    box-shadow: 0 0 0 1px var(--m-blue);
}

.gads-report-template-icon {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.gads-report-template-icon svg, .gads-report-template-icon i {
    width: 24px;
    height: 24px;
    color: var(--m-blue);
}

.gads-report-template-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.gads-report-template-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
}


/* ═══════════════════════════════════════════════════════
   M16. View All Link
   ═══════════════════════════════════════════════════════ */

.gads-view-all {
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    border: none;
    background: none;
    color: var(--m-teal);
    transition: opacity 0.2s;
}

.gads-view-all:hover { opacity: 0.8; }
.gads-view-all svg, .gads-view-all i { width: 10px; height: 10px; }


/* ═══════════════════════════════════════════════════════
   M18. Sortable Table (Campaigns, Keywords, etc.)
   ═══════════════════════════════════════════════════════ */

.gads-sortable-th {
    padding: 12px 16px;
    font-family: 'DM Sans', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    white-space: nowrap;
    user-select: none;
    transition: color 0.2s;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.gads-sortable-th.text-right { text-align: right; }
.gads-sortable-th:hover { color: var(--text-primary); }

.gads-camp-row td {
    padding: 12px 16px;
    border-bottom: 1px solid oklch(0.25 0.02 260 / 0.5);
    font-size: 13px;
    color: var(--text-primary);
}

.gads-camp-row td.text-right { text-align: right; }

.gads-camp-row:hover {
    background: oklch(0.2 0.02 260 / 0.5);
}


/* ═══════════════════════════════════════════════════════
   M17. Responsive overrides for new components
   ═══════════════════════════════════════════════════════ */

@media (max-width: 1279px) {
    .gads-kpi-grid { grid-template-columns: repeat(3, 1fr); }
    .gads-grid-12 { grid-template-columns: repeat(6, 1fr); }
    .gads-col-7, .gads-col-span-7 { grid-column: span 6; }
    .gads-col-3, .gads-col-span-3 { grid-column: span 3; }
    .gads-col-2, .gads-col-span-2 { grid-column: span 3; }
    .gads-col-span-4 { grid-column: span 3; }
    .gads-col-span-6 { grid-column: span 6; }
    .gads-col-span-8 { grid-column: span 6; }
    .gads-report-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
    .gads-kpi-grid { grid-template-columns: repeat(2, 1fr); }
    .gads-grid-12 { grid-template-columns: 1fr; }
    .gads-col-2, .gads-col-3, .gads-col-4, .gads-col-5,
    .gads-col-6, .gads-col-7, .gads-col-8, .gads-col-12,
    .gads-col-span-2, .gads-col-span-3, .gads-col-span-4, .gads-col-span-5,
    .gads-col-span-6, .gads-col-span-7, .gads-col-span-8, .gads-col-span-12 { grid-column: span 1; }
    .gads-hero { height: 100px; }
    .gads-hero-stats { display: none; }
    .gads-report-grid { grid-template-columns: 1fr; }
    .gads-ad-grid { grid-template-columns: 1fr; }
}


/* ═══════════════════════════════════════════════════════
   1. Section Layout (Sub-Nav + Content)
   ═══════════════════════════════════════════════════════ */

.gads-section {
    display: flex;
    gap: 0;
    min-height: calc(100vh - 80px);
    margin: -20px -24px;
}

/* ── Sub-Navigation ──── */

.gads-sub-nav {
    width: 220px;
    min-width: 220px;
    background: var(--bg-card);
    border-right: 1px solid var(--border);
    padding: 24px 0;
    overflow-y: auto;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    height: calc(100vh - 60px);
    display: flex;
    flex-direction: column;
}

.gads-sub-nav__header {
    padding: 0 20px 16px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.gads-sub-nav__logo {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, oklch(0.70 0.18 250), oklch(0.50 0.16 260));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    flex-shrink: 0;
}

.gads-sub-nav__title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px;
}

.gads-sub-nav__subtitle {
    font-size: 11px;
    color: var(--gads-accent);
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Nav items */
.gads-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    transition: all var(--transition);
    border-left: 3px solid transparent;
    position: relative;
}

.gads-nav-item:hover {
    background: var(--sidebar-hover);
    color: var(--text-primary);
}

.gads-nav-item.active {
    color: var(--gads-accent);
    font-weight: 600;
    border-left-color: var(--gads-accent);
    background: oklch(0.55 0.2 260 / 0.08);
}

.gads-nav-item__icon {
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0.6;
}

.gads-nav-item.active .gads-nav-item__icon { opacity: 1; }
.gads-nav-item__icon svg { width: 16px; height: 16px; }

/* Expandable groups */
.gads-nav-group__label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    transition: all var(--transition);
    user-select: none;
}

.gads-nav-group__label:hover {
    background: var(--sidebar-hover);
    color: var(--text-primary);
}

.gads-nav-group__arrow {
    margin-left: auto;
    font-size: 10px;
    transition: transform var(--transition);
    opacity: 0.4;
}

.gads-nav-group.expanded .gads-nav-group__arrow { transform: rotate(180deg); }

.gads-nav-group__items {
    max-height: 0;
    overflow: hidden;
    transition: max-height 300ms ease;
}

.gads-nav-group.expanded .gads-nav-group__items { max-height: 400px; }
.gads-nav-group__items .gads-nav-item { padding-left: 48px; font-size: 12px; }

/* Badge on nav item */
.gads-nav-badge {
    margin-left: auto;
    min-width: 18px;
    height: 18px;
    border-radius: 9999px;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
}

.gads-nav-badge:not([class*="--"]) {
    background: oklch(0.65 0.2 25 / 0.15);
    color: oklch(0.65 0.2 25);
}
.gads-nav-badge--alert { background: var(--danger-bg); color: var(--danger); }
.gads-nav-badge--info  { background: var(--gads-blue-bg); color: var(--gads-accent); }
.gads-nav-badge--ai    { background: var(--gads-purple-bg); color: var(--gads-purple); }

/* Nav divider */
.gads-nav-divider {
    height: 1px;
    margin: 8px 20px;
    background: var(--border);
    opacity: 0.5;
}

/* Nav footer */
.gads-sub-nav__footer {
    padding: 12px 20px 0;
    margin-top: auto;
    text-align: center;
}

.gads-sub-nav__footer span {
    font-size: 9px;
    color: var(--text-muted);
    font-weight: 500;
    opacity: 0.5;
}


/* ── Content Area ──── */

.gads-content {
    flex: 1;
    padding: 20px 24px;
    overflow-y: auto;
    max-width: 1200px;
}

.gads-page { display: none; }

.gads-page.active {
    display: block;
    animation: gadsFadeIn 300ms ease both;
}

@keyframes gadsFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}


/* ═══════════════════════════════════════════════════════
   2. Page Headers
   ═══════════════════════════════════════════════════════ */

.gads-page__title {
    font-size: 24px;
    font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    color: var(--text-primary);
    margin: 0 0 6px;
}

.gads-page__subtitle {
    font-size: 13px;
    font-family: 'DM Sans', sans-serif;
    color: var(--text-muted);
    margin: 0 0 20px;
}


/* ═══════════════════════════════════════════════════════
   3. Stat Cards — MATCH .summary-card
   ═══════════════════════════════════════════════════════ */

.gads-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.gads-stat-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid var(--border);
    transition: all var(--transition);
    cursor: default;
    position: relative;
    overflow: hidden;
}

.gads-stat-card:hover {
    border-color: var(--border-hover);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.gads-stat-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.gads-stat-card__icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gads-stat-card__icon svg { width: 16px; height: 16px; }

.gads-stat-card__icon--blue   { background: var(--gads-blue-bg); color: var(--gads-accent); }
.gads-stat-card__icon--green  { background: var(--gads-green-bg); color: var(--gads-green); }
.gads-stat-card__icon--yellow { background: var(--gads-yellow-bg); color: var(--gads-yellow); }
.gads-stat-card__icon--red    { background: var(--gads-red-bg); color: var(--gads-red); }

.gads-stat-card__trend {
    font-size: 11px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
    display: flex;
    align-items: center;
    gap: 3px;
}

.gads-stat-card__trend--up      { color: var(--success); }
.gads-stat-card__trend--down    { color: var(--danger); }
.gads-stat-card__trend--neutral { color: var(--text-muted); }

.gads-stat-card__value {
    font-size: 24px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.gads-stat-card__label {
    font-size: 10px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}


/* ═══════════════════════════════════════════════════════
   4. Charts Grid
   ═══════════════════════════════════════════════════════ */

.gads-charts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.gads-chart-block {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    transition: box-shadow var(--transition), transform var(--transition);
}

.gads-chart-block:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

.gads-chart-block--full { grid-column: 1 / -1; }

.gads-chart-title {
    font-size: 14px;
    font-weight: 600;
    font-family: 'DM Sans', sans-serif;
    color: var(--text-primary);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-chart-container {
    position: relative;
    height: 260px;
}

.gads-chart-container canvas { width: 100% !important; }


/* ═══════════════════════════════════════════════════════
   5. Table Sections
   ═══════════════════════════════════════════════════════ */

.gads-table-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    transition: box-shadow var(--transition), transform var(--transition);
}

.gads-table-section:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

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

.gads-table-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.gads-table-count {
    font-size: 12px;
    color: var(--text-muted);
    margin-left: 8px;
}

.gads-table-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* Data table overrides */
.gads-table-section .data-table th {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


/* ═══════════════════════════════════════════════════════
   6. Controls & Filters
   ═══════════════════════════════════════════════════════ */

.gads-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.gads-date-pills {
    display: flex;
    gap: 4px;
    background: var(--bg-card);
    padding: 3px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
}

.gads-date-pill {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.gads-date-pill:hover { background: var(--sidebar-hover); }

.gads-date-pill.active {
    background: var(--gads-accent);
    color: white;
    font-weight: 600;
}


/* ═══════════════════════════════════════════════════════
   7. Alert Banner
   ═══════════════════════════════════════════════════════ */

.gads-alert {
    border-radius: var(--radius);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.gads-alert--critical { background: var(--gads-red-bg); border: 1px solid oklch(0.6 0.22 25 / 0.2); color: var(--gads-red); }
.gads-alert--warning  { background: var(--gads-yellow-bg); border: 1px solid oklch(0.8 0.18 85 / 0.2); color: var(--gads-yellow); }
.gads-alert--info     { background: var(--gads-blue-bg); border: 1px solid oklch(0.55 0.2 260 / 0.2); color: var(--gads-accent); }

.gads-alert__icon { flex-shrink: 0; }
.gads-alert__icon svg { width: 18px; height: 18px; }
.gads-alert__text { flex: 1; font-size: 13px; font-weight: 500; }
.gads-alert__dismiss { background: none; border: none; cursor: pointer; opacity: 0.5; padding: 4px; }
.gads-alert__dismiss:hover { opacity: 1; }


/* ═══════════════════════════════════════════════════════
   8. Health Score Ring
   ═══════════════════════════════════════════════════════ */

.gads-health {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-bottom: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    transition: box-shadow var(--transition);
}

.gads-health:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.gads-health__ring {
    position: relative;
    width: 120px;
    height: 120px;
    flex-shrink: 0;
}

.gads-health__ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.gads-health__ring-bg   { fill: none; stroke: var(--border); stroke-width: 10; }
.gads-health__ring-fill { fill: none; stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 1s ease; }

.gads-health__ring-fill--excellent  { stroke: var(--gads-green); }
.gads-health__ring-fill--good       { stroke: var(--gads-accent); }
.gads-health__ring-fill--needs-work { stroke: var(--gads-yellow); }
.gads-health__ring-fill--critical   { stroke: var(--gads-red); }

.gads-health__score {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.gads-health__number { font-size: 30px; font-weight: 700; font-family: 'JetBrains Mono', monospace; letter-spacing: -0.02em; color: var(--text-primary); line-height: 1; }
.gads-health__label  { font-size: 10px; font-weight: 500; font-family: 'DM Sans', sans-serif; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 4px; }
.gads-health__details { flex: 1; }

.gads-health__sub-scores {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.gads-health__sub-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-secondary);
}

.gads-health__sub-bar  { flex: 1; height: 4px; background: var(--border); border-radius: 2px; overflow: hidden; }
.gads-health__sub-fill { height: 100%; border-radius: 2px; transition: width 800ms ease; }


/* ═══════════════════════════════════════════════════════
   9. Info Cards (Best Campaign, Top Keyword, etc.)
   ═══════════════════════════════════════════════════════ */

.gads-info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 20px;
}

.gads-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px;
    transition: box-shadow var(--transition), transform var(--transition);
}

.gads-info-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

.gads-info-card__label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.gads-info-card__value {
    font-size: 14px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
    color: var(--text-primary);
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gads-info-card__meta {
    font-size: 12px;
    color: var(--text-muted);
}


/* ═══════════════════════════════════════════════════════
   10. AI Strategist Chat
   ═══════════════════════════════════════════════════════ */

.gads-strategist {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 20px;
}

.gads-strategist__header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
    background: oklch(0.55 0.2 260 / 0.05);
}

.gads-strategist__badge {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.gads-strategist__badge--claude  { background: var(--gads-purple); color: white; }
.gads-strategist__badge--gemini  { background: var(--gads-accent); color: white; }
.gads-strategist__badge--gpt     { background: var(--gads-green); color: white; }

.gads-strategist__title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    flex: 1;
}

.gads-strategist__model-select {
    display: flex;
    gap: 4px;
}

.gads-model-btn {
    padding: 4px 10px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 600;
    border: 1px solid var(--border);
    background: transparent;
    cursor: pointer;
    transition: all var(--transition);
    color: var(--text-muted);
}

.gads-model-btn:hover { border-color: var(--border-hover); color: var(--text-primary); }

.gads-model-btn.active { color: white; border-color: transparent; }
.gads-model-btn.active[data-model*="claude"] { background: var(--gads-purple); }
.gads-model-btn.active[data-model*="gemini"] { background: var(--gads-accent); }
.gads-model-btn.active[data-model*="gpt"]    { background: var(--gads-green); }

.gads-strategist__body {
    padding: 20px;
    min-height: 100px;
    max-height: 500px;
    overflow-y: auto;
}

.gads-strategist__idle {
    text-align: center;
    padding: 30px 20px;
}

.gads-strategist__idle-text {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.6;
}

/* Chat messages */
.gads-chat-msg { margin-bottom: 12px; }

.gads-chat-msg--user .gads-chat-msg__content {
    background: var(--gads-accent);
    color: white;
    padding: 10px 14px;
    border-radius: 14px 14px 4px 14px;
    display: inline-block;
    max-width: 80%;
    font-size: 13px;
    line-height: 1.5;
    float: right;
    clear: both;
}

.gads-chat-msg--assistant { clear: both; }

.gads-chat-msg--assistant .gads-chat-msg__content {
    background: var(--bg-primary, rgba(255,255,255,0.03));
    color: var(--text-primary);
    padding: 10px 14px;
    border-radius: 14px 14px 14px 4px;
    display: inline-block;
    max-width: 85%;
    font-size: 13px;
    line-height: 1.6;
    border: 1px solid var(--border);
}

.gads-chat-msg__label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    margin-bottom: 4px;
    font-weight: 600;
}

.gads-chat-msg__label--claude { color: var(--gads-purple); }
.gads-chat-msg__label--gemini { color: var(--gads-accent); }
.gads-chat-msg__label--gpt    { color: var(--gads-green); }

/* Proposal Card */
.gads-proposal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 16px;
    margin: 12px 0;
}

.gads-proposal__title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-proposal__action {
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-primary, rgba(255,255,255,0.02));
    margin-bottom: 6px;
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.gads-proposal__impact {
    font-size: 12px;
    color: var(--gads-green);
    margin-top: 10px;
}

.gads-proposal__risk {
    font-size: 12px;
    margin-top: 4px;
}

.gads-proposal__risk--low    { color: var(--gads-green); }
.gads-proposal__risk--medium { color: var(--gads-yellow); }
.gads-proposal__risk--high   { color: var(--gads-red); }

.gads-proposal__buttons {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

/* Quick prompts */
.gads-quick-prompts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.gads-quick-prompt {
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.gads-quick-prompt:hover {
    border-color: var(--gads-accent);
    color: var(--gads-accent);
    background: var(--gads-blue-bg);
}

/* Input area */
.gads-strategist__footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-top: 1px solid var(--border);
}

.gads-chat-input {
    flex: 1;
    padding: 10px 16px;
    border-radius: 24px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.gads-chat-input:focus {
    border-color: var(--gads-accent);
    box-shadow: 0 0 0 2px oklch(0.55 0.2 260 / 0.2);
}

.gads-chat-send {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: var(--gads-accent);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.gads-chat-send:hover { opacity: 0.85; transform: scale(1.05); }
.gads-chat-send i { width: 16px; height: 16px; }


/* ═══════════════════════════════════════════════════════
   11. Status Badges
   ═══════════════════════════════════════════════════════ */

.gads-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 600;
}

.gads-status-badge--enabled { background: var(--gads-green-bg); color: var(--gads-green); }
.gads-status-badge--paused  { background: var(--gads-yellow-bg); color: var(--gads-yellow); }
.gads-status-badge--removed { background: var(--gads-red-bg); color: var(--gads-red); }

.gads-roas-badge {
    display: inline-flex;
    padding: 2px 8px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 600;
}

.gads-roas-badge--high   { background: var(--gads-green-bg); color: var(--gads-green); }
.gads-roas-badge--medium { background: var(--gads-blue-bg); color: var(--gads-accent); }
.gads-roas-badge--low    { background: var(--gads-yellow-bg); color: var(--gads-yellow); }
.gads-roas-badge--zero   { background: var(--gads-red-bg); color: var(--gads-red); }


/* ═══════════════════════════════════════════════════════
   12. Buttons
   ═══════════════════════════════════════════════════════ */

.gads-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    border: none;
    font-size: 13px;
    padding: 8px 16px;
}

.gads-btn svg { width: 14px; height: 14px; }

.gads-btn--primary { background: var(--gads-accent); color: white; }
.gads-btn--primary:hover { filter: brightness(1.1); }

.gads-btn--green { background: var(--gads-green); color: white; }
.gads-btn--green:hover { filter: brightness(1.1); }

.gads-btn--red { background: var(--gads-red); color: white; }
.gads-btn--red:hover { filter: brightness(1.1); }

.gads-btn--secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border);
}
.gads-btn--secondary:hover { border-color: var(--border-hover); }

.gads-btn--ghost { background: transparent; color: var(--gads-accent); }
.gads-btn--ghost:hover { background: var(--gads-blue-bg); }

.gads-btn--sm { padding: 5px 10px; font-size: 12px; }
.gads-btn--lg { padding: 12px 24px; font-size: 15px; }

.gads-btn--loading { pointer-events: none; opacity: 0.7; }
.gads-btn--loading::after {
    content: '';
    width: 12px; height: 12px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: gadsSpin 600ms linear infinite;
}

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


/* ═══════════════════════════════════════════════════════
   13. Tabs (for sub-pages with tabs)
   ═══════════════════════════════════════════════════════ */

.gads-tabs {
    display: flex;
    gap: 4px;
    margin: 0 0 16px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0;
}

.gads-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.gads-tab:hover { color: var(--text-primary); }

.gads-tab.active {
    color: var(--gads-accent);
    border-bottom-color: var(--gads-accent);
}

.gads-tab-content { display: none; }
.gads-tab-content.active { display: block; }


/* ═══════════════════════════════════════════════════════
   14. Skeleton Loaders
   ═══════════════════════════════════════════════════════ */

.gads-skeleton {
    background: linear-gradient(90deg, var(--bg-card) 25%, var(--border) 50%, var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: gadsSkeletonPulse 1.5s ease infinite;
    border-radius: 6px;
}

@keyframes gadsSkeletonPulse {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.gads-skeleton--text    { height: 14px; width: 60%; margin-bottom: 8px; }
.gads-skeleton--heading { height: 22px; width: 40%; margin-bottom: 14px; }
.gads-skeleton--card    { height: 100px; border-radius: var(--radius); }


/* ═══════════════════════════════════════════════════════
   15. Budget Progress Bars
   ═══════════════════════════════════════════════════════ */

.gads-budget-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.gads-budget-bar__label {
    font-size: 12px;
    color: var(--text-secondary);
    min-width: 120px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gads-budget-bar__track {
    flex: 1;
    height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
}

.gads-budget-bar__fill {
    height: 100%;
    border-radius: 4px;
    transition: width 800ms ease;
}

.gads-budget-bar__fill--ok       { background: var(--gads-green); }
.gads-budget-bar__fill--warning  { background: var(--gads-yellow); }
.gads-budget-bar__fill--critical { background: var(--gads-red); }

.gads-budget-bar__pct {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    min-width: 40px;
    text-align: right;
}


/* ═══════════════════════════════════════════════════════
   16. Sortable Tables
   ═══════════════════════════════════════════════════════ */

.gads-table-section .sortable-th {
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.gads-table-section .sortable-th:hover { color: var(--gads-accent); }

.gads-table-section .sortable-th .sort-arrow {
    display: inline-block;
    margin-left: 4px;
    font-size: 10px;
    opacity: 0.3;
}

.gads-table-section .sortable-th.sort-asc .sort-arrow,
.gads-table-section .sortable-th.sort-desc .sort-arrow {
    opacity: 1;
    color: var(--gads-accent);
}


/* ═══════════════════════════════════════════════════════
   17. Toggle Switch (Pause/Enable)
   ═══════════════════════════════════════════════════════ */

.gads-toggle {
    position: relative;
    width: 36px;
    height: 20px;
    cursor: pointer;
}

.gads-toggle input { opacity: 0; width: 0; height: 0; }

.gads-toggle__slider {
    position: absolute;
    inset: 0;
    background: var(--border);
    border-radius: 10px;
    transition: background 0.2s;
}

.gads-toggle__slider::before {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: white;
    left: 2px;
    top: 2px;
    transition: transform 0.2s;
}

.gads-toggle input:checked + .gads-toggle__slider {
    background: var(--gads-green);
}

.gads-toggle input:checked + .gads-toggle__slider::before {
    transform: translateX(16px);
}


/* ═══════════════════════════════════════════════════════
   18. Responsive
   ═══════════════════════════════════════════════════════ */

@media (max-width: 1279px) {
    .gads-sub-nav { display: none; }
    .gads-section { flex-direction: column; }

    .gads-mobile-tabs {
        display: flex;
        overflow-x: auto;
        gap: 4px;
        padding: 10px 16px;
        border-bottom: 1px solid var(--border);
        background: var(--bg-card);
    }

    .gads-mobile-tab {
        padding: 6px 14px;
        border-radius: 9999px;
        font-size: 12px;
        font-weight: 500;
        white-space: nowrap;
        cursor: pointer;
        background: transparent;
        border: none;
        color: var(--text-secondary);
        transition: all var(--transition);
    }

    .gads-mobile-tab.active {
        background: var(--gads-blue-bg);
        color: var(--gads-accent);
        font-weight: 600;
    }

    .gads-content { padding: 16px; }
    .gads-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .gads-info-grid { grid-template-columns: repeat(2, 1fr); }
    .gads-charts-grid { grid-template-columns: 1fr; }
}

@media (min-width: 1280px) {
    .gads-mobile-tabs { display: none; }
}

@media (max-width: 767px) {
    .gads-stats-grid { grid-template-columns: 1fr; }
    .gads-info-grid { grid-template-columns: 1fr; }
    .gads-health { flex-direction: column; text-align: center; }
    .gads-mobile-tabs { display: none; }
    .gads-mobile-dropdown { display: block; padding: 10px 16px; }
    .gads-mobile-dropdown select {
        width: 100%;
        padding: 8px;
        border-radius: var(--radius-sm);
        border: 1px solid var(--border);
        background: var(--bg-card);
        font-size: 13px;
        color: var(--text-primary);
    }
}

@media (min-width: 768px) {
    .gads-mobile-dropdown { display: none; }
}


/* ═══════════════════════════════════════════════════════
   19. Proposal Cards (AI Strategist)
   ═══════════════════════════════════════════════════════ */

.gads-proposal-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin: 8px 0;
    border-left: 3px solid var(--gads-accent);
}

.gads-proposal-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.gads-proposal-card__header strong {
    font-size: 14px;
    color: var(--text-primary);
}

.gads-proposal-card__actions {
    font-size: 13px;
}

.gads-proposal-card__buttons {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}


/* ═══════════════════════════════════════════════════════
   20. Report Styles
   ═══════════════════════════════════════════════════════ */

.gads-report {
    animation: gadsFadeIn 300ms ease both;
}

.gads-report h3 {
    color: var(--text-primary);
    font-weight: 600;
}

.gads-report ul li {
    color: var(--text-secondary);
}


/* ═══════════════════════════════════════════════════════
   21. Settings Tabs
   ═══════════════════════════════════════════════════════ */

.gads-settings-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    text-align: left;
    width: 100%;
    background: transparent;
    color: var(--text-muted);
    transition: all 0.15s ease;
}

.gads-settings-tab:hover {
    background: oklch(0.18 0.02 260);
    color: var(--text-primary);
}

.gads-settings-tab.active {
    background: oklch(0.22 0.02 260);
    color: white;
    font-weight: 600;
}

.gads-settings-tab i,
.gads-settings-tab svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════
   22. Bid Adjustment Badge
   ═══════════════════════════════════════════════════════ */

.gads-bid-adj-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
}

.gads-bid-adj-badge--positive {
    background: oklch(0.75 0.15 175 / 0.15);
    color: oklch(0.75 0.15 175);
}

.gads-bid-adj-badge--negative {
    background: oklch(0.65 0.2 25 / 0.15);
    color: oklch(0.65 0.2 25);
}

.gads-bid-adj-badge--neutral {
    background: oklch(0.55 0 0 / 0.15);
    color: oklch(0.55 0 0);
}


/* ═══════════════════════════════════════════════════════
   23. Search Terms Action Buttons
   ═══════════════════════════════════════════════════════ */

.gads-st-action {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.15s ease;
}

.gads-st-action--add {
    background: oklch(0.72 0.17 155 / 0.12);
    color: oklch(0.72 0.17 155);
}

.gads-st-action--add:hover {
    background: oklch(0.72 0.17 155 / 0.25);
}

.gads-st-action--neg {
    background: oklch(0.65 0.2 25 / 0.12);
    color: oklch(0.65 0.2 25);
}

.gads-st-action--neg:hover {
    background: oklch(0.65 0.2 25 / 0.25);
}


/* ═══════════════════════════════════════════════════════
   24. Recommendations Page
   ═══════════════════════════════════════════════════════ */

.gads-opt-score-container {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 20px;
}

.gads-opt-score-gauge {
    position: relative;
    width: 160px;
    height: 100px;
    flex-shrink: 0;
}

.gads-rec-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 8px;
    background: oklch(0.14 0.02 260);
    transition: all 0.15s ease;
    margin-bottom: 6px;
}

.gads-rec-item:hover {
    background: oklch(0.18 0.02 260);
}

.gads-rec-item__icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.gads-rec-item__content {
    flex: 1;
    min-width: 0;
}

.gads-rec-item__title {
    font-size: 12px;
    font-weight: 600;
    color: oklch(0.9 0.02 260);
    margin-bottom: 2px;
}

.gads-rec-item__desc {
    font-size: 10px;
    color: oklch(0.5 0.02 260);
    line-height: 1.4;
}

.gads-rec-item__actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    margin-left: auto;
}

.gads-rec-btn {
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.15s ease;
}

.gads-rec-btn--apply {
    background: oklch(0.72 0.17 155);
    color: white;
}

.gads-rec-btn--apply:hover {
    background: oklch(0.65 0.17 155);
}

.gads-rec-btn--dismiss {
    background: transparent;
    color: oklch(0.5 0.02 260);
    border: 1px solid oklch(0.3 0.02 260);
}

.gads-rec-btn--dismiss:hover {
    background: oklch(0.2 0.02 260);
}


/* ═══════════════════════════════════════════════════════
   25. Auction Insights
   ═══════════════════════════════════════════════════════ */

.gads-impr-bar-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.gads-impr-bar-label {
    width: 120px;
    font-size: 11px;
    font-weight: 500;
    color: oklch(0.8 0.02 260);
    text-align: right;
    flex-shrink: 0;
}

.gads-impr-bar-track {
    flex: 1;
    height: 24px;
    background: oklch(0.15 0.02 260);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.gads-impr-bar-fill {
    height: 100%;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 8px;
    font-size: 9px;
    font-weight: 700;
    color: white;
    font-family: 'JetBrains Mono', monospace;
    transition: width 0.8s ease;
}

.gads-impr-bar-row--highlight .gads-impr-bar-label {
    font-weight: 700;
    color: oklch(0.72 0.17 178);
}


/* ═══════════════════════════════════════════════════════
   26. Extensions Tabs
   ═══════════════════════════════════════════════════════ */

.gads-ext-tabs {
    display: flex;
    gap: 2px;
    overflow-x: auto;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0;
}

.gads-ext-tab {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    border: none;
    background: transparent;
    border-bottom: 2px solid transparent;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.gads-ext-tab:hover {
    color: var(--text-primary);
}

.gads-ext-tab.active {
    color: var(--m-blue);
    border-bottom-color: var(--m-blue);
    font-weight: 600;
}

.gads-ext-tab i,
.gads-ext-tab svg {
    width: 14px;
    height: 14px;
}


/* ═══════════════════════════════════════════════════════
   LIGHT THEME OVERRIDES
   Fixes all hardcoded dark oklch values for light mode
   ═══════════════════════════════════════════════════════ */

:root[data-theme="light"] .gads-section {
    --m-teal:    #0d9488;
    --m-blue:    #3b64d9;
    --m-deep:    #2a50c0;
    --m-amber:   #d97706;
    --m-coral:   #dc2626;
    --m-purple:  #7c3aed;
    --m-green:   #059669;
    --m-gray:    #6b7280;

    /* Theme-aware inline style tokens — LIGHT */
    --gads-thead-bg:      #f1f3f8;
    --gads-bar-track:     #e2e5ed;
    --gads-bar-track-alt: #e8eaf0;
    --gads-btn-active-bg: #e8ecf5;
    --gads-item-bg:       #f4f6fb;
    --gads-inactive-text: #5c6280;
    --gads-border-subtle: rgba(0, 0, 0, 0.08);
    --gads-legend-text:   #5c6280;
    --gads-pill-bg:       #f4f6fb;
}

/* Table headers — remove dark backgrounds */
:root[data-theme="light"] .gads-section thead,
:root[data-theme="light"] .gads-section .gads-sortable-th {
    background: #f8f9fc !important;
    color: #5c6280 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

:root[data-theme="light"] .gads-section .gads-camp-row {
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

:root[data-theme="light"] .gads-section .gads-camp-row:hover {
    background: rgba(59, 100, 217, 0.03);
}

/* Filter inputs & selects */
:root[data-theme="light"] .gads-section .gads-filter-input,
:root[data-theme="light"] .gads-section .gads-filter-select,
:root[data-theme="light"] .gads-section select {
    background: #ffffff !important;
    color: #1a1f36 !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
}

:root[data-theme="light"] .gads-section .gads-filter-input::placeholder {
    color: #9ca0b8 !important;
}

/* Health gauge & progress bars backgrounds */
:root[data-theme="light"] .gads-section .gads-health-gauge circle[opacity] {
    stroke: rgba(0, 0, 0, 0.08) !important;
}

/* Metric switch (Spend/Clicks/Conversions buttons) */
:root[data-theme="light"] .gads-metric-switch {
    background: rgba(0, 0, 0, 0.04) !important;
}

:root[data-theme="light"] .gads-metric-switch button.active {
    background: #ffffff !important;
    color: #1a1f36 !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Status badges */
:root[data-theme="light"] .gads-status-badge--enabled {
    background: rgba(5, 150, 105, 0.08) !important;
    color: #059669 !important;
}

:root[data-theme="light"] .gads-status-badge--paused {
    background: rgba(217, 119, 6, 0.08) !important;
    color: #d97706 !important;
}

/* ROAS badges */
:root[data-theme="light"] .gads-roas-badge--high {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
}

:root[data-theme="light"] .gads-roas-badge--medium {
    background: rgba(59, 100, 217, 0.1);
    color: #3b64d9;
}

:root[data-theme="light"] .gads-roas-badge--low {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
}

/* Section card hover */
:root[data-theme="light"] .gads-section-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

/* Metric card hover */
:root[data-theme="light"] .gads-metric-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

/* Hero badge */
:root[data-theme="light"] .gads-hero-badge {
    background: rgba(255, 255, 255, 0.2);
}

/* Date pills */
:root[data-theme="light"] .gads-date-pill {
    color: #5c6280 !important;
}

:root[data-theme="light"] .gads-date-pill.active {
    background: #3b64d9 !important;
    color: #ffffff !important;
}

/* Quick stat rows */
:root[data-theme="light"] .gads-quick-stat {
    border-bottom-color: rgba(0, 0, 0, 0.04);
}

/* Alert items */
:root[data-theme="light"] .gads-alert-item {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.04);
}

/* Campaign row borders */
:root[data-theme="light"] .gads-campaign-row {
    border-bottom-color: rgba(0, 0, 0, 0.04);
}

/* Sub-navigation */
:root[data-theme="light"] .gads-sub-nav {
    border-right-color: rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.5);
}

:root[data-theme="light"] .gads-nav-item:hover,
:root[data-theme="light"] .gads-nav-group__label:hover {
    background: rgba(0, 0, 0, 0.03);
}

:root[data-theme="light"] .gads-nav-item.active {
    background: rgba(59, 100, 217, 0.08);
    color: #3b64d9;
}

/* Heatmap cells — these use oklch in JS, override with CSS */
:root[data-theme="light"] .gads-section .gads-heatmap-metric-btn {
    color: #5c6280 !important;
}

:root[data-theme="light"] .gads-section .gads-heatmap-metric-btn.active {
    background: #e8ecf5 !important;
    color: #1a1f36 !important;
}

/* Settings tabs */
:root[data-theme="light"] .gads-settings-tab {
    color: #5c6280 !important;
}

:root[data-theme="light"] .gads-settings-tab.active {
    background: rgba(59, 100, 217, 0.08) !important;
    color: #3b64d9 !important;
}

/* Asset tabs */
:root[data-theme="light"] .gads-asset-tab {
    color: #5c6280 !important;
}

:root[data-theme="light"] .gads-asset-tab.active {
    color: #3b64d9 !important;
}

/* Report template cards */
:root[data-theme="light"] .gads-report-template:hover {
    border-color: rgba(59, 100, 217, 0.3);
}

/* Mobile tabs */
:root[data-theme="light"] .gads-mobile-tab {
    color: #5c6280;
}

:root[data-theme="light"] .gads-mobile-tab.active {
    color: #3b64d9;
    border-bottom-color: #3b64d9;
}

/* View all links */
:root[data-theme="light"] .gads-view-all {
    color: #3b64d9;
}

/* Chat message styles */
:root[data-theme="light"] .gads-chat-msg--user .gads-chat-msg__content {
    background: rgba(59, 100, 217, 0.08);
    color: #1a1f36;
}

:root[data-theme="light"] .gads-chat-msg--assistant .gads-chat-msg__content {
    background: rgba(0, 0, 0, 0.03);
    color: #1a1f36;
}

/* Proposal card */
:root[data-theme="light"] .gads-proposal-card {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.08);
}

/* Buttons */
:root[data-theme="light"] .gads-btn--primary {
    background: #3b64d9;
    color: #ffffff;
}

:root[data-theme="light"] .gads-btn--ghost {
    color: #5c6280;
    border-color: rgba(0, 0, 0, 0.1);
}

/* Model buttons */
:root[data-theme="light"] .gads-model-btn {
    background: rgba(0, 0, 0, 0.04);
    color: #5c6280;
    border-color: rgba(0, 0, 0, 0.08);
}

:root[data-theme="light"] .gads-model-btn.active {
    background: #3b64d9;
    color: #ffffff;
    border-color: #3b64d9;
}

/* Quick prompts */
:root[data-theme="light"] .gads-quick-prompt {
    background: rgba(0, 0, 0, 0.03);
    color: #5c6280;
    border-color: rgba(0, 0, 0, 0.06);
}

:root[data-theme="light"] .gads-quick-prompt:hover {
    background: rgba(59, 100, 217, 0.06);
    color: #3b64d9;
}

/* ═══════════════════════════════════════════════════════
   M14. Global Toolbar (Date Range + Campaign Filter)
   ═══════════════════════════════════════════════════════ */

.gads-global-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    margin-bottom: 16px;
    background: var(--bg-card, oklch(0.15 0.02 260));
    border: 1px solid var(--border, oklch(0.25 0.02 260));
    border-radius: 10px;
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(12px);
}

.gads-global-toolbar__left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.gads-global-toolbar__group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gads-global-select {
    appearance: none;
    -webkit-appearance: none;
    background: var(--gads-pill-bg, oklch(0.18 0.02 260));
    color: var(--text-primary, white);
    border: 1px solid var(--border, oklch(0.25 0.02 260));
    border-radius: 8px;
    padding: 6px 28px 6px 10px;
    font-size: 12px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239ca0b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    transition: border-color 0.2s, background 0.2s;
}

.gads-global-select:hover {
    border-color: var(--m-blue, oklch(0.65 0.18 250));
}

.gads-global-select:focus {
    outline: none;
    border-color: var(--m-blue, oklch(0.65 0.18 250));
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.15);
}

.gads-global-date-input {
    background: var(--gads-pill-bg, oklch(0.18 0.02 260));
    color: var(--text-primary, white);
    border: 1px solid var(--border, oklch(0.25 0.02 260));
    border-radius: 6px;
    padding: 5px 8px;
    font-size: 11px;
    font-family: 'JetBrains Mono', monospace;
    cursor: pointer;
}

.gads-global-date-input:focus {
    outline: none;
    border-color: var(--m-blue, oklch(0.65 0.18 250));
}

.gads-global-apply-btn {
    background: var(--m-blue, oklch(0.65 0.18 250));
    color: white;
    border: none;
    border-radius: 6px;
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.gads-global-apply-btn:hover {
    opacity: 0.85;
}

/* Light theme */
:root[data-theme="light"] .gads-global-toolbar {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 0, 0, 0.08);
}

:root[data-theme="light"] .gads-global-select {
    background: rgba(0, 0, 0, 0.03);
    color: #1a1f36;
    border-color: rgba(0, 0, 0, 0.1);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235c6280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
}

:root[data-theme="light"] .gads-global-date-input {
    background: rgba(0, 0, 0, 0.03);
    color: #1a1f36;
    border-color: rgba(0, 0, 0, 0.1);
}

/* Filter select styling (reusable) */
.gads-filter-select {
    appearance: none;
    -webkit-appearance: none;
    background: var(--gads-pill-bg, oklch(0.18 0.02 260));
    color: var(--text-primary, white);
    border: 1px solid var(--border, oklch(0.25 0.02 260));
    border-radius: 8px;
    padding: 6px 28px 6px 10px;
    font-size: 12px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239ca0b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
}

.gads-filter-select:hover {
    border-color: var(--m-blue, oklch(0.65 0.18 250));
}

.gads-filter-select:focus {
    outline: none;
    border-color: var(--m-blue, oklch(0.65 0.18 250));
}

:root[data-theme="light"] .gads-filter-select {
    background: rgba(0, 0, 0, 0.03);
    color: #1a1f36;
    border-color: rgba(0, 0, 0, 0.1);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235c6280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
}
