:root {
    --bg: #f4efe6;
    --surface: rgba(255, 252, 246, 0.88);
    --surface-strong: #fff9ef;
    --text: #0d1813;
    --muted: #5d6c63;
    --line: rgba(13, 24, 19, 0.08);
    --green: #356b4b;
    --green-deep: #163527;
    --gold: #f3a637;
    --coral: #d86644;
    --shadow: 0 18px 50px rgba(27, 50, 38, 0.12);
    --radius: 28px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(243, 166, 55, 0.22), transparent 28%),
        radial-gradient(circle at right 20%, rgba(53, 107, 75, 0.2), transparent 24%),
        linear-gradient(180deg, #f7f1e8 0%, #efe7da 100%);
}

img {
    max-width: 100%;
    display: block;
}

.page-shell {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 24px 0 48px;
}

.hero,
.section,
.admin-card {
    border: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.hero {
    position: relative;
    overflow: hidden;
    border-radius: 36px;
    padding: 26px;
}

.hero::after {
    content: '';
    position: absolute;
    inset: auto -80px -120px auto;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(243, 166, 55, 0.28), transparent 68%);
}

.topbar,
.hero-grid,
.form-grid,
.form-actions,
.admin-header,
.list-header {
    display: flex;
    gap: 18px;
}

.topbar,
.admin-header,
.list-header {
    align-items: center;
    justify-content: space-between;
}

.brand-lockup {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.nova-logo {
    width: clamp(120px, 15vw, 170px);
    opacity: 0.92;
}

.brand-logo {
    width: min(340px, 62vw);
}

.admin-link {
    color: var(--green-deep);
    text-decoration: none;
    font-weight: 700;
}

.hero-grid {
    margin-top: 28px;
    align-items: stretch;
}

.hero-copy,
.hero-panel {
    flex: 1;
}

.hero-copy {
    padding: 10px 4px 10px 0;
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--green);
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    margin: 0;
    font-family: 'Sora', sans-serif;
    line-height: 1.05;
}

h1 {
    max-width: 12ch;
    font-size: clamp(2.6rem, 5vw, 4.8rem);
}

h2 {
    max-width: 16ch;
    font-size: clamp(1.8rem, 3vw, 3rem);
}

.hero-text,
.section-heading p,
.map-panel-card p,
.hero-stat-card p,
.admin-card p {
    color: var(--muted);
    line-height: 1.65;
}

.hero-actions {
    margin: 28px 0 24px;
}

.button {
    border: 0;
    border-radius: 999px;
    padding: 14px 22px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.button:hover {
    transform: translateY(-1px);
}

.button.primary {
    color: #fff;
    background: linear-gradient(135deg, var(--green) 0%, var(--green-deep) 100%);
    box-shadow: 0 14px 28px rgba(22, 53, 39, 0.22);
}

.button.ghost {
    color: var(--green-deep);
    background: rgba(255, 255, 255, 0.66);
    border: 1px solid rgba(22, 53, 39, 0.12);
}

.hero-points {
    display: grid;
    gap: 10px;
    padding: 0;
    margin: 0;
    list-style: none;
}

.hero-points li,
.map-panel-card,
.hero-stat-card,
.result-card,
.admin-group-card {
    border-radius: 24px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.7);
}

.hero-points li {
    padding: 12px 16px;
    font-weight: 700;
}

.hero-panel {
    display: grid;
    gap: 16px;
}

.hero-visual-card {
    min-height: 240px;
    padding: 18px;
    border-radius: 28px;
    border: 1px solid var(--line);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.78), rgba(255, 243, 226, 0.92)),
        radial-gradient(circle at top left, rgba(216, 102, 68, 0.18), transparent 40%);
}

.hero-visual-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.hero-stat-card {
    padding: 22px;
}

.hero-stat-card span,
.result-card .pill,
.admin-group-card .pill {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(53, 107, 75, 0.12);
    color: var(--green-deep);
    font-size: 0.8rem;
    font-weight: 800;
}

.hero-stat-card.accent {
    background: linear-gradient(135deg, rgba(243, 166, 55, 0.2), rgba(216, 102, 68, 0.12));
}

.section {
    margin-top: 24px;
    border-radius: var(--radius);
    padding: 26px;
}

.section-heading.compact {
    margin-bottom: 22px;
}

.story-heading,
.roles-heading,
.recommendation-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
}

.story-heading > p,
.recommendation-heading > p {
    max-width: 520px;
}

.story-grid,
.roles-grid {
    display: grid;
    gap: 18px;
    margin-top: 24px;
}

.story-grid {
    grid-template-columns: 1.3fr 1fr 1fr;
}

.roles-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.story-card,
.role-card {
    border: 1px solid var(--line);
    border-radius: 26px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.7);
}

.story-card.emphasis {
    background: linear-gradient(135deg, rgba(22, 53, 39, 0.95), rgba(53, 107, 75, 0.92));
    color: #fdfaf4;
}

.story-card.emphasis p {
    color: rgba(255, 249, 239, 0.84);
}

.pill-like,
.role-index {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.pill-like {
    background: rgba(53, 107, 75, 0.12);
    color: var(--green-deep);
}

.story-card.emphasis .pill-like {
    background: rgba(255, 255, 255, 0.12);
    color: #fff9ef;
}

.role-index {
    color: var(--coral);
    background: rgba(216, 102, 68, 0.12);
}

.role-card h3,
.story-card p {
    margin-top: 16px;
}

.role-card p {
    color: var(--muted);
    line-height: 1.65;
}

.map-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.9fr);
    gap: 20px;
    margin-top: 24px;
    align-items: stretch;
}

#map {
    min-height: 560px;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid var(--line);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.map-panel,
.results-list,
.admin-groups-list {
    display: grid;
    gap: 14px;
}

.map-panel {
    align-content: start;
}

.map-panel-card,
.result-card,
.admin-group-card,
.admin-card {
    padding: 18px;
}

.map-panel-intro {
    padding: 22px;
    background:
        linear-gradient(160deg, rgba(255, 255, 255, 0.88), rgba(255, 245, 232, 0.95)),
        radial-gradient(circle at top right, rgba(53, 107, 75, 0.14), transparent 38%);
}

.map-panel-intro h3 {
    margin-top: 14px;
    font-size: 1.4rem;
}

.unit-highlights {
    display: grid;
    gap: 12px;
}

.unit-highlight-card {
    width: 100%;
    display: grid;
    gap: 6px;
    padding: 18px;
    text-align: left;
    border-radius: 22px;
    border: 1px solid rgba(13, 24, 19, 0.08);
    background: rgba(255, 255, 255, 0.78);
    color: var(--text);
    cursor: pointer;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.unit-highlight-card:hover {
    transform: translateY(-2px);
    border-color: rgba(53, 107, 75, 0.26);
    box-shadow: 0 14px 30px rgba(22, 53, 39, 0.1);
}

.unit-highlight-card.is-main {
    background: linear-gradient(145deg, rgba(22, 53, 39, 0.94), rgba(53, 107, 75, 0.9));
    color: #fff9ef;
}

.unit-highlight-city,
.unit-highlight-address,
.unit-highlight-schedule {
    color: var(--muted);
}

.unit-highlight-card.is-main .unit-highlight-city,
.unit-highlight-card.is-main .unit-highlight-address,
.unit-highlight-card.is-main .unit-highlight-schedule {
    color: rgba(255, 249, 239, 0.8);
}

.unit-highlight-card strong {
    font-family: 'Sora', sans-serif;
    font-size: 1.02rem;
}

.recommendation-section.is-hidden {
    display: none;
}

.recommendation-layout {
    display: grid;
    grid-template-columns: 1.3fr 0.9fr;
    gap: 18px;
    margin-top: 24px;
}

.recommendation-spotlight,
.recommendation-alt-card,
.admin-hero,
.admin-summary-card {
    border: 1px solid var(--line);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.72);
}

.recommendation-spotlight {
    padding: 28px;
    background: linear-gradient(135deg, rgba(22, 53, 39, 0.96), rgba(53, 107, 75, 0.9));
    color: #fff9ef;
}

.recommendation-spotlight h3 {
    margin-top: 16px;
    font-size: clamp(1.8rem, 2.5vw, 2.5rem);
}

.recommendation-spotlight p {
    color: rgba(255, 249, 239, 0.84);
    line-height: 1.65;
}

.recommendation-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin: 24px 0;
}

.recommendation-metrics div {
    padding: 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.09);
}

.recommendation-metrics strong {
    display: block;
    font-family: 'Sora', sans-serif;
    font-size: 1.2rem;
}

.recommendation-metrics span {
    display: block;
    margin-top: 6px;
    color: rgba(255, 249, 239, 0.72);
    font-size: 0.92rem;
}

.recommendation-contact {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 20px;
}

.recommendation-side {
    display: grid;
    gap: 14px;
}

.recommendation-alt-card {
    padding: 20px;
}

.recommendation-alt-card h3 {
    margin: 14px 0 8px;
}

.result-card h3,
.admin-group-card h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.result-meta,
.admin-meta {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-size: 0.95rem;
}

.gc-form {
    display: grid;
    gap: 18px;
}

.form-grid {
    flex-wrap: wrap;
}

.form-grid.two > label {
    flex: 1 1 calc(50% - 9px);
}

.form-grid.three > label {
    flex: 1 1 calc(33.333% - 12px);
}

.form-grid.four > label {
    flex: 1 1 calc(25% - 14px);
}

.gc-form label {
    display: grid;
    gap: 8px;
    color: var(--green-deep);
    font-weight: 700;
}

.inline-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
}

.inline-button {
    white-space: nowrap;
    padding-inline: 18px;
}

.gc-form input,
.gc-form select,
.gc-form textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid rgba(13, 24, 19, 0.12);
    background: rgba(255, 255, 255, 0.78);
    font: inherit;
    color: var(--text);
}

.inline-checks {
    display: grid;
    gap: 14px;
}

.check-row {
    grid-template-columns: auto 1fr;
    align-items: start;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.72);
}

.check-row input {
    width: 18px;
    height: 18px;
    margin-top: 3px;
}

.form-feedback {
    min-height: 24px;
    margin: 0;
    font-weight: 700;
}

.form-feedback.is-error {
    color: #b2342b;
}

.form-feedback.is-success {
    color: var(--green);
}

.nova-unit-marker-wrapper {
    background: transparent;
    border: 0;
}

.nova-unit-marker {
    position: relative;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nova-unit-marker-pulse,
.nova-unit-marker-core {
    position: absolute;
    border-radius: 999px;
}

.nova-unit-marker-pulse {
    inset: 6px;
    background: rgba(53, 107, 75, 0.18);
    animation: novaPulse 2.2s ease-out infinite;
}

.nova-unit-marker-core {
    inset: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Sora', sans-serif;
    font-size: 0.92rem;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(145deg, var(--green), var(--green-deep));
    border: 3px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 14px 26px rgba(22, 53, 39, 0.28);
}

.nova-unit-marker.is-main .nova-unit-marker-pulse {
    background: rgba(243, 166, 55, 0.24);
}

.nova-unit-marker.is-main .nova-unit-marker-core {
    background: linear-gradient(145deg, var(--gold), var(--coral));
}

.nova-unit-tooltip {
    border: 1px solid rgba(13, 24, 19, 0.08);
    border-radius: 999px;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--green-deep);
    font-family: 'Sora', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
}

@keyframes novaPulse {
    0% {
        transform: scale(0.88);
        opacity: 0.86;
    }

    100% {
        transform: scale(1.28);
        opacity: 0;
    }
}

.nova-unit-popup {
    min-width: 220px;
    line-height: 1.55;
}

.nova-unit-popup strong {
    display: inline-block;
    margin-bottom: 6px;
    color: var(--green-deep);
}

.admin-hero {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 22px;
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.admin-brand-lockup {
    margin-bottom: 14px;
}

.admin-brand-logo {
    width: min(320px, 54vw);
}

.admin-hero-text {
    max-width: 56ch;
    color: var(--muted);
    line-height: 1.7;
}

.admin-summary-grid {
    display: grid;
    gap: 14px;
}

.admin-summary-card {
    padding: 20px;
}

.admin-summary-card span {
    display: block;
    color: var(--green);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.admin-summary-card strong {
    display: block;
    margin: 10px 0 8px;
    font-family: 'Sora', sans-serif;
    font-size: clamp(2rem, 3vw, 2.8rem);
}

.admin-summary-card p {
    margin: 0;
}

.admin-summary-card.accent {
    background: linear-gradient(135deg, rgba(243, 166, 55, 0.2), rgba(255, 255, 255, 0.82));
}

.admin-summary-card.dark {
    background: linear-gradient(135deg, rgba(22, 53, 39, 0.94), rgba(37, 77, 58, 0.92));
    color: #fff9ef;
}

.admin-summary-card.dark span,
.admin-summary-card.dark p {
    color: rgba(255, 249, 239, 0.82);
}

.admin-body {
    min-height: 100vh;
}

.admin-header-actions {
    display: flex;
    gap: 12px;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.admin-shell {
    padding-top: 32px;
}

.admin-card.full-span {
    grid-column: 1 / -1;
}

.compact-form {
    margin-top: 18px;
}

.login-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    width: min(520px, 100%);
}

.admin-check {
    display: flex;
    align-items: center;
}

.empty-state {
    padding: 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px dashed rgba(13, 24, 19, 0.12);
    color: var(--muted);
}

@media (max-width: 960px) {
    .hero-grid,
    .admin-grid,
    .topbar,
    .admin-header,
    .list-header,
    .story-heading,
    .roles-heading,
    .recommendation-heading,
    .recommendation-contact {
        flex-direction: column;
        display: flex;
    }

    .admin-grid {
        display: flex;
    }

    .map-layout,
    .story-grid,
    .roles-grid,
    .recommendation-layout,
    .admin-hero {
        grid-template-columns: 1fr;
    }

    .form-grid.two > label,
    .form-grid.three > label,
    .form-grid.four > label {
        flex-basis: 100%;
    }

    #map {
        min-height: 380px;
    }

    .brand-logo {
        width: min(300px, 80vw);
    }

    .recommendation-metrics {
        grid-template-columns: 1fr;
    }

    .inline-field {
        grid-template-columns: 1fr;
    }
}