html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5I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I2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: absolute;
    display: block;
    width: 8rem;
    height: 8rem;
    inset: 20vh 0 auto 0;
    margin: 0 auto 0 auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

/* ==================== 管理后台样式 ==================== */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 220px;
    background: #1e293b;
    color: #e2e8f0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
}

.admin-logo {
    padding: 1rem 1.2rem;
    font-size: 1.1rem;
    border-bottom: 1px solid #334155;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.admin-nav {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 0;
}

.admin-nav-group {
    padding: 0.8rem 1.2rem 0.3rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.05em;
}

.admin-nav-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1.2rem;
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: all 0.15s;
}

.admin-nav-item:hover {
    background: #334155;
    color: #fff;
}

.admin-nav-item.active {
    background: #2563eb;
    color: #fff;
}

.admin-logout {
    color: #f87171;
}

.admin-logout:hover {
    background: #7f1d1d;
    color: #fff;
}

.admin-main {
    margin-left: 220px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.admin-topbar {
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 50;
}

.admin-content {
    padding: 1.5rem;
    flex: 1;
    background: #f8fafc;
}

.admin-page-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-card {
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    padding: 1.2rem;
    margin-bottom: 1rem;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th {
    text-align: left;
    padding: 0.75rem;
    background: #f1f5f9;
    font-weight: 600;
    font-size: 0.85rem;
    color: #475569;
    border-bottom: 2px solid #e2e8f0;
}

.admin-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.9rem;
}

.admin-table tr:hover {
    background: #f8fafc;
}

.admin-form-label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.3rem;
    font-size: 0.9rem;
}

/* 文件上传占位框 */
.upload-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 140px;
    border: 2px dashed #cbd5e1;
    border-radius: 0.5rem;
    background: #f8fafc;
    transition: all 0.2s;
}
.upload-placeholder:hover {
    border-color: #3b82f6;
    background: #eff6ff;
}

/* 文件上传预览 */
.upload-preview {
    position: relative;
    display: inline-block;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
}
.upload-preview-media {
    display: block;
    max-width: 100%;
    max-height: 200px;
    object-fit: cover;
}
.upload-preview-clear {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,0.6);
    color: #fff;
    font-size: 0.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.upload-preview-clear:hover {
    background: rgba(220,38,38,0.9);
}

.admin-form-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.375rem;
    font-size: 0.9rem;
}

.admin-form-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

.admin-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* ========== 主内容区 ========== */
.main-home {
    width: 100%;
}
.main-default {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem;
}

/* ========== 页脚 ========== */
.site-footer {
    background: #1d1d1f;
    color: #86868b;
    padding: 50px 40px 20px;
    margin-top: 0;
}
.footer-inner {
    max-width: 1400px;
    margin: 0 auto;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2.5rem;
}
.footer-brand {
    color: #fff;
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 0.8rem;
}
.footer-desc {
    font-size: 0.85rem;
    line-height: 1.6;
    margin: 0;
}
.footer-col h5 {
    color: #f5f5f7;
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0 0 1rem;
}
.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.footer-col li {
    margin-bottom: 0.6rem;
}
.footer-col a {
    color: #86868b;
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}
.footer-col a:hover {
    color: #fff;
}
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 1.2rem;
    text-align: center;
}
.footer-bottom p {
    font-size: 0.8rem;
    margin: 0;
}

/* ========== 导航栏 ========== */
.site-nav {
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding: 0.7rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}
.site-nav .navbar-brand {
    font-weight: 600;
    font-size: 1.15rem;
    letter-spacing: -0.01em;
}
.site-nav .nav-link {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.8) !important;
    transition: color 0.2s;
}
.site-nav .nav-link:hover {
    color: #fff !important;
}
.site-nav .dropdown-menu {
    background: rgba(30,30,30,0.95);
    border: 1px solid rgba(255,255,255,0.1);
    backdrop-filter: blur(20px);
}
.site-nav .dropdown-item {
    color: rgba(255,255,255,0.8);
    font-size: 0.88rem;
}
.site-nav .dropdown-item:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
}

/* ========== 首页 Hero ========== */
.hero-section {
    position: relative;
    background: linear-gradient(180deg, #000000 0%, #1d1d1f 100%);
    color: #fff;
    min-height: calc(100vh - 62px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    overflow: hidden;
}
.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}
.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}
.hero-subtitle {
    font-size: 1.25rem;
    color: #a1a1a6;
    line-height: 1.5;
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}
.hero-btn {
    display: inline-block;
    padding: 0.85rem 2rem;
    border-radius: 980px;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}
.hero-btn-primary {
    background: #0071e3;
    color: #fff;
}
.hero-btn-primary:hover {
    background: #0077ed;
    transform: scale(1.02);
}
.hero-btn-secondary {
    color: #2997ff;
    background: transparent;
}
.hero-btn-secondary:hover {
    text-decoration: underline;
}
.hero-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}
.hero-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
}
.hero-circle-1 {
    width: 400px;
    height: 400px;
    background: #0071e3;
    top: -100px;
    left: -100px;
}
.hero-circle-2 {
    width: 300px;
    height: 300px;
    background: #bf5af2;
    bottom: -50px;
    right: 10%;
}
.hero-circle-3 {
    width: 250px;
    height: 250px;
    background: #30d158;
    top: 30%;
    right: -50px;
}

/* ========== 通用区块 ========== */
.section-container {
    padding: 80px 40px;
}
.section-container > .section-header,
.section-container > .section-header-row,
.section-container > .feature-grid,
.section-container > .content-grid,
.section-container > .loading-skeleton {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}
.section-alt {
    background: #f5f5f7;
}
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}
.section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 2rem;
}
.section-title {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0;
}
.section-desc {
    color: #6e6e73;
    font-size: 1rem;
    margin: 0.3rem 0 0;
}
.section-more {
    color: #0071e3;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
}
.section-more:hover {
    text-decoration: underline;
}

/* ========== 功能卡片（Apple 两列风格） ========== */
.section-feature {
    padding: 60px 0 0;
}
.section-feature .section-header {
    padding: 0 40px 3rem;
}
.section-feature .feature-grid {
    max-width: none;
    gap: 8px;
}
.section-feature .feature-card {
    border-radius: 0;
    min-height: 380px;
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}
.feature-card {
    position: relative;
    background: linear-gradient(160deg, #2c2c2e 0%, #1d1d1f 60%, #000000 100%);
    color: #fff;
    border-radius: 0;
    padding: 3rem 2.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-height: 380px;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.3);
}
.feature-name {
    color: #fff;
}
.feature-desc {
    color: rgba(255,255,255,0.6);
}
.feature-link {
    color: #2997ff;
}
.feature-icon {
    width: 72px;
    height: 72px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
}
.feature-icon-1 { background: linear-gradient(135deg, #ff9f0a, #ff6b00); }
.feature-icon-2 { background: linear-gradient(135deg, #bf5af2, #7c3aed); }
.feature-icon-3 { background: linear-gradient(135deg, #0071e3, #0051d5); }
.feature-icon-4 { background: linear-gradient(135deg, #30d158, #28a745); }
.feature-icon-5 { background: linear-gradient(135deg, #ff453a, #d70015); }
.feature-icon-6 { background: linear-gradient(135deg, #64d2ff, #00c7be); }
.feature-name {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    letter-spacing: -0.01em;
}
.feature-desc {
    color: #6e6e73;
    font-size: 1rem;
    margin: 0 0 1.5rem;
    line-height: 1.5;
}
.feature-link {
    display: inline-block;
    color: #0071e3;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    margin-top: auto;
}
.feature-link:hover {
    text-decoration: underline;
}
.feature-arrow {
    display: none;
}

/* ========== 内容网格 ========== */
.content-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

/* ========== 加载骨架 ========== */
.loading-skeleton {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.skeleton-card {
    height: 280px;
    border-radius: 16px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ========== 底部 CTA ========== */
.cta-section {
    background: linear-gradient(180deg, #1d1d1f 0%, #000000 100%);
    color: #fff;
    padding: 80px 20px;
    text-align: center;
}
.cta-content {
    max-width: 600px;
    margin: 0 auto;
}
.cta-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 1rem;
    letter-spacing: -0.02em;
}
.cta-desc {
    color: #a1a1a6;
    font-size: 1.1rem;
    margin: 0 0 2rem;
}
.cta-btn {
    display: inline-block;
    padding: 0.85rem 2.5rem;
    border-radius: 980px;
    background: #0071e3;
    color: #fff;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}
.cta-btn:hover {
    background: #0077ed;
    transform: scale(1.02);
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
    .hero-title { font-size: 2.5rem; }
    .feature-grid, .content-grid, .loading-skeleton {
        grid-template-columns: repeat(2, 1fr);
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}
@media (max-width: 600px) {
    .hero-section { padding: 40px 16px; min-height: calc(100vh - 62px); }
    .hero-title { font-size: 2rem; }
    .hero-subtitle { font-size: 1rem; }
    .section-container { padding: 50px 16px; }
    .feature-grid, .content-grid, .loading-skeleton {
        grid-template-columns: 1fr;
    }
    .section-header-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    .cta-title { font-size: 1.8rem; }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .site-footer { padding: 40px 16px 16px; }
}

.admin-badge-success { background: #dcfce7; color: #166534; }
.admin-badge-warning { background: #fef3c7; color: #92400e; }
.admin-badge-danger { background: #fee2e2; color: #991b1b; }
.admin-badge-info { background: #dbeafe; color: #1e40af; }

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* 导航栏 dropdown-toggle 用 button 时重置默认样式 */
button.nav-link.dropdown-toggle {
    background: none;
    border: none;
    font: inherit;
    cursor: pointer;
    padding: 0.5rem 1rem;
    color: rgba(255,255,255,0.85);
}
button.nav-link.dropdown-toggle:hover,
button.nav-link.dropdown-toggle:focus {
    color: #fff;
    outline: none;
    box-shadow: none;
}

/* 登录页左右分栏布局 */
.login-split {
    display: flex;
    min-height: calc(100vh - 62px);
    background: linear-gradient(135deg, #1d1d1f 0%, #2c2c2e 50%, #000000 100%);
}

.login-left {
    flex: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: #fff;
}

.login-left-content {
    max-width: 480px;
}

.login-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: #e53935;
    color: #fff;
    font-weight: 700;
    font-size: 1.2rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.login-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.login-subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 2rem;
}

.login-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.login-features li {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.85);
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.login-features li:last-child {
    border-bottom: none;
}

.login-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.login-form-wrap {
    width: 100%;
    max-width: 400px;
}

@media (max-width: 900px) {
    .login-split {
        flex-direction: column;
    }
    .login-left {
        flex: none;
        padding: 2rem 1.5rem;
    }
    .login-title {
        font-size: 1.8rem;
    }
    .login-right {
        flex: none;
        padding: 2rem 1rem;
    }
}