/*
Theme Name: AAnu Leads Dashboard
Theme URI: https://bold-pixel.com
Author: BOLD PIXEL
Description: Central dashboard theme for syncing and managing leads across AAnu websites.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: Proprietary
Text Domain: aanu-dashboard
*/

:root {
    --bg: #0f172a;
    --card: #111827;
    --card-2: #1f2937;
    --text: #e5e7eb;
    --muted: #9ca3af;
    --accent: #22c55e;
    --accent-2: #3b82f6;
    --danger: #ef4444;
    --border: #374151;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    background: linear-gradient(180deg, #020617 0%, #0f172a 100%);
    color: var(--text);
}

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

.ah-wrap {
    max-width: 1320px;
    margin: 0 auto;
    padding: 26px 18px 36px;
}

.ah-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.ah-title {
    font-size: 30px;
    font-weight: 700;
    letter-spacing: 0.2px;
}

.ah-sub {
    color: var(--muted);
    font-size: 14px;
}

.ah-tabs {
    margin-top: 12px;
}

.ah-tab-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 4px 0 14px;
}

.ah-tab-btn {
    border: 1px solid #334155;
    border-radius: 999px;
    background: #0b1220;
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 10px;
    cursor: pointer;
}

.ah-tab-btn.is-active {
    background: #1e3a8a;
    border-color: #1d4ed8;
    color: #eff6ff;
}

.ah-tab-panel {
    display: none;
}

.ah-tab-panel.is-active {
    display: block;
}

.ah-section-title {
    margin: 0 0 8px;
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #bfdbfe;
}

.ah-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}

.ah-card {
    background: rgba(17, 24, 39, 0.8);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px;
}

.ah-kpi-label {
    color: var(--muted);
    font-size: 12px;
}

.ah-kpi-value {
    margin-top: 8px;
    font-size: 28px;
    font-weight: 700;
}

.ah-panel {
    background: rgba(17, 24, 39, 0.8);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 16px;
    margin-top: 12px;
}

.ah-panel h3 {
    margin: 0 0 12px;
    font-size: 17px;
}

.ah-subpanel {
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid #273449;
    border-radius: 12px;
    padding: 12px;
    margin-top: 10px;
}

.ah-notice {
    margin-top: 6px;
}

.ah-notice.is-success {
    border-color: #14532d;
}

.ah-notice.is-error {
    border-color: #7f1d1d;
}

.ah-table-wrap {
    overflow-x: auto;
    border: 1px solid #243041;
    border-radius: 10px;
}

.ah-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.ah-table th,
.ah-table td {
    border-bottom: 1px solid #243041;
    padding: 10px 8px;
    text-align: left;
    vertical-align: top;
    white-space: nowrap;
}

.ah-table th {
    color: #cbd5e1;
    font-weight: 600;
    background: rgba(31, 41, 55, 0.7);
}

.ah-badge {
    display: inline-flex;
    border-radius: 999px;
    border: 1px solid #334155;
    padding: 2px 8px;
    font-size: 11px;
    color: #cbd5e1;
}

.ah-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.ah-btn {
    border: 1px solid #334155;
    background: #1e293b;
    color: #e2e8f0;
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 12px;
    cursor: pointer;
}

.ah-btn-primary {
    background: #14532d;
    border-color: #166534;
}

.ah-btn-secondary {
    background: #1e3a8a;
    border-color: #1d4ed8;
}

.ah-inline-form {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.ah-inline-form input,
.ah-inline-form select {
    background: #0b1220;
    color: #e5e7eb;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 8px;
    font-size: 13px;
}

.ah-inline-form input[type="text"],
.ah-inline-form input[type="email"],
.ah-inline-form input[type="url"],
.ah-inline-form select {
    min-width: 200px;
}

.ah-note {
    font-size: 12px;
    color: #93c5fd;
}

.ah-empty {
    color: var(--muted);
    font-size: 13px;
    padding: 10px 0;
}

.ah-code {
    display: inline-block;
    background: #0b1220;
    border: 1px solid #334155;
    border-radius: 6px;
    padding: 4px 7px;
    color: #cbd5e1;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 12px;
    word-break: break-all;
}

@media (max-width: 960px) {
    .ah-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ah-wrap {
        padding: 20px 14px 28px;
    }
}

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

    .ah-topbar {
        flex-direction: column;
        align-items: flex-start;
    }
}
