* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        "Microsoft YaHei",
        sans-serif;

    background: #f7f7f5;
    color: #171717;

    /* 页脚粘底：内容不足一屏时页脚仍固定在视口底部 */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;

    /* body 为 flex 布局，显式全宽避免带 auto 边距的子项收缩 */
    width: 100%;
}

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


/* ==================== 导航 ==================== */

.navbar {
    width: 100%;
    border-bottom: 1px solid #e5e5e2;
    background: rgba(247, 247, 245, 0.92);

    position: sticky;
    top: 0;
    z-index: 100;

    backdrop-filter: blur(12px);
}

.nav-container {
    max-width: 1100px;
    height: 72px;

    margin: 0 auto;
    padding: 0 28px;

    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.18em;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    color: #666;
    font-size: 14px;

    transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: #111;
}


/* ==================== Hero ==================== */

.hero {
    min-height: 680px;

    display: flex;
    align-items: center;

    max-width: 1100px;
    margin: 0 auto;
    padding: 80px 28px;
}

.hero-content {
    max-width: 760px;
}

.eyebrow {
    margin: 0 0 20px;

    font-size: 11px;
    letter-spacing: 0.18em;

    color: #888;
}

.hero h1 {
    margin: 0;

    font-size: clamp(64px, 10vw, 120px);
    line-height: 0.95;

    letter-spacing: -0.06em;
}

.hero-title {
    margin: 34px 0 0;

    font-size: 25px;
    line-height: 1.5;
}

.hero-description {
    margin: 22px 0 0;

    color: #777;

    font-size: 15px;
    line-height: 2;
}


/* ==================== 按钮 ==================== */

.hero-buttons {
    margin-top: 42px;

    display: flex;
    gap: 12px;
}

.button {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    height: 48px;
    padding: 0 24px;

    font-size: 14px;

    border: 1px solid #171717;

    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.button.primary {
    background: #171717;
    color: white;
}

.button.primary:hover {
    background: #333;
}

.button.secondary {
    background: transparent;
}

.button.secondary:hover {
    background: #171717;
    color: white;
}


/* ==================== 内容区域 ==================== */

.section {
    max-width: 1100px;
    margin: 0 auto;

    padding: 120px 28px;
}

.section-header {
    max-width: 600px;
    margin-bottom: 55px;
}

.section-header h2 {
    margin: 0;

    font-size: 42px;
    letter-spacing: -0.04em;
}

.section-header p:last-child {
    margin-top: 18px;

    color: #777;

    line-height: 1.8;
}


/* ==================== 卡片 ==================== */

.cards {
    display: grid;

    grid-template-columns: repeat(2, 1fr);

    border-top: 1px solid #ddd;
    border-left: 1px solid #ddd;
}

.card {
    min-height: 240px;

    padding: 32px;

    border-right: 1px solid #ddd;
    border-bottom: 1px solid #ddd;
}

.card-number {
    font-size: 11px;
    color: #999;
}

.card h3 {
    margin: 40px 0 14px;

    font-size: 20px;
}

.card p {
    margin: 0;

    color: #777;

    font-size: 14px;
    line-height: 1.8;
}


/* ==================== 状态 ==================== */

.status-section {
    border-top: 1px solid #ddd;
    border-bottom: 1px solid #ddd;
}

.status-container {
    max-width: 1100px;

    margin: 0 auto;
    padding: 80px 28px;

    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
}

.status-container h2 {
    margin: 0;

    font-size: 38px;
}

.status-text {
    color: #777;

    line-height: 2;
}


/* ==================== Footer ==================== */

footer {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto;
    padding: 40px 28px 60px;

    display: flex;
    justify-content: space-between;

    color: #999;

    font-size: 12px;
}


/* ==================== 手机 ==================== */

@media (max-width: 700px) {

    .nav-container {
        height: 64px;
    }

    .nav-links {
        gap: 14px;
    }

    .nav-links a {
        font-size: 12px;
    }

    .hero {
        min-height: 600px;
        padding-top: 60px;
    }

    .hero h1 {
        font-size: 72px;
    }

    .hero-title {
        font-size: 20px;
    }

    .hero-description br {
        display: none;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .cards {
        grid-template-columns: 1fr;
    }

    .status-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    footer {
        flex-direction: column;
        gap: 8px;
    }
}

/* ==================== 领取免费鸡蛋 ==================== */

.message-page {
    min-height: calc(100vh - 140px);

    display: flex;
    align-items: center;

    max-width: 1100px;

    margin: 0 auto;

    padding: 100px 28px;
}

.message-container {
    width: 100%;
    max-width: 680px;

    margin: 0 auto;
}

.message-intro {
    margin-bottom: 55px;
}

.message-intro h1 {
    margin: 0;

    font-size: clamp(42px, 7vw, 72px);

    letter-spacing: -0.05em;

    line-height: 1;
}

.message-intro p:last-child {
    margin-top: 25px;

    max-width: 520px;

    color: #777;

    font-size: 15px;

    line-height: 2;
}


/* ==================== 表单 ==================== */

#messageForm {
    border-top: 1px solid #ddd;

    padding-top: 40px;
}

.form-group {
    margin-bottom: 30px;
}

.form-group label {
    display: block;

    margin-bottom: 10px;

    font-size: 13px;

    font-weight: 500;
}

.form-group label span {
    color: #999;
}

.form-group input,
.form-group textarea {
    width: 100%;

    border: 1px solid #d8d8d5;

    background: #fff;

    padding: 14px 15px;

    font-family: inherit;

    font-size: 14px;

    color: #171717;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.form-group input {
    height: 50px;
}

.form-group textarea {
    min-height: 170px;

    resize: vertical;

    line-height: 1.7;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: #171717;

    box-shadow:
        0 0 0 1px #171717;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #aaa;
}


/* ==================== 提交按钮 ==================== */

.submit-button {
    width: 100%;

    height: 52px;

    border: none;

    background: #171717;

    color: #fff;

    font-family: inherit;

    font-size: 14px;

    cursor: pointer;

    transition:
        background 0.2s ease,
        opacity 0.2s ease;
}

.submit-button:hover {
    background: #333;
}

.submit-button:disabled {
    cursor: not-allowed;

    opacity: 0.5;
}


/* ==================== 表单结果 ==================== */

.form-result {
    min-height: 24px;

    margin-top: 18px;

    font-size: 13px;

    line-height: 1.6;
}

.form-result.success {
    color: #333;
}

.form-result.error {
    color: #777;
}


/* ==================== 手机 ==================== */

@media (max-width: 700px) {

    .message-page {
        min-height: auto;

        padding-top: 70px;
        padding-bottom: 80px;
    }

    .message-intro {
        margin-bottom: 40px;
    }

}

/* ==================== 关于本站 ==================== */

.about-page {
    max-width: 1100px;

    margin: 0 auto;

    padding: 110px 28px 130px;
}

.about-container {
    max-width: 760px;

    margin: 0 auto;
}

.about-container > h1 {
    margin: 0;

    font-size: clamp(48px, 8vw, 82px);

    line-height: 1;

    letter-spacing: -0.06em;
}

.about-intro {
    margin-top: 45px;

    padding-bottom: 60px;

    border-bottom: 1px solid #ddd;
}

.about-intro p {
    margin: 0 0 20px;

    font-size: 17px;

    line-height: 2;

    color: #555;
}

.about-intro p:last-child {
    margin-bottom: 0;
}


/* ==================== About 内容 ==================== */

.about-section {
    padding: 60px 0;

    border-bottom: 1px solid #ddd;
}

.about-section h2 {
    margin: 0 0 24px;

    font-size: 26px;

    letter-spacing: -0.03em;
}

.about-section > p {
    margin: 0;

    color: #777;

    font-size: 15px;

    line-height: 2;
}


/* ==================== 技术列表 ==================== */

.about-list {
    border-top: 1px solid #ddd;
}

.about-item {
    display: grid;

    grid-template-columns: 60px 1fr;

    gap: 20px;

    padding: 25px 0;

    border-bottom: 1px solid #ddd;
}

.about-item > span {
    color: #999;

    font-size: 11px;

    padding-top: 4px;
}

.about-item h3 {
    margin: 0 0 8px;

    font-size: 17px;
}

.about-item p {
    margin: 0;

    color: #888;

    font-size: 14px;
}


/* ==================== 手机 ==================== */

@media (max-width: 700px) {

    .about-page {
        padding-top: 70px;
        padding-bottom: 80px;
    }

    .about-intro {
        margin-top: 35px;

        padding-bottom: 45px;
    }

    .about-section {
        padding: 45px 0;
    }

    .about-item {
        grid-template-columns: 40px 1fr;
    }

}

/* ==================== 留言状态 ==================== */

.status-area {
    display: flex;

    align-items: center;

    gap: 8px;
}

.status.pending {
    background: #fff3cd;

    color: #806000;
}

.status.invited {
    background: #e8f5e9;

    color: #356b3b;
}


/* ==================== 已邀请按钮 ==================== */

.invite-button {
    padding: 5px 10px;

    border: 1px solid #ccc;

    background: #fff;

    color: #333;

    font-family: inherit;

    font-size: 11px;

    cursor: pointer;

    white-space: nowrap;
}

.invite-button:hover {
    border-color: #171717;

    background: #171717;

    color: #fff;
}

.invite-button:disabled {
    opacity: 0.5;

    cursor: wait;
}

.icp-record {
    margin-top: 10px;
}

.icp-record a {
    color: inherit;
    text-decoration: none;
    opacity: 0.65;
    font-size: 12px;
}

.icp-record a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* ==================================================
   管理后台优化
   ================================================== */

.admin-page {
    max-width: 1280px;
    min-height: calc(100vh - 160px);

    margin: 0 auto;

    padding: 80px 40px 100px;
}


/* ==================== 登录区域 ==================== */

.admin-login {
    width: 100%;
    max-width: 460px;

    margin: 60px auto;
}

.admin-login h1 {
    margin: 0 0 40px;

    font-size: 48px;

    line-height: 1.1;

    letter-spacing: -0.04em;
}


/* ==================== 后台顶部 ==================== */

.admin-header {
    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    gap: 30px;

    margin-bottom: 35px;
}

.admin-header h1 {
    margin: 0;

    font-size: 48px;

    line-height: 1.1;

    letter-spacing: -0.04em;
}


/* ==================== 记录数量 ==================== */

.message-count {
    margin-bottom: 16px;

    color: #777;

    font-size: 13px;

    line-height: 1.5;
}


/* ==================== 表格 ==================== */

.table-wrapper {
    width: 100%;

    overflow-x: auto;

    border-top: 1px solid #ddd;

    border-left: 1px solid #ddd;

    background: #fff;
}

table {
    width: 100%;

    min-width: 900px;

    border-collapse: collapse;

    table-layout: auto;

    font-size: 13px;
}

th,
td {
    padding: 16px 18px;

    text-align: left;

    vertical-align: middle;

    border-right: 1px solid #ddd;

    border-bottom: 1px solid #ddd;
}

th {
    background: #f5f5f3;

    color: #444;

    font-size: 12px;

    font-weight: 500;

    white-space: nowrap;
}


/* ID */

th:first-child,
td:first-child {
    width: 55px;

    text-align: center;
}


/* 时间 */

th:nth-child(2),
td:nth-child(2) {
    min-width: 160px;

    white-space: nowrap;
}


/* 昵称 */

th:nth-child(3),
td:nth-child(3) {
    min-width: 100px;

    white-space: nowrap;
}


/* 邮箱 */

th:nth-child(4),
td:nth-child(4) {
    min-width: 210px;

    white-space: nowrap;
}


/* 留言 */

th:nth-child(5),
td:nth-child(5) {
    min-width: 280px;
}

.message-cell {
    max-width: 420px;

    white-space: pre-wrap;

    word-break: break-word;

    line-height: 1.7;
}


/* 状态 */

th:last-child,
td:last-child {
    min-width: 150px;
}


/* ==================== 状态区域 ==================== */

.status-area {
    display: flex;

    align-items: center;

    gap: 10px;

    white-space: nowrap;
}

.status {
    display: inline-block;

    padding: 5px 9px;

    font-size: 11px;

    line-height: 1;

    white-space: nowrap;
}

.status.pending {
    background: #fff3cd;

    color: #806000;
}

.status.invited {
    background: #e8f5e9;

    color: #356b3b;
}


/* ==================== 已邀请按钮 ==================== */

.invite-button {
    padding: 6px 11px;

    border: 1px solid #ccc;

    background: #fff;

    color: #333;

    font-family: inherit;

    font-size: 11px;

    cursor: pointer;

    transition: 0.15s ease;
}

.invite-button:hover {
    border-color: #171717;

    background: #171717;

    color: #fff;
}

.invite-button:disabled {
    opacity: 0.5;

    cursor: wait;
}


/* ==================== 退出按钮 ==================== */

.admin-logout {
    height: 40px;

    padding: 0 18px;

    border: 1px solid #ccc;

    background: transparent;

    color: #555;

    font-family: inherit;

    font-size: 12px;

    cursor: pointer;

    transition: 0.15s ease;
}

.admin-logout:hover {
    border-color: #171717;

    color: #171717;
}


/* ==================== 手机 ==================== */

@media (max-width: 700px) {

    .admin-page {
        padding: 55px 20px 70px;
    }

    .admin-header {
        align-items: flex-start;

        flex-direction: column;

        gap: 25px;
    }

    .admin-header h1,
    .admin-login h1 {
        font-size: 40px;
    }

    .table-wrapper {
        margin-right: -20px;

        width: calc(100% + 20px);
    }

}

/* ==================== 删除按钮 ==================== */

.delete-button {
    padding: 6px 11px;

    border: 1px solid #d0d0d0;

    background: transparent;

    color: #777;

    font-family: inherit;

    font-size: 11px;

    cursor: pointer;

    transition: 0.15s ease;

    white-space: nowrap;
}

.delete-button:hover {
    border-color: #b33;

    background: #b33;

    color: #fff;
}

/* ==================================================
   免费鸡蛋 · 聚合页
   ================================================== */

.eggs-page {
    max-width: 1100px;

    margin: 0 auto;

    padding: 90px 28px 110px;
}

.eggs-container {
    display: grid;

    grid-template-columns: 250px 1fr;

    gap: 64px;

    align-items: start;
}

.eggs-sidebar h1 {
    margin: 0;

    font-size: clamp(34px, 5vw, 52px);

    line-height: 1;

    letter-spacing: -0.05em;
}

.eggs-nav {
    margin-top: 38px;

    border-top: 1px solid #ddd;
}

.eggs-nav-item {
    display: flex;

    align-items: center;

    gap: 14px;

    padding: 18px 2px;

    border-bottom: 1px solid #ddd;

    color: #777;

    transition: color 0.2s ease;
}

.eggs-nav-icon {
    display: flex;

    flex-shrink: 0;

    font-size: 20px;

    line-height: 1;
}

.eggs-nav-icon svg {
    display: block;
}

.eggs-nav-text strong {
    display: block;

    font-size: 15px;

    font-weight: 600;
}

.eggs-nav-text small {
    display: block;

    margin-top: 5px;

    color: #999;

    font-size: 12px;

    line-height: 1.6;
}

.eggs-nav-item:hover,
.eggs-nav-item.active {
    color: #111;
}

.eggs-note {
    margin: 30px 0 0;

    color: #aaa;

    font-size: 12px;
}

.eggs-content {
    min-height: 480px;
}

.eggs-loading,
.eggs-error {
    padding: 60px 0;

    color: #999;

    font-size: 14px;
}


/* ==================== 功能板块公共 ==================== */

.feature-head {
    margin-bottom: 45px;
}

.feature-head h2 {
    margin: 0 0 16px;

    font-size: clamp(30px, 4.5vw, 44px);

    letter-spacing: -0.04em;

    line-height: 1.1;
}

.feature-head p {
    margin: 0;

    max-width: 540px;

    color: #777;

    font-size: 14px;

    line-height: 2;
}


/* ==================== B站解析 ==================== */

.bili-input-row {
    display: flex;

    gap: 12px;
}

.bili-input-row input {
    flex: 1;

    height: 52px;

    border: 1px solid #d8d8d5;

    background: #fff;

    padding: 0 15px;

    font-family: inherit;

    font-size: 14px;

    color: #171717;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.bili-input-row input:focus {
    border-color: #171717;

    box-shadow:
        0 0 0 1px #171717;
}

.bili-input-row input::placeholder {
    color: #aaa;
}

.bili-input-row .submit-button {
    width: auto;

    padding: 0 34px;
}

.bili-input-actions {
    display: flex;

    gap: 12px;
}

.bili-secondary-btn {
    height: 52px;

    /* 两侧各留 33px + 1px 边框，与解析按钮（0 34px，无边框）完全等宽 */
    padding: 0 33px;

    border: 1px solid #d8d8d5;

    background: #fff;

    color: #171717;

    font-family: inherit;

    font-size: 14px;

    cursor: pointer;

    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        color 0.2s ease;
}

.bili-secondary-btn:hover {
    border-color: #171717;
}

.bili-card {
    border-top: 1px solid #ddd;

    margin-top: 40px;

    padding-top: 34px;
}

.bili-card-top {
    display: flex;

    gap: 24px;
}

.bili-cover {
    width: 250px;

    aspect-ratio: 16 / 10;

    object-fit: cover;

    background: #eee;

    border: 1px solid #ddd;

    flex-shrink: 0;
}

.bili-info {
    min-width: 0;
}

.bili-info h3 {
    margin: 0 0 12px;

    font-size: 17px;

    line-height: 1.6;

    word-break: break-word;
}

.bili-meta {
    display: flex;

    flex-wrap: wrap;

    gap: 8px 18px;

    align-items: center;

    color: #888;

    font-size: 13px;
}

.bili-badge {
    padding: 4px 8px;

    background: #171717;

    color: #fff;

    font-size: 11px;

    white-space: nowrap;
}

/* 模式切换（点播/直播） */

.bili-modes {
    display: flex;

    width: max-content;

    margin-bottom: 26px;

    border: 1px solid #d8d8d5;

    background: #fff;
}

.bili-mode-btn {
    height: 42px;

    padding: 0 26px;

    border: none;

    background: transparent;

    color: #777;

    font-family: inherit;

    font-size: 13px;

    cursor: pointer;

    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.bili-mode-btn + .bili-mode-btn {
    border-left: 1px solid #d8d8d5;
}

.bili-mode-btn.active {
    background: #171717;

    color: #fff;
}

/* 直播结果卡 */

.bili-live-title {
    margin: 0 0 12px;

    font-size: 17px;

    line-height: 1.6;

    word-break: break-word;
}

.bili-live-badge {
    padding: 4px 8px;

    font-size: 11px;

    white-space: nowrap;
}

.bili-live-badge.on {
    background: #b33;

    color: #fff;
}

.bili-live-badge.off {
    background: #e5e5e2;

    color: #777;
}

/* 稳定播放链接展示条 */

.bili-stable-link {
    display: flex;

    align-items: center;

    gap: 14px;

    margin-top: 24px;

    border: 1px solid #d8d8d5;

    background: #fff;

    padding: 10px 10px 10px 16px;
}

.bili-stable-url {
    flex: 1;

    min-width: 0;

    font-size: 13px;

    line-height: 1.7;

    color: #555;

    word-break: break-all;
}

.bili-stable-link .button {
    height: 38px;

    padding: 0 18px;

    font-size: 13px;

    flex-shrink: 0;
}

.bili-pages {
    margin-top: 16px;

    display: flex;

    align-items: center;

    gap: 12px;
}

.bili-pages label {
    font-size: 13px;

    font-weight: 500;
}

.bili-pages select {
    max-width: 320px;

    height: 40px;

    border: 1px solid #d8d8d5;

    background: #fff;

    padding: 0 10px;

    font-family: inherit;

    font-size: 13px;

    color: #171717;

    outline: none;
}

.bili-pages select:focus {
    border-color: #171717;
}

.bili-video {
    display: block;

    width: 100%;

    aspect-ratio: 16 / 9;

    margin-top: 28px;

    background: #000;
}

.bili-copy-row {
    display: flex;

    justify-content: center;

    margin-top: 26px;
}

.bili-copy-row .button {
    height: 38px;

    padding: 0 26px;

    font-size: 13px;
}

.bili-note {
    margin: 26px 0 0;

    color: #aaa;

    font-size: 12px;

    line-height: 1.8;
}


/* ==================== 手机 ==================== */

@media (max-width: 700px) {

    .eggs-page {
        padding: 50px 20px 80px;
    }

    .eggs-container {
        grid-template-columns: 1fr;

        gap: 36px;
    }

    .eggs-sidebar h1 {
        font-size: 40px;
    }

    /* 侧栏导航变成顶部横滑标签 */

    .eggs-nav {
        display: flex;

        margin-top: 24px;

        border-top: none;

        border-bottom: 1px solid #ddd;

        overflow-x: auto;

        scrollbar-width: none;
    }

    .eggs-nav::-webkit-scrollbar {
        display: none;
    }

    .eggs-nav-item {
        flex-shrink: 0;

        align-items: center;

        gap: 8px;

        padding: 12px 16px;

        border-bottom: 2px solid transparent;

        margin-bottom: -1px;
    }

    .eggs-nav-text small {
        display: none;
    }

    .eggs-nav-item.active {
        border-bottom-color: #171717;
    }

    .eggs-content {
        min-height: 360px;
    }

    .bili-card-top {
        flex-direction: column;
    }

    .bili-cover {
        width: 100%;
    }

    .bili-input-row {
        flex-direction: column;
    }

    .bili-input-actions {
        width: 100%;
    }

    .bili-input-actions .submit-button,
    .bili-input-actions .bili-secondary-btn {
        flex: 1;
    }

    .bili-stable-link {
        flex-direction: column;

        align-items: stretch;
    }

    .bili-stable-link .button {
        width: 100%;
    }

}


/* ==================== 404 ==================== */

.notfound-page {
    max-width: 1100px;

    margin: 0 auto;

    padding: 130px 28px 150px;
}

.notfound-page h1 {
    margin: 0;

    font-size: clamp(96px, 16vw, 190px);

    line-height: 0.9;

    letter-spacing: -0.06em;
}

.notfound-page .notfound-text {
    margin: 32px 0 0;

    color: #777;

    font-size: 15px;

    line-height: 2;
}

.notfound-page .hero-buttons {
    margin-top: 38px;
}

@media (max-width: 700px) {

    .notfound-page {
        padding: 80px 20px 100px;
    }

    .notfound-page .hero-buttons {
        flex-direction: column;

        align-items: stretch;
    }

}