* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, system-ui, sans-serif;
}

body {
    min-height: 100vh;
    background: linear-gradient(145deg, #0b1a2e 0%, #1b3b4f 100%);
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    position: relative;
    overflow-x: hidden;
    color: #e7f3ff;
}

/* снежный фон */
.snow-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}
.snow-bg i {
    position: absolute;
    color: rgba(255, 255, 255, 0.7);
    animation: fall 10s linear infinite;
    font-size: 1.2rem;
    opacity: 0.6;
    filter: drop-shadow(0 0 6px #aaf0ff);
}
@keyframes fall {
    0% { transform: translateY(-10vh) rotate(0deg); opacity: 0.8; }
    100% { transform: translateY(110vh) rotate(360deg); opacity: 0.2; }
}

/* главный блок */
.chat-card {
    position: relative;
    z-index: 20;
    max-width: 1000px;
    width: 100%;
    background: rgba(10, 25, 40, 0.65);
    backdrop-filter: blur(14px) saturate(180%);
    border-radius: 48px 48px 32px 32px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.6), 0 0 0 2px rgba(173, 216, 230, 0.2) inset, 0 0 30px #7fd8ff55;
    padding: 28px 24px 24px;
}

/* шапка */
.header-snow {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 32px;
    background: rgba(0, 20, 40, 0.5);
    padding: 16px 22px;
    border-radius: 100px;
    border: 1px solid rgba(255,255,240,0.25);
    box-shadow: 0 8px 20px -8px black;
}
.snowflake-logo {
    font-size: 3.2rem;
    line-height: 1;
    filter: drop-shadow(0 0 10px cyan) drop-shadow(0 0 20px blue);
    animation: rotateSnow 4s infinite linear;
    display: inline-block;
}
@keyframes rotateSnow {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.1); text-shadow: 0 0 15px white; }
    100% { transform: rotate(0deg) scale(1); }
}
.title-text {
    font-size: clamp(1.1rem, 5vw, 2.2rem);
    font-weight: 800;
    background: linear-gradient(135deg, #f0fcff, #b5efff, #a0d0ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: 1px;
    text-shadow: 0 0 10px #00b7ff;
}
.title-text small {
    font-size: 0.75em;
    background: rgba(255,255,255,0.15);
    padding: 4px 10px;
    border-radius: 40px;
    margin-left: 10px;
    color: #c2e4ff;
}

/* ========= БЛОК КНОПКИ ========= */
.action-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 30px 0 20px;
    width: 100%;
}

.fancy-button {
    background: linear-gradient(145deg, #3a7ca5, #1e4f72);
    border: 2px solid rgba(255, 255, 255, 0.4);
    color: white;
    font-size: 2.2rem;
    font-weight: bold;
    padding: 20px 50px;
    border-radius: 80px;
    cursor: pointer;
    box-shadow: 0 0 30px #00a6ff, 0 10px 20px rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    transition: 0.2s;
    letter-spacing: 2px;
    text-transform: uppercase;
    min-width: 300px;
}

.fancy-button .fa-snowflake {
    filter: drop-shadow(0 0 10px white);
    animation: rotateSnow 3s infinite linear;
    font-size: 2.8rem;
}

.fancy-button:hover {
    transform: scale(1.02);
    background: linear-gradient(145deg, #4e8fc0, #2a618a);
    box-shadow: 0 0 40px #4ab0ff;
}

/* Контейнер загрузки */
.loading-container {
    width: 100%;
    max-width: 400px;
    margin: 20px auto;
    text-align: center;
    background: rgba(0, 0, 0, 0.5);
    padding: 20px;
    border-radius: 60px;
    border: 1px solid cyan;
    box-shadow: 0 0 30px #7df0ff;
    display: none;
}

.progress-bar {
    width: 100%;
    height: 20px;
    background: #222;
    border-radius: 30px;
    margin: 15px 0 10px;
    border: 2px solid white;
    overflow: hidden;
}

.progress-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #a0f0ff, #4ad0ff, #00a6ff);
    border-radius: 30px;
    box-shadow: 0 0 20px #3cc0ff;
    transition: width 1s linear;
}

.loading-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 0 10px magenta;
}

/* Блок после загрузки */
.post-loading-block {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin: 20px 0;
}

.greeting-message {
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, gold, orange, #ffb347);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: glowPulse 2s infinite;
    letter-spacing: 4px;
}

.fallback-link {
    background: rgba(255, 215, 0, 0.2);
    border: 2px solid gold;
    color: #fff4c6;
    font-size: 1.5rem;
    font-weight: bold;
    padding: 12px 30px;
    border-radius: 50px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: 0.2s;
    text-decoration: none;
    backdrop-filter: blur(5px);
}

.fallback-link:hover {
    background: rgba(255, 215, 0, 0.4);
    transform: scale(1.05);
    box-shadow: 0 0 20px gold;
}

@keyframes glowPulse {
    0% { opacity: 0.7; text-shadow: 0 0 10px gold; }
    50% { opacity: 1; text-shadow: 0 0 40px orange, 0 0 20px red; }
    100% { opacity: 0.7; text-shadow: 0 0 10px gold; }
}

/* блок с таймером */
.telegram-message-area {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin: 36px 0 28px;
}
.message-bubble {
    background: rgba(33, 69, 99, 0.7);
    backdrop-filter: blur(4px);
    border-radius: 28px 28px 28px 8px;
    padding: 26px 24px;
    max-width: 90%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 20px -5px #00000080, 0 0 0 2px #64b5f644 inset;
    position: relative;
    align-self: flex-start;
}
.message-bubble::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: -12px;
    width: 24px;
    height: 24px;
    background: rgba(33, 69, 99, 0.7);
    backdrop-filter: blur(4px);
    border-radius: 0 0 0 30px;
    box-shadow: -4px 4px 0 0 #64b5f644;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    border-left: 1px solid rgba(255,255,255,0.2);
}
.timer-header {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    margin-bottom: 16px;
    background: rgba(0,0,0,0.2);
    padding: 8px 16px;
    border-radius: 40px;
    width: fit-content;
}
.timer-header i {
    color: #ffd966;
    filter: drop-shadow(0 0 8px gold);
}
.big-timer {
    font-size: clamp(2.4rem, 10vw, 4.2rem);
    font-weight: 800;
    font-family: 'Courier New', monospace;
    letter-spacing: 6px;
    background: #111c28;
    padding: 16px 24px;
    border-radius: 60px;
    text-align: center;
    box-shadow: 0 0 20px #7df9ff, inset 0 2px 10px #b3f0ff;
    color: #c6f0ff;
    border: 2px solid white;
    margin: 10px 0 8px;
}
.timer-label {
    font-size: 1.1rem;
    opacity: 0.9;
    background: rgba(255,255,240,0.1);
    padding: 5px 15px;
    border-radius: 30px;
    display: inline-block;
}
.small-icons-row {
    display: flex;
    gap: 18px;
    margin-top: 16px;
    color: #afe1ff;
    font-size: 1.8rem;
    flex-wrap: wrap;
    justify-content: center;
}
.small-icons-row i {
    background: #112f44;
    padding: 12px;
    border-radius: 50%;
    border: 1px solid white;
    box-shadow: 0 0 15px cyan;
    transition: 0.2s;
}
.small-icons-row i:hover {
    transform: scale(1.1);
    background: #1d4e6b;
}

/* радио скрыто */
.hidden-radio {
    width: 0;
    height: 0;
    opacity: 0;
    position: absolute;
    pointer-events: none;
}

/* FOOTER */
.footer-stats {
    margin-top: 40px;
    background: rgba(2, 17, 30, 0.7);
    backdrop-filter: blur(8px);
    border-radius: 48px 48px 24px 24px;
    padding: 24px 20px 18px;
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 -10px 30px #00000050;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    color: #d7edff;
}
.stat-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: #08212e80;
    border-radius: 32px;
    padding: 14px 18px;
    border: 1px solid #5fa3c0;
    box-shadow: 0 4px 15px black;
}
.stat-title {
    font-weight: 300;
    font-size: 1rem;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px dashed #3f8fb0;
    padding-bottom: 6px;
}
.stat-numbers {
    font-size: 1.7rem;
    font-weight: 700;
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
}
.stat-numbers span {
    background: #00000040;
    padding: 5px 14px;
    border-radius: 40px;
    font-size: 1.2rem;
    border: 1px solid cyan;
}
.update-live {
    color: #6ef0b0;
    animation: pulse 2s infinite;
}
@keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.5; } }
.copyright {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #4f95b0;
    font-size: 0.95rem;
    color: #bfddee;
}
.copyright i {
    margin: 0 5px;
    color: #ffb347;
}
.hamster-icon {
    font-size: 1.7rem;
    margin-left: 10px;
    filter: drop-shadow(0 0 6px #ffb347);
}

/* Адаптивность */
@media (max-width: 600px) {
    .chat-card { padding: 16px; border-radius: 32px; }
    .header-snow { border-radius: 50px; padding: 12px; }
    .snowflake-logo { font-size: 2.6rem; }
    .fancy-button { font-size: 1.8rem; padding: 15px 30px; min-width: 250px; }
    .greeting-message { font-size: 2rem; }
    .post-loading-block { width: 100%; }
    .message-bubble { max-width: 100%; }
    .big-timer { letter-spacing: 2px; padding: 12px 10px; }
    .footer-stats { grid-template-columns: 1fr; }
}