/* ========================================
   INDEX.HTML - 首页样式
   ======================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }

body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--color-text);
    background: var(--color-body-bg);
    overflow: hidden;
}

.page {
    display: flex;
    height: 100vh;
    max-width: 1200px;
    margin: 0 auto;
    background: var(--color-surface);
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}

/* Left Brand Panel */
.brand {
    flex: 1;
    background: var(--gradient-primary);
    color: var(--color-text-inverse);
    padding: 40px 35px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}
.brand::before {
    content: '';
    position: absolute;
    top: -100px; right: -100px;
    width: 300px; height: 300px;
    background: rgba(255,255,255,0.08);
    border-radius: 50%;
}
.brand::after {
    content: '';
    position: absolute;
    bottom: -80px; left: -80px;
    width: 250px; height: 250px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
}
.brand-content {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.logo-area {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 40px;
}
.logo-icon {
    width: 48px; height: 48px;
    background: rgba(255,255,255,0.2);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
}
.logo-text { font-size: 20px; font-weight: 700; }

.brand-hero {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.brand h1 {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 16px;
    letter-spacing: 0.5px;
}
.brand h1 .accent {
    color: var(--color-accent);
}
.brand-desc {
    font-size: 16px;
    line-height: 1.7;
    opacity: 0.9;
    margin-bottom: 30px;
}
.feature-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.feature-tag {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.25);
    padding: 7px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

.brand-footer {
    margin-top: 30px;
    font-size: 13px;
    opacity: 0.6;
}

/* Right Panel */
.main {
    flex: 1.2;
    padding: 40px 45px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}
.main-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-text-dark);
}
.auth-btns { display: flex; gap: 8px; }
.auth-btns a {
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}
.auth-btns .btn-login {
    background: transparent;
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
}
.auth-btns .btn-login:hover { background: var(--color-hover-bg); }
.auth-btns .btn-register {
    background: var(--gradient-primary);
    color: var(--color-text-inverse);
}
.auth-btns .btn-register:hover { transform: translateY(-1px); box-shadow: var(--shadow-primary); }

/* Notice */
.notice {
    background: var(--gradient-notice);
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    color: var(--color-notice-text);
    line-height: 1.6;
    white-space: pre-wrap;
    margin-bottom: 20px;
}

/* Section Title */
.section-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}
.feature-card {
    background: var(--gradient-primary);
    color: var(--color-text-inverse);
    padding: 16px 12px;
    border-radius: 12px;
    text-align: center;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: all 0.25s ease;
    min-height: 100px;
}
.feature-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-primary-hover); }
.feature-card.green { background: var(--gradient-green); }
.feature-card.orange { background: var(--gradient-orange); }
.feature-card.pink { background: var(--gradient-pink); }
.feature-card .icon { font-size: 30px; line-height: 1; }
.feature-card .title { font-size: 14px; font-weight: 700; }
.feature-card .desc { font-size: 11px; opacity: 0.85; }

/* Test Grid */
.test-section { margin-bottom: 15px; }
.test-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}
.test-btn {
    padding: 15px 10px;
    border: none;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    color: var(--color-text-inverse);
}
.test-btn.number { background: var(--gradient-primary); }
.test-btn.time { background: var(--gradient-green); }
.test-btn.date { background: var(--gradient-pink); }
.test-btn.phone { background: var(--gradient-cyan); }
.test-btn:hover { transform: translateY(-2px); }
.test-btn .icon { font-size: 24px; line-height: 1; }

/* Bottom */
.bottom-bar {
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid var(--color-border);
    text-align: center;
}
.logs-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 9px 22px;
    background: transparent;
    border: 1px solid var(--color-primary);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-primary);
    cursor: pointer;
    transition: all 0.2s;
}
.logs-btn:hover { background: var(--color-hover-bg); }

/* Modal */
.logs-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0; top: 0;
    width: 100%; height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}
.logs-modal-content {
    background-color: var(--color-surface);
    margin: 5% auto;
    padding: 25px;
    border-radius: 16px;
    width: 90%;
    max-width: 550px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
}
.logs-modal-content h3 { color: var(--color-text); margin-bottom: 16px; }
.logs-close { position: absolute; right: 18px; top: 12px; font-size: 24px; font-weight: bold; cursor: pointer; color: var(--color-text-light); }
.logs-close:hover { color: var(--color-text); }
.logs-loading { text-align: center; color: var(--color-text-light); padding: 30px; }
.log-item { background: var(--color-surface-alt); border-left: 4px solid var(--color-primary); border-radius: 8px; padding: 12px; margin-bottom: 10px; }
.log-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.log-title { font-weight: 600; color: var(--color-text); font-size: 14px; }
.log-version { background: var(--gradient-primary); color: var(--color-text-inverse); padding: 2px 8px; border-radius: 10px; font-size: 10px; font-weight: 600; }
.log-date { font-size: 11px; color: var(--color-text-light); margin-bottom: 4px; }
.log-content { font-size: 12px; color: var(--color-text-secondary); line-height: 1.5; white-space: pre-wrap; }

/* Mobile */
@media screen and (max-width: 768px) {
    body { overflow: auto; }
    .page { flex-direction: column; height: auto; min-height: 100vh; }
    .brand { padding: 28px 22px; min-height: 260px; }
    .brand h1 { font-size: 28px; }
    .brand-desc { font-size: 14px; }
    .main { padding: 24px 22px; }
    .main-header h2 { font-size: 20px; }
    .feature-grid { grid-template-columns: repeat(2, 1fr); }
    .test-grid { grid-template-columns: repeat(2, 1fr); }
    .feature-card { min-height: 85px; padding: 14px 10px; }
    .feature-card .icon { font-size: 24px; }
    .feature-card .title { font-size: 13px; }
    .test-btn { padding: 13px 8px; font-size: 12px; }
    .test-btn .icon { font-size: 22px; }
}