/* ==================== 极简精致版样式 ==================== */

:root {
    /* 核心配色：黑曜石与淡丁香 */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.12);
    --accent: #c7d2fe; /* 丁香紫 */
    --text-main: #f8fafc;
    --text-dim: rgba(248, 250, 252, 0.5);

    /* 字体族定义 */
    --font-serif: 'Noto Serif SC', serif;
    --font-sans: 'Outfit', 'PingFang SC', -apple-system, sans-serif;
}

/* 深色模式强化 */
body.dark-mode {
    --glass-bg: rgba(0, 0, 0, 0.25);
    --glass-border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased; /* 字体抗锯齿优化 */
}

body {
    font-family: var(--font-sans);
    color: var(--text-main);
    background: #020617;
    height: 100vh;
    overflow: hidden;
    line-height: 1.5;
}

/* 背景滤镜增强 */
.background {
    position: fixed;
    inset: 0;
    z-index: -1;
    background: var(--bg-image) center/cover no-repeat;
    transition: 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.background::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, transparent 0%, rgba(0,0,0,0.45) 100%);
}

/* 容器布局优化 */
.container {
    max-width: 1000px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8vh 24px;
    gap: 50px;
    overflow-y: auto;
    scrollbar-width: none; /* 隐藏滚动条 */
}
.container::-webkit-scrollbar { display: none; }

/* 头部：时间与天气 */
.v-header { text-align: center; animation: slideDown 1.2s ease; }
.hero-time {
    font-size: 8rem;
    font-weight: 100;
    letter-spacing: -6px;
    line-height: 0.9;
    margin: 15px 0;
    text-shadow: 0 10px 40px rgba(0,0,0,0.3);
}
.status-bar {
    font-size: 0.85rem;
    letter-spacing: 4px;
    opacity: 0.7;
    text-transform: uppercase;
    font-weight: 500;
}
.aqi-tag {
    margin-left: 12px;
    border: 1px solid var(--glass-border);
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    background: rgba(255,255,255,0.05);
}

/* 文案区：衬线体魅力 */
.motto-area {
    font-family: var(--font-serif);
    max-width: 650px;
    margin-top: 20px;
}
#mottoText {
    font-size: 1.35rem;
    font-weight: 500;
    line-height: 1.8;
    letter-spacing: 0.8px;
    background: linear-gradient(to bottom, #fff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
#mottoFrom {
    font-size: 0.85rem;
    opacity: 0.4;
    margin-top: 15px;
    font-family: var(--font-sans);
    font-weight: 500;
}

/* 搜索框：浮动质感 */
.search-area { width: 100%; max-width: 520px; }
.search-glass {
    background: var(--glass-bg);
    backdrop-filter: blur(40px) saturate(150%);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 18px 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.search-glass:focus-within {
    background: rgba(255,255,255,0.12);
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.6);
}
#searchInput {
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 300;
}
#searchInput::placeholder { color: var(--text-dim); }

.engine-pills { display: flex; justify-content: center; gap: 12px; margin-top: 20px; }
.engine-btn {
    background: transparent;
    color: #fff;
    border: none;
    font-size: 0.8rem;
    opacity: 0.35;
    cursor: pointer;
    transition: 0.3s;
    padding: 4px 12px;
    border-radius: 20px;
}
.engine-btn.active {
    opacity: 1;
    color: var(--accent);
    background: rgba(255,255,255,0.08);
}

/* 磁贴区：平滑律动 */
.shortcuts-container { width: 100%; animation: slideUp 1s ease both; animation-delay: 0.3s; }
.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 24px;
    justify-content: center;
}

.shortcut-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    border-radius: 30px;
    padding: 30px 15px;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}
.shortcut-card:hover {
    transform: translateY(-12px) scale(1.03);
    background: rgba(255,255,255,0.12);
    border-color: var(--accent);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}
.shortcut-card .icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
    filter: drop-shadow(0 8px 15px rgba(0,0,0,0.2));
}
.shortcut-card .name {
    font-size: 0.85rem;
    opacity: 0.85;
    font-weight: 400;
}

/* 删除按钮微调 */
.del-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    opacity: 0;
    color: #fff;
    border: none;
    background: rgba(255,255,255,0.1);
    width: 22px; height: 22px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 10px;
    transition: 0.3s;
}
.shortcut-card:hover .del-btn { opacity: 0.6; }

/* 控件按钮 */
.floating-controls { position: fixed; right: 40px; bottom: 40px; display: flex; flex-direction: column; gap: 18px; z-index: 100; }
.ctrl-btn {
    width: 56px; height: 56px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: #fff;
    backdrop-filter: blur(15px);
    cursor: pointer;
    transition: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
}
.ctrl-btn:hover {
    background: var(--accent);
    color: #000;
    transform: scale(1.15) rotate(10deg);
    box-shadow: 0 15px 30px rgba(199, 210, 254, 0.3);
}

.bg-credit {
    position: fixed;
    left: 40px;
    bottom: 40px;
    font-size: 0.8rem;
    opacity: 0.3;
    font-weight: 500;
}

/* 模态框优化 */
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(2, 6, 23, 0.85);
    backdrop-filter: blur(10px);
    display: none; align-items: center; justify-content: center; z-index: 200;
}
.modal-overlay.active { display: flex; animation: fadeIn 0.3s ease; }
.glass-modal {
    background: #0f172a;
    padding: 35px;
    border-radius: 32px;
    width: 380px;
    border: 1px solid var(--glass-border);
    box-shadow: 0 25px 50px rgba(0,0,0,0.5);
}
.glass-modal h3 { margin-bottom: 25px; font-weight: 500; letter-spacing: 1px; }
.input-group input {
    width: 100%; padding: 14px 18px; margin-bottom: 12px;
    border-radius: 16px; border: 1px solid #1e293b;
    background: #020617; color: #fff; outline: none;
    transition: 0.3s;
}
.input-group input:focus { border-color: var(--accent); }
.modal-btns { display: flex; justify-content: flex-end; gap: 12px; margin-top: 20px; }
.btn { padding: 12px 24px; border-radius: 14px; cursor: pointer; border: none; font-weight: 600; font-size: 0.9rem; transition: 0.3s; }
.btn.solid { background: var(--accent); color: #000; }
.btn.solid:hover { opacity: 0.9; transform: scale(1.05); }
.btn.ghost { background: transparent; color: #64748b; }

/* 动画库 */
@keyframes slideDown { from { opacity: 0; transform: translateY(-30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* 移动端细化 */
@media (max-width: 650px) {
    .hero-time { font-size: 5.5rem; }
    .grid-layout { grid-template-columns: repeat(3, 1fr); gap: 15px; }
    .container { padding-top: 5vh; }
}