/* 
    Einstein House — Responsive Overrides
    Targets Mobile and Tablet viewports
*/

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   TABLET (≤ 1024px)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 1024px) {

    html {
        scroll-padding-top: 100px;
        scroll-behavior: smooth;
    }
    
    .container { padding: 0 32px; }

    /* Vision */
    .vision-grid { gap: 28px; }

    /* Monument */
    .monument-card-img { width: 220px; }
    .monument-card-body { padding-left: 30px; }

    /* Stewardship */
    .stewardship-left { max-width: 100%; }
    .stewardship-right { width: 100%; height: auto; aspect-ratio: 16/9; }
}

@media (max-width: 900px) {
    .vision-grid {
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "text text"
            "portrait manuscript";
        gap: 32px;
    }
    .vision-text { grid-area: text; margin-top: 40px; }
    .vision-portrait { grid-area: portrait; }
    .vision-manuscript {
        grid-area: manuscript;
        transform: rotate(4deg);
        margin-top: 0;
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   MOBILE (≤ 767px)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 767px) {
    .container { padding: 0 20px; }

    /* Navigation */
    .hamburger { display: flex; }
    .nav-links { display: none; }

    .logo img {
        height: 52px;
    }

    /* Banner Section */
    #banner {
        height: auto;
        min-height: 600px;
        padding-top: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: flex-start;
        background-position: 75% center;
    }
    
    .banner-overlay {
        background: linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.7) 100%);
    }

    .banner-content {
        position: relative;
        top: 0;
        left: 0;
        padding: 40px 20px;
        max-width: 100%;
        text-align: left;
    }

    .banner-title {
        font-size: clamp(32px, 10vw, 48px);
        line-height: 1.1;
        margin-bottom: 20px;
    }

    .banner-desc {
        font-size: 18px;
        margin-top: 20px;
        /*padding-left: 30px;*/
    }

    .banner-desc p:before {
        left: -35px;
        font-size: 40px;
    }

    .btn-teal-outline {
        margin-top: 30px;
    }

    .banner-huji {
        position: relative;
        bottom: 0;
        right: 0;
        margin-top: 0;
        align-self: flex-end;
    }

    .banner-huji img {height: 45px;margin: 20px;}

    /* Vision Section */
    #vision { padding: 60px 0; }
    .vision-grid {
        grid-template-columns: 1fr;
        grid-template-areas: none;
        gap: 0;
        display: flex;
        flex-wrap: wrap;
    }
    .vision-text {margin-top: 0;text-align: center;margin: 0;}
    .vision-text h2 { font-size: 36px; }
    .vision-images {
        display: flex;
        flex-direction: row; /* Ensure it stays horizontal */
        flex-wrap: wrap;     /* Allow items to wrap to a second row */
        justify-content: space-between;
        gap: 20px 4%;        /* Vertical gap, then horizontal gap */
        margin-top: 30px;
    }

    .vision-images > * {
        flex: 0 0 48%;       /* Each image takes up 48% of the width */
        max-width: 48%;
    }
    .vision-portrait img, 
    .vision-manuscript img {
        width: 100%;
        height: auto;
        max-width: 320px;
        height: 100%;
    }
    .vision-manuscript { transform: none; margin-top: 0; }

    /* Monument Section */
    #monument { padding: 60px 0; }
    .monument-header { margin-bottom: 40px; }
    .monument-header h2 { font-size: 32px; }
    .monument-tagline { font-size: 16px; }

    .monument-card {
        flex-direction: column;
        padding: 20px;
        align-items: stretch;
    }
    .monument-card-img {
        width: 100%;
        height: 200px;
        margin-bottom: 20px;
    }
    .monument-card-body {
        padding: 0;
        text-align: center;
    }
    .monument-card-body h3 { font-size: 20px; }
    .monument-card-body p, 
    .monument-card-body ul { font-size: 16px; }

    /* Stewardship Section */
    #stewardship {
        padding: 60px 20px;
    }
    #stewardship .container {
        flex-direction: column;
        gap: 40px;
    }
    .stewardship-right {
        order: -1; /* Image first */
        width: 100%;
        height: 300px;
    }
    .stewardship-left {
        text-align: center;
    }
    .stewardship-left h2 { font-size: 32px; margin-top: 0; }
    .stewardship-intro { margin-inline: auto; }
    .stewardship-blockquote {
        border-left: none;
        border-top: 4px solid var(--accent);
        padding: 20px 0 0 0;
        font-size: 20px;
    }
    .stewardship-note { margin-inline: auto; font-size: 16px; }
    .stewardship-left .btn-teal {align-self: center;margin: 0 auto;max-width: 100%;padding-inline: 12px;}

    /* Hero / stats Section */
    #hero {
        min-height: auto;
        padding: 40px 0 0;
    }
    .hero-content {
        width: 100%;
        padding-bottom: 40px;
    }
    .hero-sub {margin-bottom: 20px;}
    .hero-stats {
        flex-direction: column;
        gap: 20px;
    }
    .stat-item {
        padding: 0;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        padding-bottom: 20px;
        width: 100%;
    }
    .stat-item:last-child { border-bottom: none; }
    .stat-value { font-size: 28px; }
    .stat-label { font-size: 16px; }

    /* Contact Section */
    #contact { padding: 60px 0; }
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }
    .contact-quote { margin: 0 auto; font-size: 24px; }
    .contact-row { flex-direction: column; gap: 20px; }
    .form-field { width: 100%; }
    .form-field label { text-align: left; }
    .form-submit { width: 100%; margin-top: 10px; }
    .form-submit .btn-teal { width: 100%; }

    /* Footer */
    .footer-inner {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }
    .footer-links {
        justify-content: center;
        gap: 20px;
        flex-wrap: wrap;
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   SMALL MOBILE (≤ 480px)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
@media (max-width: 480px) {
    .banner-title { font-size: 32px; }
    .stewardship-left h2 { font-size: 28px; }
    .mobile-nav-link { font-size: 24px; }
}


/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   STEWARDSHIP RESPONSIVE STYLES
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* Tablet & Large Mobile (Under 1024px) */
@media (max-width: 1024px) {
    #stewardship {
        min-height: auto;
        padding: 60px 20px;
        display: block;
    }

    #stewardship .container {
        flex-direction: column; /* Stack vertically */
        gap: 40px;
    }

    .stewardship-left, 
    .stewardship-right {
        width: 100%;    /* Override fixed desktop widths */
        max-width: 100%;
        height: auto;
    }

    .stewardship-right {
        order: 0;       /* Moves image below text */
        height: 400px;  /* Maintain some height for the image */
    }

    .stewardship-intro,
    .stewardship-note {
        max-width: 100%; /* Allow text to fill the screen width */
    }
}

/* Small Mobile (Under 480px) */
@media (max-width: 480px) {
    #stewardship {
        padding: 40px 15px;
        display: block;
    }

    .stewardship-left h2 {
        margin-top: 0;
        margin-bottom: 16px;
    }

    .stewardship-blockquote {
        font-size: 20px;     /* Slightly smaller for tight screens */
        line-height: 1.5;
    }

    .stewardship-right {
        height: 300px;       /* Shorter aspect ratio for phones */
    }

    .stewardship-intro {
        font-size: 18px;
        margin-bottom: 12px;
    }
}