:root {
    --bg: #eef4fb;
    --bg-soft: #f7faff;
    --surface: rgba(255, 255, 255, 0.88);
    --surface-strong: #ffffff;
    --text: #0f172a;
    --text-soft: #516079;
    --text-muted: #6b7280;
    --border: rgba(148, 163, 184, 0.22);
    --border-strong: rgba(148, 163, 184, 0.35);

    --primary: #1d4ed8;
    --primary-hover: #1e40af;
    --primary-soft: rgba(29, 78, 216, 0.08);

    --accent: #38bdf8;
    --accent-soft: rgba(56, 189, 248, 0.12);

    --success: #0f766e;
    --danger: #b91c1c;

    --shadow-sm: 0 10px 30px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 18px 50px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 24px 80px rgba(15, 23, 42, 0.10);

    --radius-sm: 12px;
    --radius-md: 18px;
    --radius-lg: 24px;

    --container: 1200px;
    --transition: 0.2s ease;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.12), transparent 26%),
        radial-gradient(circle at top right, rgba(29, 78, 216, 0.10), transparent 24%),
        linear-gradient(180deg, #f6f9fe 0%, #eef4fb 100%);
    line-height: 1.5;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
}

button,
input,
textarea,
select {
    font: inherit;
}

.container {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
}

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

/* Header */

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: blur(16px);
    background: #f1f1f1;
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.site-header__inner {
    min-height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
}

.site-logo__image {
    display: block;
    width: 40px;
    height: 32px;
    object-fit: contain;
    flex: 0 0 auto;
}

.site-logo__text {
    display: inline-flex;
    align-items: baseline;
    font-weight: 800;
    font-size: 22px;
    letter-spacing: -0.03em;
    line-height: 2;
}

.site-logo__text-accent {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.site-logo__text-base {
    color: var(--text);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.site-nav a {
    color: var(--text-soft);
    text-decoration: none;
    font-weight: 600;
}

.site-nav a:hover {
    color: var(--text);
}

.site-main {
    padding-bottom: 64px;
}

.hero-home {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    gap: 28px;
    align-items: start;
}

.hero-home__content {
    min-width: 0;
}

.hero-home__badge {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: rgba(29, 78, 216, 0.08);
    color: var(--primary-hover);
    font-size: 14px;
    font-weight: 700;
}

.hero-home__features {
    display: grid;
    gap: 10px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
    color: var(--text-soft);
}

.hero-home__features li {
    position: relative;
    padding-left: 22px;
}

.hero-home__features li::before {
    content: "";
    position: absolute;
    top: 9px;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
}

.hero-home__aside {
    display: grid;
    gap: 18px;
}

.hero-weather-card {
    padding: 24px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(14px);
}

.hero-weather-card--soft {
    background: rgba(248, 251, 255, 0.88);
}

.hero-weather-card__label {
    margin-bottom: 12px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hero-weather-card h2 {
    margin: 0 0 12px;
    font-size: 26px;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.hero-weather-card p {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.7;
}

.home-section {
    padding: 8px 0 0;
}

@media (max-width: 900px) {
    .site-header__inner {
        min-height: 68px;
    }

    .site-nav {
        gap: 14px;
    }

    .hero-home {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .site-header__inner {
        min-height: 68px;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .site-nav {
        display: flex;
        align-items: center;
        gap: 12px;
        flex-wrap: nowrap;
        margin-left: auto;
    }

    .site-nav a {
        white-space: nowrap;
    }

    .hero-weather-card h2 {
        font-size: 22px;
    }
}

@media (max-width: 380px) {
    .site-header__inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-nav {
        margin-left: 0;
        flex-wrap: wrap;
    }
}

/* Main spacing */

main {
    padding-bottom: 64px;
}

section {
    position: relative;
}

.hero {
    padding: 72px 0 32px;
}

.hero--home {
    padding-top: 88px;
}

.hero__lead,
.hero p {
    max-width: 720px;
    margin: 0 0 28px;
    font-size: 18px;
    line-height: 1.7;
    color: var(--text-soft);
}

.hero h1 {
    margin: 0 0 16px;
    max-width: 820px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 0.98;
    letter-spacing: -0.05em;
    color: var(--text);
}

.section-header {
    margin-bottom: 20px;
}

.section-header h2,
.hero h2,
.city-card h2,
.home-section-card h2,
.forecast-section h2 {
    margin: 0;
    font-size: clamp(24px, 3vw, 32px);
    line-height: 1.1;
    letter-spacing: -0.03em;
}

/* Shared surfaces */

.surface,
.city-card,
.home-section-card,
.weather-now__main,
.weather-now__details,
.forecast-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(10px);
}

.weather-now__main {
    padding: 24px;
}

.weather-now__split {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.weather-now__left {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.weather-now__right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    flex-shrink: 0;
    text-align: right;
}

.weather-now__eyebrow {
    color: var(--primary);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.weather-now__temp {
    font-size: clamp(52px, 8vw, 72px);
    font-weight: 800;
    line-height: 0.95;
    letter-spacing: -0.04em;
}

.weather-now__icon {
    font-size: 56px;
    line-height: 1;
}

.weather-now__label {
    font-size: 18px;
    color: var(--text-soft);
    line-height: 1.3;
}

@media (max-width: 640px) {
    .weather-now__split {
        gap: 14px;
    }

    .weather-now__icon {
        font-size: 44px;
    }

    .weather-now__label {
        font-size: 16px;
    }
}

/* Search */

.search-box {
    position: relative;
    max-width: 520px;
    z-index: 30;
}

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

.search-form input {
    flex: 1;
    height: 56px;
    padding: 16px 18px;
    border: 1px solid var(--border-strong);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.94);
    color: var(--text);
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

@media (max-width: 640px) {
    .search-form input {
        min-height: 54px;
        padding: 16px 18px;
        font-size: 16px;
    }
}

.search-form input::placeholder {
    color: #94a3b8;
}

.search-form input:focus {
    border-color: rgba(29, 78, 216, 0.45);
    box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.08);
    background: #fff;
}

.search-form button,
.geo-guess__confirm,
.pagination a,
.button-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 56px;
    padding: 0 22px;
    border: 0;
    border-radius: 14px;
    cursor: pointer;
    background: linear-gradient(135deg, var(--primary) 0%, #2563eb 100%);
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    letter-spacing: -0.01em;
    transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
    box-shadow: 0 12px 24px rgba(29, 78, 216, 0.20);
}

.search-form button:hover,
.geo-guess__confirm:hover,
.pagination a:hover,
.button-primary:hover {
    transform: translateY(-1px);
    background: linear-gradient(135deg, var(--primary-hover) 0%, #1d4ed8 100%);
}

.search-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 14px;
}

.search-actions__link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.search-actions__link:hover {
    text-decoration: underline;
}

.geo-button,
.geo-guess__cancel {
    min-height: 48px;
    padding: 0 18px;
    border: 1px solid var(--border-strong);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    color: var(--text);
    cursor: pointer;
    font-weight: 600;
    transition: border-color var(--transition), background var(--transition), transform var(--transition);
}

.geo-button:hover,
.geo-guess__cancel:hover {
    transform: translateY(-1px);
    border-color: rgba(29, 78, 216, 0.24);
    background: #fff;
}

.geo-button:disabled {
    opacity: 0.7;
    cursor: wait;
}

/* Suggest */

.search-suggest {
    display: none;
    position: absolute;
    top: calc(45% + 8px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(17, 24, 39, 0.08);
    overflow: hidden;
    z-index: 50;
}

.search-suggest.is-visible {
    display: block;
}

.search-suggest__item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px 18px;
    text-decoration: none;
    color: var(--text);
    transition: background var(--transition);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

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

.search-suggest__item:hover {
    background: var(--bg-soft);
}

.search-suggest__item strong {
    font-size: 15px;
}

.search-suggest__item span {
    font-size: 14px;
    color: var(--text-muted);
}

/* Common cards */
.home-section-card,
.city-card,
.user-city-card {
    position: relative;
    z-index: 1;
}

.home-section-card {
    margin-top: 28px;
    padding: 24px;
}

.home-section-card p,
.user-city-card p {
    color: var(--text-soft);
}

.user-city-card {
    margin-top: 20px;
}

.geo-guess__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

/* Grids */

.country-links-grid,
.region-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.region-chip {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 14px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(148, 163, 184, 0.20);
    border-radius: 999px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: transform var(--transition), border-color var(--transition), background var(--transition);
}

.region-chip:hover {
    transform: translateY(-1px);
    border-color: rgba(29, 78, 216, 0.24);
    background: #fff;
}

.home-popular-cities {
    padding: 12px 0 32px;
}

.city-links-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.city-link-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 100px;
    padding: 18px;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    color: var(--text);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.city-link-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: rgba(29, 78, 216, 0.22);
}

.city-link-card strong {
    font-size: 17px;
    line-height: 1.25;
}

.city-link-card span {
    color: var(--text-muted);
    font-size: 14px;
}

.city-link-card__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.city-link-card__main {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.city-link-card__main strong {
    font-size: 17px;
    line-height: 1.25;
}

.city-link-card__main span {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1;
}

.city-link-card__weather {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
    text-align: right;
}

.city-link-card__weather-top {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.city-link-card__icon {
    font-size: 16px;
    line-height: 1;
}

.city-link-card__temp {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.1;
}

.city-link-card__label {
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.2;
    text-align: end;
}

/* Breadcrumbs */

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--text-muted);
    font-size: 14px;
}

.breadcrumbs a {
    color: var(--primary);
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

/* City page */

.updated-at {
    margin: 0 0 24px;
    color: var(--text-muted);
    font-size: 14px;
}

.city-card {
    margin-top: 24px;
    max-width: unset;
    padding: 28px;
}

.city-card p {
    margin: 0 0 14px;
    color: var(--text-soft);
}

.city-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 24px;
}

.city-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 14px;
    background: rgba(29, 78, 216, 0.08);
    color: var(--primary-hover);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
}

.country-summary-card h2 {
    margin: 0 0 12px;
}

.country-summary-card p {
    margin: 0 0 18px;
    color: var(--text-soft);
    line-height: 1.7;
}

.country-summary-list {
    display: grid;
    gap: 12px;
}

.country-summary-list__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

.country-summary-list__row:last-child {
    border-bottom: 0;
}

.country-summary-list__label {
    color: var(--text-soft);
    line-height: 1.4;
}

.country-summary-list__value {
    color: var(--text);
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
}

.weather-now {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 20px;
    margin: 24px 0;
}

.weather-now__main,
.weather-now__details,
.forecast-card {
    padding: 24px;
}

.weather-now__temp {
    margin-bottom: 10px;
    font-size: clamp(52px, 8vw, 72px);
    font-weight: 800;
    line-height: 0.95;
    letter-spacing: -0.04em;
}

.weather-now__label {
    font-size: 18px;
    color: var(--text-soft);
}

.city-link-card__meta {
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.2;
}

.weather-now__details {
    display: grid;
    gap: 16px;
}

.weather-stat {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.weather-stat__name {
    color: var(--text-muted);
}

.forecast-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.forecast-card__date {
    font-weight: 800;
    margin-bottom: 10px;
}

.forecast-card__label {
    margin-bottom: 12px;
    color: var(--text-soft);
}

.forecast-card__temps {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
}

.forecast-card__extra {
    color: var(--text-muted);
    font-size: 14px;
}

/* Country / region pages */

.country-top-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 20px;
    margin-bottom: 24px;
}

.country-city-list {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.country-city-list__item {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

.country-city-list__item a {
    color: var(--text);
    text-decoration: none;
    font-weight: 700;
}

.country-city-list__item a:hover {
    color: var(--primary);
}

.country-city-list__item span {
    color: var(--text-muted);
    text-align: right;
}

/* Pagination */

.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 28px;
}

.pagination span {
    color: var(--text-muted);
    font-size: 14px;
}

/* SEO text */

.seo-text {
    max-width: 820px;
}

.seo-text p {
    line-height: 1.8;
    color: var(--text-soft);
}

/* Search page */

.search-results {
    display: grid;
    gap: 12px;
    margin-top: 20px;
}

.search-results__item,
.search-results__item--bordered {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--border);
    border-radius: 16px;
    text-decoration: none;
    color: var(--text);
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.search-results__item:hover,
.search-results__item--bordered:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
    border-color: rgba(29, 78, 216, 0.22);
}

/* Responsive */

@media (max-width: 1024px) {
    .city-links-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .hero {
        padding: 56px 0 24px;
    }

    .hero--home {
        padding-top: 64px;
    }

    .hero h1 {
        font-size: 42px;
    }

    .weather-now,
    .country-top-grid,
    .forecast-grid {
        grid-template-columns: 1fr;
    }

    .city-links-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .container {
        width: min(var(--container), calc(100% - 24px));
    }

    header .container {
        min-height: 68px;
    }

    .site-main{
        padding: 0 10px 64px 10px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero__lead,
    .hero p {
        font-size: 16px;
    }

    .search-box {
        padding: 0;
        border-radius: 20px;
    }

    .search-form {
        flex-direction: column;
    }

    .search-form button {
        width: 100%;
    }

    .city-links-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .country-city-list__item {
        flex-direction: column;
    }

    .country-city-list__item span {
        text-align: left;
    }

    .pagination {
        flex-direction: column;
        align-items: flex-start;
    }

    .city-card,
    .weather-now__main,
    .weather-now__details,
    .forecast-card,
    .home-section-card {
        padding: 20px;
    }
}

@media (max-width: 420px) {
    .city-links-grid {
        grid-template-columns: 1fr;
    }
}

.city-page__head {
    margin-bottom: 24px;
}

.city-page__head-main {
    max-width: 900px;
}

.city-section {
    margin-top: 28px;
}

.city-section--two-cols {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.weather-feel-list {
    margin: 16px 0 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 10px;
}

.weather-feel-list__item {
    position: relative;
    padding-left: 18px;
    color: var(--text-soft);
    line-height: 1.6;
}

.weekly-forecast-card {
    max-width: none;
    width: 100%;
}

.weekly-forecast-scroll {
    overflow: visible;
    padding-bottom: 0;
    margin-top: 20px;
}

.weekly-forecast-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(150px, 1fr);
    gap: 16px;
    min-width: min-content;
}

.weekly-forecast-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 280px;
    padding: 18px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.weekly-forecast-day__date {
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
}

.weekly-forecast-day__icon {
    margin-bottom: 10px;
    font-size: 30px;
    line-height: 1;
}

.weekly-forecast-day__label {
    min-height: 36px;
    margin-bottom: 16px;
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.35;
}

.weekly-forecast-day__range-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    flex: 1;
}

.weekly-forecast-day__temp {
    font-weight: 700;
    line-height: 1;
}

.weekly-forecast-day__temp--max {
    color: var(--text);
    font-size: 18px;
}

.weekly-forecast-day__temp--min {
    color: var(--text-muted);
    font-size: 16px;
}

.weekly-forecast-day__range {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    flex: 1;
    min-height: 72px;
}

.weekly-forecast-day__range-bar {
    display: block;
    width: 10px;
    height: var(--range-height, 72px);
    min-height: 72px;
    border-radius: 999px;
    background: linear-gradient(
        180deg,
        var(--range-top, #f59e0b) 0%,
        var(--range-bottom, #3b82f6) 100%
    );
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.2),
        0 6px 16px rgba(15, 23, 42, 0.12);
}

.weekly-forecast-day__precipitation {
    margin-top: auto;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.3;
}

@media (max-width: 1231px) {
    .weekly-forecast-scroll {
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
    }

    .weekly-forecast-track {
        grid-auto-flow: column;
        grid-auto-columns: minmax(140px, 1fr);
        gap: 12px;
        min-width: min-content;
    }
}

@media (max-width: 780px) {
    .weekly-forecast-scroll {
        overflow-x: hidden;
        padding-bottom: 0;
    }

    .weekly-forecast-track {
        grid-auto-flow: unset;
        grid-auto-columns: unset;
        grid-template-columns: repeat(7, minmax(0, 1fr));
        gap: 6px;
        min-width: 100%;
    }

    .weekly-forecast-day {
        min-height: 220px;
        padding: 12px 8px;
        border-radius: 16px;
    }

    .weekly-forecast-day__date {
        margin-bottom: 8px;
        font-size: 11px;
        line-height: 1.15;
    }

    .weekly-forecast-day__icon {
        margin-bottom: 8px;
        font-size: 22px;
    }

    .weekly-forecast-day__label {
        min-height: 30px;
        margin-bottom: 10px;
        font-size: 11px;
        line-height: 1.2;
        overflow: hidden;
    }

    .weekly-forecast-day__temp--max {
        font-size: 15px;
    }

    .weekly-forecast-day__temp--min {
        font-size: 13px;
    }

    .weekly-forecast-day__range {
        min-height: 54px;
        width: 12px;
    }

    .weekly-forecast-day__range-bar {
        width: 7px;
        min-height: 54px;
    }

    .weekly-forecast-day__precipitation {
        font-size: 10px;
        line-height: 1.15;
    }
}

@media (max-width: 640px) {
    .weekly-forecast-track {
        grid-template-columns: repeat(7, minmax(0, 1fr));
        gap: 4px;
    }

    .weekly-forecast-day {
        min-height: 190px;
        padding: 10px 4px;
        border-radius: 12px;
    }

    .weekly-forecast-day__date {
        margin-bottom: 6px;
        font-size: 10px;
        line-height: 1.15;
    }

    .weekly-forecast-day__icon {
        margin-bottom: 6px;
        font-size: 18px;
    }

    .weekly-forecast-day__label {
        display: none;
    }

    .weekly-forecast-day__range-wrap {
        gap: 6px;
        margin-bottom: 10px;
    }

    .weekly-forecast-day__temp--max {
        font-size: 13px;
    }

    .weekly-forecast-day__temp--min {
        font-size: 12px;
    }

    .weekly-forecast-day__range {
        min-height: 42px;
        width: 10px;
    }

    .weekly-forecast-day__range-bar {
        width: 6px;
        min-height: 42px;
    }

    .weekly-forecast-day__precipitation {
        font-size: 9px;
        line-height: 1.15;
    }
}

@media (max-width: 520px) {
    .weekly-forecast-scroll {
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
    }

    .weekly-forecast-track {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: 62px;
        gap: 4px;
        min-width: max-content;
    }

    .weekly-forecast-day {
        min-height: 190px;
        padding: 10px 5px;
    }
}

.weather-feel-list__item::before {
    content: "";
    position: absolute;
    top: 10px;
    left: 0;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
}

.weather-now__eyebrow {
    margin-bottom: 10px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.chart-card__canvas-wrap {
    position: relative;
    height: 320px;
    margin-top: 16px;
}

.daily-scroll {
    overflow-x: auto;
    padding-bottom: 8px;
}

.daily-scroll__track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(160px, 1fr);
    gap: 8px;
    min-width: fit-content;
}

.forecast-day-card {
    min-height: 180px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.forecast-day-card__day {
    margin-bottom: 10px;
    font-size: 16px;
    font-weight: 800;
    line-height: 1.2;
}

.forecast-day-card__label {
    margin-bottom: 14px;
    color: var(--text-soft);
}

.forecast-day-card__temps {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
}

.forecast-day-card__extra {
    color: var(--text-muted);
    font-size: 14px;
}

.info-card h2 {
    margin: 0 0 14px;
}

.info-card p {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.7;
}

.info-card--accent {
    background: linear-gradient(180deg, rgba(248, 251, 255, 0.96) 0%, rgba(239, 246, 255, 0.96) 100%);
}

.info-card__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 20px;
}

.info-stat {
    padding: 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.info-stat__name {
    display: block;
    margin-bottom: 6px;
    color: var(--text-muted);
    font-size: 13px;
}

.city-about-card h2 {
    margin-bottom: 16px;
}

@media (max-width: 900px) {
    .city-section--two-cols {
        grid-template-columns: 1fr;
    }

    .info-card__stats {
        grid-template-columns: 1fr;
    }

    .chart-card__canvas-wrap {
        height: 260px;
    }
}