/* ============================================================
   谁是卧底 - 基础样式（设计令牌 / 重置 / 布局）
   主题：暗色侦探风 · 金色点缀
   ============================================================ */

:root {
    --bg-0: #0b0f1a;
    --bg-1: #111627;
    --bg-2: #1a2136;
    --bg-3: #232c46;

    --card: rgba(255, 255, 255, 0.045);
    --card-hover: rgba(255, 255, 255, 0.08);
    --line: rgba(255, 255, 255, 0.09);
    --line-strong: rgba(255, 255, 255, 0.16);

    --text-0: #f4f6fb;
    --text-1: #b6bed0;
    --text-2: #7c8598;

    --accent: #ffb84d;
    --accent-2: #ff8f3d;
    --accent-soft: rgba(255, 184, 77, 0.14);

    --success: #3fd6a5;
    --danger: #ff6b6b;
    --info: #5aa9ff;

    --grad-accent: linear-gradient(135deg, #ffd27a 0%, #ff9d3b 100%);
    --grad-danger: linear-gradient(135deg, #ff8a8a 0%, #ff4d6d 100%);
    --grad-info: linear-gradient(135deg, #7cc4ff 0%, #4d82ff 100%);

    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;

    --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.35);
    --shadow-soft: 0 6px 18px rgba(0, 0, 0, 0.25);

    --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    height: 100%;
}

body {
    font-family: var(--font);
    background: var(--bg-0);
    color: var(--text-0);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* 全局背景氛围 */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(900px 500px at 85% -10%, rgba(255, 158, 59, 0.14), transparent 60%),
        radial-gradient(700px 450px at -10% 110%, rgba(74, 122, 255, 0.12), transparent 60%),
        var(--bg-0);
}

a {
    color: var(--accent);
    text-decoration: none;
}

button {
    font-family: inherit;
    border: none;
    cursor: pointer;
    background: none;
    color: inherit;
}

input, textarea {
    font-family: inherit;
    color: inherit;
}

::placeholder {
    color: var(--text-2);
}

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-thumb {
    background: var(--bg-3);
    border-radius: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}

/* ---------- 通用布局 ---------- */
.container {
    max-width: 560px;
    margin: 0 auto;
    padding: 20px 18px calc(40px + var(--safe-bottom));
    min-height: 100%;
}

.page {
    animation: pageIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes pageIn {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.4s ease both;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ---------- 顶部应用栏 ---------- */
.app-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 6px 0 16px;
}

.app-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
}

.app-logo {
    width: 38px;
    height: 38px;
    flex: none;
    display: block;
    filter: drop-shadow(0 4px 12px rgba(255, 158, 59, 0.35));
}

/* ---------- 首页 ---------- */
.hero {
    text-align: center;
    padding: 34px 0 8px;
}

.hero .hero-logo {
    width: 110px;
    height: 110px;
    margin: 0 auto 22px;
    filter: drop-shadow(0 10px 30px rgba(255, 158, 59, 0.35));
    animation: floaty 4s ease-in-out infinite;
}

@keyframes floaty {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-8px); }
}

.hero h1 {
    font-size: 34px;
    font-weight: 800;
    letter-spacing: 6px;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    margin-top: 10px;
    color: var(--text-1);
    font-size: 15px;
    letter-spacing: 1px;
}

.hero .sub-chip {
    display: inline-block;
    margin-top: 14px;
    padding: 6px 16px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    color: var(--text-1);
    font-size: 13px;
    background: var(--card);
}

/* 首页按钮区 */
.home-actions {
    margin-top: 34px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.home-action {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border-radius: var(--radius-lg);
    background: var(--card);
    border: 1px solid var(--line);
    transition: transform 0.2s, background 0.2s, border-color 0.2s;
    text-align: left;
    width: 100%;
}

.home-action:hover {
    transform: translateY(-3px);
    background: var(--card-hover);
    border-color: var(--line-strong);
}

.home-action:active {
    transform: scale(0.98);
}

.home-action .act-icon {
    width: 52px;
    height: 52px;
    flex: none;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.home-action .act-icon.primary {
    background: var(--grad-accent);
    color: #2a1a00;
}

.home-action .act-icon.secondary {
    background: var(--grad-info);
}

.home-action .act-title {
    font-size: 17px;
    font-weight: 700;
}

.home-action .act-desc {
    font-size: 13px;
    color: var(--text-2);
    margin-top: 2px;
}

.home-action .act-arrow {
    margin-left: auto;
    color: var(--text-2);
}

/* 会话恢复卡片 */
.resume-card {
    margin-top: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: var(--radius-md);
    border: 1px dashed var(--accent);
    background: var(--accent-soft);
    cursor: pointer;
    transition: transform 0.2s;
}

.resume-card:hover {
    transform: translateY(-2px);
}

.resume-card .resume-text {
    font-size: 14px;
    color: var(--text-0);
}

.resume-card .resume-text small {
    color: var(--text-2);
    display: block;
}

/* 页脚 */
.footer-note {
    margin-top: 40px;
    text-align: center;
    color: var(--text-2);
    font-size: 12px;
    letter-spacing: 1px;
}

/* 上传图片等通用内容（预留） */
.muted { color: var(--text-2); }
.text-center { text-align: center; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }