:root {
    --ink: #17211c;
    --muted: #6d7771;
    --line: #dfe5e1;
    --paper: #f6f7f4;
    --white: #ffffff;
    --green: #1f5c46;
    --green-dark: #164534;
    --green-soft: #e6f1eb;
    --danger: #9f3b36;
    --danger-soft: #fff1ef;
    --shadow: 0 24px 70px rgba(23, 33, 28, .12);
}

* { box-sizing: border-box; }

html { font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif; }

body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
}

.admin-login {
    --green: #334f7d;
    --green-dark: #243b61;
    --green-soft: #e9eef7;
}

.admin-login .brand-panel {
    background:
        radial-gradient(circle at 18% 10%, rgba(153, 179, 224, .26), transparent 28%),
        radial-gradient(circle at 92% 86%, rgba(129, 153, 198, .17), transparent 32%),
        linear-gradient(145deg, #1f304d 0%, #334f7d 58%, #1f304d 100%);
}

.admin-login .brand-mark { color: #1f304d; background: #b8c9e8; }
.admin-login .brand-copy .eyebrow { color: #b8c9e8; }

a { color: inherit; }

button, input { font: inherit; }

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

.auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(360px, 44%) 1fr;
    position: relative;
}

.brand-panel {
    min-height: 100vh;
    padding: clamp(38px, 5vw, 72px);
    color: #f4fbf7;
    background:
        radial-gradient(circle at 18% 10%, rgba(132, 190, 159, .28), transparent 28%),
        radial-gradient(circle at 92% 86%, rgba(139, 177, 154, .16), transparent 32%),
        linear-gradient(145deg, #173c2e 0%, #245943 58%, #173c2e 100%);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.brand-panel::before,
.brand-panel::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 50%;
}

.brand-panel::before { width: 420px; height: 420px; right: -250px; top: 12%; }
.brand-panel::after { width: 280px; height: 280px; right: -120px; top: 28%; }

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    width: fit-content;
    text-decoration: none;
    font-weight: 760;
    letter-spacing: -.02em;
    font-size: 1.08rem;
}

.brand-light { color: #fff; }

.brand-mark {
    width: 35px;
    height: 35px;
    display: inline-grid;
    place-items: center;
    border-radius: 11px;
    background: #a9d6bb;
    color: #173c2e;
    font-family: Georgia, serif;
    font-weight: 800;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25);
}

.brand-copy {
    max-width: 560px;
    margin: auto 0;
    position: relative;
    z-index: 1;
}

.eyebrow {
    margin: 0 0 16px;
    color: #72a88c;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.brand-copy .eyebrow { color: #a9d6bb; }

.brand-copy h1 {
    margin: 0;
    font-family: Georgia, "Noto Serif SC", serif;
    font-size: clamp(2.8rem, 5vw, 5rem);
    font-weight: 500;
    line-height: 1.08;
    letter-spacing: -.045em;
}

.brand-copy > p:last-child {
    max-width: 440px;
    margin: 26px 0 0;
    color: rgba(244, 251, 247, .7);
    line-height: 1.8;
}

.quote-card {
    position: relative;
    z-index: 1;
    max-width: 460px;
    padding: 20px 24px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 17px;
    background: rgba(255, 255, 255, .06);
    backdrop-filter: blur(8px);
}

.quote-card p { margin: 0 0 10px; line-height: 1.55; }
.quote-card > span:last-child { color: rgba(255, 255, 255, .5); font-size: .78rem; }
.quote-mark { float: left; margin: -7px 10px 0 -4px; color: #a9d6bb; font: 2.8rem Georgia, serif; }

.feature-list {
    position: relative;
    z-index: 1;
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 14px;
    color: rgba(255, 255, 255, .72);
    font-size: .9rem;
}

.feature-list span {
    display: inline-grid;
    place-items: center;
    width: 23px;
    height: 23px;
    margin-right: 9px;
    border-radius: 50%;
    color: #173c2e;
    background: #a9d6bb;
    font-weight: 900;
}

.form-panel {
    min-height: 100vh;
    padding: 56px clamp(28px, 8vw, 120px);
    background: #fbfcfa;
    display: grid;
    place-items: center;
}

.form-wrap { width: min(100%, 430px); }
.form-wrap-register { max-width: 460px; }
.mobile-brand { display: none; }

.form-heading { margin-bottom: 30px; }
.form-heading h2 { margin: 0 0 12px; font-family: Georgia, "Noto Serif SC", serif; font-size: clamp(2rem, 3vw, 2.7rem); font-weight: 500; letter-spacing: -.035em; }
.form-heading > p:last-child { margin: 0; color: var(--muted); line-height: 1.7; }

.alert {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: -8px 0 22px;
    padding: 12px 14px;
    color: var(--danger);
    background: var(--danger-soft);
    border: 1px solid #f1cfcb;
    border-radius: 11px;
    font-size: .88rem;
    line-height: 1.45;
}

.alert-icon {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    color: #fff;
    background: var(--danger);
    font-size: .72rem;
    font-weight: 800;
}

.auth-form { display: grid; gap: 11px; }
.auth-form label, .label-row label { font-size: .82rem; font-weight: 750; }
.label-row { display: flex; justify-content: space-between; align-items: center; margin-top: 3px; }
.helper-text { color: #929a95; font-size: .72rem; }

.input-wrap { position: relative; margin-bottom: 7px; }

.input-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    color: #849089;
    font-weight: 700;
    pointer-events: none;
}

.lock-icon { font-size: 1.05rem; transform: translateY(-53%) rotate(45deg); }

.input-wrap input {
    width: 100%;
    height: 52px;
    padding: 0 16px 0 45px;
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: 12px;
    outline: none;
    background: var(--white);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}

.input-wrap input::placeholder { color: #a7aea9; }
.input-wrap input:focus { border-color: #4f8a70; box-shadow: 0 0 0 4px rgba(54, 119, 87, .11); }

.captcha-row { display: grid; grid-template-columns: minmax(0, 1fr) 160px; gap: 12px; align-items: start; }
.captcha-row .input-wrap { margin-bottom: 0; }
.captcha-refresh {
    width: 160px;
    height: 52px;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #eef4f0;
    cursor: pointer;
}
.captcha-refresh img { display: block; width: 160px; height: 56px; margin-top: -2px; }

.primary-button {
    width: 100%;
    min-height: 52px;
    margin-top: 10px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: var(--green);
    box-shadow: 0 10px 24px rgba(31, 92, 70, .2);
    cursor: pointer;
    font-weight: 760;
    transition: background .2s, transform .2s, box-shadow .2s;
}

.primary-button:hover { background: var(--green-dark); box-shadow: 0 12px 28px rgba(31, 92, 70, .25); transform: translateY(-1px); }
.primary-button:active { transform: translateY(0); }
.primary-button:focus-visible, .ghost-button:focus-visible, a:focus-visible { outline: 3px solid rgba(54, 119, 87, .28); outline-offset: 3px; }

.form-footer { margin: 26px 0 0; color: var(--muted); text-align: center; font-size: .88rem; }
.form-footer a { color: var(--green); font-weight: 760; text-underline-offset: 3px; }

.page-footer { position: absolute; right: 32px; bottom: 22px; color: #a0a7a2; font-size: .7rem; }

.dashboard-body { min-height: 100vh; background: #f1f4f0; }

.dashboard-nav {
    height: 76px;
    padding: 0 clamp(22px, 6vw, 84px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, .9);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(12px);
}

.ghost-button {
    padding: 10px 16px;
    color: var(--green);
    border: 1px solid #cbd8d0;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    font-weight: 700;
}

.ghost-button:hover { background: var(--green-soft); }

.dashboard-main { width: min(1100px, calc(100% - 40px)); margin: 0 auto; padding: clamp(48px, 8vw, 90px) 0; }

.welcome-card {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: clamp(28px, 5vw, 52px);
    color: #f5fbf7;
    border-radius: 24px;
    background: linear-gradient(135deg, #173c2e, #28654c);
    box-shadow: var(--shadow);
}

.welcome-card .eyebrow { color: #a9d6bb; }
.welcome-card h1 { margin: 0 0 10px; font: 500 clamp(2rem, 4vw, 3.5rem) Georgia, "Noto Serif SC", serif; letter-spacing: -.04em; }
.welcome-card p:last-child { margin: 0; color: rgba(255, 255, 255, .68); }

.avatar {
    flex: 0 0 auto;
    width: clamp(72px, 10vw, 110px);
    height: clamp(72px, 10vw, 110px);
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 50%;
    color: #173c2e;
    background: #a9d6bb;
    font: 500 clamp(2rem, 4vw, 3.4rem) Georgia, serif;
}

.dashboard-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 22px; }

.info-card {
    min-width: 0;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
}

.card-icon {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    color: var(--green);
    background: var(--green-soft);
    border-radius: 12px;
    font-weight: 850;
}

.info-card p { margin: 0 0 5px; color: var(--muted); font-size: .75rem; }
.info-card strong { display: block; overflow: hidden; text-overflow: ellipsis; font-size: .92rem; }
.status-active { color: #24724e; }

.security-note {
    margin-top: 22px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid #cce2d5;
    border-radius: 16px;
    background: var(--green-soft);
}

.security-icon { width: 39px; height: 39px; display: grid; place-items: center; color: #fff; background: var(--green); border-radius: 50%; font-weight: 850; }
.security-note h2 { margin: 0 0 5px; font-size: .98rem; }
.security-note p { margin: 0; color: #567064; font-size: .84rem; }

/* 站长与管理员控制台 */
.console-body { min-height: 100vh; background: #f3f5f2; }
.admin-body { --green: #334f7d; --green-dark: #243b61; --green-soft: #e9eef7; }
.console-nav {
    min-height: 72px;
    padding: 10px clamp(18px, 4vw, 64px);
    display: flex;
    align-items: center;
    gap: 32px;
    background: rgba(255, 255, 255, .94);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(12px);
}
.console-links { margin-right: auto; display: flex; align-items: center; gap: 4px; }
.console-links a { padding: 9px 12px; color: var(--muted); border-radius: 9px; text-decoration: none; font-size: .84rem; font-weight: 700; }
.console-links a:hover, .console-links a.active { color: var(--green); background: var(--green-soft); }
.ghost-link { padding: 9px 14px; color: var(--green); border: 1px solid #cbd8d0; border-radius: 9px; text-decoration: none; font-size: .82rem; font-weight: 750; }
.console-main { width: min(1240px, calc(100% - 40px)); margin: 0 auto; padding: 46px 0 80px; }
.narrow-main { width: min(760px, calc(100% - 40px)); }
.page-title-row { margin-bottom: 28px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.page-title-row h1 { margin: 0 0 8px; font: 500 clamp(2rem, 4vw, 3.2rem) Georgia, "Noto Serif SC", serif; letter-spacing: -.04em; }
.page-title-row p:last-child { margin: 0; color: var(--muted); line-height: 1.6; }
.primary-link { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; color: #fff; background: var(--green); border-radius: 10px; text-decoration: none; font-size: .84rem; font-weight: 760; }
.button-reset { border: 0; cursor: pointer; }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 20px; }
.metric-grid.four-cols { grid-template-columns: repeat(4, 1fr); }
.metric-card { padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 8px 30px rgba(23, 33, 28, .04); }
.metric-card span { display: block; color: var(--muted); font-size: .78rem; font-weight: 700; }
.metric-card strong { display: block; margin: 10px 0 6px; font: 600 1.75rem Georgia, serif; }
.metric-card small { color: #8a948e; }
.panel { margin-top: 18px; padding: 24px; border: 1px solid var(--line); border-radius: 17px; background: #fff; box-shadow: 0 8px 30px rgba(23, 33, 28, .035); }
.panel-heading { margin-bottom: 20px; display: flex; justify-content: space-between; gap: 20px; }
.panel-heading h2, .domain-card h2 { margin: 0 0 6px; font-size: 1.08rem; }
.panel-heading p, .domain-card-head p { margin: 0; color: var(--muted); font-size: .82rem; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .82rem; }
th { padding: 12px; color: var(--muted); border-bottom: 1px solid var(--line); text-align: left; font-size: .72rem; letter-spacing: .04em; }
td { padding: 14px 12px; border-bottom: 1px solid #edf0ed; vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
td code { font-size: .74rem; }
.empty-cell, .empty-panel { color: var(--muted); text-align: center; padding: 36px; }
.money-positive { color: #24724e; font-weight: 750; }
.table-sub { display: block; margin-top: 4px; color: var(--muted); }
.table-action { color: var(--green); font-weight: 750; text-underline-offset: 3px; }
.table-action-stack { display: flex; flex-wrap: wrap; gap: 7px 12px; min-width: 120px; }
.notice { margin: 0 0 18px; padding: 13px 15px; border: 1px solid; border-radius: 11px; font-size: .86rem; }
.notice.success { color: #216144; background: #e8f5ed; border-color: #bcdcc9; }
.notice.error { color: var(--danger); background: var(--danger-soft); border-color: #edc8c4; }
.form-panel-card { padding: 28px; }
.console-form { display: grid; gap: 16px; }
.console-form label { display: grid; gap: 7px; color: #44514a; font-size: .8rem; font-weight: 720; }
.console-form input, .console-form select, .console-form textarea, .inline-form input {
    width: 100%;
    min-height: 46px;
    padding: 0 13px;
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    outline: none;
}
.console-form textarea { min-height: 120px; padding: 12px 13px; resize: vertical; font: inherit; line-height: 1.55; }
.console-form input:focus, .console-form select:focus, .console-form textarea:focus, .inline-form input:focus { border-color: var(--green); box-shadow: 0 0 0 4px rgba(54, 119, 87, .1); }
.console-form input:disabled { color: #77817b; background: #f3f5f3; }
.compact-button { width: auto; min-width: 150px; justify-self: start; padding: 0 24px; }
.inline-form { display: flex; gap: 12px; }
.inline-form input { flex: 1; }
.search-form { max-width: 560px; margin-bottom: 18px; }
.secondary-button { min-height: 40px; padding: 0 15px; color: var(--green); border: 1px solid #bfd0c6; border-radius: 9px; background: var(--green-soft); cursor: pointer; font-weight: 750; }
.domain-list { display: grid; gap: 18px; }
.domain-card { padding: 26px; }
.domain-card-head { display: flex; justify-content: space-between; gap: 20px; }
.status-stack { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.badge { display: inline-flex; align-items: center; width: fit-content; padding: 5px 9px; border-radius: 999px; font-size: .7rem; font-weight: 780; }
.badge.good { color: #216144; background: #e5f4eb; }
.badge.warn { color: #8a5a12; background: #fff3d9; }
.badge.bad { color: #963c37; background: #ffebe9; }
.badge.neutral { color: #647069; background: #eef1ef; }
.badge.device-badge { color: #2f5f83; background: #e8f2f9; }
.verification-box { margin-top: 20px; padding: 18px; border: 1px dashed #b8cec1; border-radius: 12px; background: #f2f8f4; }
.verification-box > p { margin: 0 0 12px; font-size: .83rem; }
.verification-box dl { margin: 0 0 14px; display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px 12px; }
.verification-box dt { color: var(--muted); font-size: .76rem; }
.verification-box dd { margin: 0; overflow-wrap: anywhere; }
.verification-box code { padding: 3px 6px; background: #e1eee6; border-radius: 5px; }
.domain-settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 22px; }
.compact-form { padding: 20px; border: 1px solid #e3e8e4; border-radius: 13px; }
.compact-form h3 { margin: 0; font-size: .94rem; }
.form-hint { margin: 0; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.form-section-heading { margin-top: 10px; padding-top: 22px; border-top: 1px solid var(--line); }
.form-section-heading h2 { margin: 0 0 6px; font-size: 1.05rem; }
.form-section-heading p { margin: 0; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.payout-security-note { padding: 11px 13px; border-radius: 9px; background: var(--green-soft); }
.rule-readonly { display: grid; gap: 14px; }
.rule-summary { margin: 0; display: grid; gap: 10px; }
.rule-summary > div { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 9px; border-bottom: 1px solid #e6ebe7; }
.rule-summary > div:last-child { padding-bottom: 0; border-bottom: 0; }
.rule-summary dt { color: var(--muted); font-size: .78rem; }
.rule-summary dd { margin: 0; font-weight: 760; }
.rule-limits { padding-top: 12px; border-top: 1px solid var(--line); }
.ad-rate-grid { display: grid; gap: 10px; }
.ad-rate-row { padding: 13px; display: grid; grid-template-columns: minmax(120px, .85fr) minmax(145px, 1fr); align-items: end; gap: 10px 14px; border: 1px solid #e3e8e4; border-radius: 11px; background: #fafbfa; }
.ad-rate-name strong, .ad-rate-name small { display: block; }
.ad-rate-name small { margin-top: 4px; color: var(--muted); font-size: .68rem; font-weight: 500; }
.ad-rate-row > label { margin: 0; }
.ad-rate-row > label input[type="number"] { min-height: 38px; height: 38px; }
.ad-rate-result { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: .72rem; }
.ad-rate-result strong { color: var(--green); font-size: .8rem; }
.console-form .rate-toggle { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.console-form .rate-toggle input { width: 17px; min-height: 17px; height: 17px; padding: 0; accent-color: var(--green); }
.readonly-ad-rates { display: grid; gap: 8px; }
.readonly-ad-rate { padding: 10px 0; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid #e6ebe7; }
.readonly-ad-rate:last-child { border-bottom: 0; }
.readonly-ad-rate strong, .readonly-ad-rate small { display: block; }
.readonly-ad-rate strong { font-size: .8rem; }
.readonly-ad-rate small { margin-top: 4px; color: var(--muted); font-size: .7rem; }
.reward-rule-cell { min-width: 210px; }
.admin-rule-form { gap: 7px; }
.admin-rule-form label { grid-template-columns: 72px 105px; align-items: center; gap: 6px; font-size: .68rem; }
.admin-rule-form input { min-height: 32px; height: 32px; padding: 0 7px; font-size: .72rem; }
.split-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.split-summary > div { padding: 10px 24px; border-right: 1px solid var(--line); }
.split-summary > div:last-child { border-right: 0; }
.split-summary span { display: block; color: var(--muted); font-size: .78rem; }
.split-summary strong { display: block; margin-top: 9px; font: 600 1.55rem Georgia, serif; }
.action-cell { min-width: 230px; }
.action-cell form { display: inline-flex; gap: 5px; margin: 2px; }
.tiny-button { padding: 6px 8px; color: #5e6963; border: 1px solid #d4dad6; border-radius: 7px; background: #fff; cursor: pointer; font-size: .7rem; font-weight: 700; }
.tiny-button.approve { color: #216144; border-color: #bcdcc9; background: #e8f5ed; }
.tiny-button.reject { color: #963c37; border-color: #edc8c4; background: #ffefed; }
.setup-steps { margin: 0 0 22px; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); list-style: none; border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; }
.setup-steps li { min-width: 0; padding: 16px; display: flex; align-items: center; gap: 11px; color: #909993; border-right: 1px solid var(--line); }
.setup-steps li:last-child { border-right: 0; }
.setup-steps li > span { flex: 0 0 auto; width: 29px; height: 29px; display: grid; place-items: center; border-radius: 50%; color: #7b857f; background: #edf0ee; font-size: .76rem; font-weight: 800; }
.setup-steps li strong, .setup-steps li small { display: block; }
.setup-steps li strong { font-size: .8rem; }
.setup-steps li small { margin-top: 3px; font-size: .68rem; }
.setup-steps li.active { color: var(--green); background: #f5faf7; }
.setup-steps li.active > span { color: #fff; background: var(--green); }
.setup-panel { margin-top: 0; padding: clamp(22px, 4vw, 34px); }
.bound-domain { margin-bottom: 18px; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border: 1px solid var(--line); border-radius: 11px; background: #fafbfa; }
.bound-domain span { color: var(--muted); font-size: .76rem; }
.bound-domain strong { overflow-wrap: anywhere; }
.setup-verification { margin-top: 0; }
.setup-verification dl { margin-bottom: 16px; }
.setup-actions { margin-top: 22px; display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.reward-details-panel { margin-top: 22px; }
.reward-metrics { margin-bottom: 22px; }
.reward-events-table { min-width: 1050px; }
.reward-page-cell { min-width: 280px; max-width: 420px; }
.reward-page-link { display: block; max-width: 420px; overflow: hidden; color: var(--green); text-overflow: ellipsis; white-space: nowrap; text-underline-offset: 3px; }
.reward-entry-panel { margin-top: 22px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.reward-entry-panel h2 { margin: 0 0 7px; font-size: 1.08rem; }
.reward-entry-panel p { margin: 0; color: var(--muted); font-size: .82rem; }
.reward-entry-button { display: inline-flex; align-items: center; justify-content: center; gap: 14px; flex: 0 0 auto; text-decoration: none; }
.webmaster-reward-entry { display: grid; align-items: stretch; }
.webmaster-reward-entry .reward-metrics { margin: 4px 0 0; }
.webmaster-reward-entry .reward-entry-button { justify-self: end; }
.reward-list-panel { margin-top: 0; }
.reward-event-list { display: grid; border: 1px solid #e5eae6; border-radius: 13px; overflow: hidden; }
.reward-event-list-item { min-width: 0; padding: 17px 18px; display: grid; grid-template-columns: 170px minmax(0, 1fr) 170px 24px; align-items: center; gap: 18px; color: inherit; border-bottom: 1px solid #e8ece9; background: #fff; text-decoration: none; transition: background .18s, box-shadow .18s; }
.reward-event-list-item:last-child { border-bottom: 0; }
.reward-event-list-item:hover { position: relative; z-index: 1; background: #f6faf7; box-shadow: inset 3px 0 0 var(--green); }
.reward-list-time strong, .reward-list-time small, .reward-list-content p, .reward-list-content > small, .reward-list-money strong, .reward-list-money span, .reward-list-money small { display: block; }
.reward-list-time strong { font-size: .78rem; }
.reward-list-time small, .reward-list-content > small, .reward-list-money small { margin-top: 5px; color: var(--muted); font-size: .68rem; }
.reward-list-title { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.reward-list-title strong { font-size: .88rem; }
.reward-list-content { min-width: 0; }
.reward-list-content p, .reward-list-content > small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reward-list-content p { margin: 6px 0 0; color: #526058; font-size: .75rem; }
.reward-list-money { text-align: right; }
.reward-list-money strong { color: #24724e; font-size: .82rem; }
.reward-list-money span { margin-top: 4px; color: #526058; font-size: .72rem; }
.reward-list-arrow { color: var(--green); font-size: 1.15rem; }
.reward-event-detail-panel { margin-top: 22px; }
.reward-event-detail-grid { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.reward-event-detail-grid > div { min-width: 0; padding: 15px 17px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.reward-event-detail-grid > div:nth-child(2n) { border-right: 0; }
.reward-event-detail-grid > div.detail-wide { grid-column: 1 / -1; border-right: 0; }
.reward-event-detail-grid > div:last-child { border-bottom: 0; }
.reward-event-detail-grid dt { color: var(--muted); font-size: .7rem; }
.reward-event-detail-grid dd { margin: 7px 0 0; overflow-wrap: anywhere; font-size: .84rem; font-weight: 730; }
.reward-event-detail-grid dd small { display: block; margin-top: 5px; color: var(--muted); font-size: .68rem; font-weight: 500; }
.reward-event-detail-grid dd a { color: var(--green); text-underline-offset: 3px; }
.reward-event-detail-grid code { font-size: .72rem; }
.muted-text { color: var(--muted); }
.pagination { margin-top: 20px; display: flex; align-items: center; justify-content: space-between; }
.admin-domain-review-list { display: grid; gap: 14px; margin-top: 20px; }
.admin-domain-review-item { padding: 22px 24px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 8px 30px rgba(23, 33, 28, .035); position: relative; transition: border-color .2s, box-shadow .2s, transform .2s; }
.admin-domain-review-item:has(.admin-domain-review-link:hover) { border-color: #b9c8d9; box-shadow: 0 12px 34px rgba(38, 58, 91, .09); transform: translateY(-1px); }
.admin-domain-review-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.domain-title-line { display: flex; align-items: baseline; gap: 10px; }
.domain-title-line strong { font: 600 1.2rem Georgia, "Noto Serif SC", serif; }
.domain-title-line span { color: var(--muted); font-size: .7rem; }
.admin-domain-review-head p { margin: 7px 0 0; color: var(--muted); font-size: .8rem; }
.admin-domain-review-facts { margin: 20px 0 0; display: grid; grid-template-columns: 1.25fr .7fr .9fr .9fr .9fr 1fr; border: 1px solid #e6eae7; border-radius: 12px; background: #fafbfa; }
.admin-domain-review-facts > div { min-width: 0; padding: 13px 15px; border-right: 1px solid #e6eae7; }
.admin-domain-review-facts > div:last-child { border-right: 0; }
.admin-domain-review-facts dt { color: var(--muted); font-size: .68rem; }
.admin-domain-review-facts dd { margin: 6px 0 0; overflow: hidden; font-size: .8rem; font-weight: 740; text-overflow: ellipsis; white-space: nowrap; }
.admin-domain-review-links { margin-top: 16px; padding-top: 14px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid #edf0ed; }
.admin-domain-review-link { padding: 0 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--green); text-decoration: none; font-size: .8rem; font-weight: 780; }
.admin-domain-review-link:first-child { padding-left: 0; }
.admin-domain-review-link:last-child { padding-right: 0; border-left: 1px solid #e4e9e5; }
.admin-domain-missing { margin-top: 16px; padding-top: 14px; color: var(--danger); border-top: 1px solid #edf0ed; font-size: .78rem; }
.admin-profile-panel { max-width: 780px; margin-top: 0; }
.admin-webmaster-domains { margin-top: 42px; }
.section-heading { margin-bottom: 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.section-heading .eyebrow { margin-bottom: 10px; }
.section-heading h2 { margin: 0 0 7px; font: 500 2rem Georgia, "Noto Serif SC", serif; }
.section-heading p:last-child { margin: 0; color: var(--muted); font-size: .84rem; }
.admin-domain-edit-card { margin-top: 14px; }
.admin-domain-summary { margin: 20px 0; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.admin-domain-summary strong { font-size: 1rem; overflow-wrap: anywhere; }
.admin-domain-edit-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: stretch; gap: 20px; }
.admin-domain-edit-grid > .panel { margin-top: 0; }
.admin-domain-settings-row { margin-top: 22px; }
.admin-domain-settings-row > .panel { height: 100%; }
.admin-domain-settings-stack { display: grid; grid-template-columns: 1fr; gap: 20px; }
.admin-domain-settings-stack .ad-rate-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.admin-domain-settings-stack .admin-review-box { min-height: 0; }
.admin-domain-detail-facts { margin: 22px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.admin-domain-detail-facts > div { min-width: 0; padding: 15px 17px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.admin-domain-detail-facts > div:nth-child(2n) { border-right: 0; }
.admin-domain-detail-facts > div:nth-last-child(-n+2) { border-bottom: 0; }
.admin-domain-detail-facts dt { color: var(--muted); font-size: .72rem; }
.admin-domain-detail-facts dd { margin: 7px 0 0; overflow-wrap: anywhere; font-size: .84rem; font-weight: 720; }
.admin-domain-detail-facts dd small { display: block; margin-top: 4px; color: var(--muted); font-weight: 500; }
.admin-domain-detail-facts code { padding: 3px 6px; background: var(--green-soft); border-radius: 5px; font-size: .74rem; }
.admin-review-box { display: flex; flex-direction: column; gap: 14px; }
.admin-review-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.admin-review-actions + .admin-review-actions { padding-top: 14px; border-top: 1px solid var(--line); }
.settlement-actions-grid { display: grid; grid-template-columns: 1.45fr .75fr; align-items: start; gap: 20px; }
.settlement-actions-grid > .panel { margin-top: 0; }
.settlement-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ad-unit-form-grid { display: grid; grid-template-columns: 1.1fr 1.1fr .8fr .9fr .7fr; gap: 14px; }
.ad-unit-table { min-width: 920px; }
.ad-unit-table input, .ad-unit-table select { width: 100%; min-height: 36px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }

@media (max-width: 850px) {
    .auth-shell { display: block; background: #fbfcfa; }
    .brand-panel { display: none; }
    .form-panel { min-height: 100vh; padding: 34px 22px 70px; }
    .mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 55px; font-weight: 760; }
    .page-footer { right: 0; left: 0; text-align: center; }
    .dashboard-grid { grid-template-columns: 1fr; }
    .console-nav { align-items: flex-start; flex-wrap: wrap; gap: 10px 20px; }
    .console-links { order: 3; width: 100%; overflow-x: auto; }
    .metric-grid, .metric-grid.four-cols { grid-template-columns: repeat(2, 1fr); }
    .domain-settings-grid { grid-template-columns: 1fr; }
    .admin-domain-review-facts { grid-template-columns: repeat(2, 1fr); }
    .admin-domain-review-facts > div { border-bottom: 1px solid #e6eae7; }
    .admin-domain-review-facts > div:nth-child(2n) { border-right: 0; }
    .admin-domain-edit-grid { grid-template-columns: 1fr; }
    .admin-domain-settings-stack .ad-rate-grid { grid-template-columns: 1fr; }
    .settlement-actions-grid { grid-template-columns: 1fr; }
    .ad-unit-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .reward-event-list-item { grid-template-columns: 145px minmax(0, 1fr) 145px 20px; gap: 12px; }
}

@media (max-width: 560px) {
    .welcome-card { align-items: flex-start; flex-direction: column; }
    .dashboard-nav { height: 68px; }
    .dashboard-main { width: min(100% - 28px, 1100px); padding-top: 30px; }
    .captcha-row { grid-template-columns: 1fr 132px; }
    .captcha-refresh, .captcha-refresh img { width: 132px; }
    .console-main, .narrow-main { width: min(100% - 24px, 1240px); padding-top: 28px; }
    .page-title-row { align-items: flex-start; flex-direction: column; }
    .metric-grid, .metric-grid.four-cols, .split-summary { grid-template-columns: 1fr; }
    .ad-rate-row { grid-template-columns: 1fr; }
    .reward-entry-panel { align-items: stretch; flex-direction: column; }
    .reward-entry-button, .webmaster-reward-entry .reward-entry-button { width: 100%; justify-self: stretch; }
    .reward-event-list-item { grid-template-columns: 1fr 22px; }
    .reward-list-time, .reward-list-content, .reward-list-money { grid-column: 1; text-align: left; }
    .reward-list-arrow { grid-column: 2; grid-row: 1 / span 3; align-self: center; }
    .reward-event-detail-grid { grid-template-columns: 1fr; }
    .reward-event-detail-grid > div, .reward-event-detail-grid > div:nth-child(2n) { border-right: 0; }
    .reward-event-detail-grid > div.detail-wide { grid-column: 1; }
    .split-summary > div { border-right: 0; border-bottom: 1px solid var(--line); }
    .split-summary > div:last-child { border-bottom: 0; }
    .domain-card-head { flex-direction: column; }
    .status-stack { justify-content: flex-start; }
    .inline-form { flex-direction: column; }
    .verification-box dl { grid-template-columns: 1fr; }
    .setup-steps { grid-template-columns: 1fr; }
    .setup-steps li { border-right: 0; border-bottom: 1px solid var(--line); }
    .setup-steps li:last-child { border-bottom: 0; }
    .setup-actions { align-items: stretch; flex-direction: column-reverse; }
    .setup-actions .ghost-link { text-align: center; }
    .admin-domain-review-head, .section-heading { align-items: flex-start; flex-direction: column; }
    .admin-domain-review-facts { grid-template-columns: 1fr; }
    .admin-domain-review-facts > div { border-right: 0; }
    .admin-domain-review-facts > div:last-child { border-bottom: 0; }
    .admin-domain-detail-facts { grid-template-columns: 1fr; }
    .admin-domain-detail-facts > div { border-right: 0; }
    .admin-domain-detail-facts > div:nth-last-child(2) { border-bottom: 1px solid var(--line); }
    .settlement-form-row { grid-template-columns: 1fr; }
    .ad-unit-form-grid { grid-template-columns: 1fr; }
}

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