:root {
    --page: #f4f4f2;
    --card: #ffffff;
    --ink: #171819;
    --muted: #73767c;
    --line: #e5e5e2;
    --soft: #f8f8f6;
    --black: #1d1e20;
    --yellow: #a56a00;
    --yellow-bg: #fff7df;
    --green: #177844;
    --green-bg: #edf8f1;
    --red: #b42318;
    --red-bg: #fff1ef;
    --blue: #315f9f;
    --blue-bg: #f0f5fc;
    --radius: 8px;
}

* {
    box-sizing: border-box;
}

html {
    background: var(--page);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: var(--page);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    font-size: 15px;
    line-height: 1.6;
}

button,
input,
select,
textarea {
    color: inherit;
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    cursor: pointer;
}

a {
    color: inherit;
    text-decoration: none;
}

img,
video {
    display: block;
    max-width: 100%;
}

[hidden] {
    display: none !important;
}

.site-shell {
    width: min(760px, calc(100% - 28px));
    margin: 0 auto;
    padding: 46px 0 28px;
}

.entry-shell {
    display: flex;
    min-height: 100vh;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 28px;
}

.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 1px 2px rgba(20, 21, 23, 0.03);
}

.entry-card {
    width: min(430px, 100%);
    padding: 34px 32px 28px;
    text-align: center;
}

.intro-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.8fr);
    gap: 28px;
    align-items: center;
    margin-bottom: 14px;
    padding: 28px;
}

.intro-card .brand-mark {
    margin: 0 0 18px;
}

.intro-card .lead {
    margin-bottom: 0;
}

.intro-card .code-form {
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--soft);
}

.intro-card > .text-button {
    grid-column: 1 / -1;
    justify-self: center;
    margin-top: -8px;
}

.brand-mark {
    display: grid;
    width: 46px;
    height: 46px;
    margin: 0 auto 20px;
    place-items: center;
    border-radius: 8px;
    background: var(--black);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
}

.eyebrow {
    margin: 0 0 8px;
    color: #9a9c9f;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

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

h1 {
    margin-bottom: 11px;
    font-size: 25px;
    line-height: 1.3;
    letter-spacing: 0;
}

.lead {
    margin-bottom: 26px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.7;
}

.code-form {
    text-align: left;
}

.code-form label,
.field label {
    display: block;
    margin-bottom: 8px;
    color: #4e5155;
    font-size: 12px;
    font-weight: 600;
}

.code-form input {
    width: 100%;
    height: 52px;
    margin-bottom: 12px;
    padding: 0 15px;
    border: 1px solid #d9d9d6;
    border-radius: 7px;
    outline: none;
    background: #fff;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-align: center;
    text-transform: uppercase;
}

.code-form input:focus {
    border-color: #1d1e20;
}

.button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    border: 1px solid #d7d7d4;
    border-radius: 7px;
    background: #fff;
    color: var(--ink);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
}

.button:active {
    transform: translateY(1px);
}

.button-primary {
    border-color: var(--black);
    background: var(--black);
    color: #fff;
}

.button-secondary {
    background: #fff;
    color: #303236;
}

.button-quiet {
    min-height: 34px;
    padding: 0 11px;
    border-color: #dededb;
    background: #f8f8f6;
    font-size: 12px;
}

.button-wide {
    width: 100%;
}

.text-button {
    margin-top: 18px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #676a6e;
    font-size: 12px;
}

.site-footer {
    margin: 18px 0 0;
    color: #9b9d9f;
    font-size: 11px;
    text-align: center;
}

.notice {
    margin-bottom: 14px;
    padding: 15px 17px;
    border: 1px solid #ead8a8;
    border-radius: var(--radius);
    background: var(--yellow-bg);
    color: #74511a;
    font-size: 12px;
    line-height: 1.75;
    text-align: center;
}

.notice-lock {
    border-color: #cfd8e8;
    background: #f2f6fb;
    color: #405b7d;
}

.section-card {
    margin-bottom: 14px;
    overflow: hidden;
}

.section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 19px 20px 16px;
    border-bottom: 1px solid var(--line);
}

.section-kicker {
    margin: 0 0 4px;
    color: #96989c;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.section-title {
    margin: 0;
    font-size: 18px;
    line-height: 1.4;
    letter-spacing: 0;
}

.section-note {
    color: #8c8f93;
    font-size: 11px;
    white-space: nowrap;
}

.section-body {
    padding: 20px;
}

.video-frame {
    position: relative;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 16 / 9;
    border: 1px solid #dededb;
    border-radius: 7px;
    background: #ececea;
}

.video-frame video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #171819;
}

.video-placeholder {
    display: grid;
    width: 100%;
    height: 100%;
    place-items: center;
    color: #85878a;
    font-size: 13px;
}

.download-note {
    margin: 0 0 16px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.75;
}

.app-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--soft);
}

.app-icon {
    display: grid;
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    place-items: center;
    overflow: hidden;
    border-radius: 8px;
    background: #e9e8e4;
    color: #52545a;
    font-size: 21px;
    font-weight: 700;
}

.app-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-info {
    min-width: 0;
    flex: 1;
}

.app-name {
    overflow-wrap: anywhere;
    font-size: 15px;
    font-weight: 650;
}

.app-meta {
    margin-top: 2px;
    color: #929498;
    font-size: 11px;
}

.app-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    justify-content: flex-end;
}

.download-hint {
    min-height: 20px;
    margin: 12px 0 0;
    color: #8a8d91;
    font-size: 11px;
    line-height: 1.7;
}

.account-gate {
    padding: 2px 0 0;
}

.account-gate .button {
    min-height: 50px;
    font-size: 14px;
}

.account-stack {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.account-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
}

.account-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
    background: #fafaf8;
    color: #6f7175;
    font-size: 11px;
    font-weight: 600;
}

.limit-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-bottom: 1px solid var(--line);
}

.limit-item {
    padding: 14px;
}

.limit-item + .limit-item {
    border-left: 1px solid var(--line);
}

.limit-label {
    color: #96989b;
    font-size: 10px;
}

.limit-value {
    margin-top: 3px;
    font-size: 16px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.credential-row {
    display: grid;
    grid-template-columns: 50px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    margin: 0 14px;
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
}

.credential-label {
    color: #8a8d91;
    font-size: 12px;
}

.credential-value {
    min-width: 0;
    overflow-wrap: anywhere;
    user-select: all;
    font-size: 14px;
    font-weight: 550;
}

.verify-card {
    margin: 14px;
    padding: 17px 14px 14px;
    border: 1px solid #dededb;
    border-radius: 7px;
    background: #fafaf8;
    text-align: center;
}

.verify-head {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-size: 12px;
    font-weight: 650;
}

.verify-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #2f9b60;
}

.verify-tip {
    margin: 6px 0 0;
    color: #8b8d91;
    font-size: 11px;
}

.verify-code {
    min-height: 38px;
    margin: 10px 0 6px;
    font-size: 30px;
    font-weight: 750;
    line-height: 1.2;
    letter-spacing: 0.15em;
    font-variant-numeric: tabular-nums;
}

.verify-foot {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    color: #9a9c9f;
    font-size: 10px;
}

.guide-grid {
    display: grid;
    gap: 10px;
}

.guide-image {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 7px;
}

.guide-step {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 13px 14px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fafaf8;
}

.guide-number {
    display: grid;
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    place-items: center;
    border-radius: 50%;
    background: #1e1f21;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
}

.guide-copy {
    color: #5f6266;
    font-size: 12px;
    line-height: 1.7;
}

.auth-card {
    margin-bottom: 16px;
    padding: 24px 20px;
    border: 1px solid #ead7a5;
    border-radius: var(--radius);
    background: #fff9e9;
}

.auth-tag {
    display: inline-block;
    margin-bottom: 14px;
    padding: 4px 8px;
    border-radius: 4px;
    background: #f2d98f;
    color: #433311;
    font-size: 11px;
    font-weight: 700;
}

.auth-card h2 {
    margin-bottom: 10px;
    font-size: 19px;
    line-height: 1.5;
}

.auth-card p {
    margin-bottom: 16px;
    color: #6b572f;
    font-size: 13px;
    line-height: 1.8;
}

.auth-flow {
    display: flex;
    align-items: center;
    gap: 7px;
}

.auth-flow span {
    flex: 1;
    padding: 8px 6px;
    border: 1px solid #e5cf9d;
    border-radius: 5px;
    background: #fffdf7;
    color: #4e4023;
    font-size: 10px;
    text-align: center;
}

.auth-flow i {
    font-style: normal;
    color: #8d7545;
}

.expired-shell {
    display: flex;
    min-height: 100vh;
    align-items: center;
    justify-content: center;
    padding: 24px 14px;
}

.expired-card {
    width: min(430px, 100%);
    padding: 32px 28px 27px;
    text-align: center;
}

.status-icon {
    display: grid;
    width: 52px;
    height: 52px;
    margin: 0 auto 18px;
    place-items: center;
    border-radius: 50%;
    background: var(--red-bg);
    color: var(--red);
    font-size: 22px;
    font-weight: 700;
}

.expired-card h1 {
    margin-bottom: 9px;
    font-size: 23px;
}

.expired-card p {
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 13px;
}

.contact-value {
    margin: 14px 0;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--soft);
    font-size: 16px;
    font-weight: 700;
    user-select: all;
    overflow-wrap: anywhere;
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: grid;
    padding: 20px;
    place-items: center;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(23, 24, 25, 0.35);
}

.modal-panel {
    position: relative;
    width: min(360px, 100%);
    padding: 23px;
    border: 1px solid #dededb;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 55px rgba(18, 19, 21, 0.16);
}

.modal-panel h2 {
    margin-bottom: 9px;
    font-size: 18px;
}

.modal-panel p {
    margin-bottom: 20px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.75;
    overflow-wrap: anywhere;
}

.toast {
    position: fixed;
    bottom: max(26px, env(safe-area-inset-bottom));
    left: 50%;
    z-index: 200;
    max-width: calc(100% - 32px);
    padding: 10px 16px;
    border-radius: 6px;
    background: #222325;
    color: #fff;
    font-size: 12px;
    text-align: center;
    transform: translateX(-50%);
}

@media (max-width: 680px) {
    .site-shell {
        width: calc(100% - 20px);
        padding-top: 22px;
    }

    .entry-shell {
        padding-top: 18px;
    }

    .entry-card {
        padding: 29px 20px 24px;
    }

    .intro-card {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 22px 18px;
    }

    .intro-card .brand-mark {
        margin: 0 auto 16px;
    }

    .intro-card .intro-copy {
        text-align: center;
    }

    .section-head {
        padding: 17px 16px 14px;
    }

    .section-note {
        display: none;
    }

    .section-body {
        padding: 16px;
    }

    .app-row {
        align-items: flex-start;
    }

    .app-actions {
        width: 100%;
        justify-content: stretch;
    }

    .app-actions .button {
        flex: 1;
    }

    .app-row {
        flex-wrap: wrap;
    }

    .credential-row {
        grid-template-columns: 42px minmax(0, 1fr) 62px;
        gap: 7px;
        margin: 0 12px;
    }

    .credential-row .button {
        width: 62px;
        padding: 0 7px;
    }

    .auth-card {
        padding: 21px 16px;
    }

    .auth-flow {
        gap: 4px;
    }

    .auth-flow span {
        padding: 7px 3px;
        font-size: 9px;
    }
}

@media (max-width: 380px) {
    .credential-row {
        grid-template-columns: 36px minmax(0, 1fr) 58px;
        gap: 5px;
    }

    .credential-row .button {
        width: 58px;
    }

    .limit-item {
        padding: 12px 10px;
    }
}
