@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Playfair+Display:wght@500;600;700&display=swap");

body.state-directory-page {
    overflow-x: clip;
    font-family: var(--temple-font-ui, "Inter", "Roboto", Arial, sans-serif);
}

body.state-directory-page .state-directory,
body.state-directory-page .state-directory-filter input,
body.state-directory-page .state-directory-filter select,
body.state-directory-page .state-directory-filter button {
    font-family: var(--temple-font-ui, "Inter", "Roboto", Arial, sans-serif);
}

body.state-directory-page .state-directory__hero .pageheader__left h1,
body.state-directory-page .state-directory__intro h2,
body.state-directory-page .state-directory-card h3,
body.state-directory-page .state-directory__empty h3 {
    font-family: var(--temple-font-heading, "Playfair Display", Georgia, serif);
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

body.state-directory-page .state-directory__hero .pageheader__left h1 {
    color: #FFFFFF;
}

.state-directory__hero {
    background-image: linear-gradient(135deg, rgba(25, 18, 12, 0.64), rgba(109, 69, 17, 0.45)), url("../images/backgrounds/divine-mandir-hub-pageheader-bg.png");
    background-position: center;
    background-size: cover;
}

.state-directory__body {
    overflow-x: clip;
    padding-top: clamp(38px, 5vw, 68px) !important;
}

.state-directory__intro {
    margin-bottom: 24px;
}

.state-directory__intro p {
    max-width: 850px;
    margin-inline: auto;
}

.state-directory__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    max-width: 820px;
    margin: 0 auto 24px;
}

.state-directory__stats p {
    display: grid;
    gap: 5px;
    margin: 0;
    padding: 17px 18px;
    border: 1px solid rgba(183, 117, 43, 0.18);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(66, 41, 20, 0.07);
    text-align: center;
}

.state-directory__stats strong {
    color: #7c4d1c;
    font-size: 1.75rem;
    line-height: 1;
}

.state-directory__stats span {
    color: #5f4937;
    font-size: 0.84rem;
    font-weight: 700;
}

.state-directory-filter {
    display: grid;
    grid-template-columns: minmax(220px, 1.5fr) repeat(3, minmax(145px, 0.85fr)) auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 18px;
    padding: 18px;
    border: 1px solid rgba(183, 117, 43, 0.18);
    border-radius: 22px;
    background: #fffdf8;
    box-shadow: 0 12px 32px rgba(66, 41, 20, 0.07);
}

.state-directory-filter label {
    display: grid;
    gap: 7px;
    min-width: 0;
    color: #4f3928;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.state-directory-filter input,
.state-directory-filter select,
.state-directory-filter__reset {
    min-height: 48px;
    width: 100%;
    padding: 0 14px;
    border: 1px solid rgba(120, 82, 32, 0.24);
    border-radius: 14px;
    background: #fff;
    color: #2f2419;
    font: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

.state-directory-filter input:focus-visible,
.state-directory-filter select:focus-visible,
.state-directory-filter__reset:focus-visible,
.state-directory-card a:focus-visible,
.state-directory__results a:focus-visible {
    outline: 3px solid #d4943d;
    outline-offset: 3px;
}

.state-directory-filter__reset {
    width: auto;
    min-width: 92px;
    border-color: #9d5e1f;
    background: #a96722;
    color: #fff;
    cursor: pointer;
    font-weight: 800;
}

.state-directory-filter__reset:hover {
    background: #85501b;
}

.state-directory__results {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
    color: #5f4937;
    font-size: 0.9rem;
    font-weight: 700;
}

.state-directory__results p {
    margin: 0;
}

.state-directory__results a {
    color: #8a541b;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.state-directory-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-width: 0;
    padding: 20px;
    border: 1px solid rgba(120, 82, 32, 0.16);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(42, 31, 21, 0.07);
}

.state-directory-card__topline {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 6px 12px;
    margin-bottom: 12px;
    color: #8a541b;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.state-directory-card h3 {
    margin: 0 0 9px;
    overflow-wrap: anywhere;
    color: #2b1e14;
    font-family: var(--temple-font-heading, "Playfair Display", Georgia, serif);
    font-size: 1.16rem;
    line-height: 1.35;
}

.state-directory-card h3 a {
    color: inherit;
}

.state-directory-card__location,
.state-directory-card__deity {
    margin: 0 0 8px;
    color: #5e4938;
    font-size: 0.87rem;
    line-height: 1.55;
}

.state-directory-card__location i {
    margin-right: 5px;
    color: #a96722;
}

.state-directory-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 4px 0 16px;
    padding: 0;
    list-style: none;
}

.state-directory-card__tags li {
    padding: 5px 9px;
    border-radius: 999px;
    background: #fff3df;
    color: #744719;
    font-size: 0.7rem;
    font-weight: 700;
    line-height: 1.25;
}

.state-directory-card__action {
    align-self: flex-start;
    margin-top: auto;
    color: #8a541b;
    font-size: 0.87rem;
    font-weight: 800;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.state-directory-card__action--pending {
    color: #75685d;
    text-decoration: none;
}

.state-directory__empty {
    margin-top: 18px;
    padding: 26px;
    border: 1px solid rgba(120, 82, 32, 0.16);
    border-radius: 20px;
    background: #fff;
    text-align: center;
}

.state-directory__empty h3,
.state-directory__empty p {
    margin: 0;
}

.state-directory__empty p {
    margin-top: 6px;
}

@media (max-width: 1199px) {
    .state-directory-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .state-directory-filter__search {
        grid-column: 1 / -1;
    }

    .state-directory-filter__reset {
        width: 100%;
    }
}

@media (max-width: 767px) {
    .state-directory__stats,
    .state-directory-filter {
        grid-template-columns: 1fr;
    }

    .state-directory-filter__search {
        grid-column: auto;
    }

    .state-directory__results {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 389px) {
    .state-directory__stats {
        gap: 9px;
    }

    .state-directory-filter,
    .state-directory-card {
        padding: 15px;
        border-radius: 16px;
    }

    .state-directory-card__topline {
        flex-direction: column;
    }
}
