/* Trang thời tiết KTTV - mobile-first */
body.page-thoitiet .site-footer {
    display: none;
}
body.page-thoitiet main.container,
body.page-thoitiet .container-fluid {
    max-width: none;
    padding-left: 0;
    padding-right: 0;
}
body.page-thoitiet .breadcrumb-wrap {
    display: none;
}

.wx-app {
    position: relative;
    min-height: calc(100vh - 56px);
    max-width: 480px;
    margin: 0 auto;
    padding: 0 0 1.25rem;
    color: #fff;
    font-size: 1.0625rem;
    line-height: 1.5;
    overflow-x: hidden;
}

.wx-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    background: linear-gradient(165deg, #5ba3e8 0%, #3d7fc4 35%, #2a5f9e 70%, #1e4a7a 100%);
    transition: background 0.6s ease;
}
.wx-bg.wx-bg--cloudy {
    background: linear-gradient(165deg, #6b8fa8 0%, #4a6d8a 40%, #3a5870 100%);
}
.wx-bg.wx-bg--rain {
    background: linear-gradient(165deg, #4a6278 0%, #364d62 50%, #2a3d4f 100%);
}
.wx-bg.wx-bg--night {
    background: linear-gradient(165deg, #1a2a44 0%, #0f1a2e 50%, #0a1220 100%);
}

.wx-screen {
    position: relative;
    z-index: 1;
    padding: 0.75rem 1rem 1rem;
}
.wx-screen[hidden] {
    display: none !important;
}

.wx-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}
.wx-header--simple {
    justify-content: center;
    margin-bottom: 1rem;
}
.wx-header-actions {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    flex-shrink: 0;
}
.wx-header-spacer {
    width: 2.75rem;
    height: 2.75rem;
    flex-shrink: 0;
}
.wx-location {
    flex: 1;
    text-align: center;
    font-weight: 600;
    font-size: 1.125rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wx-page-title {
    flex: 1;
    text-align: center;
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    color: #fff;
}
.wx-icon-btn {
    width: 2.75rem;
    height: 2.75rem;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}
.wx-icon-btn:active {
    background: rgba(255, 255, 255, 0.28);
}

.wx-hero {
    text-align: center;
    padding: 0.5rem 0 1rem;
}
.wx-hero-icon {
    font-size: 4rem;
    line-height: 1;
    margin-bottom: 0.35rem;
    opacity: 0.95;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}
.wx-hero-temp {
    font-size: clamp(3.5rem, 16vw, 5rem);
    font-weight: 300;
    line-height: 1;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.2);
}
.wx-hero-desc {
    font-size: 1.2rem;
    font-weight: 500;
    margin-top: 0.4rem;
    opacity: 0.95;
}

.wx-stats {
    display: flex;
    justify-content: center;
    gap: 0.35rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}
.wx-stat {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(15, 40, 70, 0.55);
    border-radius: 999px;
    padding: 0.55rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    backdrop-filter: blur(8px);
}
.wx-stat i {
    opacity: 0.85;
}

.wx-card {
    background: rgba(12, 35, 62, 0.72);
    border-radius: 1.1rem;
    padding: 1rem 1rem 0.85rem;
    margin-bottom: 1rem;
    backdrop-filter: blur(12px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}
.wx-card-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.wx-hourly {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
    -webkit-overflow-scrolling: touch;
}
.wx-hourly::-webkit-scrollbar {
    display: none;
}
.wx-hour-item {
    flex: 0 0 auto;
    min-width: 4rem;
    text-align: center;
    font-size: 0.95rem;
}
.wx-hour-item .wx-time {
    opacity: 0.9;
    margin-bottom: 0.35rem;
}
.wx-hour-item .wx-hicon {
    font-size: 1.5rem;
    margin-bottom: 0.3rem;
}
.wx-hour-item .wx-htemp {
    font-weight: 700;
}

.wx-daily {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}
.wx-day-row {
    display: grid;
    grid-template-columns: 6.25rem 2.25rem 1fr 2.75rem 2.75rem;
    align-items: center;
    gap: 0.4rem;
    font-size: 1rem;
}
.wx-day-label {
    font-weight: 600;
    white-space: nowrap;
}
.wx-day-icon {
    font-size: 1.35rem;
    text-align: center;
}
.wx-day-bar-wrap {
    position: relative;
    height: 0.45rem;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    overflow: hidden;
}
.wx-day-bar {
    position: absolute;
    top: 0;
    bottom: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, #f9a825, #ffca28);
}
.wx-day-temp {
    text-align: right;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}
.wx-day-temp--min {
    opacity: 0.85;
    font-weight: 500;
}

.wx-alert-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.wx-alert-card {
    background: rgba(12, 35, 62, 0.72);
    border-radius: 1rem;
    padding: 1rem;
    backdrop-filter: blur(12px);
}
.wx-alert-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 0.4rem;
}
.wx-alert-card p {
    margin: 0;
    font-size: 1rem;
    opacity: 0.95;
}
.wx-alert-card--none {
    border-left: 3px solid #66bb6a;
}
.wx-alert-card--warn {
    border-left: 3px solid #ffa726;
}

.wx-search-panel {
    background: rgba(12, 35, 62, 0.72);
    border-radius: 1rem;
    padding: 1.25rem;
    backdrop-filter: blur(12px);
}
.wx-search-hint {
    font-size: 1rem;
    opacity: 0.95;
    margin-bottom: 1rem;
    line-height: 1.5;
}
.wx-app .form-label {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.88) !important;
    margin-bottom: 0.4rem;
}
.wx-input {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    color: #fff;
}
.wx-input option {
    color: #212529;
    background: #fff;
}
.wx-input:disabled {
    opacity: 0.55;
}
.wx-input::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

/* Tom Select - nền kính mờ, chữ trắng rõ (tránh trắng trên trắng) */
.wx-app .ts-wrapper.form-select-tim-kiem.single .ts-control,
.wx-app .ts-wrapper.form-select-tim-kiem.multi .ts-control {
    background-color: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    color: #fff;
}
.wx-app .ts-wrapper.form-select-tim-kiem .ts-control .item {
    color: #fff;
}
.wx-app .ts-wrapper.form-select-tim-kiem .ts-control input,
.wx-app .ts-wrapper.form-select-tim-kiem .ts-control .items-placeholder {
    color: #fff;
}
.wx-app .ts-wrapper.form-select-tim-kiem .ts-control input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}
.wx-app .ts-wrapper.form-select-tim-kiem.focus .ts-control,
.wx-app .ts-wrapper.form-select-tim-kiem.dropdown-active .ts-control {
    border-color: rgba(255, 255, 255, 0.45);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.12);
}
.wx-app .ts-wrapper.form-select-tim-kiem.disabled .ts-control {
    background-color: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.75);
    opacity: 1;
}
.wx-app .ts-wrapper.form-select-tim-kiem.disabled .ts-control .item {
    color: rgba(255, 255, 255, 0.75);
}
.wx-app .ts-wrapper.form-select-tim-kiem.form-select-sm.single .ts-control {
    font-size: 1rem;
    padding: 0.5rem 2.25rem 0.5rem 0.75rem;
    min-height: calc(1.5em + 1rem + 3px);
}
.wx-btn-primary {
    background: #fff;
    color: #1565c0;
    font-weight: 700;
    font-size: 1.0625rem;
    border: none;
    border-radius: 999px;
    padding: 0.8rem 1.15rem;
}

.wx-loading {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.25);
}
.wx-loading[hidden] {
    display: none !important;
}
.wx-spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: wx-spin 0.8s linear infinite;
}
@keyframes wx-spin {
    to { transform: rotate(360deg); }
}

.wx-error {
    position: relative;
    z-index: 2;
    margin: 0 1rem 1rem;
    padding: 0.85rem 1rem;
    background: rgba(198, 40, 40, 0.9);
    border-radius: 0.75rem;
    font-size: 1rem;
    line-height: 1.5;
}
.wx-error[hidden] {
    display: none !important;
}

.wx-source {
    position: relative;
    z-index: 1;
    margin: 0;
    padding: 1rem 1rem calc(1rem + env(safe-area-inset-bottom, 0px));
    text-align: center;
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.82);
}

@media (min-width: 481px) {
    .wx-app {
        border-left: 1px solid rgba(255, 255, 255, 0.08);
        border-right: 1px solid rgba(255, 255, 255, 0.08);
    }
}
