/* ═══════════════════════════════════════════════════════════════════
   JoyA — Premium Theme (Celestial Observatory)
   ═══════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════════
   PREMIUM THEME — Celestial Observatory
   ═══════════════════════════════════════════════════════════════════ */

[data-theme="premium"] {
    --bg-primary: #06090f;
    --bg-secondary: #0c1018;
    --bg-card: rgba(14, 18, 30, 0.65);
    --bg-card-hover: rgba(20, 25, 40, 0.7);
    --bg-input: rgba(18, 22, 36, 0.8);

    --border: rgba(200, 169, 126, 0.08);
    --border-focus: rgba(200, 169, 126, 0.35);

    --text-primary: #ede9e3;
    --text-secondary: #8a8693;
    --text-muted: #55516a;

    --accent: #c8a97e;
    --accent-dim: rgba(200, 169, 126, 0.10);
    --accent-glow: rgba(200, 169, 126, 0.20);

    --success: #5b8a72;
    --warning: #bd914d;
    --danger: #b35454;
    --info: #5c7b9e;

    --radius: 16px;
    --radius-sm: 10px;

    --font-heading: 'Cormorant Garamond', 'Georgia', serif;
    --heading-weight: 600;

    --card-blur: 16px;
    --card-border: rgba(200, 169, 126, 0.06);

    /* ── Planet Inline Colors (premium palette: warmer, muted) ── */
    --planet-sun: #D4A855;
    --planet-moon: #A8B8C8;
    --planet-mars: #C47070;
    --planet-mercury: #6DAA9E;
    --planet-jupiter: #B5A07A;
    --planet-venus: #C090A8;
    --planet-saturn: #7888B5;
    --planet-rahu: #6A6A78;
    --planet-ketu: #6A6A78;
    --planet-karmic: #9A88C0;
    --planet-maasesha: #5BAAC8;
    --planet-mudda: #A05BC8;

    /* ── Badge Colors (premium: softer, harmonized) ── */
    --badge-exalted: #6dd4a0;
    --badge-exalted-border: #6dd4a0;
    --badge-own: #8aaed4;
    --badge-moolat: #8aaed4;
    --badge-debil: #d48a8a;
    --badge-debil-border: #d48a8a;
    --badge-friendly: #7cc8a8;
    --badge-friendly-border: #6dd4a0;
    --badge-great-friend: #6dd4a0;
    --badge-great-friend-border: #6dd4a0;
    --badge-enemy: #d48a8a;
    --badge-enemy-border: #d48a8a;
    --badge-great-enemy: #d48a8a;
    --badge-great-enemy-border: #d48a8a;
    --badge-retro: #d4b06d;
    --badge-combust: #d4b06d;

    /* ── Functional Status (premium) ── */
    --color-pushkara: #a99cd4;
    --color-vargottama: #a99cd4;
    --color-gandanta: #d4b06d;
    --color-digbala: #c8a97e;
    --color-mrityu: #d48a8a;

    /* ── Extended Accent / Semantic (premium) ── */
    --accent-light: #d4b88e;
    --warning-alt: #d4a855;
    --color-purple: #9aa0d4;
    --color-purple-soft: #b8a8d4;
    --danger-soft: #d48a8a;
    --text-on-accent: #06090f;

    /* ── Shadows (premium: deeper) ── */
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.55);
    --shadow-glow-accent: 0 0 20px var(--accent-glow);
}

/* ── Premium: Background ───────────────────────────────────────── */

[data-theme="premium"] body {
    background: #06090f;
    background-image:
        radial-gradient(ellipse 80% 50% at 20% -10%, rgba(139, 126, 200, 0.07) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 80% 110%, rgba(200, 169, 126, 0.05) 0%, transparent 60%),
        radial-gradient(ellipse 40% 30% at 50% 50%, rgba(100, 80, 160, 0.03) 0%, transparent 70%);
}

/* ── Premium: Header ───────────────────────────────────────────── */

[data-theme="premium"] .header {
    background: rgba(6, 9, 15, 0.8);
    border-bottom: 1px solid rgba(200, 169, 126, 0.06);
}

[data-theme="premium"] .header__logo .header__title {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    background: linear-gradient(135deg, #c8a97e, #e8d5b8, #c8a97e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="premium"] .header__tagline {
    color: #6a6578;
    letter-spacing: 0.15em;
    font-size: 0.7rem;
}

/* ── Premium: Cards (Glassmorphism) ─────────────────────────────── */

[data-theme="premium"] .card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--card-blur));
    -webkit-backdrop-filter: blur(var(--card-blur));
    border: 1px solid var(--card-border);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

[data-theme="premium"] .card:hover {
    border-color: rgba(200, 169, 126, 0.1);
}

/* ── Premium: Headings ──────────────────────────────────────────── */

[data-theme="premium"] .card__title {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.3rem;
    letter-spacing: 0.03em;
    color: #c8a97e;
}

[data-theme="premium"] .section__title {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.1rem;
    letter-spacing: 0.03em;
}

[data-theme="premium"] .chart-title {
    font-family: var(--font-heading);
    color: #E8E6E3;
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}
[data-theme="premium"] .chart-title span {
    font-size: 0.95em;
    font-weight: 500;
}

/* ── Premium: Form ──────────────────────────────────────────────── */

[data-theme="premium"] input,
[data-theme="premium"] select {
    background: var(--bg-input);
    backdrop-filter: blur(8px);
    border-color: rgba(200, 169, 126, 0.06);
    border-radius: var(--radius-sm);
}

[data-theme="premium"] input:focus,
[data-theme="premium"] select:focus {
    border-color: rgba(200, 169, 126, 0.25);
    box-shadow: 0 0 0 3px rgba(200, 169, 126, 0.06);
}

[data-theme="premium"] label {
    color: #7a7488;
    font-size: 0.68rem;
    letter-spacing: 0.12em;
}

/* ── Premium: Buttons ───────────────────────────────────────────── */

[data-theme="premium"] .btn--primary {
    background: linear-gradient(135deg, #c8a97e, #a88b5e);
    color: #0a0a0f;
    font-weight: 600;
    box-shadow: 0 2px 12px rgba(200, 169, 126, 0.15);
    border: none;
}

[data-theme="premium"] .btn--primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #d4b88e, #c8a97e);
    box-shadow: 0 4px 20px rgba(200, 169, 126, 0.25);
    transform: translateY(-1px);
}

[data-theme="premium"] .btn--secondary {
    border-color: rgba(200, 169, 126, 0.12);
    color: #8a8693;
}

[data-theme="premium"] .btn--secondary:hover:not(:disabled) {
    border-color: rgba(200, 169, 126, 0.25);
    background: rgba(200, 169, 126, 0.05);
    color: #c8a97e;
}

/* ── Premium: Tables ────────────────────────────────────────────── */

[data-theme="premium"] .table th {
    color: #c8a97e;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    border-bottom: 1px solid rgba(200, 169, 126, 0.15);
    background: rgba(14, 18, 30, 0.85);
    box-shadow: 0 4px 6px -4px rgba(0, 0, 0, 0.4);
}

[data-theme="premium"] .table td {
    padding: 0.7rem 0.65rem;
    border-bottom-color: rgba(200, 169, 126, 0.04);
}

[data-theme="premium"] .table tbody tr:hover {
    background: rgba(200, 169, 126, 0.03);
}

/* ── Premium: Badges ────────────────────────────────────────────── */

[data-theme="premium"] .badge {
    border-radius: 20px;
    font-size: 0.62rem;
    padding: 0.2rem 0.6rem;
    letter-spacing: 0.02em;
}

[data-theme="premium"] .badge--exalted {
    background: rgba(109, 212, 160, 0.10);
    color: #6dd4a0;
}

[data-theme="premium"] .badge--debil {
    background: rgba(212, 138, 138, 0.10);
    color: #d48a8a;
}

[data-theme="premium"] .badge--own {
    background: rgba(138, 174, 212, 0.10);
    color: #8aaed4;
}

[data-theme="premium"] .badge--moolat {
    background: rgba(138, 174, 212, 0.08);
    color: #8aaed4;
}

[data-theme="premium"] .badge--combust {
    background: rgba(212, 176, 109, 0.10);
    color: #d4b06d;
}

[data-theme="premium"] .badge--mks {
    background: rgba(212, 138, 138, 0.10);
    color: #d48a8a;
}

[data-theme="premium"] .badge--pushkara {
    background: rgba(139, 126, 200, 0.10);
    color: #a99cd4;
}

[data-theme="premium"] .badge--vargottama {
    background: rgba(139, 126, 200, 0.10);
    color: #a99cd4;
}

[data-theme="premium"] .badge--gandanta {
    background: rgba(212, 176, 109, 0.10);
    color: #d4b06d;
}

[data-theme="premium"] .badge--abhijit {
    background: rgba(126, 170, 200, 0.10);
    color: #8ec4e0;
}

[data-theme="premium"] .badge--yuddha {
    background: rgba(212, 138, 138, 0.10);
    color: #d48a8a;
}

[data-theme="premium"] .badge--digbala {
    background: rgba(200, 169, 126, 0.10);
    color: #c8a97e;
}

[data-theme="premium"] .badge--yogakaraka {
    background: linear-gradient(135deg, rgba(139, 126, 200, 0.15), rgba(200, 169, 126, 0.15));
    color: #c8b8e0;
}

/* ── Premium: South Indian Chart ────────────────────────────────── */

[data-theme="premium"] .si-grid {
    border-color: rgba(200, 169, 126, 0.1);
}

[data-theme="premium"] .si-cell {
    border-color: rgba(200, 169, 126, 0.06);
}

[data-theme="premium"] .si-cell--lagna {
    background: rgba(200, 169, 126, 0.04);
}

/* ── Premium: Shadbala & SAV ────────────────────────────────────── */

[data-theme="premium"] .shadbala-planet {
    background: rgba(14, 18, 30, 0.5);
    border-color: rgba(200, 169, 126, 0.06);
}

[data-theme="premium"] .sav-col {
    background: rgba(200, 169, 126, 0.06);
}

/* ── Premium: Dasha ─────────────────────────────────────────────── */

[data-theme="premium"] .dasha-current {
    border-color: rgba(200, 169, 126, 0.1);
    background: rgba(200, 169, 126, 0.03);
}

/* ── Premium: Varga tabs ────────────────────────────────────────── */

[data-theme="premium"] .vargas-tab {
    border-color: rgba(200, 169, 126, 0.08);
}

[data-theme="premium"] .vargas-tab.active,
[data-theme="premium"] .vargas-tab:hover {
    border-color: rgba(200, 169, 126, 0.3);
    color: #c8a97e;
    background: rgba(200, 169, 126, 0.06);
}

/* ── Premium: Report ────────────────────────────────────────────── */

[data-theme="premium"] .report-summary {
    border-left-color: #c8a97e;
    background: rgba(200, 169, 126, 0.03);
}

[data-theme="premium"] .report-section__title {
    font-family: var(--font-heading);
    color: #c8a97e;
}

[data-theme="premium"] .report-chip {
    background: rgba(200, 169, 126, 0.08);
    color: #a99cd4;
}

/* ── Premium: Stream Progress ───────────────────────────────────── */

[data-theme="premium"] .stream-progress {
    background: rgba(14, 18, 30, 0.5);
    border-color: rgba(200, 169, 126, 0.06);
}

[data-theme="premium"] .stream-step--active {
    background: rgba(200, 169, 126, 0.05);
}

/* ── Premium: Footer ────────────────────────────────────────────── */

[data-theme="premium"] .footer {
    border-top: 1px solid rgba(200, 169, 126, 0.06);
}

/* ── Premium: Scrollbar ─────────────────────────────────────────── */

[data-theme="premium"] ::-webkit-scrollbar-thumb {
    background: rgba(200, 169, 126, 0.15);
}

[data-theme="premium"] ::-webkit-scrollbar-thumb:hover {
    background: rgba(200, 169, 126, 0.25);
}

/* ── Premium: Lagna row ─────────────────────────────────────────── */

[data-theme="premium"] .lagna-row td {
    border-bottom-color: rgba(200, 169, 126, 0.12) !important;
}

/* ── Premium: Planet Popup ──────────────────────────────────────── */
[data-theme="premium"] .planet-popup {
    background: rgba(20, 18, 35, 0.92);
    backdrop-filter: blur(24px);
    border-color: rgba(200, 169, 126, 0.15);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7), 0 0 40px rgba(200, 169, 126, 0.05);
}

[data-theme="premium"] .planet-popup__header {
    font-family: var(--font-heading);
    color: var(--accent);
}

[data-theme="premium"] .planet-popup__source {
    border-top-color: rgba(200, 169, 126, 0.1);
}

[data-theme="premium"] .planet-popup-overlay {
    background: rgba(10, 8, 24, 0.65);
}


/* ── Premium Checkout Modal ─────────────────────────────────────── */
.modal--premium {
    max-width: 800px;
    padding: 0;
    background: #111116;
    border: 1px solid rgba(200, 169, 126, 0.2);
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    overflow: hidden;
}

#premium-phase-generating,
#premium-phase-done,
#compat-prem-phase-generating,
#compat-prem-phase-done {
    padding: 2.5rem;
}
.premium-checkout__header {
    background: #1a1a24;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    
    color: var(--text-muted);
}
.premium-checkout__title {
    font-size: 0.9rem;
    color: var(--accent);
}
.premium-checkout__log {
    padding: 1.5rem;
    background: rgba(0,0,0,0.3);
    
    color: #c4bbae;
    font-size: 0.9rem;
    line-height: 1.5;
    border-bottom: 1px dashed rgba(200, 169, 126, 0.2);
}
.premium-checkout__log-prefix {
    color: var(--accent);
    font-weight: bold;
}
.premium-checkout__body {
    padding: 1.5rem;
    max-height: 45vh;
    overflow-y: auto;
}
.premium-checkout__subtitle {
    font-size: 0.85rem;
    font-weight: bold;
    color: #a0a0b0;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
}
.premium-checkout__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
.premium-checkout__cluster {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}
.cluster__title {
    font-size: 0.95rem;
    color: #d2c8bc;
    font-weight: 600;
}
.cluster__desc {
    font-size: 0.85rem;
    color: #d2c8bc;
    padding-left: 1.5rem;
}
.premium-checkout__footer {
    padding: 1.5rem;
    background: #1a1a24;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    gap: 1rem;
}
.premium-checkout__time {
    font-size: 0.85rem;
    color: #c4bbae;
    line-height: 1.4;
    flex: 1;
}
.premium-checkout__action-box {
    background: rgba(0,0,0,0.2);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(200, 169, 126, 0.1);
    min-width: 280px;
    text-align: center;
}
.action-box__price {
    font-size: 0.9rem;
    color: #d2c8bc;
}
.action-box__price span {
    font-size: 1.2rem;
    color: #c4bbae;
    font-weight: bold;
    margin-left: 0.5rem;
}
.action-box__secure {
    font-size: 0.75rem;
    color: #d2c8bc;
    margin-top: 0.8rem;
}

@media (max-width: 768px) {
    .premium-checkout__grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .premium-checkout__footer {
        flex-direction: column;
        text-align: center;
    }
}

.premium-checkout__grid--list {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
}
.cluster__list {
    margin: 0.5rem 0 0 0;
    padding-left: 1.5rem;
    list-style-type: none;
}
.cluster__list li {
    font-size: 0.85rem;
    color: #d2c8bc;
    position: relative;
    margin-bottom: 0.4rem;
    line-height: 1.4;
}
.cluster__list li::before {
    content: '✦';
    position: absolute;
    left: -1.2rem;
    color: var(--accent);
    font-size: 0.8rem;
}

.cluster__list li strong {
    color: var(--accent);
    font-weight: 600;
}

/* ── Premium: Focus Selector ────────────────────────────────────── */
.premium-checkout__focus {
    padding: 1.2rem 1.5rem;
    background: rgba(14, 18, 30, 0.4);
    border-bottom: 1px dashed rgba(200, 169, 126, 0.15);
}
.focus__label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: bold;
}
.focus__controls {
    display: flex;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.3rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.03);
    overflow-x: auto;
}
.focus__controls::-webkit-scrollbar {
    display: none;
}
.focus__option {
    flex: 1;
    position: relative;
    cursor: pointer;
    min-width: fit-content;
}
.focus__option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.focus__text {
    display: block;
    text-align: center;
    padding: 0.5rem 0.8rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
}
.focus__option input:checked + .focus__text {
    background: rgba(200, 169, 126, 0.12);
    color: var(--accent);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.05);
    font-weight: 600;
}
.focus__option:hover input:not(:checked) + .focus__text {
    background: rgba(255, 255, 255, 0.03);
    color: #e0dcd5;
}
.focus__description {
    margin-top: 0.8rem;
    font-size: 0.8rem;
    color: #a0a0b0;
    line-height: 1.4;
    transition: opacity 0.2s ease-in-out;
}

/* Premium Concierge Banner */
.premium-concierge-banner {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 1rem;
    background: linear-gradient(145deg, rgba(200, 169, 126, 0.05) 0%, rgba(14, 18, 30, 0.4) 100%);
    border: 1px solid rgba(200, 169, 126, 0.15);
    border-radius: 8px;
    position: relative;
    overflow: hidden;
}

.premium-concierge-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, var(--accent), transparent);
    box-shadow: 0 0 10px var(--accent-glow);
}

.pcb-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    box-shadow: inset 0 0 8px rgba(200, 169, 126, 0.05);
}

.pcb-content {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.pcb-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.pcb-desc {
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin: 0;
}
