/* 本地平台页面的共享样式（登录/注册/导航/上传/管理/单树查看）。 */
*,
*::before,
*::after {
    box-sizing: border-box;
}

:root {
    --ink: #1e2a3a;
    --muted: rgba(50, 70, 110, 0.58);
    --line: rgba(80, 100, 150, 0.14);
    --accent: #7f95b2;
    --accent-dark: #647b98;
    --danger: #b05c5c;
    --ok: #4f8a68;
    --warn: #b27b43;
}

body {
    margin: 0;
    min-height: 100vh;
    padding: 2rem 1.5rem;
    font-family: 'Inter', 'Segoe UI', 'Microsoft YaHei', sans-serif;
    color: var(--ink);
    background: linear-gradient(135deg, #f9f0f5 0%, #edf7f9 22%, #f2edfa 45%, #f5f0f5 65%, #f0f5fa 82%, #faf3ec 100%);
    background-attachment: fixed;
}

a {
    color: var(--accent-dark);
}

.hidden {
    display: none !important;
}

.dashboard {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 2.1rem 2.4rem 2.4rem;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.85);
    box-shadow: 0 20px 60px rgba(0, 20, 40, 0.08);
    backdrop-filter: blur(22px);
}

.dashboard.narrow {
    max-width: 760px;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding-bottom: 1.2rem;
    border-bottom: 1px solid var(--line);
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 0.08rem;
    line-height: 1.15;
}

.brand-icon {
    width: 84px;
    height: 84px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 0 0 auto;
    box-shadow: 0 8px 22px rgba(9, 38, 48, 0.22);
}

.brand-icon img {
    width: 100%;
    height: 100%;
    display: block;
}

.brand-name {
    font-size: 1.25rem;
    font-weight: 600;
}

.brand-name span {
    font-weight: 300;
    color: rgba(60, 80, 120, 0.45);
    margin-left: 0.12rem;
}

.brand-name span+span {
    margin-left: 0.32rem;
}

.brand-tagline {
    font-size: 0.66rem;
    font-weight: 400;
    letter-spacing: 0.06em;
    color: rgba(60, 80, 120, 0.5);
    white-space: nowrap;
}

.site-slogan {
    margin: -0.55rem 0 1.2rem;
    font-size: 0.82rem;
    letter-spacing: 0.12em;
    color: rgba(60, 80, 120, 0.55);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
    font-size: 0.8rem;
}

.nav-right a {
    text-decoration: none;
    color: var(--muted);
}

.nav-right a:hover {
    color: var(--ink);
}

.nav-user {
    color: var(--muted);
    font-size: 0.76rem;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lang-label {
    color: var(--muted);
    font-size: 0.72rem;
    letter-spacing: 0.02em;
}

.lang-select {
    padding: 0.28rem 0.6rem;
    border-radius: 14px;
    border: 1px solid rgba(139, 158, 183, 0.28);
    background: rgba(255, 255, 255, 0.65);
    color: rgba(40, 60, 110, 0.8);
    font-family: inherit;
    font-size: 0.76rem;
    cursor: pointer;
    outline: none;
}

h1 {
    font-size: 1.6rem;
    font-weight: 550;
    margin: 1.5rem 0 0.4rem;
}

.subtitle {
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.75;
    margin: 0 0 1.2rem;
}

.searchbar {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 1.2rem 0 1.4rem;
    flex-wrap: wrap;
}

.searchbar input[type="search"],
.searchbar input[type="text"] {
    flex: 1 1 320px;
    min-width: 220px;
    padding: 11px 16px;
    border-radius: 16px;
    border: 1px solid rgba(139, 158, 183, 0.3);
    background: rgba(255, 255, 255, 0.72);
    font-family: inherit;
    font-size: 0.88rem;
    color: var(--ink);
    outline: none;
}

.searchbar input:focus {
    border-color: rgba(127, 149, 178, 0.7);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 9px 18px;
    border: none;
    border-radius: 22px;
    background: linear-gradient(135deg, #8b9eb7, #b5a8a8);
    color: #fff;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
}

.btn:hover {
    background: linear-gradient(135deg, #7d92ab, #a89999);
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.btn-ghost {
    color: var(--muted);
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(139, 158, 183, 0.3);
}

.btn-ghost:hover {
    color: var(--ink);
    background: rgba(255, 255, 255, 0.85);
}

.btn-danger {
    background: linear-gradient(135deg, #c58d8d, #b57878);
}

.btn-small {
    padding: 5px 12px;
    font-size: 0.72rem;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 16px;
}

.card {
    padding: 1.2rem 1.25rem 1.15rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 8px 28px rgba(0, 20, 40, 0.045);
    display: flex;
    flex-direction: column;
}

.card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 0.6rem;
}

.chip {
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 0.67rem;
    color: rgba(50, 70, 110, 0.65);
    background: rgba(139, 158, 183, 0.12);
    border: 1px solid rgba(139, 158, 183, 0.15);
}

.chip.warn {
    color: #8b5a2b;
    background: rgba(196, 168, 112, 0.16);
    border-color: rgba(196, 168, 112, 0.3);
}

.chip.ok {
    color: #396c50;
    background: rgba(95, 150, 115, 0.12);
    border-color: rgba(95, 150, 115, 0.22);
}

.card .meta {
    font-size: 0.73rem;
    color: var(--muted);
    line-height: 1.7;
    margin-bottom: 0.6rem;
}

.card .actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: auto;
    padding-top: 0.4rem;
}

.card .heat {
    font-size: 0.72rem;
    color: var(--muted);
    margin-left: auto;
}

.empty {
    padding: 1.2rem 0;
    color: var(--muted);
    font-size: 0.85rem;
}

.pager {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    margin-top: 1.3rem;
    font-size: 0.78rem;
    color: var(--muted);
}

.tabs {
    display: flex;
    gap: 8px;
    margin: 1rem 0;
}

.tab {
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--muted);
    text-decoration: none;
    font-size: 0.78rem;
}

.tab.active {
    color: var(--ink);
    background: rgba(139, 158, 183, 0.14);
}

.form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 18px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.field.full {
    grid-column: 1 / -1;
}

label {
    font-size: 0.78rem;
    font-weight: 500;
    color: rgba(40, 60, 100, 0.76);
}

.req {
    color: #c08080;
    margin-left: 2px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="datetime-local"],
textarea,
input[type="search"] {
    width: 100%;
    padding: 9px 13px;
    border-radius: 14px;
    border: 1px solid rgba(139, 158, 183, 0.3);
    background: rgba(255, 255, 255, 0.7);
    font-family: inherit;
    font-size: 0.84rem;
    color: var(--ink);
    outline: none;
}

textarea {
    min-height: 90px;
    resize: vertical;
    line-height: 1.6;
}

input:focus,
textarea:focus {
    border-color: rgba(127, 149, 178, 0.7);
    box-shadow: 0 0 0 3px rgba(139, 158, 183, 0.08);
}

input[type="file"] {
    font-size: 0.78rem;
    color: var(--muted);
    padding: 7px 0;
}

.hint {
    font-size: 0.68rem;
    color: rgba(50, 70, 110, 0.48);
    line-height: 1.6;
}

.actions-row {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 1.4rem;
}

.notice {
    margin: 1rem 0;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: rgba(212, 197, 160, 0.16);
    border: 1px solid rgba(196, 168, 112, 0.3);
    font-size: 0.8rem;
    line-height: 1.8;
    color: rgba(80, 65, 40, 0.85);
}

.error {
    color: var(--danger);
    font-size: 0.8rem;
    margin: 0.6rem 0;
    white-space: pre-wrap;
}

.success {
    color: var(--ok);
    font-size: 0.8rem;
    margin: 0.6rem 0;
}

.footer {
    margin-top: 1.8rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
    font-size: 0.7rem;
    color: rgba(50, 70, 110, 0.42);
    line-height: 1.7;
}

.beian {
    margin-top: 0.9rem;
    text-align: center;
    font-size: 0.7rem;
    color: rgba(50, 70, 110, 0.42);
}

.footer .beian {
    margin-top: 0.35rem;
}

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

.beian a:hover {
    text-decoration: underline;
}

.auth-links {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--muted);
}

.auth-links a {
    color: var(--accent-dark);
    text-decoration: none;
}

.code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.76rem;
    background: rgba(139, 158, 183, 0.12);
    padding: 1px 5px;
    border-radius: 5px;
}

.reviewer-row,
.admin-row {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px dashed var(--line);
    font-size: 0.78rem;
}

.lock-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(196, 168, 112, 0.18);
    color: #8b5a2b;
}

.table-list {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.78rem;
}

.table-list th,
.table-list td {
    text-align: left;
    padding: 8px 6px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.table-list th {
    color: var(--muted);
    font-weight: 500;
}

@media (max-width: 720px) {
    body {
        padding: 1rem 0.75rem;
    }

    .dashboard {
        padding: 1.3rem 1.1rem 1.5rem;
        border-radius: 20px;
    }

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