:root {
    --bg-light: #FDFDFD;
    --bg-accent: #F9F8F6;
    --champagne: #CDC0A6;
    --champagne-dark: #A89B82;
    --gold-glow: rgba(205, 192, 166, 0.3);
    --text-dark: #333333;
    --text-muted: #666666;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start; /* changed to allow scrolling naturally */
}

/* Light Breathing Background */
.breathing-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at center, var(--bg-light) 0%, var(--bg-accent) 100%);
    z-index: -2;
    animation: breatheLight 8s infinite alternate ease-in-out;
}

@keyframes breatheLight {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.05); opacity: 1; }
}

#sparkles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: -1;
}

.sparkle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: var(--champagne-dark);
    border-radius: 50%;
    box-shadow: 0 0 6px var(--champagne-dark);
    animation: twinkleLight linear infinite;
}

@keyframes twinkleLight {
    0% { opacity: 0; transform: translateY(0) scale(0.5); }
    50% { opacity: 0.6; transform: translateY(-20px) scale(1); }
    100% { opacity: 0; transform: translateY(-40px) scale(0.5); }
}

h1, h2, h3, h4 {
    font-family: 'Comfortaa', cursive;
    color: var(--champagne-dark);
    margin-top: 0;
    font-weight: 700;
    letter-spacing: 1px;
}

.glow-text {
    font-size: 3.5rem;
    text-transform: uppercase;
    text-shadow: 0 0 15px var(--gold-glow);
    margin-bottom: 0.5rem;
}

.subtitle {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    color: var(--text-muted);
    font-weight: 300;
}

.container {
    width: 100%;
    max-width: 900px;
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.glass-panel {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(205, 192, 166, 0.5);
    border-radius: 6px;
    padding: 3rem 2rem;
    text-align: center;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
}

.hero-image-wrapper {
    margin: 2rem auto;
    border-radius: 50%;
    overflow: hidden;
    width: 200px;
    height: 200px;
    border: 1px solid var(--champagne);
    padding: 8px;
    background: white;
    box-shadow: 0 10px 30px rgba(205, 192, 166, 0.2);
}

.hero-image-wrapper img {
    border-radius: 50%;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Interactive Setup Elements */
.interactive-setup {
    width: 100%;
    margin-top: 2rem;
}

.setup-heading {
    font-size: 1.2rem;
    color: var(--champagne-dark);
    margin-bottom: 1rem;
    text-transform: uppercase;
}

#user-question {
    width: 100%;
    height: 120px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--champagne);
    border-radius: 4px;
    padding: 1.5rem;
    font-family: 'Comfortaa', cursive;
    font-size: 13pt;
    color: var(--text-dark);
    resize: none;
    margin-bottom: 2rem;
    outline: none;
    transition: all 0.3s ease;
}

#user-question:focus {
    border-color: var(--champagne-dark);
    box-shadow: 0 0 10px rgba(205, 192, 166, 0.2);
}

.spread-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto 2.5rem;
}

.spread-btn {
    flex: 1;
    min-width: 250px;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--accent-champagne);
    padding: 1.8rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
    font-family: 'Comfortaa', cursive;
    font-size: 13pt;
}

.spread-btn:hover {
    border-color: var(--champagne-dark);
    background: var(--bg-accent);
}

.spread-btn.active {
    background: var(--champagne);
    color: white;
    border-color: var(--champagne-dark);
    box-shadow: 0 4px 15px var(--gold-glow);
}

.spread-btn.active .spread-title,
.spread-btn.active .spread-desc {
    color: white;
}

.spread-title {
    font-family: 'Comfortaa', cursive;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--champagne-dark);
}

.spread-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.cta-wrapper {
    margin-top: 1rem;
}

.pulse-gold-anim {
    background: var(--bg-light);
    color: var(--champagne-dark);
    font-weight: 700;
    font-size: 1.1rem;
    padding: 1.5rem 4rem;
    border: 1px solid var(--champagne);
    border-radius: 3px;
    cursor: pointer;
    text-transform: uppercase;
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 3px;
    box-shadow: 0 0 15px rgba(205, 192, 166, 0.05);
    animation: goldPulseLight 2.5s infinite;
    transition: all 0.3s;
}

.pulse-gold-anim:hover:not(:disabled) {
    background: var(--champagne);
    color: white;
    transform: translateY(-2px);
}

@keyframes goldPulseLight {
    0% { box-shadow: 0 0 0 0 rgba(205, 192, 166, 0.4); }
    70% { box-shadow: 0 0 0 20px rgba(205, 192, 166, 0); }
    100% { box-shadow: 0 0 0 0 rgba(205, 192, 166, 0); }
}

.sub-cta {
    margin-top: 1rem;
    font-size: 0.9rem;
    letter-spacing: 2px;
    color: var(--champagne-dark);
    font-style: italic;
    font-weight: 400;
}

.hidden {
    display: none !important;
}

/* Reading Layouts */
.reading-section {
    width: 100%;
    animation: fadeIn 1s forwards;
    padding-bottom: 5rem;
}

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

.spread-container {
    display: flex;
    flex-direction: column;
    gap: 4rem; /* Spacing between rows */
    margin-bottom: 4rem;
}

/* Individual Reading Row */
.reading-row {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
    justify-content: center;
    align-items: stretch;
}

.reading-row.right-aligned {
    flex-direction: row-reverse;
}

/* Card Visuals */
.card-display {
    perspective: 1000px;
    flex-shrink: 0;
}

.card-container {
    width: 280px;
    height: 420px;
    border-radius: 4px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-style: preserve-3d;
}

.card-inner.flipped {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 4px;
    border: 1px solid var(--champagne);
    overflow: hidden;
}

.card-front {
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
}

.card-back-pattern {
    width: 92%;
    height: 94%;
    border: 1px solid rgba(205, 192, 166, 0.5);
    background: repeating-linear-gradient(45deg, var(--bg-accent), var(--bg-accent) 15px, white 15px, white 30px);
}

.card-back {
    transform: rotateY(180deg);
    background: white;
}

.card-back img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Text Content Area */
.reading-content {
    flex: 1;
    min-width: 320px;
    text-align: left;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.reading-position-tag {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--champagne);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.reading-content h2 {
    font-family: 'Comfortaa', cursive;
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--champagne-dark);
    line-height: 1.2;
}

.hero-ctas {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.explanation-block {
    margin-bottom: 2.5rem;
}

.explanation-block h4 {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--champagne-dark);
    letter-spacing: 2px;
    margin-bottom: 0.8rem;
    margin-top: 2rem;
    font-weight: 700;
    border-bottom: 1px solid var(--gold-glow);
    display: inline-block;
    padding-bottom: 4px;
}

.deep-dive-text {
    font-size: 1.1rem;
    line-height: 1.9;
    color: var(--text-dark);
    margin-bottom: 2rem;
    white-space: pre-line; /* preserves the spacing for the long text */
}

.application-list {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.application-list li {
    padding: 0.8rem 0;
    border-bottom: 1px solid rgba(205, 192, 166, 0.2);
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.application-list li::before {
    content: '✦';
    color: var(--champagne);
    font-size: 0.8rem;
}

.meta-box {
    background: var(--bg-accent);
    padding: 2rem;
    border-radius: 4px;
    margin-bottom: 2rem;
    border-left: 3px solid var(--champagne);
}

.meta-box h4 {
    margin-top: 0;
}

.meta-content {
    font-style: italic;
    color: var(--text-muted);
}

.ritual-box {
    background: rgba(205, 192, 166, 0.1);
    padding: 2rem;
    border-radius: 4px;
    margin-bottom: 1rem;
    border: 1px dashed var(--champagne);
}

.ritual-box h4 {
    color: var(--champagne-dark);
}

.mantra-block {
    text-align: center;
    padding: 2rem;
    margin: 3rem 0;
    border-top: 1px solid var(--gold-glow);
    border-bottom: 1px solid var(--gold-glow);
}

.mantra-text {
    font-family: 'Comfortaa', cursive;
    font-size: 1.5rem;
    color: var(--champagne-dark);
    font-style: italic;
    font-weight: 700;
}

/* Mini CTAs */
.mini-ctas {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(205, 192, 166, 0.2);
}

.mini-cta-link {
    font-size: 0.75rem; /* Smaller button style as requested */
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--champagne-dark);
    text-decoration: none;
    font-weight: 700;
    padding: 0.8rem 1.2rem;
    border: 1px solid rgba(205, 192, 166, 0.3);
    border-radius: 20px; /* pill shape for button feel */
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    background: transparent;
    display: inline-block;
    font-family: 'Comfortaa', cursive; /* Using the requested font */
}

.mini-cta-link:hover {
    border-color: transparent;
    color: var(--deep-taupe);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* Sparkling & Color-Shifting Outline Effect */
.cta-sparkle:hover {
    background: linear-gradient(white, white) padding-box,
                linear-gradient(45deg, #CDC0A6, #A89B82, #ffecd2, #CDC0A6) border-box;
    border: 1px solid transparent;
    background-size: 200% auto;
    animation: sparkleBorder 2s linear infinite;
}

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

/* Add a shimmering sparkle overlay */
.mini-cta-link::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to bottom right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%);
    transform: rotate(45deg);
    transition: all 0.7s;
    opacity: 0;
    pointer-events: none;
}

.mini-cta-link:hover::after {
    left: 100%;
    top: 100%;
    opacity: 1;
}

/* Back to Top */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--champagne);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    z-index: 100;
    transition: all 0.3s;
}

#back-to-top:hover {
    background: var(--champagne-dark);
    transform: translateY(-5px);
}

.highlight {
    color: var(--champagne-dark);
    font-weight: 500;
    border-left: 3px solid var(--champagne);
    padding-left: 1.5rem;
    background: rgba(205, 192, 166, 0.05);
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* === GATED MODAL === */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(43, 39, 36, 0.9);
    backdrop-filter: blur(15px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--off-white);
    padding: 4rem 3rem;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    text-align: center;
    box-shadow: 0 40px 80px rgba(0,0,0,0.5);
    position: relative;
    border: 1px solid var(--accent-gold);
    transform: scale(0.95) translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
}

.modal-content h2 {
    font-family: 'Comfortaa', cursive;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--deep-taupe);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.modal-content .spread-desc {
    font-size: 13pt;
    color: var(--stone-gray);
    font-family: 'Comfortaa', cursive;
}

.modal-content p {
    font-size: 1.2rem;
    color: var(--stone-gray);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.gated-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 450px;
    margin: 0 auto;
}

.gated-form input[type="email"] {
    padding: 1.5rem;
    border: 1px solid var(--accent-champagne);
    background: #fff;
    font-family: 'Comfortaa', cursive;
    font-size: 13pt;
    border-radius: 4px;
    transition: all 0.3s ease;
    text-align: center;
}

.gated-form input[type="email"]:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 20px rgba(181, 153, 112, 0.1);
}

#draw-btn {
    background: var(--off-white);
    color: var(--deep-taupe);
    border: 1px solid var(--accent-gold);
    padding: 1.5rem 4rem;
    font-size: 13pt;
    font-family: 'Comfortaa', cursive;
    letter-spacing: 0.25em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s ease;
    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.gated-submit {
    background: var(--deep-taupe);
    color: var(--off-white);
    padding: 1.5rem;
    border: none;
    border-radius: 4px;
    font-family: 'Comfortaa', cursive;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 13pt;
}

.gated-submit:hover {
    background: var(--accent-gold);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--accent-gold);
    cursor: pointer;
    opacity: 0.3;
    transition: opacity 0.3s;
}

.modal-close:hover {
    opacity: 1;
}

/* === Synthesis Block === */
.synthesis-block {
    margin-top: 5rem;
    padding: 4rem;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid var(--accent-gold);
    box-shadow: 0 20px 50px rgba(181, 153, 112, 0.15);
    animation: scaleUp 0.8s ease-out forwards;
}

@keyframes scaleUp {
    from { opacity: 0; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1); }
}

.synthesis-content {
    font-family: 'Comfortaa', cursive;
    font-size: 13pt;
    line-height: 2;
    color: var(--text-dark);
    max-width: 700px;
    margin: 2rem auto 0;
}

.synthesis-intro {
    font-weight: 700;
    color: var(--champagne-dark);
    margin-bottom: 2rem;
    font-size: 1.2rem;
}

.bespoke-wisdom {
    font-style: italic;
    background: rgba(205, 192, 166, 0.05);
    padding: 2rem;
    border-radius: 8px;
    border-left: 4px solid var(--accent-gold);
    margin: 2.5rem 0;
}

.motivational-signoff {
    margin-top: 3rem;
    font-weight: 600;
}

.loving-signature {
    margin-top: 4rem;
    font-style: italic;
    color: var(--champagne-dark);
    border-top: 1px solid var(--accent-gold);
    padding-top: 2rem;
    display: inline-block;
}

@media (max-width: 768px) {
    .reading-row {
        flex-direction: column;
        align-items: center;
    }
    
    .reading-row.right-aligned {
        flex-direction: column;
    }

    .synthesis-block {
        padding: 2rem 1.5rem;
    }
}
