:root {
    color-scheme: light;
    --ink: #183b34;
    --muted: #65746e;
    --paper: #f3f6f1;
    --surface: #ffffff;
    --line: #d7e0d8;
    --green: #286352;
    --lime: #d7f36a;
    --coral: #dd684e;
    --danger: #a63f32;
    font-family: "DM Sans", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--paper);
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    color: var(--ink);
    background-color: var(--paper);
    background-image: linear-gradient(rgba(40, 99, 82, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(40, 99, 82, 0.035) 1px, transparent 1px);
    background-size: 32px 32px;
}

a {
    color: inherit;
}

button,
textarea {
    font: inherit;
}

button:focus-visible,
a:focus-visible,
textarea:focus-visible {
    outline: 3px solid var(--coral);
    outline-offset: 3px;
}

.app-frame {
    min-height: 100vh;
}

.app-main {
    width: 100%;
}

.site-header {
    min-height: 78px;
    padding: 0 max(28px, calc((100vw - 1160px) / 2));
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.9);
}

.wordmark {
    color: var(--ink);
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    font-size: 25px;
    font-weight: 700;
    text-decoration: none;
}

.wordmark span {
    color: var(--coral);
}

.primary-nav {
    display: flex;
    align-items: center;
    gap: 30px;
    font-size: 14px;
}

.primary-nav a,
.signout-link {
    text-decoration: none;
}

.primary-nav a:hover,
.signout-link:hover {
    color: var(--green);
}

.primary-nav a.active {
    color: var(--green);
    text-decoration: underline;
    text-decoration-color: var(--coral);
    text-underline-offset: 6px;
}

.signout-form {
    margin: 0;
}

.signout-link {
    padding: 0;
    color: var(--ink);
    border: 0;
    background: transparent;
    cursor: pointer;
}

.signin-link {
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 4px;
}

.home-shell,
.content-page {
    width: min(100% - 56px, 1000px);
    margin-inline: auto;
}

.home-shell {
    padding: 78px 0 32px;
}

.intro {
    max-width: 770px;
    padding: 14px 0 70px;
}

.eyebrow {
    margin: 0 0 22px;
    color: var(--green);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

.intro h1 {
    margin-bottom: 22px;
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    font-size: 64px;
    font-weight: 600;
    line-height: 1.02;
}

.intro h1 span {
    color: var(--green);
}

.intro-copy,
.page-intro {
    max-width: 540px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.65;
}

.section-heading,
.claims-heading {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 8px;
}

.section-heading h2,
.claims-heading h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
}

.section-rule {
    height: 1px;
    flex: 1;
    background: var(--line);
}

.directory-list {
    border-top: 1px solid var(--line);
}

.directory-item {
    min-height: 84px;
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(130px, 0.8fr) 30px;
    align-items: center;
    gap: 20px;
    padding: 18px 14px;
    border-bottom: 1px solid var(--line);
    text-decoration: none;
    transition: background-color 150ms ease, padding 150ms ease;
}

.directory-item:hover {
    padding-inline: 20px 8px;
    background: rgba(255, 255, 255, 0.8);
}

.directory-name {
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    font-size: 20px;
    font-weight: 600;
}

.directory-url,
.empty-directory {
    color: var(--muted);
    font-size: 14px;
}

.directory-arrow {
    color: var(--green);
    font-size: 22px;
    text-align: right;
}

.empty-directory {
    margin: 0;
    padding: 25px 14px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.site-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 74px;
    padding-top: 18px;
    color: var(--muted);
    border-top: 1px solid var(--line);
    font-size: 12px;
}

.site-footer a {
    text-decoration: none;
}

.content-page {
    max-width: 860px;
    padding: 72px 0 100px;
}

.content-page > h1 {
    margin-bottom: 12px;
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    font-size: 48px;
    font-weight: 600;
}

.identity-summary {
    display: flex;
    align-items: center;
    gap: 18px;
    margin: 42px 0 45px;
    padding: 22px;
    border-left: 5px solid var(--lime);
    background: var(--surface);
}

.identity-mark {
    width: 52px;
    height: 52px;
    display: grid;
    flex: 0 0 52px;
    place-items: center;
    border-radius: 50%;
    color: var(--ink);
    background: var(--lime);
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    font-size: 22px;
    font-weight: 700;
}

.identity-summary h2 {
    margin: 0 0 5px;
    font-size: 18px;
}

.identity-summary p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.claims-heading {
    justify-content: space-between;
    margin-bottom: 12px;
}

.claims-heading span {
    color: var(--muted);
    font-size: 13px;
}

.claims-list {
    margin: 0;
    border-top: 1px solid var(--line);
}

.claim-row {
    display: grid;
    grid-template-columns: minmax(170px, 0.65fr) minmax(0, 1.35fr);
    gap: 24px;
    padding: 15px 4px;
    border-bottom: 1px solid var(--line);
    font-size: 14px;
}

.claim-row dt {
    color: var(--muted);
    overflow-wrap: anywhere;
}

.claim-row dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.note-form {
    margin: 38px 0 42px;
    padding: 24px;
    border: 1px solid var(--line);
    background: var(--surface);
}

.note-form label {
    display: block;
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 700;
}

.note-form textarea {
    width: 100%;
    min-height: 112px;
    resize: vertical;
    padding: 12px;
    border: 1px solid #afbeb2;
    border-radius: 3px;
    color: var(--ink);
    background: #fbfcfa;
}

.form-footer {
    min-height: 45px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
    margin-top: 12px;
}

.validation-message,
.error-notice {
    color: var(--danger);
}

.action-button {
    min-height: 42px;
    padding: 0 16px;
    border: 0;
    border-radius: 4px;
    color: var(--ink);
    background: var(--lime);
    font-weight: 700;
    cursor: pointer;
}

.action-button:disabled {
    cursor: wait;
    opacity: 0.7;
}

.note-list {
    border-top: 1px solid var(--line);
}

.note-item {
    margin: 0;
    padding: 21px 14px;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.62);
}

.note-item > p {
    margin-bottom: 18px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.note-item footer {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    color: var(--muted);
    font-size: 12px;
}

.notice {
    display: grid;
    gap: 5px;
    margin-top: 36px;
    padding: 18px 20px;
    border-left: 4px solid var(--coral);
    background: var(--surface);
    color: var(--muted);
    font-size: 14px;
}

.notice strong {
    color: var(--ink);
}

.route-status {
    width: min(100% - 56px, 1000px);
    margin: 60px auto;
    color: var(--muted);
}

#blazor-error-ui {
    display: none;
    position: fixed;
    z-index: 10;
    right: 16px;
    bottom: 16px;
    max-width: calc(100vw - 32px);
    padding: 14px 18px;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface);
    box-shadow: 0 8px 28px rgba(24, 59, 52, 0.15);
}

#blazor-error-ui .reload {
    margin-left: 8px;
    color: var(--green);
}

#blazor-error-ui .dismiss {
    margin-left: 8px;
    cursor: pointer;
}

@media (max-width: 640px) {
    .site-header {
        min-height: 68px;
        padding-inline: 20px;
    }

    .primary-nav {
        gap: 14px;
        font-size: 12px;
    }

    .home-shell,
    .content-page {
        width: min(100% - 40px, 1000px);
    }

    .home-shell {
        padding-top: 50px;
    }

    .intro {
        padding-bottom: 52px;
    }

    .intro h1 {
        font-size: 46px;
    }

    .intro-copy,
    .page-intro {
        font-size: 15px;
    }

    .directory-item {
        grid-template-columns: minmax(0, 1fr) 26px;
        gap: 7px 12px;
        padding-inline: 8px;
    }

    .directory-name {
        font-size: 18px;
    }

    .directory-url {
        grid-column: 1;
        grid-row: 2;
    }

    .directory-arrow {
        grid-column: 2;
        grid-row: 1 / span 2;
    }

    .site-footer {
        margin-top: 56px;
    }

    .content-page {
        padding-top: 52px;
    }

    .content-page > h1 {
        font-size: 38px;
    }

    .claim-row {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .note-form {
        padding: 17px;
    }
}

@media (max-width: 360px) {
    .site-header {
        padding-inline: 14px;
    }

    .wordmark {
        font-size: 21px;
    }

    .primary-nav {
        gap: 9px;
        font-size: 11px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}