/* God Beyond Walls - Making Disciples Who Make Disciples
   Stylesheet v1.0
   ================================================== */

:root {
    --gold: #A68A3A;          /* Darkened for better contrast (was #C4A35A) */
    --gold-light: #D4B76A;
    --gold-decorative: #C4A35A; /* Original gold for decorative elements */
    --cream: #FAF7F2;
    --cream-dark: #F0EBE3;
    --deep-green: #2D4A3E;
    --forest: #1A2F26;
    --text: #3A3A3A;
    --text-light: #595959;    /* Darkened for better contrast (was #666666) */
    --warmth: #E8DED0;
}

/* ===========================================
   Reset & Base
   =========================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Nunito Sans', sans-serif;
    background: var(--cream);
    color: var(--text);
    line-height: 1.7;
    font-size: 17px;
    overflow-x: hidden;
}

/* Grain overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03;
    pointer-events: none;
    z-index: 1000;
}

h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 500;
    line-height: 1.2;
}

/* ===========================================
   Navigation
   =========================================== */

nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(250, 247, 242, 0.95);
    backdrop-filter: blur(10px);
    z-index: 100;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(196, 163, 90, 0.2);
}

.logo {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--deep-green);
    text-decoration: none;
    letter-spacing: 0.02em;
}

.logo span {
    color: var(--gold);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a:focus {
    color: var(--gold);
}

/* ===========================================
   Accessibility - Focus Styles
   =========================================== */

/* Global focus styles */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

/* Skip link for keyboard navigation */
.skip-link {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--deep-green);
    color: var(--cream);
    padding: 1rem 2rem;
    z-index: 1000;
    text-decoration: none;
    font-weight: 600;
    border-radius: 0 0 8px 8px;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

/* ===========================================
   Hero Section
   =========================================== */

.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 8rem 2rem 4rem;
    position: relative;
    background: linear-gradient(180deg, var(--cream) 0%, var(--warmth) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at 50% 30%, rgba(196, 163, 90, 0.15) 0%, transparent 60%);
    pointer-events: none;
}

.hero-content {
    max-width: 900px;
    position: relative;
    z-index: 1;
}

.hero-eyebrow {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 1s ease forwards 0.3s;
}

.hero h1 {
    font-size: clamp(2.8rem, 7vw, 5rem);
    color: var(--deep-green);
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 1s ease forwards 0.5s;
}

.hero h1 em {
    color: var(--gold);
    font-style: italic;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto 2.5rem;
    font-weight: 300;
    opacity: 0;
    animation: fadeUp 1s ease forwards 0.7s;
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--deep-green);
    color: var(--cream);
    padding: 1rem 2.5rem;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeUp 1s ease forwards 0.9s;
}

.hero-cta:hover,
.hero-cta:focus {
    background: var(--gold);
    transform: translateY(-2px);
}

.hero-cta:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

.hero-cta svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

.hero-cta:hover svg {
    transform: translateX(4px);
}

.scripture {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 1.15rem;
    color: var(--text-light);
    margin-top: 4rem;
    max-width: 700px;
    opacity: 0;
    animation: fadeUp 1s ease forwards 1.1s;
}

.scripture cite {
    display: block;
    font-style: normal;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    color: var(--gold);
}

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

/* ===========================================
   Section Styles (shared)
   =========================================== */

section {
    padding: 6rem 2rem;
}

.section-container {
    max-width: 1100px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--deep-green);
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.gold-line {
    width: 60px;
    height: 3px;
    background: var(--gold);
    margin: 1.5rem auto 0;
}

/* ===========================================
   Vision Section
   =========================================== */

.vision {
    background: var(--cream);
}

.vision-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.vision-card {
    background: white;
    padding: 2.5rem;
    border: 1px solid rgba(196, 163, 90, 0.2);
    position: relative;
    transition: all 0.3s ease;
}

.vision-card:hover {
    border-color: var(--gold);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(45, 74, 62, 0.08);
}

.vision-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gold);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
}

.vision-card:hover::before {
    transform: scaleY(1);
}

.vision-icon {
    width: 48px;
    height: 48px;
    color: var(--gold);
    margin-bottom: 1.5rem;
}

.vision-card h3 {
    font-size: 1.5rem;
    color: var(--deep-green);
    margin-bottom: 1rem;
}

.vision-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ===========================================
   Multiplication Section
   =========================================== */

.multiplication {
    background: var(--forest);
    color: var(--cream);
    position: relative;
    overflow: hidden;
}

.multiplication::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(196, 163, 90, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.multiplication .section-header h2 {
    color: var(--cream);
}

.multiplication .section-header p {
    color: rgba(250, 247, 242, 0.7);
}

.multiplication .gold-line {
    background: var(--gold);
}

.mult-visual {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 3rem;
    position: relative;
    z-index: 1;
}

.mult-step {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(196, 163, 90, 0.3);
    min-width: 140px;
    transition: all 0.3s ease;
}

.mult-step:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--gold);
}

.mult-number {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.5rem;
    color: var(--gold);
    font-weight: 600;
}

.mult-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(250, 247, 242, 0.6);
    margin-top: 0.5rem;
}

.mult-arrow {
    display: flex;
    align-items: center;
    color: var(--gold);
    font-size: 1.5rem;
}

.mult-explanation {
    text-align: center;
    margin-top: 3rem;
    font-size: 1.1rem;
    color: rgba(250, 247, 242, 0.8);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.mult-explanation strong {
    color: var(--gold);
}

/* ===========================================
   Sessions Section
   =========================================== */

.sessions {
    background: var(--cream-dark);
}

.workbook-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.workbook-card {
    background: white;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(166, 138, 58, 0.15);
    transition: box-shadow 0.3s ease;
}

.workbook-card:hover {
    box-shadow: 0 8px 30px rgba(45, 74, 62, 0.1);
}

.workbook-card-header {
    background: var(--deep-green);
    color: var(--cream);
    padding: 1.75rem 1.5rem;
    text-align: center;
}

.workbook-card-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gold-light);
    display: block;
    margin-bottom: 0.5rem;
}

.workbook-card-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
    color: var(--cream);
}

.workbook-card-range {
    font-size: 0.85rem;
    opacity: 0.7;
}

.workbook-card-index {
    padding: 1.25rem 1.5rem 1.25rem 2.75rem;
    margin: 0;
    flex: 1;
}

.workbook-card-index li {
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    font-size: 0.88rem;
    color: var(--text);
    line-height: 1.4;
}

.workbook-card-index li::marker {
    color: var(--gold);
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    font-size: 1rem;
}

.workbook-card-index li:last-child {
    border-bottom: none;
}

.workbook-card-download {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.15rem 1.5rem;
    background: var(--deep-green);
    color: var(--cream);
    text-decoration: none;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    transition: all 0.3s ease;
    margin-top: auto;
}

.workbook-card-download:hover,
.workbook-card-download:focus {
    background: var(--forest);
}

.workbook-card-download:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

.workbook-card-download svg {
    width: 20px;
    height: 20px;
    color: var(--gold-light);
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.workbook-card-download:hover svg {
    transform: translateY(2px);
}

.ipad-download-hint {
    display: none;
    padding: 0.5rem 1rem;
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.72rem;
    color: #8a7f6f;
    line-height: 1.4;
    text-align: center;
    font-style: italic;
}

.ipad-detected .ipad-download-hint {
    display: block;
}

/* ===========================================
   About Section
   =========================================== */

.about {
    background: white;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    align-items: center;
}

.about-image {
    position: relative;
}

.about-image::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: -20px;
    bottom: -20px;
    border: 2px solid var(--gold);
    z-index: 0;
}

.about-image-placeholder {
    width: 100%;
    aspect-ratio: 4/5;
    background: linear-gradient(135deg, var(--warmth) 0%, var(--cream-dark) 100%);
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 1rem;
    color: var(--text-light);
}

.about-image-placeholder svg {
    width: 64px;
    height: 64px;
    color: var(--gold);
    opacity: 0.6;
}

.about-photo {
    width: 100%;
    height: auto;
    display: block;
    position: relative;
    z-index: 1;
}

.about-text h2 {
    font-size: 2.5rem;
    color: var(--deep-green);
    margin-bottom: 1.5rem;
}

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--text-light);
}

.about-text blockquote {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.3rem;
    font-style: italic;
    color: var(--deep-green);
    border-left: 3px solid var(--gold);
    padding-left: 1.5rem;
    margin: 2rem 0;
}

.about-text blockquote cite {
    display: block;
    font-size: 0.95rem;
    font-style: normal;
    color: var(--gold);
    margin-top: 0.75rem;
}

/* ===========================================
   Preview/Study Guide Section
   =========================================== */

.preview {
    background: linear-gradient(135deg, var(--cream-dark) 0%, var(--warmth) 100%);
}

/* Chat window with macOS-style chrome */
.chat-window {
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px rgba(45, 74, 62, 0.15);
    overflow: hidden;
    border: 1px solid rgba(196, 163, 90, 0.2);
    max-width: 800px;
    margin: 0 auto;
}

.chat-window-header {
    background: var(--forest);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chat-header-title {
    margin-left: auto;
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--cream);
    letter-spacing: 0.02em;
}

.chat-header-title span {
    font-weight: 400;
    opacity: 0.7;
}

.chat-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
}

.chat-dot:first-child { background: #ff5f57; }
.chat-dot:nth-child(2) { background: #ffbd2e; }
.chat-dot:nth-child(3) { background: #28ca42; }

.chat-iframe {
    width: 100%;
    height: 500px;
    border: none;
    display: block;
}

/* ===========================================
   Contact Section
   =========================================== */

.contact {
    background: var(--cream);
    text-align: center;
}

.contact-content {
    max-width: 600px;
    margin: 0 auto;
}

.contact h2 {
    font-size: 2.5rem;
    color: var(--deep-green);
    margin-bottom: 1rem;
}

.contact p {
    color: var(--text-light);
    margin-bottom: 2rem;
}

.contact-email {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.3rem;
    color: var(--gold);
    text-decoration: none;
    font-family: 'Cormorant Garamond', serif;
    transition: color 0.3s ease;
    cursor: pointer;
    background: none;
    border: none;
}

.contact-email:hover,
.contact-email:focus {
    color: var(--deep-green);
}

.contact-email:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

.contact-email svg {
    width: 24px;
    height: 24px;
}

.contact-cta {
    margin-top: 3rem;
}

.contact-cta a,
.contact-cta button {
    display: inline-block;
    background: var(--deep-green);
    color: var(--cream);
    padding: 1rem 2.5rem;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.contact-cta a:hover,
.contact-cta a:focus,
.contact-cta button:hover,
.contact-cta button:focus {
    background: var(--gold);
}

.contact-cta a:focus-visible,
.contact-cta button:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

/* ===========================================
   Footer
   =========================================== */

footer {
    background: var(--forest);
    color: rgba(250, 247, 242, 0.6);
    text-align: center;
    padding: 3rem 2rem;
}

footer .logo {
    color: var(--cream);
    margin-bottom: 1rem;
    display: inline-block;
}

footer p {
    font-size: 0.9rem;
}

/* ===========================================
   Mobile Responsive
   =========================================== */

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .hero {
        padding: 7rem 1.5rem 3rem;
    }

    section {
        padding: 4rem 1.5rem;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .about-image {
        max-width: 300px;
        margin: 0 auto;
    }

    .mult-visual {
        flex-direction: column;
        align-items: center;
    }

    .mult-arrow {
        transform: rotate(90deg);
    }

    .chat-iframe {
        height: 400px;
    }

    .chat-window {
        border-radius: 8px;
    }

    .workbook-cards {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .workbook-card-title {
        font-size: 1.3rem;
    }

    /* Mobile navigation */
    .mobile-menu-btn {
        display: flex;
        flex-direction: column;
        gap: 5px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0.5rem;
    }

    .mobile-menu-btn span {
        display: block;
        width: 24px;
        height: 2px;
        background: var(--deep-green);
        transition: all 0.3s ease;
    }

    .mobile-menu-btn[aria-expanded="true"] span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .mobile-menu-btn[aria-expanded="true"] span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn[aria-expanded="true"] span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(250, 247, 242, 0.98);
        flex-direction: column;
        padding: 1rem 2rem;
        gap: 0;
        border-bottom: 1px solid rgba(196, 163, 90, 0.2);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        border-bottom: 1px solid rgba(196, 163, 90, 0.1);
    }

    .nav-links li:last-child {
        border-bottom: none;
    }

    .nav-links a {
        display: block;
        padding: 1rem 0;
    }
}

/* Desktop: hide mobile menu button */
@media (min-width: 769px) {
    .mobile-menu-btn {
        display: none;
    }
}

/* ===========================================
   Accessibility - Reduced Motion
   =========================================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    html {
        scroll-behavior: auto;
    }

    .hero-eyebrow,
    .hero h1,
    .hero-subtitle,
    .hero-cta,
    .scripture {
        opacity: 1;
        transform: none;
        animation: none;
    }
}

/* ===========================================
   Screen Reader Only (Visually Hidden)
   =========================================== */

.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;
}
