/* ======================================================================
   打工人时光机 Worker Home
   设计：温暖渐变 Hero + 玻璃拟态卡片 + 完整黑夜模式
   ====================================================================== */

/* ---------- 主题变量 ---------- */
.wh-hero {
    --wh-amber: #f59e0b;
    --wh-orange: #f97316;
    --wh-rose: #f43f5e;
    --wh-ink: #1f2937;
    --wh-ink-soft: #4b5563;
    --wh-card-bg: rgba(255, 255, 255, 0.86);
    --wh-card-border: rgba(255, 255, 255, 0.9);
    --wh-shadow: 0 16px 40px rgba(245, 158, 11, 0.16);
    --wh-text-on-gradient: #fff;
}

:root[data-theme="dark"] .wh-hero {
    --wh-ink: #f1f5f9;
    --wh-ink-soft: #cbd5e1;
    --wh-card-bg: rgba(19, 28, 49, 0.72);
    --wh-card-border: rgba(255, 255, 255, 0.10);
    --wh-shadow: 0 18px 44px rgba(0, 0, 0, 0.45);
}

/* ---------- Hero ---------- */
.wh-hero {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    padding: 44px 32px 36px;
    text-align: center;
    background:
        radial-gradient(900px 420px at 12% -10%, rgba(255, 214, 120, 0.55) 0%, transparent 55%),
        radial-gradient(760px 400px at 90% 110%, rgba(255, 141, 90, 0.45) 0%, transparent 55%),
        linear-gradient(135deg, #fbbf24 0%, #f59e0b 34%, #f97316 72%, #ef4444 120%);
    box-shadow: var(--wh-shadow);
}

:root[data-theme="dark"] .wh-hero {
    background:
        radial-gradient(900px 420px at 12% -10%, rgba(245, 158, 11, 0.28) 0%, transparent 55%),
        radial-gradient(760px 400px at 90% 110%, rgba(244, 63, 94, 0.26) 0%, transparent 55%),
        linear-gradient(135deg, #1a1428 0%, #221a33 40%, #2d1e38 75%, #33202f 120%);
    border: 1px solid rgba(245, 158, 11, 0.18);
}

.wh-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    pointer-events: none;
}
.wh-glow-1 { width: 320px; height: 320px; top: -120px; left: -80px; background: rgba(255, 255, 255, 0.35); }
.wh-glow-2 { width: 260px; height: 260px; bottom: -110px; right: -60px; background: rgba(255, 236, 179, 0.4); }
:root[data-theme="dark"] .wh-glow-1 { background: rgba(245, 158, 11, 0.20); }
:root[data-theme="dark"] .wh-glow-2 { background: rgba(244, 63, 94, 0.16); }

.wh-greet {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.94);
    letter-spacing: 0.3px;
    margin-bottom: 10px;
    position: relative;
}
.wh-greet-icon { font-size: 20px; }
.wh-dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(255, 255, 255, 0.55); }
:root[data-theme="dark"] .wh-greet { color: #fcd34d; }

.wh-clock {
    font-size: 58px;
    font-weight: 800;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
    color: var(--wh-text-on-gradient);
    text-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
    letter-spacing: 2px;
    position: relative;
}
:root[data-theme="dark"] .wh-clock { color: #fde68a; text-shadow: 0 4px 22px rgba(0, 0, 0, 0.5); }

.wh-status {
    display: inline-block;
    margin-top: 12px;
    padding: 7px 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    color: #7c2d12;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(6px);
    position: relative;
}
:root[data-theme="dark"] .wh-status { color: #fde68a; background: rgba(245, 158, 11, 0.14); }

.wh-sub {
    margin-top: 10px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.82);
    position: relative;
}
:root[data-theme="dark"] .wh-sub { color: rgba(253, 230, 138, 0.65); }

/* ---------- 主倒计时卡 ---------- */
.wh-main-card {
    margin-top: 30px;
    position: relative;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
    border-radius: 18px;
    padding: 26px 20px 22px;
    background: var(--wh-card-bg);
    border: 1px solid var(--wh-card-border);
    backdrop-filter: blur(10px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}
:root[data-theme="dark"] .wh-main-card { box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5); }

.wh-main-label {
    font-size: 16px;
    font-weight: 700;
    color: var(--wh-ink);
}
.wh-main-icon { margin-right: 6px; }

.wh-main-time {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 14px;
}
.wh-num {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 78px;
}
.wh-num > span:first-child {
    font-size: 46px;
    font-weight: 800;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
    color: var(--wh-orange);
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.wh-unit { margin-top: 4px; font-size: 12px; color: var(--wh-ink-soft); letter-spacing: 2px; }
.wh-colon {
    font-size: 40px;
    font-weight: 800;
    color: rgba(249, 115, 22, 0.45);
    padding-bottom: 16px;
    font-variant-numeric: tabular-nums;
}

.wh-main-msg {
    margin-top: 12px;
    font-size: 14px;
    font-weight: 600;
    color: var(--wh-rose);
}

/* ---------- 次卡片 ---------- */
.wh-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 20px;
}
.wh-card {
    border-radius: 16px;
    padding: 20px 18px;
    background: var(--wh-card-bg);
    border: 1px solid var(--wh-card-border);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.wh-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.10);
}
:root[data-theme="dark"] .wh-card {
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
}
:root[data-theme="dark"] .wh-card:hover {
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.5);
}

.wh-card-top {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--wh-ink);
}
.wh-card-icon { font-size: 20px; }
.wh-card-num {
    margin-top: 12px;
    font-size: 40px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--wh-ink);
}
.wh-card-unit { font-size: 12px; color: var(--wh-ink-soft); margin-left: 4px; }
.wh-card-sub { margin-top: 6px; font-size: 12px; color: var(--wh-ink-soft); }

.wh-card-bar {
    margin-top: 14px;
    height: 6px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.08);
    overflow: hidden;
}
:root[data-theme="dark"] .wh-card-bar { background: rgba(255, 255, 255, 0.08); }
.wh-card-fill {
    height: 100%;
    width: 0;
    border-radius: 999px;
    transition: width 0.8s ease;
}
.wh-fill-weekend { background: linear-gradient(90deg, #06b6d4, #3b82f6); }
.wh-fill-pay { background: linear-gradient(90deg, #10b981, #84cc16); }
.wh-fill-work { background: linear-gradient(90deg, #f59e0b, #f43f5e); }

/* ---------- 区块 ---------- */
.wh-section {
    margin-top: 34px;
    border-radius: 18px;
    padding: 26px 24px;
    background: var(--wh-card-bg);
    border: 1px solid var(--wh-card-border);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
}
:root[data-theme="dark"] .wh-section {
    background: var(--c-bg-card, #131c31);
    border-color: var(--c-border, rgba(255, 255, 255, 0.08));
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.3);
}

.wh-section-head h2 {
    font-size: 20px;
    font-weight: 800;
    color: var(--wh-ink);
    margin: 0;
}
.wh-section-head p {
    margin: 8px 0 0;
    font-size: 13px;
    color: var(--wh-ink-soft);
}

/* ---------- 表单 ---------- */
.wh-form {
    margin-top: 18px;
    padding: 18px;
    border-radius: 14px;
    background: rgba(249, 115, 22, 0.05);
    border: 1px dashed rgba(249, 115, 22, 0.35);
}
:root[data-theme="dark"] .wh-form {
    background: rgba(245, 158, 11, 0.06);
    border-color: rgba(245, 158, 11, 0.25);
}
.wh-form-row {
    display: grid;
    grid-template-columns: 1.4fr 1fr 0.8fr 1fr;
    gap: 12px;
    align-items: end;
}
.wh-field { display: flex; flex-direction: column; gap: 6px; }
.wh-field label {
    font-size: 12px;
    font-weight: 700;
    color: var(--wh-ink-soft);
}
.wh-field input,
.wh-field select {
    height: 40px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: #fff;
    color: var(--wh-ink);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
:root[data-theme="dark"] .wh-field input,
:root[data-theme="dark"] .wh-field select {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.12);
    color: var(--wh-ink);
}
.wh-field input:focus,
.wh-field select:focus {
    border-color: var(--wh-orange);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.18);
}
.wh-check-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    color: var(--wh-ink);
    font-weight: 600;
    height: 40px;
}
.wh-check-label input { width: 16px; height: 16px; accent-color: var(--wh-orange); }

.wh-add-btn {
    height: 40px;
    padding: 0 18px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}
.wh-add-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(249, 115, 22, 0.4); }
.wh-add-btn:active { transform: translateY(0); }

/* ---------- 纪念日列表 ---------- */
.wh-ann-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 18px;
}
.wh-ann-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border-radius: 14px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
:root[data-theme="dark"] .wh-ann-item {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}
.wh-ann-item:hover { transform: translateY(-3px); box-shadow: 0 10px 22px rgba(0, 0, 0, 0.10); }
.wh-ann-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    background: rgba(249, 115, 22, 0.10);
    flex-shrink: 0;
}
.wh-ann-body { flex: 1; min-width: 0; }
.wh-ann-name {
    font-size: 15px;
    font-weight: 700;
    color: var(--wh-ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wh-ann-date { font-size: 12px; color: var(--wh-ink-soft); margin-top: 2px; }
.wh-ann-countdown { text-align: right; flex-shrink: 0; }
.wh-ann-days {
    font-size: 26px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--wh-orange);
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.wh-ann-days.is-today { background: linear-gradient(135deg, #10b981, #84cc16); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.wh-ann-days-label { font-size: 11px; color: var(--wh-ink-soft); }
.wh-ann-del {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 8px;
    background: rgba(239, 68, 68, 0.10);
    color: #ef4444;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease;
}
.wh-ann-del:hover { background: rgba(239, 68, 68, 0.20); transform: scale(1.06); }

.wh-ann-empty {
    margin-top: 20px;
    text-align: center;
    padding: 26px 0 10px;
    color: var(--wh-ink-soft);
}
.wh-empty-icon { font-size: 40px; margin-bottom: 8px; }

/* ---------- 设置区 ---------- */
.wh-settings {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 18px;
}
.wh-setting {
    padding: 16px;
    border-radius: 14px;
    background: rgba(59, 130, 246, 0.05);
    border: 1px dashed rgba(59, 130, 246, 0.3);
}
:root[data-theme="dark"] .wh-setting {
    background: rgba(59, 130, 246, 0.06);
    border-color: rgba(59, 130, 246, 0.25);
}
.wh-setting-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--wh-ink);
    margin-bottom: 10px;
}
.wh-setting-control {
    display: flex;
    gap: 10px;
    align-items: center;
}
.wh-setting-control input {
    flex: 1;
    height: 38px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: #fff;
    color: var(--wh-ink);
    font-size: 14px;
    outline: none;
}
:root[data-theme="dark"] .wh-setting-control input {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.12);
    color: var(--wh-ink);
}
.wh-save-btn {
    height: 38px;
    padding: 0 16px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.3);
    white-space: nowrap;
}
.wh-save-btn:hover { transform: translateY(-2px); }
.wh-save-btn:active { transform: translateY(0); }

/* ---------- 工具简介 ---------- */
.wh-info { margin-top: 34px; }
.detail-title-row .detail-icon.t-amber {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: #fff;
}
.badge.b-dark {
    background: linear-gradient(135deg, #312e81, #4338ca);
    color: #e0e7ff;
}

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
    .wh-cards { grid-template-columns: repeat(3, 1fr); gap: 12px; }
    .wh-card { padding: 16px 12px; }
    .wh-card-num { font-size: 32px; }
    .wh-form-row { grid-template-columns: 1fr 1fr; }
    .wh-ann-list { grid-template-columns: 1fr; }
    .wh-settings { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .wh-hero { padding: 30px 16px 26px; }
    .wh-clock { font-size: 44px; }
    .wh-main-time { gap: 4px; }
    .wh-num { min-width: 60px; }
    .wh-num > span:first-child { font-size: 34px; }
    .wh-colon { font-size: 30px; }
    .wh-cards { grid-template-columns: 1fr; }
    .wh-form-row { grid-template-columns: 1fr; }
    .wh-ann-days { font-size: 22px; }
}
