:root {
    color-scheme: light;
    --portal-ink: #172033;
    --portal-muted: #657086;
    --portal-line: #e4e8ef;
    --portal-surface: #ffffff;
    --portal-canvas: #f5f7fa;
    --portal-accent: #0f766e;
    --portal-accent-dark: #115e59;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
    margin: 0;
}

body {
    background: var(--portal-canvas);
    color: var(--portal-ink);
    font-family: "Segoe UI", "Microsoft YaHei", sans-serif;
}

.portal-header {
    width: 100%;
    background: var(--portal-surface);
    border-bottom: 1px solid var(--portal-line);
}

.portal-header__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    min-height: 72px;
    width: min(100% - 48px, 1280px);
    margin: 0 auto;
}

.portal-brand {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    gap: 12px;
    color: var(--portal-ink);
    text-decoration: none;
}

.portal-brand__logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.portal-brand__name {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0;
}

.portal-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
}

.portal-nav__link {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 72px;
    color: var(--portal-muted);
    font-size: 0.95rem;
    text-decoration: none;
    transition: color 160ms ease;
}

.portal-nav__link:hover,
.portal-nav__link--active {
    color: var(--portal-accent);
}

.portal-nav__link--active::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    background: var(--portal-accent);
    content: "";
}

.portal-header__actions {
    min-width: 1px;
}

.portal-footer__text {
    margin: 0 auto 0 0;
}

.portal-main {
    width: min(100% - 48px, 1280px);
    margin: 0 auto;
    padding: 96px 0 128px;
}

.portal-intro {
    max-width: 720px;
}

.portal-kicker {
    margin: 0 0 16px;
    color: var(--portal-accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.portal-intro h1 {
    margin: 0;
    color: var(--portal-ink);
    font-size: 4.5rem;
    line-height: 1.05;
}

.portal-intro__text {
    max-width: 600px;
    margin: 24px 0 0;
    color: var(--portal-muted);
    font-size: 1.1rem;
    line-height: 1.8;
}

.portal-primary-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-top: 32px;
    padding: 0 18px;
    border-radius: 6px;
    background: var(--portal-accent);
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 160ms ease;
}

.portal-primary-link:hover {
    background: var(--portal-accent-dark);
}

@media (max-width: 720px) {
    .portal-header__inner,
    .portal-main {
        width: min(100% - 32px, 1280px);
    }

    .portal-header__inner {
        grid-template-columns: 1fr auto;
        gap: 20px;
    }

    .portal-nav {
        grid-column: 1 / -1;
        grid-row: 2;
        justify-content: flex-start;
        gap: 20px;
        overflow-x: auto;
        border-top: 1px solid var(--portal-line);
    }

    .portal-nav__link {
        min-height: 52px;
        white-space: nowrap;
    }

    .portal-main {
        padding-top: 64px;
    }

    .portal-intro h1 {
        font-size: 2.75rem;
    }
}
