:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --bg: #f8fafc;
    --card: #ffffff;
    --text: #1e293b;
    --text-light: #64748b;
    --border: #e2e8f0;
    --radius: 12px;
    --connected: #10b981;    /* Зеленый для connected */
    --on: #10b981;           /* Зеленый для on */
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

body {
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    padding: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.header .subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
    margin-bottom: 30px;
}

.card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Стили для заголовка карточки с выравниванием */
.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.card-title-content {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1; /* Занимает всё доступное пространство слева */
}

.card-title-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-title-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Стили для статусной иконки */
.status-icon {
    width: 24px;
    height: 24px;
    display: inline-block;
    vertical-align: middle;
}

.status-icon svg {
    width: 100%;
    height: 100%;
}

.status-icon-unknown {
    color: var(--text-light);
}

.status-icon-off {
    color: var(--danger);
}

.status-icon-on {
    color: var(--success);
}

/* Анимация для иконки connecting */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.status-icon-connecting svg {
    animation: spin 1.5s linear infinite;
}

/* Анимация для иконки disconnecting */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-icon-disconnecting svg {
    animation: pulse 1s ease-in-out infinite;
}

/* Текст статуса в заголовке */
.card-status-text {
    font-size: 0.9rem;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 12px;
    background: var(--bg);
}

.card-status-unknown {
    color: var(--text-light);
    background: rgba(100, 116, 139, 0.1);
}

.card-status-off {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
}

.card-status-on {
    color: var(--success);
    background: rgba(16, 185, 129, 0.1);
}

.card-status-connecting {
    color: var(--warning);
    background: rgba(245, 158, 11, 0.1);
}

.card-status-disconnecting {
    color: var(--warning);
    background: rgba(245, 158, 11, 0.1);
}

/* Старый индикатор статуса (убираем или изменяем) */
.status-indicator {
    display: none; /* Скрываем старый индикатор */
}

.card-title i {
    font-size: 1.4rem;
}

.status-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 500;
    margin-bottom: 20px;
}

.status-connected,
.status-on {
    background: rgba(16, 185, 129, 0.1);
    color: var(--connected);
    border: 2px solid var(--connected);
}

.status-disconnected {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    border: 2px solid var(--danger);
}

.status-connecting {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
    border: 2px solid var(--warning);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    color: var(--text-light);
    font-weight: 500;
}

.info-value {
    font-weight: 600;
    color: var(--text);
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 4px;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: var(--primary-hover);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-warning {
    background: var(--warning);
    color: white;
}

.btn-secondary {
    background: var(--border);
    color: var(--text);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.btn-group .btn {
    flex: 1;
    min-width: 140px;
}

.server-list {
    max-height: 155px;
    min-height: 155px;
    overflow-y: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-top: 15px;
}

/*#historyList {
    max-height: 155px !important;
    min-height: 155px !important;
}*/

.server-item {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.2s;
}

.server-item:hover {
    background: rgba(37, 99, 235, 0.05);
}

.server-item.selected {
    background: rgba(37, 99, 235, 0.1);
    border-left: 4px solid var(--primary);
}

.server-item:last-child {
    border-bottom: none;
}

.server-city {
    font-weight: 600;
    color: var(--text);
}

.server-nick {
    font-weight: 400;
    color: var(--primary);
}

.server-region {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-top: 4px;
}

.history-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.history-item:last-child {
    border-bottom: none;
}

.history-time {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.history-server {
    font-weight: 500;
}

.config-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.config-label {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
}

.config-value {
    color: var(--text-light);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.config-value:hover {
    background: rgba(0, 0, 0, 0.05);
}

.config-input {
    padding: 6px 12px;
    border: 2px solid var(--primary);
    border-radius: 6px;
    font-size: 1rem;
    width: 200px;
}

.checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.stat-card {
    background: var(--bg);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-top: 5px;
}

.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: var(--text-light);
}

.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Стили для заблокированных элементов */
.server-item.disabled {
    cursor: not-allowed !important;
    opacity: 0.6 !important;
    background-color: rgba(0, 0, 0, 0.05) !important;
}

.server-item.disabled:hover {
    background-color: rgba(0, 0, 0, 0.05) !important;
    transform: none !important;
}

.btn:disabled {
    cursor: not-allowed !important;
    opacity: 0.6 !important;
}

.btn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
}

.history-index {
    display: inline-block;
    width: 20px;
    color: var(--text-light);
    font-weight: bold;
    margin-right: 5px;
}

/*
* notification start
*/
/* Контейнер для уведомлений */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1001; /* Выше чем у .notification (1000) */
    max-width: 400px;
    pointer-events: none; /* Контейнер не блокирует клики */
}

/* Обновляем существующий стиль .notification */
.notification {
    position: relative; /* Меняем с fixed на relative */
    top: auto; /* Убираем фиксированную позицию */
    right: auto;
    padding: 16px 24px;
    border-radius: 8px;
    background: white;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 1000;
    animation: slideIn 0.3s ease;
    transition: transform 0.3s ease, opacity 0.3s ease;
    opacity: 1;
    pointer-events: auto; /* Уведомления кликабельны */
    border-left: 4px solid transparent; /* Будет переопределено классами */
    margin-bottom: 0;
}

/* Исправляем анимацию slideIn */
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Добавляем анимацию скрытия */
@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

.notification.hiding {
    animation: slideOut 0.3s ease forwards;
}

/* Оставляем существующие цветовые классы как есть */
.notification-success {
    border-left: 4px solid var(--success);
}

.notification-error {
    border-left: 4px solid var(--danger);
}

.notification-warning {
    border-left: 4px solid var(--warning);
}

.notification-info {
    border-left: 4px solid var(--primary);
}
/*
* notification end
*/

.mobile-warning {
    display: none;
    background: var(--warning);
    color: white;
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .mobile-warning {
        display: block;
    }

    .btn-group {
        flex-direction: column;
    }

    .btn-group .btn {
        width: 100%;
    }
}

.filter-info {
    background: rgba(37, 99, 235, 0.05);
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.filter-info ul {
    list-style: none;
    margin-top: 10px;
}

.filter-info li {
    padding: 4px 0;
    color: var(--text-light);
}

.connection-timer {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: var(--primary);
}

/* Стили для новой карточки Browser Location Info */
.card:nth-child(1) .card-title i {
    color: #3b82f6; /* Синий для локации */
}

/* Стили для новой карточки Automatically Location Selection */
.card:nth-child(3) .card-title i {
    color: #8b5cf6; /* Фиолетовый для автоматического выбора */
}

/* Стили для выпадающего списка */
.config-select {
    padding: 6px 12px;
    border: 2px solid var(--border);
    border-radius: 6px;
    font-size: 0.9rem;
    background: var(--card);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.2s;
}

.config-select:hover {
    border-color: var(--primary);
}

.config-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Стили для карточек статистики в новом формате */
.info-row.compact {
    padding: 8px 0;
    font-size: 0.9rem;
}

.info-row.compact .info-label {
    font-weight: normal;
}

/* Стили для индикатора скорости */
.speed-indicator {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-left: 10px;
}

.speed-fast {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border: 1px solid var(--success);
}

.speed-medium {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
    border: 1px solid var(--warning);
}

.speed-slow {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    border: 1px solid var(--danger);
}

/* Адаптивные стили для новых карточек */
@media (max-width: 1200px) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .config-select {
        width: 100%;
        margin-top: 5px;
    }

    .config-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .config-label {
        margin-bottom: 5px;
    }
}

/* Стили для отображения информации о скорости */
.speed-info {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 5px;
}

.speed-value {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: var(--primary);
}

.speed-unit {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Улучшенные стили для кнопок */
.btn i {
    font-size: 0.9em;
}

/* Анимация для авто-выбора */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(139, 92, 246, 0.5);
    }
    50% {
        box-shadow: 0 0 15px rgba(139, 92, 246, 0.8);
    }
}

.card:nth-child(3):hover {
    animation: pulse-glow 2s infinite;
}

.status-connected {
    color: var(--success) !important;
    font-weight: 600 !important;
}

.status-connecting,
.status-disconnecting {
    color: var(--warning) !important;
    font-weight: 600 !important;
}

.status-disconnected,
.status-unknown {
    color: var(--text-light) !important;
    font-weight: normal !important;
}

/* Стили для оверлея обновления браузерной локации */
.browser-location-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 100;
    border-radius: var(--radius);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none; /* Разрешаем клики сквозь оверлей на элементы ниже */
}

.card:first-child {
    position: relative;
    overflow: hidden;
}

.updating-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(37, 99, 235, 0.2);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.updating-text {
    color: var(--primary);
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.9);
    padding: 8px 16px;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Для мобильных устройств */
@media (max-width: 768px) {
    .browser-location-overlay {
        background: rgba(255, 255, 255, 0.95);
    }

    .updating-text {
        font-size: 0.9rem;
        padding: 6px 12px;
    }
}

/* Добавьте в конец файла ui.css */

/* Стили для карточки Auto Rotation */
.rotation-progress-container {
    margin: 10px 0 5px 0;
    padding: 0;
}

.rotation-progress-bar {
    width: 100%;
    height: 2px;
    background: var(--border);
    border-radius: 1px;
    overflow: hidden;
}

.rotation-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--success));
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 1px;
}

/* Статусы авто-ротации */
.status-active {
    color: var(--success);
    font-weight: 600;
}

.status-waiting {
    color: var(--warning);
}

.status-error {
    color: var(--danger);
}

.status-inactive {
    color: var(--text-light);
}

/* Кнопка Cancel */
#btnCancelRotation {
    width: 100%;
    padding: 8px;
    font-size: 0.9rem;
    margin-top: 10px;
}

/* Стили для карточки Auto Rotation */
.auto-rotation-card {
    position: relative;
    overflow: visible;
}

/* Рамки для Auto Rotation */
.rotation-frame {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    margin: 10px 0;
    transition: all 0.3s ease;
    position: relative;
}

/* Состояния рамок */
.rotation-frame.active {
    border-color: var(--primary);
    box-shadow: 0 0 0 1px var(--primary), 0 2px 8px rgba(37, 99, 235, 0.1);
    background: rgba(37, 99, 235, 0.02);
}

.rotation-frame.success {
    border-color: var(--success);
    box-shadow: 0 0 0 1px var(--success), 0 2px 8px rgba(16, 185, 129, 0.1);
    background: rgba(16, 185, 129, 0.02);
}

.rotation-frame.error {
    border-color: var(--danger);
    box-shadow: 0 0 0 1px var(--danger), 0 2px 8px rgba(239, 68, 68, 0.1);
    background: rgba(239, 68, 68, 0.02);
}

.rotation-frame.completed {
    border-color: var(--border);
    box-shadow: none;
    background: transparent;
}

/* Индикатор состояния в углу рамки */
.rotation-frame::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
    transition: all 0.3s ease;
    z-index: 2;
}

.rotation-frame.active::before {
    background: var(--primary);
    box-shadow: 0 0 0 2px white, 0 0 0 4px var(--primary);
    animation: pulse-frame 2s infinite;
}

.rotation-frame.success::before {
    background: var(--success);
    box-shadow: 0 0 0 2px white, 0 0 0 4px var(--success);
}

.rotation-frame.error::before {
    background: var(--danger);
    box-shadow: 0 0 0 2px white, 0 0 0 4px var(--danger);
}

@keyframes pulse-frame {
    0%, 100% {
        box-shadow: 0 0 0 2px white, 0 0 0 4px var(--primary);
    }
    50% {
        box-shadow: 0 0 0 2px white, 0 0 0 6px rgba(37, 99, 235, 0.5);
    }
}

/* Ползунок прогресса (очень тонкий, прижатый к низу) */
.rotation-progress-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    border-radius: 0 0 var(--radius) var(--radius);
    overflow: hidden;
    z-index: 3;
}

.rotation-progress-bar {
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.05);
    position: relative;
}

.rotation-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--success));
    width: 0%;
    transition: width 0.5s linear;
    position: absolute;
    top: 0;
    left: 0;
}

/* Текст таймера над ползунком */
.rotation-timer-text {
    position: absolute;
    right: 10px;
    bottom: 5px;
    font-size: 0.75rem;
    color: var(--text-light);
    font-weight: 500;
    z-index: 4;
    background: rgba(255, 255, 255, 0.9);
    padding: 2px 6px;
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Кнопка Cancel */
.btn-cancel {
    width: 100%;
    padding: 10px;
    font-size: 0.9rem;
    border-radius: 6px;
    background: linear-gradient(135deg, var(--danger), #dc2626);
    border: none;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.2);
}

.btn-cancel:hover:not(:disabled) {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(239, 68, 68, 0.3);
}

.btn-cancel:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(239, 68, 68, 0.2);
}

/* Статусы текстовые */
.status-active {
    color: var(--primary);
    font-weight: 600;
}

.status-waiting {
    color: var(--warning);
}

.status-error {
    color: var(--danger);
}

.status-inactive {
    color: var(--text-light);
}

.status-completed {
    color: var(--success);
    font-weight: 600;
}

.status-failed {
    color: var(--danger);
    font-weight: 600;
}

/* Адаптивность для рамок */
@media (max-width: 768px) {
    .rotation-frame {
        padding: 10px;
        margin: 8px 0;
    }

    .rotation-frame::before {
        width: 8px;
        height: 8px;
        top: -4px;
    }

    .rotation-timer-text {
        font-size: 0.7rem;
        bottom: 4px;
        right: 8px;
    }
}

/* Анимация пульсации для привлечения внимания */
@keyframes pulse-highlight {
    0%, 100% {
        box-shadow: 0 0 0 1px var(--primary), 0 2px 8px rgba(37, 99, 235, 0.1);
    }
    50% {
        box-shadow: 0 0 0 3px var(--primary), 0 4px 16px rgba(37, 99, 235, 0.3);
    }
}

@keyframes pulse-fast {
    0%, 100% {
        box-shadow: 0 0 0 1px var(--warning), 0 2px 8px rgba(245, 158, 11, 0.2);
    }
    50% {
        box-shadow: 0 0 0 3px var(--warning), 0 4px 16px rgba(245, 158, 11, 0.4);
    }
}

/* Стили для кнопки Launch */
.btn-launch {
    width: 100%;
    margin-top: 10px;
    padding: 10px;
    background: linear-gradient(135deg, var(--warning), #f59e0b);
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.2);
}

.btn-launch:hover {
    background: linear-gradient(135deg, #e69500, #d97706);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.3);
}

.btn-launch:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(245, 158, 11, 0.2);
}

/* Стили для фокуса на рамке */
.rotation-frame:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Анимации для появления/исчезновения элементов */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeOutDown {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(10px);
        display: none;
    }
}

/* Классы для анимаций */
.fade-in-up {
    animation: fadeInUp 0.4s ease forwards;
}

.fade-out-down {
    animation: fadeOutDown 0.4s ease forwards;
}

/* Текст отсчета для Launch Site */
.countdown-text {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 5px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.countdown-text.active {
    color: var(--warning);
    font-weight: 600;
}

.countdown-text.complete {
    color: var(--success);
    font-weight: 600;
}

/* Прогресс бар для Launch Site */
.launch-progress-bar {
    width: 100%;
    height: 2px;
    background: var(--border);
    margin-top: 8px;
    border-radius: 1px;
    overflow: hidden;
}

.launch-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--warning), var(--success));
    width: 0%;
    transition: width 0.5s linear;
}

/* ============================= */
/* Auto Rotation icon animation */
/* ============================= */

@keyframes rotate-continuous {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* Вращение иконки, когда карточка в режиме autorotation */
.auto-rotation-card.autorotation-active
.card-title-content i {
    animation: rotate-continuous 1.2s linear infinite;
    transform-origin: 50% 50%;
}

/* ============================= */
/* Heartbeat effect (AutoRotation) */
/* ============================= */

@keyframes heartbeat {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.015); }
    60%  { transform: scale(0.995); }
    100% { transform: scale(1); }
}

/* Постоянный heartbeat при активной авторотации */
.auto-rotation-card.autorotation-active {
    animation: heartbeat 2.2s ease-in-out infinite;
    box-shadow:
        0 0 0 0 rgba(37, 99, 235, 0.35),
        var(--shadow);
}

/* Усиление heartbeat при hover */
.auto-rotation-card.autorotation-active:hover {
    animation: heartbeat 1.2s ease-in-out infinite;
    box-shadow:
        0 0 0 6px rgba(37, 99, 235, 0.25),
        0 12px 24px rgba(37, 99, 235, 0.25);
}
