/* mobile-compat.css — shared responsive fixes for public pages */

html {
    -webkit-text-size-adjust: 100%;
}

body {
    overflow-x: clip;
    max-width: 100%;
}

img, video, svg {
    max-width: 100%;
    height: auto;
}

/* Main site nav (index-style) */
.site-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem 1rem;
    padding: 0.75rem 1rem;
}

.site-nav a {
    display: inline-block;
    padding: 0.35rem 0.5rem;
    line-height: 1.3;
}

/* Sunday dinner / giving list nav */
.site-nav-list {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1rem !important;
}

.site-nav-list a {
    padding: 0.35rem 0.25rem;
}

/* Responsive type on main-site headers */
@media (max-width: 640px) {
    .site-header h1 {
        font-size: clamp(1.5rem, 7vw, 2.2rem) !important;
        line-height: 1.2;
        word-wrap: break-word;
    }

    .site-header p {
        font-size: 0.95rem;
        padding: 0 0.25rem;
    }

    .site-main section,
    .site-main .theme-section,
    .site-main .sign-up {
        padding: 1.25rem !important;
    }

    .site-cards {
        grid-template-columns: 1fr !important;
    }

    .site-menu-grid {
        grid-template-columns: 1fr !important;
    }

    .ways-grid,
    .campaigns-grid {
        grid-template-columns: 1fr !important;
    }

    .table-scroll {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -0.25rem;
        padding: 0 0.25rem;
    }

    .table-scroll table {
        min-width: 520px;
    }
}

/* Easter feature cards (CDN Tailwind pages don't load tailwind.css) */
.feature-card {
    background: rgba(30, 41, 55, 0.92);
    border: 1px solid #475569;
    border-radius: 1.25rem;
    padding: 1.25rem;
    transition: all 0.2s ease;
    display: block;
    text-decoration: none;
    color: inherit;
}

.feature-card:hover {
    border-color: #34d399;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    transform: translateY(-2px);
}

/* Easter top navigation */
.easter-top-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.mobile-nav {
    display: none;
}

@media (max-width: 767px) {
    .mobile-nav {
        display: flex;
        flex: 1 1 100%;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.4rem 0.5rem;
        font-size: 0.8rem;
        order: 3;
        width: 100%;
        padding-top: 0.25rem;
    }

    .mobile-nav a {
        padding: 0.45rem 0.65rem;
        border: 1px solid rgba(255, 255, 255, 0.28);
        border-radius: 0.5rem;
        white-space: nowrap;
        min-height: 36px;
        display: inline-flex;
        align-items: center;
    }

    .easter-brand {
        flex: 1 1 auto;
        min-width: 0;
    }

    .easter-brand .font-semibold,
    .easter-brand .text-xl {
        font-size: 1rem;
        line-height: 1.2;
    }

    .easter-hero-title {
        font-size: clamp(2rem, 10vw, 3.5rem) !important;
    }

    .easter-event-badge {
        max-width: 100%;
        text-align: center;
        font-size: 0.7rem !important;
        letter-spacing: 0.06em !important;
        padding-left: 0.75rem !important;
        padding-right: 0.75rem !important;
    }

    .easter-hero-cta {
        width: 100%;
        max-width: 320px;
        min-width: 0 !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
        font-size: 1.1rem !important;
    }

    /* iOS: fixed backgrounds cause layout jank */
    .hero-bg,
    .admin-bg {
        background-attachment: scroll !important;
    }
}

/* Unified Easter page header (registration, stats, drawings) */
.site-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.site-page-header .header-meta {
    text-align: right;
    min-width: 0;
}

@media (max-width: 639px) {
    .site-page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-page-header .header-meta {
        text-align: left;
        width: 100%;
    }

    .site-page-header .header-meta .text-2xl {
        font-size: 1.35rem;
    }

    .site-page-header .header-meta .tracking-\[3px\] {
        letter-spacing: 0.08em !important;
        font-size: 0.65rem;
        line-height: 1.3;
        word-break: break-word;
    }

    .registration-card {
        padding: 1.25rem !important;
    }

    .registration-card .flex.gap-6 {
        flex-direction: column;
        gap: 1rem;
    }

    .stats-city-count {
        font-size: clamp(2.5rem, 14vw, 4rem) !important;
    }

    .stats-city-title {
        font-size: clamp(1.25rem, 5vw, 2rem) !important;
        line-height: 1.2;
    }

    .stats-gender-count {
        font-size: clamp(2.5rem, 12vw, 3.5rem) !important;
    }

    .drawings-status-bar {
        flex-direction: column;
        align-items: stretch !important;
        gap: 0.75rem;
        padding: 1rem !important;
    }

    .drawings-status-actions {
        flex-direction: column;
        width: 100%;
        gap: 0.5rem !important;
    }

    .drawings-status-actions button {
        width: 100%;
        justify-content: center;
    }

    .drawings-winner-prompt {
        font-size: clamp(1.75rem, 9vw, 3rem) !important;
        line-height: 1.05;
        padding: 0 0.5rem;
    }

    .drawings-draw-btn {
        width: 100%;
        max-width: 320px;
        padding: 1rem 1.5rem !important;
        font-size: 1.35rem !important;
    }

    .drawings-list-header {
        flex-direction: column !important;
        align-items: center !important;
        gap: 0.75rem;
    }

    .drawings-list-header button {
        margin-left: 0 !important;
        width: 100%;
        max-width: 280px;
    }

    .drawings-main-panel {
        padding: 1.25rem !important;
    }

    .photos-page-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 1rem;
    }

    .photos-page-header .photos-header-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .photos-church-name {
        font-size: 1.25rem !important;
        line-height: 1.2;
        word-break: break-word;
    }
}

@media (max-width: 480px) {
    .easter-stats-label {
        font-size: 0.7rem !important;
        letter-spacing: 0.12em !important;
        line-height: 1.35;
        padding: 0 0.5rem;
    }
}