:root {
    --bg-dark: #0a0b1e;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-glass: rgba(255, 255, 255, 0.05);
    --border-glass: rgba(255, 255, 255, 0.1);

    --accent-gold: #d4af37;
    --accent-gold-bright: #f4d03f;
    --accent-indigo: #6366f1;
    --accent-purple: #a855f7;
    --accent-rose: #ec4899;

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --font-main: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-serif: 'Playfair Display', serif;

    --shadow-premium: 0 8px 32px 0 rgba(0, 0, 0, 0.8);
    --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.2);
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

.dark-theme {
    background: radial-gradient(ellipse at 30% 20%, #161a3d 0%, #0a0b1e 70%);
}

/* ═══ BACKGROUND ═══ */
.background-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.12;
    animation: float 20s infinite alternate ease-in-out;
}

.orb-1 {
    width: 50vw;
    height: 50vw;
    background: var(--accent-indigo);
    top: -15%;
    left: -15%;
}

.orb-2 {
    width: 40vw;
    height: 40vw;
    background: var(--accent-purple);
    bottom: -15%;
    right: -15%;
    animation-delay: -7s;
}

.orb-3 {
    width: 35vw;
    height: 35vw;
    background: var(--accent-gold);
    top: 25%;
    left: 35%;
    animation-delay: -12s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(8%, 6%) scale(1.08);
    }
}

/* Stars */
.stars {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(1px 1px at 20% 30%, rgba(255, 255, 255, 0.3) 0%, transparent 100%),
        radial-gradient(1px 1px at 40% 70%, rgba(255, 255, 255, 0.2) 0%, transparent 100%),
        radial-gradient(1px 1px at 60% 15%, rgba(255, 255, 255, 0.25) 0%, transparent 100%),
        radial-gradient(1px 1px at 80% 55%, rgba(255, 255, 255, 0.15) 0%, transparent 100%),
        radial-gradient(1px 1px at 10% 80%, rgba(255, 255, 255, 0.2) 0%, transparent 100%),
        radial-gradient(1px 1px at 70% 90%, rgba(255, 255, 255, 0.18) 0%, transparent 100%);
    background-size: 250px 250px;
    animation: starsTwinkle 8s ease-in-out infinite alternate;
}

@keyframes starsTwinkle {
    0% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

/* ═══ TYPOGRAPHY ═══ */
h1,
h2,
h3,
h4 {
    font-family: var(--font-serif);
    font-weight: 700;
}

.eyebrow {
    font-family: var(--font-main);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-size: 0.75rem;
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
    display: block;
}

/* ═══ LAYOUT ═══ */
header {
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo h1 {
    font-size: 1.5rem;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-gold));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.symbol {
    font-size: 2rem;
    color: var(--accent-gold);
    animation: pulse 4s infinite ease-in-out;
}

.current-status {
    font-size: 0.8rem;
    color: var(--text-secondary);
    background: var(--bg-glass);
    padding: 0.4rem 1rem;
    border-radius: 99px;
    border: 1px solid var(--border-glass);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    backdrop-filter: blur(8px);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem 2rem;
}

section {
    margin-bottom: 3rem;
}

/* ═══ GLASS CARD ═══ */
.glass {
    background: var(--bg-glass);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-premium);
}

/* ═══ HERO CARD ═══ */
.main-card {
    padding: 3rem;
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 2rem;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.card-header h2 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    line-height: 1.1;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    letter-spacing: 0.05em;
}

.main-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.planet-icon {
    font-size: 5.5rem;
    position: absolute;
    color: var(--accent-gold);
    text-shadow: 0 0 40px rgba(212, 175, 55, 0.4);
    animation: pulse 4s infinite ease-in-out;
    user-select: none;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.85;
    }

    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

.countdown-svg {
    width: 230px;
    height: 230px;
}

.countdown-svg circle {
    fill: none;
    stroke-width: 3.5;
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
}

.countdown-svg .bg {
    stroke: rgba(255, 255, 255, 0.04);
}

.countdown-svg .progress {
    stroke: var(--accent-gold);
    stroke-dasharray: 283;
    stroke-dashoffset: 0;
    stroke-linecap: round;
    transition: stroke-dashoffset 4.5s linear;
}

.hour-description {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-weight: 300;
    max-width: 400px;
    line-height: 1.4;
    cursor: pointer;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.2);
    display: inline-block;
    transition: var(--transition-smooth);
}

.hour-description:hover {
    color: var(--accent-gold);
    border-bottom-color: var(--accent-gold);
}

.time-left {
    position: absolute;
    bottom: -2rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 500;
}

/* Transition flash */
.transition-flash .main-card {
    animation: hourFlash 1.5s ease-out;
}

@keyframes hourFlash {
    0% {
        box-shadow: 0 0 60px rgba(99, 102, 241, 0.5), var(--shadow-premium);
    }

    100% {
        box-shadow: var(--shadow-premium);
    }
}

/* Favorable Actions */
.favorable-actions {
    grid-column: 1 / -1;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-glass);
}

.favorable-actions h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.favorable-actions ul {
    list-style: none;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.favorable-actions li {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-glass);
    font-size: 0.9rem;
    white-space: nowrap;
    transition: var(--transition-smooth);
}

.favorable-actions li:hover {
    background: rgba(255, 255, 255, 0.06);
}

/* ═══ TRADITION CARDS ═══ */
.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 1.5rem;
}

.trad-card {
    padding: 2rem;
    transition: var(--transition-smooth);
    position: relative;
}

.trad-card.clickable {
    cursor: pointer;
}

.trad-card:hover {
    background: rgba(255, 255, 255, 0.07);
    transform: translateY(-4px);
    box-shadow: var(--shadow-premium), var(--shadow-glow);
}

.info-term {
    cursor: help;
    border-bottom: 1px dotted rgba(255, 255, 255, 0.3);
    transition: all 0.2s ease;
}

.info-term:hover {
    color: var(--accent-gold);
    border-bottom-color: var(--accent-gold);
}

.info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    font-size: 10px;
    border: 1px solid var(--accent-gold);
    color: var(--accent-gold);
    border-radius: 50%;
    margin-left: 4px;
    vertical-align: middle;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.info-term:hover .info-icon {
    opacity: 1;
    background: var(--accent-gold);
    color: var(--bg-dark);
    transform: scale(1.1);
}

.trad-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.btn-info-small {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-info-small:hover {
    background: var(--accent-gold);
    color: var(--bg-dark);
    border-color: var(--accent-gold);
}

.btn-info-circle {
    background: transparent;
    border: 1px solid rgba(212, 175, 55, 0.4);
    color: var(--accent-gold);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
    line-height: 1;
}

.btn-info-circle:hover {
    background: var(--accent-gold);
    color: var(--bg-dark);
    border-color: var(--accent-gold);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}


.trad-icon {
    font-size: 1.5rem;
}

.trad-header h3 {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.entity-name {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
}

.entity-meaning {
    color: var(--accent-gold);
    font-style: italic;
    margin-bottom: 1.25rem;
    font-size: 0.95rem;
}

.entity-details {
    margin-bottom: 1.5rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 0.88rem;
}

.detail-row span:first-child {
    color: var(--text-muted);
}

.card-hint {
    position: absolute;
    bottom: 0.75rem;
    right: 1.25rem;
    font-size: 0.7rem;
    color: var(--text-muted);
    opacity: 0;
    transition: opacity 0.3s;
    letter-spacing: 0.05em;
}

.trad-card:hover .card-hint {
    opacity: 1;
}

/* ═══ BUTTONS ═══ */
.btn {
    font-family: var(--font-main);
    padding: 0.65rem 1.25rem;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-smooth);
    width: 100%;
    justify-content: center;
    font-size: 0.88rem;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-indigo);
    color: white;
}

.btn-primary:hover {
    background: #4f46e5;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-glass);
    color: var(--text-primary);
}

.btn-outline:hover {
    background: var(--bg-glass);
    border-color: var(--text-secondary);
}

.btn-sm {
    padding: 0.5rem 1rem;
}

/* Audio playing state */
.btn.playing {
    pointer-events: none;
    position: relative;
}

.btn.playing::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(99, 102, 241, 0.2) 50%, transparent 100%);
    animation: audioSweep 1.5s infinite;
}

@keyframes audioSweep {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

/* ═══ INTENTIONS ═══ */
.intentions-picker {
    padding: 2rem;
    text-align: center;
}

.intentions-picker h3 {
    margin-bottom: 1.25rem;
    font-weight: 500;
}

.intentions-grid {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.intention-btn {
    background: transparent;
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    padding: 0.5rem 1.5rem;
    border-radius: 99px;
    cursor: pointer;
    transition: var(--transition-smooth);
    font-family: var(--font-main);
    font-size: 0.88rem;
}

.intention-btn:hover,
.intention-btn.active {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
    background: rgba(212, 175, 55, 0.06);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.1);
}

/* ═══ FOOTER ═══ */
footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    max-width: 1400px;
    margin: 1rem auto 2rem;
    border-radius: var(--radius-lg);
}

.footer-info p {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.location-picker {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.btn-text {
    background: none;
    border: none;
    color: var(--accent-indigo);
    cursor: pointer;
    text-decoration: none;
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    transition: var(--transition-smooth);
    font-family: var(--font-main);
}

.btn-text:hover {
    background: rgba(99, 102, 241, 0.1);
}

/* Location input & autocomplete */
.location-display {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.location-input-wrapper {
    position: relative;
}

.location-input {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--accent-indigo);
    color: var(--text-primary);
    font-family: var(--font-main);
    font-size: 0.85rem;
    padding: 0.4rem 0.85rem;
    border-radius: 10px;
    outline: none;
    width: 260px;
    transition: var(--transition-smooth);
}

.location-input:focus {
    border-color: var(--accent-gold);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.15);
    background: rgba(255, 255, 255, 0.1);
}

.location-input::placeholder {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.location-input:disabled {
    opacity: 0.5;
    cursor: wait;
}

.location-icon {
    font-size: 1rem;
}

/* Autocomplete dropdown */
.location-dropdown {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 0;
    width: 320px;
    background: rgba(15, 17, 40, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.6);
    z-index: 500;
    overflow: hidden;
    animation: dropdownSlide 0.2s ease;
}

@keyframes dropdownSlide {
    0% {
        opacity: 0;
        transform: translateY(6px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.ac-item {
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    transition: background 0.15s ease;
}

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

.ac-item:hover {
    background: rgba(99, 102, 241, 0.12);
}

.ac-item.ac-empty {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.85rem;
    cursor: default;
}

.ac-main {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.15rem;
}

.ac-sub {
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

/* ═══ MODALS ═══ */
#modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

.modal {
    width: 92%;
    max-width: 640px;
    padding: 2.5rem;
    position: relative;
    max-height: 85vh;
    overflow-y: auto;
    animation: modalSlideUp 0.3s ease;
}

@keyframes modalSlideUp {
    0% {
        transform: translateY(20px);
        opacity: 0;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal::-webkit-scrollbar {
    width: 6px;
}

.modal::-webkit-scrollbar-track {
    background: transparent;
}

.modal::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
}

#close-modal {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    font-size: 1.3rem;
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

#close-modal:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.modal-title {
    font-size: 2rem;
    margin-bottom: 0.25rem;
}

.modal-subtitle {
    color: var(--accent-gold);
    font-style: italic;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.modal-pronunciation {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: -1rem;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.modal-section {
    margin-bottom: 2rem;
}

.modal-section h4 {
    font-size: 1rem;
    color: var(--accent-indigo);
    margin-bottom: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-family: var(--font-main);
}

.modal-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.4rem 1.5rem;
    font-size: 0.9rem;
}

.modal-grid>span:nth-child(odd) {
    color: var(--text-muted);
}

.modal-grid>span:nth-child(even) {
    color: var(--text-primary);
}

.psalm-text {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.psalm-latin {
    font-style: italic;
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.powers-list {
    list-style: none;
    padding: 0;
}

.powers-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-size: 0.9rem;
    position: relative;
    padding-left: 1.25rem;
}

.powers-list li::before {
    content: '✦';
    position: absolute;
    left: 0;
    color: var(--accent-gold);
    font-size: 0.75rem;
    top: 0.65rem;
}

.invocation-text {
    font-family: var(--font-serif);
    font-style: italic;
    line-height: 1.8;
    font-size: 0.95rem;
    border-left: 3px solid var(--accent-indigo);
    padding-left: 1.25rem;
    margin-top: 0.5rem;
}

.nakshatra-purpose {
    margin-top: 1rem;
    font-style: italic;
    color: var(--accent-gold);
    font-size: 0.9rem;
}

.mantra-display {
    font-size: 1.3rem;
    color: var(--accent-gold-bright);
    text-align: center;
    padding: 1.5rem;
    background: rgba(212, 175, 55, 0.05);
    border: 1px dashed rgba(212, 175, 55, 0.2);
    border-radius: var(--radius-md);
    letter-spacing: 0.05em;
}

/* Nakshatra & Spirit chips */
.nakshatra-list,
.spirits-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.nakshatra-chip,
.spirit-chip {
    font-size: 0.75rem;
    padding: 0.3rem 0.7rem;
    border-radius: 99px;
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    white-space: nowrap;
    transition: var(--transition-smooth);
}

.nakshatra-chip.active,
.spirit-chip.active {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
    background: rgba(212, 175, 55, 0.08);
}

.chip-symbol {
    margin-right: 0.25rem;
}

.hidden {
    display: none !important;
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 900px) {
    .grid-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .main-card {
        grid-template-columns: 1fr;
        padding: 2rem 1.5rem;
    }

    .card-header h2 {
        font-size: 2.2rem;
    }

    .countdown-svg {
        width: 170px;
        height: 170px;
    }

    .planet-icon {
        font-size: 4rem;
    }

    .favorable-actions ul {
        justify-content: center;
    }

    footer {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .modal {
        padding: 1.5rem;
    }

    .modal-title {
        font-size: 1.5rem;
    }
}

/* Profile Modal */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
    opacity: 0.8;
}

.form-group input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    padding: 0.6rem;
    border-radius: 4px;
    font-family: inherit;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-row .form-group {
    flex: 1;
}

#natal-results {
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid var(--accent-gold);
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1.5rem;
}

#natal-results h4 {
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
}

/* Lunar Mansion Styles */
.mansion-result-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.mansion-result-card h5 {
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.res-mansion-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--accent-gold);
    margin-bottom: 0.2rem;
}

.res-mansion-meaning {
    font-style: italic;
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 0.5rem;
}

.res-mansion-advice,
.mansion-advice {
    font-size: 0.9rem;
    background: rgba(var(--accent-indigo-rgb), 0.2);
    padding: 0.6rem;
    border-radius: 4px;
    border-left: 2px solid var(--accent-indigo);
    margin-top: 0.5rem;
}

.mansion-img-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-style: italic;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    border-top: 1px solid var(--border-glass);
}

/* Ensure Grid supports 4 items nicely */
.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

/* ═══════════════════════════════════════════════════════════
   ELEMENTAL THEMES (Resonance)
   ═══════════════════════════════════════════════════════════ */

/* FIRE (Aries, Leo, Sagittarius) - Gold, Crimson, Ember */
.theme-fire {
    --bg-gradient: radial-gradient(circle at 50% -20%, #2a0a0a, #0f0505 80%);
    --accent-gold: #ffd700;
    --accent-indigo: #e63946;
    /* shifting indigo to crimson red */
    --orb-color-1: rgba(255, 69, 0, 0.4);
    --orb-color-2: rgba(255, 215, 0, 0.3);
}

/* WATER (Cancer, Scorpio, Pisces) - Teal, Silver, Ocean */
.theme-water {
    --bg-gradient: radial-gradient(circle at 50% -20%, #001f3f, #020b1c 80%);
    --accent-gold: #00d4ff;
    /* shifting gold to cyan/electric blue */
    --accent-indigo: #0077b6;
    --text-primary: #e0faff;
    --orb-color-1: rgba(0, 150, 255, 0.4);
    --orb-color-2: rgba(0, 255, 255, 0.2);
}

/* AIR (Gemini, Libra, Aquarius) - Sky, Lavender, Cloud */
.theme-air {
    --bg-gradient: radial-gradient(circle at 50% -20%, #1e1e2e, #0d0d15 80%);
    --accent-gold: #cdb4db;
    /* lavender gold */
    --accent-indigo: #a2d2ff;
    /* sky blue */
    --orb-color-1: rgba(200, 200, 255, 0.4);
    --orb-color-2: rgba(255, 255, 255, 0.3);
    /* Lighter vibe? keep dark mode but airy */
}

/* EARTH (Taurus, Virgo, Capricorn) - Emerald, Bronze, Forest */
.theme-earth {
    --bg-gradient: radial-gradient(circle at 50% -20%, #1a2f1a, #0a110a 80%);
    --accent-gold: #d4a373;
    /* bronze/wood */
    --accent-indigo: #2d6a4f;
    /* forest green */
    --orb-color-1: rgba(40, 167, 69, 0.4);
    --orb-color-2: rgba(212, 163, 115, 0.3);
}

/* Schedule Modal */
.scrollable-schedule {
    max-height: 50vh;
    overflow-y: auto;
    padding-right: 0.5rem;
}

.modal-header-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.audio-play-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--border-glass);
    border-radius: 50%;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition-smooth);
    color: var(--text-primary);
}

.audio-play-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
    border-color: var(--accent-gold);
    box-shadow: 0 0 15px var(--accent-gold);
}

.audio-play-btn.playing {
    animation: pulseGlow 1.5s infinite;
    color: var(--accent-gold);
}

@keyframes pulseGlow {
    0% {
        box-shadow: 0 0 5px var(--accent-gold);
    }

    50% {
        box-shadow: 0 0 20px var(--accent-gold);
    }

    100% {
        box-shadow: 0 0 5px var(--accent-gold);
    }
}

.schedule-row {
    display: grid;
    grid-template-columns: 80px 100px 1fr;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    align-items: center;
    font-size: 0.95rem;
}

.schedule-row:last-child {
    border-bottom: none;
}

.schedule-row.current-row {
    background: rgba(255, 215, 0, 0.1);
    border-radius: 8px;
    padding-left: 0.5rem;
    margin-left: -0.5rem;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.sr-time {
    opacity: 0.7;
    font-size: 0.9rem;
    font-family: monospace;
}

.sr-planet {
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.sched-icon {
    font-size: 1.2rem;
}

.sr-summary {
    opacity: 0.8;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ═══ ALCHEMICAL CALENDAR ═══ */
.calendar-nav {
    display: flex;
    gap: 12px;
    margin: 20px 0;
    padding: 15px 5px;
    overflow-x: auto;
    scrollbar-width: none;
    /* Hide scrollbar for cleaner look */
    -ms-overflow-style: none;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.calendar-nav::-webkit-scrollbar {
    display: none;
}

.day-btn {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    padding: 12px 18px;
    border-radius: 16px;
    cursor: pointer;
    white-space: nowrap;
    font-family: var(--font-main);
    font-size: 0.8rem;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    min-width: 90px;
    backdrop-filter: blur(5px);
}

.day-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(212, 175, 55, 0.3);
    transform: translateY(-2px);
}

.day-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15), rgba(212, 175, 55, 0.05));
    color: var(--accent-gold);
    border-color: var(--accent-gold);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.15);
    font-weight: 600;
}

.day-btn .day-symbol {
    font-size: 1.4rem;
    margin-bottom: 2px;
    opacity: 0.5;
    transition: var(--transition-smooth);
}

.day-btn.active .day-symbol {
    opacity: 1;
    transform: scale(1.1);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}

.calendar-windows .day-group {
    display: none;
    animation: fadeInSlide 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.calendar-windows .day-group.active {
    display: block;
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ritual-manuscript {
    background: linear-gradient(rgba(212, 175, 55, 0.03), rgba(212, 175, 55, 0.01));
    padding: 24px;
    border-radius: 20px;
    border: 1px solid rgba(212, 175, 55, 0.15);
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
}

.ritual-manuscript::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-gold), transparent);
    opacity: 0.3;
}

.ritual-step {
    margin-bottom: 18px;
}

.ritual-step:last-child {
    margin-bottom: 0;
}

.ritual-label {
    font-size: 0.65rem;
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 6px;
    display: block;
    opacity: 0.8;
}

.ritual-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-primary);
    font-family: var(--font-serif);
}