:root {
    --bg: #f5f7fb;
    --panel: #ffffff;
    --text: #1c2430;
    --muted: #6b7280;
    --line: #e5e8ef;
    --accent: #2f6fed;
    --accent-dark: #2358c9;
    --accent-soft: #eaf1ff;
    --green: #0f9d58;
    --amber: #c77700;
    --radius: 14px;
    --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 10px 28px rgba(16, 24, 40, .05);
}

* {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-size: 15px;
    line-height: 1.7;
}

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

a:hover {
    text-decoration: underline;
}

h1, h2, h3 {
    line-height: 1.35;
    margin: 0 0 12px;
}

h2 {
    font-size: 1.25rem;
}

h3 {
    font-size: 1rem;
}

p {
    margin: 0 0 12px;
}

time, .big-clock, .calib-value, .city-clock, .compare-clock {
    font-variant-numeric: tabular-nums;
}

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 16px;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* 头部 */
.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(255, 255, 255, .94);
    border-bottom: 1px solid var(--line);
    backdrop-filter: saturate(180%) blur(8px);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 58px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--text);
    font-weight: 700;
    font-size: 1.02rem;
}

.brand:hover {
    text-decoration: none;
}

.brand-mark {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    position: relative;
}

.brand-mark::before,
.brand-mark::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    background: var(--accent);
    transform-origin: 0 50%;
}

.brand-mark::before {
    width: 5px;
    height: 2px;
    transform: translate(-1px, -1px) rotate(-90deg);
}

.brand-mark::after {
    width: 4px;
    height: 2px;
    transform: translate(-1px, -1px) rotate(25deg);
}

.site-nav {
    display: none;
    flex-direction: column;
    gap: 4px;
    position: absolute;
    left: 0;
    right: 0;
    top: 58px;
    background: var(--panel);
    border-bottom: 1px solid var(--line);
    padding: 10px 16px 14px;
}

.site-nav.open {
    display: flex;
}

.site-nav a {
    color: #374151;
    padding: 8px 0;
    font-size: .95rem;
}

.nav-toggle {
    border: 1px solid var(--line);
    background: var(--panel);
    color: var(--text);
    border-radius: 9px;
    padding: 6px 12px;
    font: inherit;
    font-size: .88rem;
    cursor: pointer;
}

/* 主区域 */
main {
    padding: 22px 0 44px;
}

.hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 22px;
    margin-bottom: 8px;
}

.eyebrow {
    color: var(--accent);
    font-size: .78rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin: 0 0 6px;
}

.hero h1,
.page-head h1 {
    font-size: clamp(1.55rem, 5vw, 2rem);
    margin-bottom: 10px;
}

.big-clock {
    display: block;
    font-size: clamp(2.7rem, 13vw, 4.6rem);
    font-weight: 650;
    letter-spacing: .01em;
    line-height: 1.08;
    margin: 2px 0 8px;
}

.hero-date {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    font-size: .92rem;
    margin: 0;
}

.tag {
    display: inline-block;
    background: var(--accent-soft);
    color: var(--accent-dark);
    border-radius: 999px;
    padding: 2px 10px;
    font-size: .78rem;
    line-height: 1.6;
}

.calibration {
    background: #fafbfe;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 14px;
}

.calib-item {
    padding: 7px 0;
    border-bottom: 1px dashed var(--line);
}

.calib-item:last-of-type {
    border-bottom: 0;
}

.calib-label {
    display: block;
    color: var(--muted);
    font-size: .78rem;
}

.calib-value {
    font-size: 1.12rem;
    font-weight: 600;
}

.calib-diff {
    color: var(--accent);
}

.calib-note {
    color: var(--muted);
    font-size: .76rem;
    margin: 6px 0 0;
}

.section {
    margin-top: 28px;
}

.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.section-more {
    font-size: .88rem;
}

.prose p {
    color: #374151;
    max-width: 72ch;
}

.page-head {
    padding: 8px 0 4px;
}

.lead {
    color: #4b5563;
    max-width: 74ch;
}

.muted {
    color: var(--muted);
    font-size: .84rem;
}

.muted-link {
    color: var(--muted);
}

/* 表格 */
.table-wrap {
    overflow-x: auto;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .88rem;
    white-space: nowrap;
}

.data-table th {
    text-align: left;
    font-weight: 600;
    color: var(--muted);
    background: #f8fafc;
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
}

.data-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #eef1f6;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr:hover {
    background: #fafcff;
}

.data-table td .muted {
    display: block;
    font-size: .76rem;
}

.fast {
    color: var(--green);
}

.slow {
    color: var(--amber);
}

/* 城市卡片 */
.city-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
}

.city-card {
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px 14px;
    color: var(--text);
    transition: border-color .15s ease, transform .15s ease;
}

.city-card:hover {
    border-color: #bfd0f5;
    text-decoration: none;
    transform: translateY(-1px);
}

.city-name {
    font-weight: 600;
    font-size: .94rem;
}

.city-clock {
    font-size: 1.32rem;
    font-weight: 600;
}

.city-meta {
    color: var(--muted);
    font-size: .76rem;
}

/* 工具卡片 */
.tool-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.tool-card {
    display: block;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 16px;
    color: var(--text);
}

.tool-card:hover {
    border-color: #bfd0f5;
    text-decoration: none;
}

.tool-card strong {
    display: block;
    margin-bottom: 2px;
}

.tool-card span {
    color: var(--muted);
    font-size: .84rem;
}

/* FAQ */
.faq details {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 8px;
}

.faq summary {
    cursor: pointer;
    font-weight: 600;
    font-size: .94rem;
}

.faq summary:hover {
    color: var(--accent);
}

.faq p {
    color: #4b5563;
    margin: 8px 0 0;
    font-size: .9rem;
}

/* 面包屑 */
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    font-size: .82rem;
    color: var(--muted);
    margin-top: 5px;
    margin-bottom: 14px;
}

.breadcrumb a {
    color: var(--muted);
}

.breadcrumb span[aria-current] {
    color: var(--text);
}

/* 城市页 */
.hero-city {
    margin-bottom: 0;
}

.compare-card {
    background: #fafbfe;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.compare-clock {
    font-size: 1.9rem;
    font-weight: 600;
    line-height: 1.25;
}

.compare-diff {
    font-weight: 600;
}

.compare-diff.fast {
    color: var(--green);
}

.compare-diff.slow {
    color: var(--amber);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.info-item {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 10px 12px;
    min-width: 0;
}

.info-item span {
    display: block;
    color: var(--muted);
    font-size: .76rem;
}

.info-item strong {
    display: block;
    font-weight: 600;
    font-size: .92rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.badge {
    display: inline-block;
    margin-left: 6px;
    background: var(--accent-soft);
    color: var(--accent-dark);
    border-radius: 999px;
    padding: 0 8px;
    font-size: .72rem;
}

/* 搜索 */
.search-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 18px 0 6px;
}

.search-bar input {
    flex: 1;
    min-width: 0;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--panel);
    font: inherit;
    color: var(--text);
}

.search-bar input:focus {
    outline: 2px solid var(--accent-soft);
    border-color: var(--accent);
}

.search-count {
    color: var(--muted);
    font-size: .8rem;
    white-space: nowrap;
}

.search-empty {
    background: var(--panel);
    border: 1px dashed var(--line);
    border-radius: 10px;
    padding: 14px;
    color: var(--muted);
}

.world-group h2 {
    margin-top: 4px;
}

.chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0 0 8px;
}

.chip {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 5px 12px;
    font-size: .85rem;
    color: var(--text);
}

.chip time {
    color: var(--accent);
    font-weight: 600;
    font-size: .82rem;
}

.chip:hover {
    border-color: #bfd0f5;
    text-decoration: none;
}

.directory-group h3 {
    margin: 14px 0 8px;
    color: #374151;
}

/* 工具表单 */
.tool-panels {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    min-width: 0;
}

.panel {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 18px;
    min-width: 0;
}

.panel h2 {
    font-size: 1.05rem;
}

.form {
    margin-bottom: 6px;
}

.form label {
    display: block;
    color: var(--muted);
    font-size: .8rem;
    margin-bottom: 6px;
}

.input-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.input-row input {
    flex: 1 1 170px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    font: inherit;
    background: #fff;
    color: var(--text);
}

.input-row input:focus {
    outline: 2px solid var(--accent-soft);
    border-color: var(--accent);
}

.btn {
    display: inline-block;
    border: 1px solid var(--accent);
    background: var(--accent);
    color: #fff;
    border-radius: 10px;
    padding: 9px 16px;
    font: inherit;
    font-size: .88rem;
    cursor: pointer;
    line-height: 1.5;
}

.btn:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    text-decoration: none;
}

.btn-ghost {
    background: transparent;
    color: var(--accent);
    border-color: #c9d8f7;
    padding: 6px 12px;
    font-size: .8rem;
}

.btn-ghost:hover {
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.result {
    margin: 14px 0 0;
    border-top: 1px solid var(--line);
}

.result > div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 0;
    border-bottom: 1px dashed var(--line);
}

.result > div:last-child {
    border-bottom: 0;
}

.result dt {
    color: var(--muted);
    font-size: .84rem;
}

.result dd {
    margin: 0;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    text-align: right;
    word-break: break-all;
}

/* 页脚 */
.site-footer {
    border-top: 1px solid var(--line);
    background: var(--panel);
    margin-top: 36px;
    padding-top: 22px;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-inner p {
    color: var(--muted);
    font-size: .82rem;
    margin: 4px 0 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    font-size: .84rem;
}

.footer-xmlmap {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 12px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px dashed var(--line);
    font-size: .78rem;
}

.footer-xmlmap-label {
    color: var(--muted);
    white-space: nowrap;
}

.footer-xmlmap-links {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 12px;
}

.footer-xmlmap-links a {
    color: #8a93a3;
    white-space: nowrap;
}

.footer-xmlmap-links a:hover {
    color: var(--accent);
}

.copyright {
    color: #9aa1ad;
    font-size: .76rem;
    padding-top: 14px;
    padding-bottom: 20px;
}

.copyright .update-time {
    margin-left: 8px;
    white-space: nowrap;
}

/* 桌面端 */
@media (min-width: 768px) {
    body {
        font-size: 15px;
    }

    .nav-toggle {
        display: none;
    }

    .site-nav {
        display: flex;
        flex-direction: row;
        position: static;
        background: none;
        border: 0;
        padding: 0;
        gap: 22px;
    }

    .site-nav a {
        font-size: .9rem;
        padding: 0;
    }

    .hero {
        grid-template-columns: 1.5fr 1fr;
        padding: 28px;
    }

    .big-clock {
        font-size: 4.3rem;
    }

    .calibration {
        align-self: start;
    }

    .tool-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .tool-panels {
        grid-template-columns: 1fr 1fr;
    }

    .info-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer-inner {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }

    .data-table {
        font-size: .9rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
    }
}

/* ================= 天气站组件 ================= */
.header-search {
    position: relative;
    display: none;
    flex: 1;
    max-width: 340px;
    margin: 0;
}

.header-search input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #f8fafc;
    font: inherit;
    font-size: .88rem;
    color: var(--text);
}

.header-search input:focus {
    outline: 2px solid var(--accent-soft);
    border-color: var(--accent);
    background: #fff;
}

.header-search button {
    position: absolute;
    right: 3px;
    top: 3px;
    bottom: 3px;
    padding: 0 12px;
    border: 0;
    border-radius: 7px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-size: .8rem;
    cursor: pointer;
}

.search-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 6px);
    z-index: 60;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(16, 24, 40, .12);
    max-height: 360px;
    overflow-y: auto;
}

.search-results a {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 12px;
    color: var(--text);
    font-size: .88rem;
    border-bottom: 1px solid #f1f4f9;
}

.search-results a:last-child {
    border-bottom: 0;
}

.search-results a:hover,
.search-results a.active {
    background: var(--accent-soft);
    text-decoration: none;
}

.search-results .sr-region {
    color: var(--muted);
    font-size: .76rem;
    white-space: nowrap;
}

.search-results .sr-empty {
    padding: 12px;
    color: var(--muted);
    font-size: .84rem;
}

.search-hero {
    margin: 14px 0 4px;
}

.search-hero form {
    display: flex;
    gap: 8px;
}

.search-hero input {
    flex: 1;
    min-width: 0;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--panel);
    font: inherit;
    font-size: .96rem;
}

.search-hero button {
    padding: 0 22px;
    border: 0;
    border-radius: 12px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    cursor: pointer;
}

/* 首页 */
.home-lead {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 14px;
    margin-top: 10px;
    margin-bottom: 12px;
}

.home-lead h1 {
    font-size: clamp(1.5rem, 5vw, 2.1rem);
    margin: 0;
}

.home-lead .muted {
    font-size: .86rem;
}

.wx-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
    gap: 10px;
}

.wx-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 13px 14px;
    color: var(--text);
    min-width: 0;
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.wx-card:hover {
    border-color: #bfd0f5;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(16, 24, 40, .07);
}

.wx-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 6px;
}

.wx-card-name {
    font-weight: 650;
    font-size: .95rem;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wx-card-region {
    display: block;
    color: var(--muted);
    font-size: .72rem;
    font-weight: 400;
}

.wx-card-temp {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 1.72rem;
    font-weight: 650;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}

.wx-card-temp .wi {
    width: 34px;
    height: 34px;
}

.wx-card-text {
    color: #4b5563;
    font-size: .82rem;
}

.wx-card-meta {
    color: var(--muted);
    font-size: .74rem;
    display: flex;
    flex-wrap: wrap;
    gap: 2px 8px;
}

.wx-card .aqi-badge {
    position: static;
    align-self: flex-start;
    margin-top: 2px;
}

.wx-card-temp sup {
    font-size: .4em;
    font-weight: 500;
    vertical-align: super;
    top: -.35em;
}

.wi {
    display: inline-block;
    width: 1em;
    height: 1em;
    vertical-align: -0.12em;
    flex: none;
}

/* 城市天气头图 */
.wx-hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
    margin-top: 10px;
    background: linear-gradient(135deg, #2f6fed 0%, #4f8ff7 55%, #7ab4ff 100%);
    color: #fff;
    border-radius: 18px;
    padding: 22px;
    box-shadow: 0 12px 30px rgba(47, 111, 237, .18);
}

.wx-hero a {
    color: #fff;
    text-decoration: underline;
}

.wx-hero-top {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.wx-hero-top h1 {
    color: #fff;
    font-size: clamp(1.4rem, 4.4vw, 1.9rem);
    margin: 0;
}

.wx-hero-tag {
    background: rgba(255, 255, 255, .18);
    border-radius: 999px;
    padding: 2px 10px;
    font-size: .76rem;
}

.wx-hero-now {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.wx-hero-icon {
    width: 82px;
    height: 82px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .14);
    border-radius: 20px;
}

.wx-hero-icon .wi {
    width: 62px;
    height: 62px;
}

.wx-hero-temp {
    font-size: clamp(3rem, 12vw, 4.4rem);
    font-weight: 650;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.wx-hero-temp sup {
    font-size: .34em;
    font-weight: 500;
    vertical-align: super;
    top: -0.2em;
}

.wx-hero-desc {
    font-size: .92rem;
    line-height: 1.7;
    opacity: .95;
}

.wx-hero-desc strong {
    font-weight: 600;
}

.wx-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.wx-stats li {
    background: rgba(255, 255, 255, .14);
    border-radius: 11px;
    padding: 9px 10px;
    min-width: 0;
}

.wx-stats span {
    display: block;
    font-size: .72rem;
    opacity: .8;
}

.wx-stats strong {
    display: block;
    font-size: .95rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wx-hero .aqi-badge {
    background: rgba(255, 255, 255, .92);
    color: var(--text);
}

.wx-hero-note {
    font-size: .74rem;
    opacity: .75;
    margin: 0;
}

/* 预警 */
.wx-alert {
    margin-top: 14px;
    background: #fff8e6;
    border: 1px solid #f3d9a4;
    border-radius: 12px;
    padding: 14px 16px;
}

.wx-alert h2 {
    color: #9a6200;
    font-size: .98rem;
    margin-bottom: 6px;
}

.wx-alert ul {
    margin: 0;
    padding-left: 18px;
}

.wx-alert li {
    color: #6b4a00;
    font-size: .86rem;
    margin-bottom: 4px;
}

.wx-alert .src {
    color: #9a7a3a;
    font-size: .74rem;
    margin: 6px 0 0;
}

/* 面板 */
.wx-panel {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 16px;
    min-width: 0;
}

.wx-panel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.wx-panel-head h2 {
    margin: 0;
    font-size: 1.05rem;
}

.wx-panel-head .muted {
    font-size: .78rem;
}

/* 24 小时 */
.hour-list {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
}

.hour-item {
    flex: none;
    width: 66px;
    text-align: center;
    padding: 8px 2px;
    border-radius: 9px;
}

.hour-item:hover {
    background: #f6f9ff;
}

.hour-item time {
    display: block;
    color: var(--muted);
    font-size: .74rem;
}

.hour-item .wi {
    width: 30px;
    height: 30px;
    margin: 4px 0 2px;
}

.hour-temp {
    display: block;
    font-size: .92rem;
    font-weight: 600;
}

.hour-pop {
    display: block;
    color: var(--accent);
    font-size: .7rem;
    min-height: 1em;
}

.wx-chart {
    display: block;
    width: 100%;
    height: auto;
    margin-top: 6px;
    overflow: visible;
}

.wx-chart text {
    font-size: 10px;
    fill: #6b7280;
    font-family: inherit;
}

.wx-chart .line {
    fill: none;
    stroke: #2f6fed;
    stroke-width: 2.2;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.wx-chart .area {
    fill: url(#wxGrad);
    opacity: .55;
}

.wx-chart .dot {
    fill: #fff;
    stroke: #2f6fed;
    stroke-width: 1.8;
}

/* 预报表格 */
.wx-table-wrap {
    overflow-x: auto;
}

.wx-days {
    width: 100%;
    border-collapse: collapse;
    font-size: .86rem;
    white-space: nowrap;
}

.wx-days th {
    text-align: left;
    font-weight: 500;
    color: var(--muted);
    font-size: .76rem;
    padding: 6px 8px;
    border-bottom: 1px solid var(--line);
}

.wx-days td {
    padding: 9px 8px;
    border-bottom: 1px solid #eff2f7;
    vertical-align: middle;
}

.wx-days tr:last-child td {
    border-bottom: 0;
}

.wx-days tr:hover td {
    background: #fafcff;
}

.wx-days .day-name {
    font-weight: 600;
}

.wx-days .day-date {
    display: block;
    color: var(--muted);
    font-size: .72rem;
    font-weight: 400;
}

.wx-days .wi {
    width: 28px;
    height: 28px;
    margin-right: 6px;
}

.wx-days .day-weather {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.wx-days .tmax {
    color: #d9480f;
    font-weight: 600;
}

.wx-days .tmin {
    color: #2f6fed;
    font-weight: 600;
}

.wx-days .pop {
    color: var(--accent);
}

/* AQI */
.aqi-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 999px;
    padding: 2px 9px;
    font-size: .74rem;
    line-height: 1.7;
    white-space: nowrap;
}

.aqi-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.aqi-good { background: #e6f7ee; color: #0f8a4a; }
.aqi-moderate { background: #fdf6e3; color: #a87300; }
.aqi-light { background: #fff0e6; color: #c25e00; }
.aqi-medium { background: #fdecea; color: #c0392b; }
.aqi-heavy { background: #f6e6f8; color: #8e24aa; }
.aqi-severe { background: #ece0e0; color: #7b1a1a; }

.aqi-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--shadow);
}

.aqi-hero-value {
    font-size: 3.4rem;
    font-weight: 650;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.aqi-hero-level {
    display: inline-block;
    border-radius: 999px;
    padding: 3px 12px;
    font-size: .84rem;
    margin-bottom: 4px;
}

.aqi-hero-advice {
    color: #4b5563;
    font-size: .88rem;
    max-width: 60ch;
}

.aqi-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    width: 100%;
}

.aqi-item {
    background: #fafbfe;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 9px 11px;
}

.aqi-item span {
    display: block;
    color: var(--muted);
    font-size: .72rem;
}

.aqi-item strong {
    display: block;
    font-size: .96rem;
    font-variant-numeric: tabular-nums;
}

.aqi-note {
    color: var(--muted);
    font-size: .76rem;
    margin: 10px 0 0;
}

/* 列表区 */
.sec-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.loc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
    gap: 8px;
}

.loc-card {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 9px 11px;
    color: var(--text);
    font-size: .88rem;
    min-width: 0;
}

.loc-card:hover {
    border-color: #bfd0f5;
    text-decoration: none;
    background: #fafcff;
}

.loc-card strong {
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.loc-card span {
    color: var(--muted);
    font-size: .72rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 历史文章条目 */
.entry-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.entry-item {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 11px 14px;
    color: var(--text);
    min-width: 0;
}

.entry-item:hover {
    border-color: #bfd0f5;
    text-decoration: none;
}

.entry-title {
    font-size: .9rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.entry-meta {
    color: var(--muted);
    font-size: .74rem;
    white-space: nowrap;
}

/* 历史表格 */
.history-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.history-stats .aqi-item {
    background: #fafbfe;
}

.month-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.month-tabs a {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 12px;
    font-size: .8rem;
    color: var(--text);
}

.month-tabs a.on,
.month-tabs a:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    text-decoration: none;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .85rem;
}

.history-table th,
.history-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #eff2f7;
    text-align: left;
    white-space: nowrap;
}

.history-table th {
    color: var(--muted);
    font-weight: 500;
    font-size: .76rem;
    background: #f8fafc;
}

.history-table tr:last-child td {
    border-bottom: 0;
}

.history-table .wi {
    width: 24px;
    height: 24px;
    margin-right: 4px;
}

.history-table .tmax { color: #d9480f; font-weight: 600; }
.history-table .tmin { color: #2f6fed; font-weight: 600; }

/* 提示条 */
.notice {
    background: #eef4ff;
    border: 1px solid #d6e3ff;
    border-radius: 10px;
    padding: 11px 14px;
    color: #34508a;
    font-size: .82rem;
    margin: 14px 0 0;
}

.notice.warn {
    background: #fff8e6;
    border-color: #f3d9a4;
    color: #8a5d00;
}

/* 内容文章 */
.article-body {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 20px;
}

.article-body p {
    color: #374151;
    max-width: 76ch;
}

.article-facts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin: 14px 0;
}

.article-facts .aqi-item {
    background: #fafbfe;
}

/* 空状态 */
.empty-state {
    background: var(--panel);
    border: 1px dashed var(--line);
    border-radius: 12px;
    padding: 22px 18px;
    text-align: center;
    color: var(--muted);
    font-size: .88rem;
}

.empty-state strong {
    display: block;
    color: var(--text);
    font-size: 1.05rem;
    margin-bottom: 6px;
}

@media (min-width: 560px) {
    .wx-stats {
        grid-template-columns: repeat(6, 1fr);
    }

    .history-stats {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 768px) {
    .header-search {
        display: block;
    }

    .wx-hero {
        grid-template-columns: 1.15fr 1fr;
        align-items: center;
        padding: 26px 28px;
    }

    .wx-stats {
        grid-template-columns: repeat(3, 1fr);
    }

    .sec-grid {
        grid-template-columns: 1fr 1fr;
    }

    .entry-list {
        grid-template-columns: 1fr 1fr;
    }

    .article-facts {
        grid-template-columns: repeat(4, 1fr);
    }

    .aqi-grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (max-width: 767px) {
    .header-inner {
        flex-wrap: wrap;
    }

    .site-nav {
        top: 58px;
    }

    .wx-hero {
        padding: 18px;
    }

    .wx-hero-icon {
        width: 64px;
        height: 64px;
        border-radius: 16px;
    }

    .wx-hero-icon .wi {
        width: 48px;
        height: 48px;
    }
}

.wx-hero-top,
.wx-hero-note {
    grid-column: 1 / -1;
}

.wx-chart {
    height: 76px;
}

.wx-alert details {
    margin-top: 6px;
}

.wx-alert summary {
    cursor: pointer;
    font-size: .88rem;
    font-weight: 600;
    color: #6b4a00;
}

.wx-alert details p {
    margin: 6px 0 0;
    font-size: .84rem;
    line-height: 1.7;
}

.section .wx-panel > h2:first-child,
.section > h1:first-child {
    margin-top: 0;
}

/* 天气时长页面 */
.variant-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 16px 0 4px;
}

.variant-nav .chip {
    background: var(--panel);
    border: 1px solid var(--line);
    color: var(--text);
    padding: 6px 12px;
    white-space: nowrap;
}

.variant-nav .chip:hover {
    border-color: #bfd0f5;
    text-decoration: none;
}

.variant-nav .chip.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.climate-table td,
.climate-table th {
    white-space: nowrap;
}

.region-list {
    margin-top: 10px;
}

/* 网站地图 */
.sitemap-list {
    display: grid;
    gap: 10px;
}

.sitemap-item {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px 14px;
}

.sitemap-item h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    line-height: 1.4;
}

.sitemap-item h3 a {
    color: var(--text);
}

.sitemap-variants {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 14px;
    font-size: .82rem;
    line-height: 1.9;
}

.sitemap-variants a {
    color: var(--muted);
}

.sitemap-variants a:hover {
    color: var(--accent);
    text-decoration: none;
}

.sitemap-group-title {
    margin: 18px 0 6px;
    font-size: .9rem;
    color: var(--muted);
    font-weight: 600;
}

.sitemap-segments {
    margin-top: 12px;
    padding: 12px 14px;
    background: #fafbfe;
    border: 1px dashed var(--line);
    border-radius: 12px;
}
