/* /assets/css/css.css */
:root {
    --primary-red: #d32f2f;
    --dark-red: #8b0000;
    --bg-dark: #0a0a0a;
    --card-bg: #1a1a1a;
    --text-light: #f4f4f4;
    --glass: rgba(255, 255, 255, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
}

img {
    display: block;
    max-width: 100%;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    border: 0;
    cursor: pointer;
    background: transparent;
    color: inherit;
}

#emergency-banner {
    background-color: #b91c1c;
    color: white;
    text-align: center;
    padding: 0.5rem 0;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.875rem;
    width: 100%;
    transition: transform 0.3s ease-in-out;
    position: fixed;
    top: 0;
    z-index: 1100;
}

nav {
    position: fixed;
    top: 36px;
    width: 100%;
    padding: 1.2rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--glass);
    transition: top 0.3s ease-in-out;
}

body.scrolled #emergency-banner {
    transform: translateY(-100%);
}

body.scrolled nav {
    top: 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: white;
}

.logo img {
    height: 50px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
    align-items: center;
}

.nav-links a,
.nav-dropdown-toggle {
    text-decoration: none;
    color: var(--text-light);
    font-weight: 500;
    transition: 0.3s;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-links a:hover,
.nav-dropdown-toggle:hover,
.nav-dropdown.open .nav-dropdown-toggle,
.nav-dropdown:focus-within .nav-dropdown-toggle {
    color: var(--primary-red);
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    align-items: center;
    display: inline-flex;
    gap: 6px;
}

.nav-dropdown-toggle svg {
    height: 14px;
    width: 14px;
    transition: transform 0.2s ease;
}

.nav-dropdown.open .nav-dropdown-toggle svg,
.nav-dropdown:focus-within .nav-dropdown-toggle svg {
    transform: rotate(180deg);
}

.nav-dropdown-menu {
    background: rgba(10, 10, 10, 0.98);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.34);
    display: flex;
    flex-direction: column;
    gap: 0;
    left: 0;
    list-style: none;
    min-width: 170px;
    opacity: 0;
    padding: 8px;
    pointer-events: none;
    position: absolute;
    top: calc(100% + 12px);
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-dropdown-menu a {
    border-radius: 4px;
    display: block;
    padding: 10px 12px;
    white-space: nowrap;
}

.nav-dropdown-menu a:hover {
    background: rgba(211, 47, 47, 0.16);
}

.nav-dropdown.open .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

@media (min-width: 769px) and (max-width: 1158px) {
    .nav-gallery-item {
        display: none;
    }
}

@media (min-width: 769px) and (max-width: 1053px) {
    .logo span {
        display: none;
    }
}

@media (max-width: 339px) {
    .logo span {
        display: none;
    }
}

@media (min-width: 769px) and (max-width: 859px) {
    .nav-community-connect-item {
        display: none;
    }
}

.members-btn {
    background: white;
    color: black !important;
    padding: 8px 20px;
    border-radius: 4px;
    font-weight: bold !important;
    transition: 0.3s !important;
}

.members-btn:hover {
    background: var(--primary-red) !important;
    color: white !important;
}

.mobile-menu-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    color: white;
}

.mobile-menu-btn svg {
    width: 22px;
    height: 22px;
}

.hero {
    min-height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.65), rgba(10,10,10,1)), url('/assets/img/header.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 150px 10% 70px;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5.5rem);
    line-height: 1;
    margin-bottom: 20px;
    text-shadow: 0 0 20px rgba(185, 28, 28, 0.4);
    font-style: italic;
    font-weight: 900;
    text-transform: uppercase;
    user-select: none;
}

.hero-logo {
    height: clamp(110px, 16vw, 180px);
    margin-bottom: 24px;
    width: auto;
}

.hero-welcome {
    color: #fff;
    font-size: clamp(1.1rem, 2vw, 1.6rem);
    font-weight: 700;
    letter-spacing: 0;
    margin-bottom: 12px;
}

.red-gradient {
    background: linear-gradient(135deg, #b91c1c 0%, #7f1d1d 100%);
}

section {
    padding: 80px 10%;
}

.section-title {
    font-size: 2.8rem;
    margin-bottom: 50px;
    text-align: center;
    font-weight: 900;
    text-transform: uppercase;
    font-style: italic;
}

.mission-statement-section {
    background: #0a0a0a;
    color: white;
    padding-top: 64px;
    padding-bottom: 64px;
    text-align: center;
}

.mission-statement-inner {
    margin: 0 auto;
    max-width: 860px;
}

.mission-statement-kicker {
    color: var(--primary-red);
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    margin-bottom: 18px;
    text-transform: uppercase;
}

.mission-statement-quote {
    color: #fff;
    font-size: clamp(1.05rem, 1.7vw, 1.45rem);
    font-weight: 700;
    line-height: 1.55;
    margin: 0;
    position: relative;
}

.mission-statement-quote::before,
.mission-statement-quote::after {
    color: var(--primary-red);
    display: block;
    font-size: clamp(2.8rem, 6vw, 4.75rem);
    font-weight: 900;
    line-height: 0.72;
}

.mission-statement-quote::before {
    content: open-quote;
    margin-bottom: 4px;
}

.mission-statement-quote::after {
    content: close-quote;
    margin-top: 16px;
}

.hero-mission-statement {
    max-width: 920px;
}

.hero-mission-statement .mission-statement-kicker {
    margin-bottom: 10px;
}

.hero-mission-statement .mission-statement-quote {
    color: #f4f4f4;
    font-size: clamp(0.95rem, 1.25vw, 1.12rem);
    font-weight: 500;
    line-height: 1.55;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.72);
}

.hero-mission-statement .mission-statement-quote::before,
.hero-mission-statement .mission-statement-quote::after {
    display: none;
}

.footer-social-link {
    align-items: center;
    color: #9ca3af;
    display: inline-flex;
    justify-content: center;
    margin-top: 16px;
    transition: color 0.2s ease, transform 0.2s ease;
}

.footer-social-link:hover,
.footer-social-link:focus-visible {
    color: white;
    transform: translateY(-1px);
}

.footer-social-link svg {
    fill: currentColor;
    height: 28px;
    width: 28px;
}

.community-connect-section {
    background: #101010;
    padding-top: 70px;
    padding-bottom: 70px;
}

.community-connect-inner {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
    align-items: center;
    gap: 48px;
    max-width: 1150px;
    margin: 0 auto;
}

.community-connect-kicker {
    color: var(--primary-red);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.community-connect-copy h2 {
    color: white;
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-style: italic;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 22px;
    text-transform: uppercase;
}

.community-connect-copy p:not(.community-connect-kicker) {
    color: #d1d5db;
    font-size: 1.08rem;
    line-height: 1.75;
    margin-bottom: 28px;
}

.community-connect-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 52px;
    padding: 0 26px;
    border-radius: 999px;
    color: white;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-decoration: none;
    text-transform: uppercase;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.community-connect-btn:hover,
.community-connect-btn:focus-visible {
    box-shadow: 0 0 22px rgba(185,28,28,0.45);
    transform: translateY(-1px);
}

.community-connect-btn svg {
    width: 18px;
    height: 18px;
}

.community-connect-video {
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}

.community-connect-video video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.pediatric-provider-section {
    background: #0a0a0a;
    padding-top: 40px;
}

.pediatric-provider-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
    align-items: center;
    gap: 48px;
    max-width: 1150px;
    margin: 0 auto;
}

.pediatric-provider-copy {
    border-left: 4px solid var(--primary-red);
    padding-left: 28px;
}

.pediatric-provider-kicker {
    color: var(--primary-red);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.pediatric-provider-copy h2 {
    color: white;
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-style: italic;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 22px;
    text-transform: uppercase;
}

.pediatric-provider-copy p:last-child {
    color: #d1d5db;
    font-size: 1.1rem;
    line-height: 1.8;
    max-width: 720px;
}

.pediatric-provider-image {
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}

.pediatric-provider-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-section {
    overflow: hidden;
}

.gallery-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 32px;
}

.gallery-heading .section-title {
    margin-bottom: 0;
    text-align: left;
}

.gallery-controls {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.gallery-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    color: white;
    transition: background 0.25s ease, transform 0.25s ease;
}

.gallery-arrow:hover,
.gallery-arrow:focus-visible {
    background: rgba(211,47,47,0.85);
    transform: translateY(-1px);
}

.gallery-reel {
    --gallery-gap: 18px;
    overflow: hidden;
    width: 100%;
    padding: 2px;
}

.gallery-track {
    display: flex;
    gap: var(--gallery-gap);
    will-change: transform;
    transition: transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-reel-item {
    position: relative;
    flex: 0 0 clamp(260px, 31vw, 430px);
    aspect-ratio: 4 / 3;
    border-radius: 8px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08);
}

.gallery-reel-item::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.04);
}

.gallery-reel-item img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(35%);
    opacity: 0;
    transform: scale(1.015);
    transition: opacity 0.35s ease, transform 0.4s ease, filter 0.4s ease;
}

.gallery-reel-item.loaded img {
    opacity: 1;
}

.gallery-reel-item:hover img,
.gallery-reel-item:focus-visible img {
    filter: grayscale(0%);
    transform: scale(1.045);
}

.gallery-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 2000;
}

.gallery-modal.open {
    opacity: 1;
    visibility: visible;
}

.gallery-modal-content {
    max-width: min(1100px, 88vw);
    max-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-modal-content img {
    max-width: 100%;
    max-height: 85vh;
    width: auto;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 20px 80px rgba(0,0,0,0.6);
}

.gallery-modal-close,
.gallery-modal-nav {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 999px;
    color: white;
    transition: background 0.25s ease, transform 0.25s ease;
}

.gallery-modal-close:hover,
.gallery-modal-nav:hover {
    background: rgba(255,255,255,0.14);
    transform: scale(1.03);
}

.gallery-modal-close {
    top: 24px;
    right: 24px;
}

.gallery-modal-prev {
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
}

.gallery-modal-next {
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
}

.gallery-modal-prev:hover,
.gallery-modal-next:hover {
    transform: translateY(-50%) scale(1.03);
}

.glass {
    background: rgba(20, 20, 20, 0.7);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-field {
    min-height: 56px;
}

.contact-field:focus {
    border-color: var(--primary-red);
}

.contact-field.field-error {
    border-color: #ef4444;
    box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.35);
}

.contact-form-errors,
.contact-form-status {
    border-radius: 8px;
    font-size: 0.92rem;
    line-height: 1.5;
    padding: 14px 16px;
}

.contact-form-errors {
    background: rgba(127, 29, 29, 0.35);
    border: 1px solid rgba(239, 68, 68, 0.45);
    color: #fecaca;
}

.contact-form-errors ul {
    list-style: disc;
    margin-left: 18px;
}

.contact-form-status {
    margin-bottom: 18px;
}

.contact-form-status.success {
    background: rgba(22, 101, 52, 0.28);
    border: 1px solid rgba(34, 197, 94, 0.42);
    color: #bbf7d0;
}

.contact-form-status.error {
    background: rgba(127, 29, 29, 0.35);
    border: 1px solid rgba(239, 68, 68, 0.45);
    color: #fecaca;
}

.contact-submit-disabled {
    cursor: wait;
    opacity: 0.72;
}

select.contact-field {
    appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, white 50%),
        linear-gradient(135deg, white 50%, transparent 50%);
    background-position:
        calc(100% - 22px) calc(50% - 3px),
        calc(100% - 16px) calc(50% - 3px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
    padding-right: 3.5rem;
}

.field-hidden {
    display: none;
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 768px) {
    nav {
        top: 36px;
        padding: 1rem 5%;
        flex-wrap: wrap;
        gap: 12px;
    }

    .mobile-menu-btn {
        display: inline-flex;
    }

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        padding: 16px 0 4px;
    }

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

    .nav-dropdown {
        width: 100%;
    }

    .nav-dropdown-toggle {
        justify-content: space-between;
        width: 100%;
    }

    .nav-dropdown-menu {
        background: rgba(255, 255, 255, 0.04);
        border-color: rgba(255, 255, 255, 0.1);
        box-shadow: none;
        display: none;
        margin-top: 10px;
        min-width: 0;
        opacity: 1;
        padding: 6px;
        pointer-events: auto;
        position: static;
        transform: none;
        width: 100%;
    }

    .nav-dropdown.open .nav-dropdown-menu,
    .nav-dropdown:focus-within .nav-dropdown-menu {
        display: flex;
    }

    .community-connect-inner {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .community-connect-copy p:not(.community-connect-kicker) {
        font-size: 1rem;
    }

    .community-connect-video {
        width: 100%;
    }

    .pediatric-provider-inner {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .pediatric-provider-copy {
        padding-left: 20px;
    }

    .pediatric-provider-copy p:last-child {
        font-size: 1rem;
    }

    .pediatric-provider-image {
        max-width: 420px;
    }

    .gallery-heading {
        align-items: flex-start;
        flex-direction: column;
        margin-bottom: 24px;
    }

    .gallery-heading .section-title {
        font-size: 2.15rem;
    }

    .gallery-controls {
        width: 100%;
        justify-content: flex-end;
    }

    .gallery-reel-item {
        flex-basis: min(78vw, 340px);
    }

    .gallery-modal {
        padding: 20px;
    }

    .gallery-modal-close {
        top: 14px;
        right: 14px;
    }

    .gallery-modal-prev,
    .gallery-modal-next {
        width: 44px;
        height: 44px;
        bottom: 20px;
        top: auto;
        transform: none;
    }

    .gallery-modal-prev {
        left: calc(50% - 56px);
    }

    .gallery-modal-next {
        right: calc(50% - 56px);
    }

    .gallery-modal-prev:hover,
    .gallery-modal-next:hover {
        transform: scale(1.03);
    }
}
