:root {
    /* White Theme Colors */
    --bg-color-1: #f8fafc;
    --bg-color-2: #e2e8f0;
    --bg-color-3: #cbd5e1;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --accent: #4f46e5;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.9);
    --card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
}

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

body {
    background-color: var(--bg-color-1);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    position: relative;
}

/* Background animation */
.background-animation {
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, #eff6ff, #f8fafc, #f1f5f9 70%);
    animation: rotateBg 40s linear infinite;
    z-index: -1;
    opacity: 0.8;
}

@keyframes rotateBg {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.d-none {
    display: none !important;
}

/* ── Site Header ───────────────────────────────────────────────────────────── */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(248, 250, 252, 0.88);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(203, 213, 225, 0.5);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
}

.site-header__inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

/* Brand / Logo */
.site-header__brand {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
    flex-shrink: 0;
}

.brand-icon {
    font-size: 1.6rem;
    color: var(--accent);
    line-height: 1;
    display: flex;
    align-items: center;
    transition: transform 0.3s ease;
}

.site-header__brand:hover .brand-icon {
    transform: scale(1.15) rotate(-5deg);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-main {
    font-family: 'Crimson Pro', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
}

.brand-sub {
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    white-space: nowrap;
}

/* Navigation */
.site-header__nav {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

/* Nav Buttons */
.nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 1.1rem;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    border: 2px solid transparent;
}

.nav-btn--trivia {
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: #fff;
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.35);
}

.nav-btn--trivia:hover {
    background: linear-gradient(135deg, #6d28d9, #4338ca);
    box-shadow: 0 4px 14px rgba(124, 58, 237, 0.5);
    transform: translateY(-2px);
}

.nav-btn--quiz {
    background: transparent;
    color: var(--accent);
    border-color: var(--accent);
}

.nav-btn--quiz:hover {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
    transform: translateY(-2px);
}

/* Hamburger */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.4rem;
    border-radius: 8px;
    transition: background 0.2s;
}

.nav-hamburger:hover {
    background: rgba(79, 70, 229, 0.08);
}

.nav-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Mobile drop-down nav */
.mobile-nav {
    display: none;
    flex-direction: column;
    background: rgba(248, 250, 252, 0.98);
    border-top: 1px solid rgba(203, 213, 225, 0.5);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
}

.mobile-nav--open {
    max-height: 200px;
    padding: 0.75rem 0;
}

.mobile-nav__link {
    display: block;
    padding: 0.85rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    transition: background 0.2s, color 0.2s;
}

.mobile-nav__link:hover {
    background: rgba(79, 70, 229, 0.07);
    color: var(--accent);
}

/* ── Responsive breakpoint ────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .nav-btn {
        display: none;
    }
    .nav-hamburger {
        display: flex;
    }
    .mobile-nav {
        display: flex;
    }
    .brand-sub {
        display: none;
    }
}

/* ── Container (push below fixed header) ─────────────────────────────────── */
.container {
    padding: 7rem 1.5rem 4rem;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    z-index: 1;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 3.5rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease;
}

.main-card {
    transform: translateY(20px);
    opacity: 0;
    animation: fadeUp 0.8s ease-out forwards;
    margin-bottom: 5rem;
}

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

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(0,0,0,0.04);
}

.label {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent);
}

.version-selector {
    display: flex;
    gap: 0.5rem;
}

.version-btn {
    background: transparent;
    border: 1px solid #cbd5e1;
    color: var(--text-secondary);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.version-btn:hover {
    color: var(--text-primary);
    border-color: var(--text-primary);
    background: rgba(0,0,0,0.02);
}

.version-btn.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.verse-content {
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#verse-text, .list-verse-text {
    font-family: 'Crimson Pro', serif;
    font-size: 2.2rem;
    line-height: 1.5;
    font-weight: 400;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    transition: opacity 0.5s ease;
}

#verse-text::before, .list-verse-text::before {
    content: "“";
    color: var(--accent);
    opacity: 0.3;
    margin-right: 0.2rem;
}

#verse-text::after, .list-verse-text::after {
    content: "”";
    color: var(--accent);
    opacity: 0.3;
    margin-left: 0.2rem;
}

#verse-reference, .list-verse-reference {
    font-family: 'Inter', sans-serif;
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--accent);
    text-align: right;
    transition: opacity 0.5s ease;
}

#verse-reference::before, .list-verse-reference::before {
    content: "— ";
}

.hidden {
    opacity: 0;
    pointer-events: none;
}

.loader {
    width: 48px;
    height: 48px;
    border: 3px solid #e2e8f0;
    border-bottom-color: var(--accent);
    border-radius: 50%;
    display: inline-block;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
    margin: 0 auto;
}

@keyframes rotation {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.card-footer {
    margin-top: 3rem;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.action-btn {
    background: white;
    border: 1px solid #e2e8f0;
    color: var(--text-primary);
    padding: 0.8rem 1.5rem;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.action-btn:hover {
    background: #f8fafc;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.action-btn svg {
    transition: transform 0.3s ease;
    color: var(--accent);
}

/* Only rotate the icon on the Random button, not Copy/Share */
#random-btn:hover svg {
    transform: rotate(180deg);
}

/* Search Section */
.search-section {
    margin-bottom: 3rem;
    display: flex;
    justify-content: center;
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 600px;
}

.search-input {
    width: 100%;
    padding: 1rem 1.5rem 1rem 3rem;
    border-radius: 30px;
    border: 1px solid #cbd5e1;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-size: 1rem;
    font-family: inherit;
    color: var(--text-primary);
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.02);
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}

.search-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    pointer-events: none;
}

/* More verses section */
.more-verses-section {
    margin-top: 2rem;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.verse-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.verse-list-item {
    padding: 2.5rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.02);
    animation: fadeIn 0.5s ease forwards;
    text-decoration: none;
    color: inherit;
    display: block;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.verse-list-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -8px rgba(0,0,0,0.08);
}

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

.list-verse-text {
    font-size: 1.6rem; 
}

.list-verse-reference {
    font-size: 1.1rem;
}

@media (max-width: 600px) {
    .glass-card, .verse-list-item {
        padding: 2rem 1.5rem;
    }
    
    #verse-text {
        font-size: 1.8rem;
    }
    
    .list-verse-text {
        font-size: 1.4rem;
    }

    .card-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
}

/* ── Toast notification ────────────────────────────────────────────────────── */
#toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(1rem);
    background: #0f172a;
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 9999;
    white-space: nowrap;
}

#toast.toast-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
