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

:root {
    --bg-dark: #0f0f0f;
    --bg-card: rgba(30, 30, 30, 0.6);
    --bg-card-hover: rgba(40, 40, 40, 0.7);
    --bg-input: rgba(50, 50, 50, 0.5);
    --text-primary: #f0f0f0;
    --text-secondary: #b0b0b0;
    --text-muted: #888888;
    --accent: #ffffff;
    --accent-hover: #d0d0d0;
    --border: rgba(255, 255, 255, 0.1);
    --border-strong: rgba(255, 255, 255, 0.2);
    --error: #ff6b6b;
    --success: #4ecb71;
    --blur: 20px;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --transition: 0.3s ease;
    --radius: 16px;
    --radius-sm: 10px;
    --header-bg: rgba(15, 15, 15, 0.7);
    --section-gradient-1: #1a1a2e;
    --section-gradient-2: #16213e;
    --gradient-end: #0f0f0f;
    --title-gradient: linear-gradient(135deg, #ffffff 0%, #a0a0a0 100%);
}

body.light-theme {
    --bg-dark: #f5f5f7;
    --bg-card: rgba(255, 255, 255, 0.6);
    --bg-card-hover: rgba(255, 255, 255, 0.8);
    --bg-input: rgba(240, 240, 240, 0.7);
    --text-primary: #1a1a1a;
    --text-secondary: #555555;
    --text-muted: #999999;
    --accent: #1a1a1a;
    --accent-hover: #333333;
    --border: rgba(0, 0, 0, 0.1);
    --border-strong: rgba(0, 0, 0, 0.2);
    --error: #d32f2f;
    --success: #2e7d32;
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --header-bg: rgba(245, 245, 247, 0.8);
    --section-gradient-1: #e8e8ee;
    --section-gradient-2: #dde4f0;
    --gradient-end: #f5f5f7;
    --title-gradient: linear-gradient(135deg, #1a1a1a 0%, #555555 100%);
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 70px;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    transition: background-color 0.4s ease, color 0.4s ease;
}

#particlesCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.header,
.section,
.weather-card,
.about-card,
.contact-form {
    position: relative;
    z-index: 1;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--header-bg);
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    padding: 0 20px;
    transition: background 0.4s ease, border-color 0.4s ease;
}

.nav {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 12px 0;
    flex-wrap: wrap;
}

.nav__btn {
    background: rgba(128, 128, 128, 0.08);
    color: var(--text-secondary);
    border: 1px solid transparent;
    padding: 10px 20px;
    font-size: 15px;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition);
    font-family: inherit;
    white-space: nowrap;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.nav__btn:hover {
    color: var(--text-primary);
    border-color: var(--border);
    background: rgba(128, 128, 128, 0.15);
}

.nav__btn.active {
    color: var(--text-primary);
    border-color: var(--accent);
    background: rgba(128, 128, 128, 0.2);
    font-weight: 600;
}

.theme-toggle {
    background: rgba(128, 128, 128, 0.08);
    border: 1px solid var(--border);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all var(--transition);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 0;
    margin-left: 8px;
}

.theme-toggle:hover {
    background: rgba(128, 128, 128, 0.2);
    border-color: var(--accent);
    transform: rotate(30deg);
}

.theme-toggle__icon {
    transition: transform 0.3s ease;
    display: block;
    line-height: 1;
}

.section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 20px 60px;
    transition: background 0.4s ease;
}

.section--home {
    background: radial-gradient(ellipse at center, var(--section-gradient-1) 0%, var(--gradient-end) 70%);
}

.section--forecast {
    background: radial-gradient(ellipse at center, var(--section-gradient-2) 0%, var(--gradient-end) 70%);
}

.section--about {
    background: radial-gradient(ellipse at center, var(--section-gradient-1) 0%, var(--gradient-end) 70%);
}

.section--contacts {
    background: radial-gradient(ellipse at center, var(--section-gradient-2) 0%, var(--gradient-end) 70%);
}

.section__content {
    max-width: 650px;
    width: 100%;
    text-align: center;
}

.section__title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: 1px;
    transition: color 0.4s ease;
}

.section__desc {
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-size: 16px;
    transition: color 0.4s ease;
}

.logo-placeholder {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    border: 2px dashed var(--border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    transition: background 0.4s ease, border-color 0.4s ease;
}

.logo-placeholder__text {
    font-size: 48px;
    opacity: 0.7;
    animation: iconFloat 3s ease-in-out infinite;
}

.title {
    font-size: 56px;
    font-weight: 800;
    letter-spacing: 3px;
    margin-bottom: 10px;
    background: var(--title-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    transition: color 0.4s ease;
}

.hint {
    font-size: 14px;
    color: var(--text-muted);
    transition: color 0.4s ease;
}

.search {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
}

.search__input {
    flex: 1;
    min-width: 200px;
    padding: 14px 18px;
    font-size: 16px;
    background: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    outline: none;
    transition: all var(--transition);
    font-family: inherit;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.search__input:focus {
    border-color: var(--accent);
}

.search__input::placeholder {
    color: var(--text-muted);
}

.search__btn {
    padding: 14px 28px;
    font-size: 16px;
    background: var(--accent);
    color: var(--bg-dark);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    transition: all var(--transition);
    font-family: inherit;
    white-space: nowrap;
}

.search__btn:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(128, 128, 128, 0.3);
}

.search__btn:active {
    transform: translateY(0);
}

.search__btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.autocomplete-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    margin-top: 4px;
    box-shadow: var(--shadow);
}

.error {
    color: var(--error);
    font-size: 14px;
    min-height: 20px;
    margin-bottom: 10px;
}

.weather-card {
    background: var(--bg-card);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px;
    margin-top: 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease, background 0.4s ease, border-color 0.4s ease;
    pointer-events: none;
    box-shadow: var(--shadow);
}

.weather-card.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.weather-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 8px;
}

.weather-card__city {
    font-size: 24px;
    font-weight: 700;
}

.weather-card__date {
    color: var(--text-muted);
    font-size: 14px;
    transition: color 0.4s ease;
}

.weather-card__main {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 16px;
}

.weather-card__icon {
    font-size: 72px;
    display: inline-block;
}

.weather-card__icon.animated {
    animation: weatherPulse 2s ease-in-out infinite;
}

.weather-card__temp {
    font-size: 64px;
    font-weight: 800;
    letter-spacing: 2px;
}

.weather-card__desc {
    color: var(--text-secondary);
    font-size: 18px;
    text-transform: capitalize;
    margin-bottom: 24px;
    transition: color 0.4s ease;
}

.weather-card__details {
    display: flex;
    justify-content: space-around;
    gap: 16px;
    flex-wrap: wrap;
}

.detail {
    text-align: center;
    min-width: 80px;
    background: rgba(128, 128, 128, 0.05);
    padding: 12px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    transition: background 0.4s ease, border-color 0.4s ease;
}

.detail__label {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
    transition: color 0.4s ease;
}

.detail__value {
    font-size: 18px;
    font-weight: 600;
}

.forecast-mini {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.forecast-mini__card {
    background: rgba(128, 128, 128, 0.05);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    text-align: center;
    flex: 1;
    min-width: 120px;
    transition: all var(--transition);
}

.forecast-mini__card:hover {
    background: rgba(128, 128, 128, 0.12);
    border-color: var(--border-strong);
    transform: translateY(-4px);
}

.forecast-mini__day {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 8px;
    transition: color 0.4s ease;
}

.forecast-mini__icon {
    font-size: 36px;
    margin-bottom: 8px;
}

.forecast-mini__icon.animated {
    animation: weatherPulse 2.5s ease-in-out infinite;
}

.forecast-mini__temp {
    font-size: 20px;
    font-weight: 700;
}

.forecast-mini__desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
    transition: color 0.4s ease;
}

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

@keyframes weatherPulse {
    0%, 100% { transform: scale(1); }
    30% { transform: scale(1.15); }
    60% { transform: scale(0.95); }
}

.about-card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px;
    text-align: left;
    box-shadow: var(--shadow);
    transition: background 0.4s ease, border-color 0.4s ease;
}

.about-card__text {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 16px;
    line-height: 1.8;
    transition: color 0.4s ease;
}

.about-card__text:last-child {
    margin-bottom: 0;
}

.about-card__text strong {
    color: var(--text-primary);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    max-width: 450px;
    margin: 0 auto;
}

.contact-form__input,
.contact-form__textarea {
    padding: 14px 18px;
    font-size: 16px;
    background: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    outline: none;
    transition: all var(--transition);
    font-family: inherit;
    resize: vertical;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.contact-form__input:focus,
.contact-form__textarea:focus {
    border-color: var(--accent);
}

.contact-form__input::placeholder,
.contact-form__textarea::placeholder {
    color: var(--text-muted);
}

.contact-form__btn {
    padding: 14px 28px;
    font-size: 16px;
    background: var(--accent);
    color: var(--bg-dark);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    transition: all var(--transition);
    font-family: inherit;
    align-self: center;
}

.contact-form__btn:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(128, 128, 128, 0.3);
}

.contact-form__success {
    color: var(--success);
    font-size: 14px;
    min-height: 20px;
    text-align: center;
}

@media (max-width: 600px) {
    .title {
        font-size: 38px;
    }

    .section__title {
        font-size: 26px;
    }

    .nav__btn {
        padding: 8px 14px;
        font-size: 13px;
    }

    .theme-toggle {
        width: 36px;
        height: 36px;
        font-size: 17px;
    }

    .weather-card__temp {
        font-size: 48px;
    }

    .weather-card__icon {
        font-size: 56px;
    }

    .forecast-mini {
        flex-direction: column;
    }

    .forecast-mini__card {
        min-width: auto;
    }

    .search {
        flex-direction: column;
        align-items: stretch;
    }

    .search__btn {
        width: 100%;
    }
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border-strong);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.nav__weather-icon {
    position: relative;
    width: 50px;
    height: 45px;
    margin-right: 4px;
    flex-shrink: 0;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.nav__weather-icon:hover {
    transform: scale(1.1);
}

.nav__weather-icon:hover .lightning {
    animation: lightningFlash 0.3s ease-in-out 3;
}

.cloud {
    position: absolute;
    top: 5px;
    left: 0;
    width: 50px;
    height: 25px;
    animation: cloudFloat 4s ease-in-out infinite;
}

.cloud__body {
    position: absolute;
    bottom: 0;
    left: 5px;
    width: 40px;
    height: 16px;
    background: linear-gradient(180deg, #b0b8c0 0%, #8899aa 100%);
    border-radius: 20px;
    box-shadow: inset 0 -4px 6px rgba(0,0,0,0.2), 0 4px 8px rgba(0,0,0,0.3);
}

.cloud__ball {
    position: absolute;
    background: linear-gradient(135deg, #c8d0d8 0%, #99aabb 100%);
    border-radius: 50%;
    box-shadow: inset -3px -3px 6px rgba(0,0,0,0.15);
}

.cloud__ball--left {
    width: 22px;
    height: 22px;
    bottom: 8px;
    left: 0;
}

.cloud__ball--right {
    width: 20px;
    height: 20px;
    bottom: 10px;
    right: 0;
}

.cloud__ball--top {
    width: 24px;
    height: 24px;
    bottom: 12px;
    left: 11px;
}

.lightning {
    position: absolute;
    top: 22px;
    left: 30px;
    font-size: 16px;
    color: #ffd700;
    text-shadow: 0 0 8px #ffd700, 0 0 16px #ffaa00, 0 0 24px #ff8800;
    animation: lightningFloat 2s ease-in-out infinite;
    z-index: 2;
    transform: rotate(15deg);
}

.rain-drops {
    position: absolute;
    top: 28px;
    left: 8px;
    width: 34px;
    height: 15px;
}

.rain-drop {
    position: absolute;
    bottom: 0;
    width: 2px;
    height: 8px;
    background: linear-gradient(180deg, transparent, #6ab7ff);
    border-radius: 0 0 2px 2px;
    opacity: 0;
}

.rain-drop:nth-child(1) {
    left: 6px;
    animation: rainFall 1.5s ease-in infinite;
}

.rain-drop:nth-child(2) {
    left: 16px;
    animation: rainFall 1.5s ease-in 0.5s infinite;
}

.rain-drop:nth-child(3) {
    left: 26px;
    animation: rainFall 1.5s ease-in 1s infinite;
}

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

@keyframes lightningFloat {
    0%, 100% { 
        opacity: 0.3;
        transform: rotate(15deg) scale(0.9);
    }
    50% { 
        opacity: 1;
        transform: rotate(15deg) scale(1.2);
    }
}

@keyframes lightningFlash {
    0%, 100% { 
        opacity: 1;
        text-shadow: 0 0 8px #ffd700, 0 0 16px #ffaa00, 0 0 24px #ff8800;
    }
    50% { 
        opacity: 0.2;
        text-shadow: 0 0 2px #ffd700, 0 0 4px #ffaa00;
    }
}

@keyframes rainFall {
    0% {
        opacity: 0;
        transform: translateY(0);
    }
    30% {
        opacity: 0.8;
    }
    100% {
        opacity: 0;
        transform: translateY(10px);
    }
}

@media (max-width: 600px) {
    .nav__weather-icon {
        width: 40px;
        height: 35px;
    }

    .cloud {
        width: 40px;
        height: 20px;
    }

    .cloud__body {
        width: 32px;
        height: 12px;
        left: 4px;
    }

    .cloud__ball--left {
        width: 18px;
        height: 18px;
        bottom: 6px;
    }

    .cloud__ball--right {
        width: 16px;
        height: 16px;
        bottom: 8px;
    }

    .cloud__ball--top {
        width: 20px;
        height: 20px;
        bottom: 10px;
        left: 9px;
    }

    .lightning {
        font-size: 13px;
        top: 18px;
        left: 24px;
    }

    .rain-drops {
        top: 23px;
        left: 6px;
        width: 28px;
    }
}

body.light-theme .cloud__body {
    background: linear-gradient(180deg, #8899aa 0%, #667788 100%);
}

body.light-theme .cloud__ball {
    background: linear-gradient(135deg, #aabbcc 0%, #778899 100%);
}

body.light-theme .lightning {
    color: #ffaa00;
    text-shadow: 0 0 6px #ffaa00, 0 0 12px #ff8800;
}

body.light-theme .rain-drop {
    background: linear-gradient(180deg, transparent, #4488cc);
}

.weather-card__datetime {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.weather-card__time {
    color: var(--accent);
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 1px;
}

.theme-toggle-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 4px;
}

.theme-toggle__label {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
}

.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 46px;
    height: 46px;
    background: var(--bg-card);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    background: var(--accent);
    color: var(--bg-dark);
    border-color: var(--accent);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.section__content {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section.visible .section__content {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 600px) {
    .weather-card__time {
        font-size: 16px;
    }

    .theme-toggle__label {
        display: none;
    }

    .scroll-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* Фото городов на главной странице */
.section--home {
    position: relative;
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    padding: 0;
    overflow: hidden;
}

.section--home .section__image {
    position: relative;
    width: 25%;
    min-width: 200px;
    overflow: hidden;
}

/* Закругление у левого фото (слева прямые углы, справа скругленные) */
.section--home .section__image--left {
    border-radius: 0 40px 40px 0;
}

/* Закругление у правого фото (справа прямые углы, слева скругленные) */
.section--home .section__image--right {
    border-radius: 40px 0 0 40px;
}

.section--home .section__image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Наследуем закругления для img, чтобы фото тоже были скругленными */
.section--home .section__image--left img {
    border-radius: 0 40px 40px 0;
}

.section--home .section__image--right img {
    border-radius: 40px 0 0 40px;
}

.section--home .section__content-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 40px 60px;
    min-height: 100vh;
}

.section--home .section__content {
    max-width: 550px;
    width: 100%;
    text-align: center;
}

/* Затемнение фото */
.section--home .section__image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.1) 100%);
    pointer-events: none;
    border-radius: inherit;
}

.section--home .section__image--right::after {
    background: linear-gradient(to left, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.1) 100%);
}

/* Светлая тема */
body.light-theme .section--home .section__image::after {
    background: linear-gradient(to right, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.05) 100%);
}

body.light-theme .section--home .section__image--right::after {
    background: linear-gradient(to left, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.05) 100%);
}

/* Адаптив */
@media (max-width: 900px) {
    .section--home .section__image {
        width: 20%;
        min-width: 120px;
    }
    
    .section--home .section__image--left {
        border-radius: 0 25px 25px 0;
    }
    
    .section--home .section__image--right {
        border-radius: 25px 0 0 25px;
    }
    
    .section--home .section__image--left img {
        border-radius: 0 25px 25px 0;
    }
    
    .section--home .section__image--right img {
        border-radius: 25px 0 0 25px;
    }
}

@media (max-width: 700px) {
    .section--home .section__image {
        display: none;
    }
    
    .section--home .section__content-wrapper {
        padding: 100px 20px 60px;
    }
}

/* Анимированный дождь на фоне главной страницы */
.section--home .section__content-wrapper {
    position: relative;
    overflow: hidden;
}

.rain-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.drop {
    position: absolute;
    bottom: 100%;
    width: 2px;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.2));
    animation: fall linear infinite;
}

/* Разная высота капель */
.drop:nth-child(1) { left: 5%; height: 40px; animation-duration: 1.2s; animation-delay: 0s; }
.drop:nth-child(2) { left: 12%; height: 60px; animation-duration: 1.8s; animation-delay: 0.5s; }
.drop:nth-child(3) { left: 18%; height: 35px; animation-duration: 1.4s; animation-delay: 0.2s; }
.drop:nth-child(4) { left: 25%; height: 70px; animation-duration: 2s; animation-delay: 0.8s; }
.drop:nth-child(5) { left: 32%; height: 45px; animation-duration: 1.6s; animation-delay: 0.1s; }
.drop:nth-child(6) { left: 38%; height: 55px; animation-duration: 1.9s; animation-delay: 0.6s; }
.drop:nth-child(7) { left: 45%; height: 30px; animation-duration: 1.3s; animation-delay: 0.9s; }
.drop:nth-child(8) { left: 52%; height: 65px; animation-duration: 1.7s; animation-delay: 0.3s; }
.drop:nth-child(9) { left: 58%; height: 50px; animation-duration: 2.1s; animation-delay: 0.4s; }
.drop:nth-child(10) { left: 65%; height: 38px; animation-duration: 1.5s; animation-delay: 0.7s; }
.drop:nth-child(11) { left: 72%; height: 72px; animation-duration: 1.9s; animation-delay: 0.15s; }
.drop:nth-child(12) { left: 78%; height: 42px; animation-duration: 1.4s; animation-delay: 0.55s; }
.drop:nth-child(13) { left: 85%; height: 58px; animation-duration: 1.8s; animation-delay: 0.85s; }
.drop:nth-child(14) { left: 92%; height: 48px; animation-duration: 1.6s; animation-delay: 0.25s; }
.drop:nth-child(15) { left: 15%; height: 52px; animation-duration: 2.2s; animation-delay: 0.95s; }
.drop:nth-child(16) { left: 48%; height: 62px; animation-duration: 1.5s; animation-delay: 0.45s; }
.drop:nth-child(17) { left: 68%; height: 36px; animation-duration: 1.7s; animation-delay: 0.65s; }
.drop:nth-child(18) { left: 8%; height: 44px; animation-duration: 1.9s; animation-delay: 0.35s; }
.drop:nth-child(19) { left: 42%; height: 68px; animation-duration: 1.3s; animation-delay: 0.75s; }
.drop:nth-child(20) { left: 88%; height: 33px; animation-duration: 2s; animation-delay: 0.05s; }
.drop:nth-child(21) { left: 3%; height: 56px; animation-duration: 1.6s; animation-delay: 0.5s; }
.drop:nth-child(22) { left: 22%; height: 41px; animation-duration: 2.1s; animation-delay: 0.9s; }
.drop:nth-child(23) { left: 35%; height: 64px; animation-duration: 1.4s; animation-delay: 0.2s; }
.drop:nth-child(24) { left: 55%; height: 37px; animation-duration: 1.8s; animation-delay: 0.7s; }
.drop:nth-child(25) { left: 62%; height: 59px; animation-duration: 1.5s; animation-delay: 0.4s; }
.drop:nth-child(26) { left: 75%; height: 46px; animation-duration: 2s; animation-delay: 0.6s; }
.drop:nth-child(27) { left: 82%; height: 53px; animation-duration: 1.7s; animation-delay: 0.1s; }
.drop:nth-child(28) { left: 95%; height: 39px; animation-duration: 1.9s; animation-delay: 0.8s; }
.drop:nth-child(29) { left: 28%; height: 61px; animation-duration: 1.4s; animation-delay: 0.3s; }
.drop:nth-child(30) { left: 98%; height: 47px; animation-duration: 1.6s; animation-delay: 0.55s; }

@keyframes fall {
    0% {
        transform: translateY(-100px);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(100vh);
        opacity: 0;
    }
}

/* Для светлой темы - капли темнее */
body.light-theme .drop {
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.1));
}

/* Плавное появление боковых фото на главной при загрузке */
.section--home .section__image--left img {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.section--home .section__image--right img {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* Анимация запускается после загрузки страницы */
body.loaded .section--home .section__image--left img,
body.loaded .section--home .section__image--right img {
    opacity: 1;
    transform: translateX(0);
}
