/**
 * Shared component UI styles
 * Extracted from component templates to keep presentational rules in one place.
 */

:root {
    --nmh-accent: #ffc03c;
    --nmh-accent-strong: #d97706;
    --nmh-ink: #111827;
    --nmh-copy: #374151;
    --nmh-copy-muted: #4b5563;
    --nmh-subtle: #6b7280;
    --nmh-muted: #9ca3af;
    --nmh-panel: #ffffff;
    --nmh-panel-muted: #f9fafb;
    --nmh-tooltip: #333333;
    --nmh-shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.1);
    --nmh-shadow-md: 0 8px 12px rgba(0, 0, 0, 0.15);
    --nmh-radius-sm: 8px;
    --nmh-radius-md: 12px;
    --nmh-transition-fast: 0.2s ease;
}

.hero-section-cta {
    height: 55vh;
    min-height: 500px;
    background-color: #000000;
    display: flex;
    align-items: center;
    position: relative;
    color: #ffffff;
    overflow: hidden;
}

.hero-background-media-cta {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.hero-overlay-cta {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to right,
        rgba(0, 0, 0, 0.7) 0%,
        rgba(241, 180, 52, 0.6) 70%
    );
    z-index: 2;
}

.hero-content-cta {
    position: relative;
    z-index: 3;
    max-width: 45rem;
}

.hero-subheading-cta {
    font-size: 0.9rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1rem;
}

.hero-heading-cta {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    font-weight: 700;
    line-height: 1.4;
    color: #ffffff;
    max-width: 45rem;
    margin-bottom: 1.5rem;
}

.hero-body-cta {
    font-size: 1.05rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.92);
    max-width: 42rem;
    margin-bottom: 2rem;
}

.btn-mission {
    display: inline-flex;
    align-items: center;
    background-color: rgba(33, 37, 41, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.7);
    color: #ffffff;
    padding: 0.5rem 0.5rem 0.5rem 1.25rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-mission:hover,
.btn-mission:focus-visible {
    background-color: #ffffff;
    color: #000000 !important;
}

.btn-mission:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

.btn-mission i {
    background-color: #ffffff;
    color: #000000;
    border-radius: 50%;
    padding: 0.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 1rem;
    transition: all 0.3s ease;
}

.btn-mission:hover i,
.btn-mission:focus-visible i {
    background-color: #000000;
    color: #ffffff;
}

.nmh-home-feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 18px;
    padding: 44px 20px 56px;
    max-width: 1440px;
    margin: 0 auto;
}

.nmh-home-feature-card {
    background: var(--nmh-panel);
    border: 1px solid #e5e7eb;
    border-radius: 26px;
    padding: 18px 20px 18px;
    min-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform var(--nmh-transition-fast), box-shadow var(--nmh-transition-fast), border-color var(--nmh-transition-fast);
}

.nmh-home-feature-card:hover {
    transform: translateY(-3px);
    border-color: #d1d5db;
    box-shadow: 0 18px 40px rgba(17, 24, 39, 0.06);
}

.nmh-home-feature-icon {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.65rem;
    color: #1f2937;
}

.nmh-home-feature-icon svg {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.nmh-home-feature-title {
    color: #1f2937;
    font-size: clamp(1.2rem, 1.8vw, 1.55rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 0.45rem;
}

.nmh-home-feature-description {
    color: #6b7280;
    line-height: 1.5;
    font-size: 0.92rem;
    max-width: 30ch;
    margin: 0 auto 0.75rem;
}

.nmh-home-feature-card > :last-child {
    margin-bottom: 0;
}

.nmh-home-feature-card--muted {
    background: #fcfcfc;
}

.nmh-home-btn {
    color: #111827;
    padding: 0;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color var(--nmh-transition-fast), transform var(--nmh-transition-fast);
}

.nmh-home-btn:hover,
.nmh-home-btn:focus-visible {
    color: var(--nmh-accent-strong) !important;
    transform: translateY(-1px);
}

.nmh-home-btn:focus-visible {
    outline: 2px solid rgba(217, 119, 6, 0.4);
    outline-offset: 3px;
}

.nmh-home-btn--compact {
    margin-top: auto;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
}

.nmh-home-btn--compact i {
    font-size: 1rem;
}

.nmh-home-status {
    color: #4b5563;
    font-size: 0.82rem;
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0.55rem 0.95rem;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.nmh-home-section {
    padding: 84px 20px;
}

.nmh-home-section--muted {
    background: var(--nmh-panel-muted);
}

.nmh-home-section--overview {
    background: transparent;
}

.main-content-wrapper > .nmh-home-section--overview:last-child {
    padding-bottom: calc(84px + 100px);
    margin-bottom: -100px;
}

.nmh-home-section--story {
    position: relative;
    background:
        url("../images/apri-post-list-bg.webp") center center / cover no-repeat,
        #070707;
    padding-top: 68px;
    padding-bottom: 68px;
    isolation: isolate;
    overflow: hidden;
}

.nmh-home-section--story::before,
.nmh-home-section--story::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
}

.nmh-home-section--story::before {
    background: linear-gradient(
        180deg,
        rgba(7, 7, 7, 0.55) 0%,
        rgba(7, 7, 7, 0.72) 48%,
        rgba(7, 7, 7, 0.82) 100%
    );
}

.nmh-home-section--story::after {
    background: linear-gradient(
        135deg,
        rgba(151, 27, 47, 0.28) 0%,
        rgba(151, 27, 47, 0.08) 24%,
        rgba(255, 192, 60, 0.08) 58%,
        rgba(255, 192, 60, 0) 100%
    );
    mix-blend-mode: screen;
    opacity: 0.7;
    pointer-events: none;
}

.nmh-home-copy {
    max-width: 800px;
    margin: 0 auto;
}

.nmh-home-story {
    position: relative;
    z-index: 1;
    max-width: 960px;
    margin: 0 auto;
}

.nmh-home-overview {
    position: relative;
    z-index: 1;
    max-width: 1240px;
    margin: 0 auto;
}

.nmh-home-overview-header {
    text-align: center;
    max-width: 760px;
    margin: 0 auto 44px;
}

.nmh-home-story-shell {
    max-width: 820px;
    margin: 0 auto;
}

.nmh-home-story-intro {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    max-width: 620px;
    margin: 0 auto 28px;
}

.nmh-home-story-content {
    max-width: 760px;
    margin: 0 auto;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.nmh-home-kicker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.95rem;
    margin-bottom: 1rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.08);
    color: #f5d48a;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.nmh-home-kicker--light {
    border-color: #ead7a3;
    background: #fff4cf;
    color: #971b2f;
}

.nmh-home-section-title {
    text-align: center;
    margin-bottom: 0;
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.nmh-home-section-title--story {
    color: #ffffff;
    text-align: center;
    font-size: clamp(2rem, 3vw, 2.8rem);
    line-height: 1.02;
    max-width: 14ch;
}

.nmh-home-section-title--wide {
    margin-bottom: 0;
}

.nmh-home-stat-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 46px;
    height: 32px;
    padding: 0 0.8rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.nmh-home-body-text {
    line-height: 1.8;
    color: var(--nmh-copy-muted);
    text-align: left;
    margin: 0;
    font-size: 1.02rem;
}

.nmh-home-body-text--story {
    color: rgba(255, 255, 255, 0.84);
    font-size: 1rem;
    line-height: 1.85;
    max-width: none;
}

.nmh-home-body-text + .nmh-home-body-text {
    margin-top: 1.5rem;
}

.nmh-home-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.nmh-home-section--overview .nmh-home-overview-header {
    margin-bottom: 38px;
}

.nmh-home-section--overview .nmh-home-section-title--wide {
    color: #21141a;
}

.nmh-home-stat {
    padding: 34px 30px;
    border-radius: 28px;
    border: 1px solid #ece7db;
    background: linear-gradient(180deg, #ffffff 0%, #fbfaf7 100%);
    text-align: left;
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.05);
}

.nmh-home-section--overview .nmh-home-stat {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 208px;
    padding: 36px 30px;
    border-color: rgba(151, 27, 47, 0.14);
    background: linear-gradient(180deg, #fcf8f9 0%, #f7eef1 100%);
    box-shadow: 0 16px 34px rgba(151, 27, 47, 0.05);
}

.nmh-home-section--overview .nmh-home-stat:hover {
    border-color: rgba(151, 27, 47, 0.28);
    background: linear-gradient(180deg, #fdf9fa 0%, #f5e9ee 100%);
    box-shadow: 0 18px 36px rgba(151, 27, 47, 0.08);
}

.nmh-home-stat-index {
    margin-bottom: 1.4rem;
    border: 1px solid #f1dfb4;
    background: #fff8e7;
    color: #9a6708;
}

.nmh-home-section--overview .nmh-home-stat-index {
    margin-bottom: 1.1rem;
    border-color: #ead7a3;
    background: #fff4cf;
    color: #971b2f;
}

.nmh-home-stat-value {
    font-size: clamp(3rem, 6vw, 4.5rem);
    font-weight: 700;
    color: #111827;
    line-height: 0.95;
    letter-spacing: -0.05em;
}

.nmh-home-section--overview .nmh-home-stat-value {
    color: #971b2f;
}

.nmh-home-stat-label {
    color: #4b5563;
    margin-top: 0.9rem;
    font-size: 1rem;
    font-weight: 600;
}

.nmh-home-section--overview .nmh-home-stat-label {
    color: #4a2a33;
}

@media (max-width: 767px) {
    .hero-section-cta {
        min-height: 460px;
    }

    .nmh-home-feature-grid,
    .nmh-home-section {
        padding-left: 16px;
        padding-right: 16px;
    }

    .nmh-home-section {
        padding-top: 64px;
        padding-bottom: 64px;
    }

    .main-content-wrapper > .nmh-home-section--overview:last-child {
        padding-bottom: calc(64px + 100px);
    }

    .nmh-home-story-shell {
    }

    .nmh-home-story-intro {
        justify-content: flex-start;
        margin-bottom: 24px;
    }

    .nmh-home-feature-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .nmh-home-feature-card {
        padding: 18px 18px 16px;
    }

    .nmh-home-stat-value {
        font-size: 2.5rem;
    }

    .nmh-home-section--overview .nmh-home-stat {
        min-height: 182px;
        padding: 30px 24px;
    }

}

@media (max-width: 991px) {
    .nmh-home-stats-grid {
        grid-template-columns: 1fr;
    }

    .nmh-home-story-intro {
        justify-content: flex-start;
        max-width: none;
    }

    .nmh-home-story-shell,
    .nmh-home-story-content {
        max-width: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .nmh-home-feature-card,
    .nmh-home-btn,
    .btn-mission,
    .btn-mission i {
        transition: none;
    }

    .nmh-home-feature-card:hover,
    .nmh-home-btn:hover,
    .nmh-home-btn:focus-visible,
    .btn-mission:hover,
    .btn-mission:focus-visible {
        transform: none;
    }
}
