:root {
    color-scheme: light;
    --bg: #f7f4fb;
    --surface: #ffffff;
    --ink: #241a31;
    --muted: #6f637b;
    --line: #ded4e8;
    --brand: #6f3bb3;
    --brand-strong: #3f1d68;
    --brand-deep: #25103f;
    --accent: #c49a2c;
    --accent-strong: #f3c64e;
    --green: #2f6f5f;
    --focus: #7d4bc3;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.5;
}

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

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
    padding: 0 32px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 700;
}

.brand-mark {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 6px;
    background: var(--brand);
    color: white;
}

.language-form select,
.auth-form input {
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 8px 10px;
    background: white;
}

.menu-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 32px;
    background: var(--brand-deep);
    color: white;
}

.menu-links,
.account-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.account-menu {
    margin-left: auto;
}

.account-menu span {
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
    font-weight: 700;
}

.menu-bar a,
.menu-bar button,
.button,
.auth-form button {
    border: 0;
    border-radius: 6px;
    padding: 10px 14px;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.menu-bar a:hover,
.menu-bar button:hover {
    background: rgba(255, 255, 255, 0.13);
}

.app-shell {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    min-height: calc(100vh - 168px);
}

.app-shell-public {
    display: block;
}

.left-nav {
    padding: 24px 16px;
    background: #f0e9f8;
    border-right: 1px solid var(--line);
}

.nav-heading {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
}

.nav-group-label {
    margin: 18px 0 6px;
    padding: 0 12px;
    color: var(--brand);
    font-size: 13px;
    font-weight: 700;
}

.left-nav a {
    display: block;
    padding: 10px 12px;
    border-radius: 6px;
    color: #344054;
    font-size: 14px;
}

.left-nav a:hover {
    background: white;
}

.main-content {
    padding: 32px;
}

.app-shell-public .main-content {
    padding: 0;
}

.hero,
.section,
.auth-panel {
    max-width: 1120px;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
    align-items: center;
    gap: 32px;
    max-width: none;
    min-height: calc(100vh - 120px);
    padding: 56px clamp(24px, 6vw, 84px);
    background:
        linear-gradient(90deg, rgba(37, 16, 63, 0.95) 0%, rgba(63, 29, 104, 0.88) 44%, rgba(63, 29, 104, 0.46) 72%, rgba(37, 16, 63, 0.30) 100%),
        url("/static/img/home-hero-theology.png");
    background-size: cover;
    background-position: center;
    color: white;
}

.hero-content {
    max-width: 760px;
}

.hero h1,
.section h1 {
    margin: 0 0 12px;
    font-size: 40px;
    line-height: 1.15;
}

.hero h1 {
    font-size: 58px;
    max-width: 820px;
}

.hero p,
.lead {
    max-width: 720px;
    color: inherit;
    font-size: 18px;
}

.hero p {
    max-width: 680px;
    color: rgba(255, 255, 255, 0.90);
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--brand);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
}

.hero .eyebrow {
    color: var(--accent-strong);
}

.button,
.auth-form button {
    display: inline-block;
    margin-top: 14px;
    background: var(--brand);
    color: white;
    font-weight: 700;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.button-primary,
.button-offer {
    background: var(--accent-strong);
    color: #241a31;
}

.button-secondary {
    border: 1px solid rgba(255, 255, 255, 0.56);
    background: rgba(255, 255, 255, 0.10);
}

.hero-offer {
    align-self: center;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 8px;
    padding: 26px;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(10px);
}

.discount-badge {
    color: var(--accent-strong);
    font-size: 56px;
    font-weight: 800;
    line-height: 0.95;
}

.hero-offer p {
    margin: 12px 0 8px;
    color: white;
    font-size: 17px;
}

.home-message {
    padding: 22px clamp(24px, 6vw, 84px);
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}

.home-message div {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    max-width: 1440px;
    margin: 0 auto;
}

.home-message span {
    color: var(--green);
    font-weight: 700;
}

.home-message strong {
    color: var(--brand-strong);
    font-size: 18px;
}

.section {
    margin: 0 auto;
    padding: 42px 32px 54px;
}

.app-shell-public .section {
    max-width: none;
    padding: 42px clamp(24px, 6vw, 84px) 54px;
}

.app-shell-public .topic-group {
    max-width: 1440px;
    margin-left: auto;
    margin-right: auto;
}

.topic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.topic-group + .topic-group {
    margin-top: 40px;
}

.topic-card,
.placeholder-panel,
.auth-panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    padding: 20px;
}

.topic-card h3 {
    margin: 0 0 8px;
    font-size: 18px;
}

.topic-card p {
    margin: 0 0 12px;
    color: var(--muted);
}

.price-line {
    margin: 8px 0 4px;
    color: var(--brand-strong);
    font-size: 16px;
    font-weight: 700;
}

.discount-line {
    margin: 0 0 12px;
    color: var(--brand);
    font-size: 20px;
    font-weight: 800;
}

.topic-card span {
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

.topic-link:hover {
    border-color: var(--brand);
}

.article-content {
    margin-top: 28px;
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
}

.article-content h1 {
    font-size: 34px;
}

.article-content h2 {
    margin: 34px 0 12px;
    color: var(--brand-strong);
    font-size: 24px;
}

.article-content h3 {
    margin: 24px 0 10px;
    color: var(--brand);
    font-size: 20px;
}

.article-content p,
.article-content li,
.article-content blockquote {
    color: #3b3048;
    font-size: 17px;
}

.article-content blockquote {
    margin: 20px 0;
    padding: 16px 20px;
    border-left: 4px solid var(--accent);
    background: #fbf7ec;
    font-weight: 700;
}

.hebrew-page .main-content {
    direction: rtl;
    text-align: right;
}

.hebrew-page .article-content {
    direction: rtl;
    text-align: right;
}

.hebrew-page .article-content blockquote {
    border-right: 4px solid var(--accent);
    border-left: 0;
}

.auth-panel {
    max-width: 480px;
}

.auth-form {
    display: grid;
    gap: 14px;
}

.auth-form label {
    display: grid;
    gap: 6px;
    font-weight: 700;
}

.form-error {
    color: #a33b2f;
    font-weight: 700;
}

.site-footer {
    min-height: 48px;
    padding: 14px 32px;
    border-top: 1px solid var(--line);
    background: var(--surface);
    color: var(--muted);
}

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

@media (max-width: 820px) {
    .site-header,
    .menu-bar {
        padding: 0 16px;
    }

    .menu-bar {
        flex-wrap: wrap;
    }

    .account-menu {
        margin-left: 0;
    }

    .app-shell {
        grid-template-columns: 1fr;
    }

    .left-nav {
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .main-content {
        padding: 20px;
    }

    .app-shell-public .main-content {
        padding: 0;
    }

    .hero {
        grid-template-columns: 1fr;
        min-height: auto;
        padding: 28px;
    }

    .hero h1,
    .section h1 {
        font-size: 32px;
    }

    .hero h1 {
        font-size: 38px;
    }

    .discount-badge {
        font-size: 42px;
    }
}
