/* TempMail Pro - Основные стили */

:root {
    --primary-color: #667eea;
    --primary-dark: #764ba2;
    --secondary-color: #f093fb;
    --success-color: #4caf50;
    --error-color: #f44336;
    --warning-color: #ff9800;
    --info-color: #2196f3;

    --text-primary: #333333;
    --text-secondary: #666666;
    --text-muted: #999999;
    --text-white: #ffffff;

    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-hover: #e9ecef;
    --bg-dark: #2c3e50;
    --bg-overlay: rgba(0, 0, 0, 0.5);

    --border-color: #e0e0e0;
    --border-radius: 8px;
    --border-radius-lg: 12px;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.2);

    --transition: all 0.3s ease;
    --font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
}

/* Базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-primary);
    background: #000;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}


/* Навигация */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-title {
    font-size: 1.8rem;
    color: var(--primary-color);
    font-weight: 800;
    margin-bottom: 0.2rem;
    background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: brandGlow 3s ease-in-out infinite;
}

.brand-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1px;
}

@keyframes brandGlow {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.auth-buttons, .user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.balance {
    background: var(--bg-secondary);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    font-weight: 600;
    color: var(--primary-color);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 3px;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
    transition: var(--transition);
}

/* Видео фон */
.video-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: -1;
}

/* Основной контент */
.main-content {
    position: relative;
    z-index: 1;
    padding: 2rem 0;
    min-height: 100vh;
}

.hero-section {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-white);
}

.hero-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hero-section p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.dns-status {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    margin: 2rem auto;
    max-width: 600px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--warning-color);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-dot.active {
    background: var(--success-color);
    animation: none;
}

/* Карточки */
.card {
    background: var(--bg-primary);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}

.card h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 600;
}

/* Формы */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
    background: var(--bg-primary);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Кнопки */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
    color: var(--text-white);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--text-white);
}

.btn-success {
    background: var(--success-color);
    color: var(--text-white);
}

.btn-error {
    background: var(--error-color);
    color: var(--text-white);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    width: 100%;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.btn-link {
    background: none;
    border: none;
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
    font-size: inherit;
}

/* Результаты */
.result-card {
    margin: 2rem 0;
}

.result-card.success {
    background: #e8f5e8;
    border: 2px solid var(--success-color);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
}

.result-card.error {
    background: #ffeaea;
    border: 2px solid var(--error-color);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
}

.email-display {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--success-color);
    word-break: break-all;
    margin: 1rem 0;
    padding: 1rem;
    background: rgba(76, 175, 80, 0.1);
    border-radius: var(--border-radius);
}

/* Список email адресов */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.emails-list {
    display: grid;
    gap: 1rem;
}

.email-item {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.email-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow-sm);
}

.email-item .email-address {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.email-item .email-info {
    display: flex;
    gap: 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.email-item .email-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.9rem;
}

.stat-badge {
    background: var(--primary-color);
    color: var(--text-white);
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
}

/* Тарифы */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.pricing-card {
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    text-align: center;
    transition: var(--transition);
}

.pricing-card.featured {
    border-color: var(--primary-color);
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-5px);
}

.pricing-card h4 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.price {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
}

.features {
    list-style: none;
    text-align: left;
}

.features li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.features li:before {
    content: "✓";
    color: var(--success-color);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-overlay);
    backdrop-filter: blur(5px);
    z-index: 2000;
    animation: fadeIn 0.3s ease;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: var(--bg-primary);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 971px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideIn 0.3s ease;
}

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    color: var(--primary-color);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    line-height: 1;
}

.modal-close:hover {
    color: var(--error-color);
}

.modal-body {
    padding: 2rem;
}

.auth-switch {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

/* Пополнение баланса */
.balance-presets {
    display: flex;
    gap: 0.5rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

/* Уведомления */
.notifications {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 3000;
    max-width: 400px;
}

.notification {
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--info-color);
    animation: slideInRight 0.3s ease;
}

.notification.success {
    border-left-color: var(--success-color);
}

.notification.error {
    border-left-color: var(--error-color);
}

.notification.warning {
    border-left-color: var(--warning-color);
}

/* Утилиты */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-muted { color: var(--text-muted); }
.text-primary { color: var(--primary-color); }
.text-success { color: var(--success-color); }
.text-error { color: var(--error-color); }

.loading {
    text-align: center;
    color: var(--text-muted);
    font-style: italic;
    padding: 2rem;
}

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Сервисная сетка */
.services-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
    padding: 0 2rem;
    align-items: flex-start;
}

/* Адаптивность для карточек сервисов */
@media (max-width: 1200px) {
    .services-grid {
        justify-content: center;
        gap: 1.5rem;
    }
}

.service-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 1.75rem;
    text-align: center;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    color: var(--text-white);
    width: calc(20% - 0.8rem);
    height: 225px;
    flex: 0 0 calc(20% - 0.8rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg,
        rgba(102, 126, 234, 0.1) 0%,
        rgba(118, 75, 162, 0.1) 50%,
        rgba(240, 147, 251, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.service-card:hover:not(.coming-soon):not(.in-maintenance) {
    transform: translateY(-8px) scale(1.02);
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(102, 126, 234, 0.3);
    box-shadow:
        0 20px 40px rgba(102, 126, 234, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.1);
}

.service-card:hover:not(.coming-soon):not(.in-maintenance)::before {
    opacity: 1;
}

.service-card.coming-soon {
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.service-card.coming-soon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 15% 25%, rgba(255, 223, 0, 0.8) 0%, transparent 8%),
        radial-gradient(circle at 85% 15%, rgba(255, 193, 7, 0.7) 0%, transparent 10%),
        radial-gradient(circle at 10% 80%, rgba(218, 165, 32, 0.9) 0%, transparent 12%),
        radial-gradient(circle at 90% 75%, rgba(255, 215, 0, 0.75) 0%, transparent 9%),
        radial-gradient(circle at 50% 10%, rgba(255, 179, 0, 0.85) 0%, transparent 7%),
        radial-gradient(circle at 25% 60%, rgba(255, 223, 0, 0.7) 0%, transparent 11%),
        radial-gradient(circle at 70% 50%, rgba(255, 193, 7, 0.8) 0%, transparent 10%),
        radial-gradient(circle at 40% 90%, rgba(218, 165, 32, 0.75) 0%, transparent 8%),
        linear-gradient(135deg,
            rgba(255, 223, 0, 0.95) 0%,
            rgba(255, 215, 0, 0.95) 15%,
            rgba(255, 193, 7, 0.95) 30%,
            rgba(255, 179, 0, 0.95) 45%,
            rgba(218, 165, 32, 0.95) 60%,
            rgba(255, 193, 7, 0.95) 75%,
            rgba(255, 223, 0, 0.95) 100%
        );
    background-size: 400% 400%;
    animation: backgroundGlow 30s ease-in-out infinite, goldSplashes 30s ease-in-out infinite;
    z-index: 1;
    border-radius: inherit;
    box-shadow:
        inset 0 0 60px rgba(255, 215, 0, 0.6),
        inset 0 0 100px rgba(218, 165, 32, 0.4);
}

.service-card.coming-soon > * {
    position: relative;
    z-index: 2;
    opacity: 0.3;
}

.service-card.coming-soon::after {
    content: 'В РАЗРАБОТКЕ';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #1a1a1a;
    font-weight: 900;
    font-size: 1.3rem;
    letter-spacing: 5px;
    text-shadow:
        0 2px 4px rgba(255, 255, 255, 0.8),
        0 0 20px rgba(255, 215, 0, 1),
        0 0 40px rgba(255, 215, 0, 1);
    animation: textGlow 30s ease-in-out infinite;
    z-index: 10;
}

@keyframes backgroundGlow {
    0% {
        opacity: 1;
        background-position: 0% 50%;
    }
    4.75% {
        opacity: 1;
        background-position: 100% 50%;
    }
    7.6% {
        opacity: 0.5;
        background-position: 100% 100%;
    }
    9.5% {
        opacity: 0;
        background-position: 50% 100%;
    }
    19%, 100% {
        opacity: 0;
        background-position: 0% 50%;
    }
}

@keyframes goldSplashes {
    0% {
        filter: brightness(1) blur(0px);
    }
    1.9% {
        filter: brightness(1.3) blur(2px);
    }
    3.8% {
        filter: brightness(1.1) blur(1px);
    }
    5.7% {
        filter: brightness(1.5) blur(3px);
    }
    7.6% {
        filter: brightness(1) blur(1px);
    }
    9.5% {
        filter: brightness(0.8) blur(0px);
    }
    11.4% {
        filter: brightness(0.6) blur(1px);
    }
    19%, 100% {
        filter: brightness(0.6) blur(0px);
    }
}

@keyframes textGlow {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.8),
            0 0 25px rgba(255, 215, 0, 1),
            0 0 50px rgba(255, 215, 0, 0.9),
            0 0 75px rgba(218, 165, 32, 0.7);
    }
    4.75% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.1);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 1),
            0 0 40px rgba(255, 215, 0, 1),
            0 0 80px rgba(255, 215, 0, 1),
            0 0 120px rgba(218, 165, 32, 1);
    }
    7.6% {
        opacity: 0.6;
        transform: translate(-50%, -50%) scale(1.08);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.4),
            0 0 25px rgba(255, 215, 0, 0.6),
            0 0 50px rgba(255, 215, 0, 0.4);
    }
    9.5% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.05);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.1),
            0 0 10px rgba(255, 215, 0, 0.2);
    }
    19%, 100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.05);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.1),
            0 0 10px rgba(255, 215, 0, 0.2);
    }
}

.service-card.coming-soon:hover {
    transform: none;
}

/* Техническое обслуживание - оранжевый стиль */
.service-card.in-maintenance {
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.service-card.in-maintenance::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 15% 25%, rgba(255, 140, 0, 0.8) 0%, transparent 8%),
        radial-gradient(circle at 85% 15%, rgba(255, 127, 0, 0.7) 0%, transparent 10%),
        radial-gradient(circle at 10% 80%, rgba(255, 165, 0, 0.9) 0%, transparent 12%),
        radial-gradient(circle at 90% 75%, rgba(255, 140, 0, 0.75) 0%, transparent 9%),
        radial-gradient(circle at 50% 10%, rgba(255, 120, 0, 0.85) 0%, transparent 7%),
        radial-gradient(circle at 25% 60%, rgba(255, 140, 0, 0.7) 0%, transparent 11%),
        radial-gradient(circle at 70% 50%, rgba(255, 127, 0, 0.8) 0%, transparent 10%),
        radial-gradient(circle at 40% 90%, rgba(255, 165, 0, 0.75) 0%, transparent 8%),
        linear-gradient(135deg,
            rgba(255, 140, 0, 0.95) 0%,
            rgba(255, 127, 0, 0.95) 15%,
            rgba(255, 165, 0, 0.95) 30%,
            rgba(255, 120, 0, 0.95) 45%,
            rgba(255, 145, 0, 0.95) 60%,
            rgba(255, 127, 0, 0.95) 75%,
            rgba(255, 140, 0, 0.95) 100%
        );
    background-size: 400% 400%;
    animation: backgroundGlowOrange 30s ease-in-out infinite, orangeSplashes 30s ease-in-out infinite;
    z-index: 1;
    border-radius: inherit;
    box-shadow:
        inset 0 0 60px rgba(255, 140, 0, 0.6),
        inset 0 0 100px rgba(255, 127, 0, 0.4);
}

.service-card.in-maintenance > * {
    position: relative;
    z-index: 2;
    opacity: 0.3;
}

.service-card.in-maintenance::after {
    content: 'ТЕХНИЧЕСКОЕ ОБСЛУЖИВАНИЕ';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #1a1a1a;
    font-weight: 900;
    font-size: 1.1rem;
    letter-spacing: 4px;
    text-shadow:
        0 2px 4px rgba(255, 255, 255, 0.8),
        0 0 20px rgba(255, 140, 0, 1),
        0 0 40px rgba(255, 140, 0, 1);
    animation: textGlowOrange 30s ease-in-out infinite;
    z-index: 10;
}

@keyframes backgroundGlowOrange {
    0% {
        opacity: 1;
        background-position: 0% 50%;
    }
    4.75% {
        opacity: 1;
        background-position: 100% 50%;
    }
    7.6% {
        opacity: 0.5;
        background-position: 100% 100%;
    }
    9.5% {
        opacity: 0;
        background-position: 50% 100%;
    }
    19%, 100% {
        opacity: 0;
        background-position: 0% 50%;
    }
}

@keyframes orangeSplashes {
    0% {
        filter: brightness(1) blur(0px);
    }
    1.9% {
        filter: brightness(1.3) blur(2px);
    }
    3.8% {
        filter: brightness(1.1) blur(1px);
    }
    5.7% {
        filter: brightness(1.5) blur(3px);
    }
    7.6% {
        filter: brightness(1) blur(1px);
    }
    9.5% {
        filter: brightness(0.8) blur(0px);
    }
    11.4% {
        filter: brightness(0.6) blur(1px);
    }
    19%, 100% {
        filter: brightness(0.6) blur(0px);
    }
}

@keyframes textGlowOrange {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.8),
            0 0 25px rgba(255, 140, 0, 1),
            0 0 50px rgba(255, 140, 0, 0.9),
            0 0 75px rgba(255, 127, 0, 0.7);
    }
    4.75% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.1);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 1),
            0 0 40px rgba(255, 140, 0, 1),
            0 0 80px rgba(255, 140, 0, 1),
            0 0 120px rgba(255, 127, 0, 1);
    }
    7.6% {
        opacity: 0.6;
        transform: translate(-50%, -50%) scale(1.08);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.4),
            0 0 25px rgba(255, 140, 0, 0.6),
            0 0 50px rgba(255, 140, 0, 0.4);
    }
    9.5% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.05);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.1),
            0 0 10px rgba(255, 140, 0, 0.2);
    }
    19%, 100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.05);
        text-shadow:
            0 2px 4px rgba(255, 255, 255, 0.1),
            0 0 10px rgba(255, 140, 0, 0.2);
    }
}

.service-card.in-maintenance:hover {
    transform: none;
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 0.8rem;
    display: block;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.animated-icon {
    animation: iconFloat 3s ease-in-out infinite;
}

.animated-icon-pdf {
    animation: pdfGlow 2s ease-in-out infinite;
}

.animated-icon-mobile {
    animation: mobileShake 1.5s ease-in-out infinite;
}

.animated-icon-bookmaker {
    animation: bookmakerSpin 2.5s ease-in-out infinite;
}

.animated-icon-support {
    animation: supportWave 3s ease-in-out infinite;
}

.animated-icon-admin {
    animation: adminRotate 4s ease-in-out infinite;
}

.animated-icon-photo {
    animation: photoFlash 2s ease-in-out infinite;
}

@keyframes iconFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    33% { transform: translateY(-8px) rotate(2deg); }
    66% { transform: translateY(-4px) rotate(-1deg); }
}

@keyframes pdfGlow {
    0%, 100% { transform: scale(1); filter: brightness(1) drop-shadow(0 0 5px rgba(255, 165, 0, 0.3)); }
    50% { transform: scale(1.05); filter: brightness(1.2) drop-shadow(0 0 15px rgba(255, 165, 0, 0.6)); }
}

@keyframes mobileShake {
    0%, 100% { transform: translateX(0) rotateZ(0deg); }
    25% { transform: translateX(-2px) rotateZ(-1deg); }
    50% { transform: translateX(2px) rotateZ(1deg); }
    75% { transform: translateX(-1px) rotateZ(-0.5deg); }
}

@keyframes bookmakerSpin {
    0%, 100% { transform: rotateZ(0deg) scale(1); filter: hue-rotate(0deg); }
    25% { transform: rotateZ(90deg) scale(1.1); filter: hue-rotate(45deg); }
    50% { transform: rotateZ(180deg) scale(1.05); filter: hue-rotate(90deg); }
    75% { transform: rotateZ(270deg) scale(1.1); filter: hue-rotate(135deg); }
}

@keyframes photoFlash {
    0%, 100% { transform: scale(1); filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 255, 0.4)); }
    10% { transform: scale(1.15); filter: brightness(1.5) drop-shadow(0 0 20px rgba(255, 255, 255, 0.9)); }
    20% { transform: scale(1); filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 255, 0.4)); }
}

/* Bookmaker Shop Styles */
.bookmaker-shop-content {
    padding: 20px 0;
}

.shop-filters {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-color);
}

.filter-group select {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-color);
    color: var(--text-color);
    font-size: 14px;
}

.bookmaker-grid {
    display: block;
    margin-top: 20px;
}

.bookmaker-row {
    display: flex;
    align-items: center;
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.bookmaker-row:hover {
    border-color: var(--primary-color);
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.bookmaker-info {
    display: flex;
    align-items: center;
    flex: 1;
    gap: 15px;
}

.bookmaker-flag {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 150px;
}

.bookmaker-flag .flag-icon {
    width: 24px;
    height: 18px;
    border-radius: 3px;
}

.bookmaker-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 120px;
}

.bookmaker-logo img {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}

.bookmaker-quantity {
    min-width: 120px;
    display: flex;
    align-items: center;
}

.stock-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    gap: 4px;
    transition: all 0.3s ease;
}

.stock-badge.in-stock {
    background: linear-gradient(135deg, #10b98120 0%, #22c55e15 100%);
    color: #10b981;
    border: 1px solid #10b98140;
}

.stock-badge.out-of-stock {
    background: linear-gradient(135deg, #ef444420 0%, #dc262615 100%);
    color: #ef4444;
    border: 1px solid #ef444440;
}

.bookmaker-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    min-width: 80px;
}

.bookmaker-buy {
    min-width: 120px;
}

.bookmaker-buy .buy-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.bookmaker-buy .buy-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .shop-filters {
        flex-direction: column;
        gap: 15px;
    }

    .bookmaker-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .bookmaker-flag,
    .bookmaker-logo,
    .bookmaker-quantity,
    .bookmaker-price {
        min-width: auto;
    }
}

@keyframes supportWave {
    0%, 100% { transform: rotateZ(0deg) translateY(0px); }
    25% { transform: rotateZ(-10deg) translateY(-3px); }
    50% { transform: rotateZ(0deg) translateY(-6px); }
    75% { transform: rotateZ(10deg) translateY(-3px); }
}

@keyframes adminRotate {
    0%, 100% { transform: rotateY(0deg) scale(1); filter: hue-rotate(0deg); }
    25% { transform: rotateY(90deg) scale(1.05); filter: hue-rotate(90deg); }
    50% { transform: rotateY(180deg) scale(1.1); filter: hue-rotate(180deg); }
    75% { transform: rotateY(270deg) scale(1.05); filter: hue-rotate(270deg); }
}

.service-card h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: inherit;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.service-card p {
    opacity: 0.8;
    font-size: 0.85rem;
    line-height: 1.4;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* Photo Generation Styles */
.photo-services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding: 10px 0;
}

.photo-service-card {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border: 2px solid rgba(102, 126, 234, 0.2);
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.photo-service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-service-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(102, 126, 234, 0.5);
    box-shadow:
        0 20px 40px rgba(102, 126, 234, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.1);
}

.photo-service-card:hover::before {
    opacity: 1;
}

.photo-service-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    animation: photoServicePulse 2s ease-in-out infinite;
}

.photo-service-card h4 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--text-primary);
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.photo-service-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

@keyframes photoServicePulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.5));
    }
    50% {
        transform: scale(1.1);
        filter: drop-shadow(0 0 20px rgba(118, 75, 162, 0.8));
    }
}

/* Face Swap Styles */
.face-swap-container {
    padding: 20px 0;
}

.face-swap-upload-section {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.upload-panel {
    position: relative;
    min-height: 350px;
}

.upload-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    border: 3px dashed rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    background: rgba(102, 126, 234, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
    min-height: 300px;
}

.upload-zone:hover {
    border-color: rgba(102, 126, 234, 0.6);
    background: rgba(102, 126, 234, 0.1);
}

.upload-zone.drag-over {
    border-color: #00ff88;
    background: rgba(0, 255, 136, 0.1);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 15px;
    opacity: 0.7;
}

.upload-zone h4 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.upload-zone p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.btn-upload {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 10px 30px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-upload:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.image-preview {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid rgba(102, 126, 234, 0.3);
}

.image-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.btn-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 0, 0, 0.8);
    color: white;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.btn-remove:hover {
    background: rgba(255, 0, 0, 1);
    transform: scale(1.1);
}

.swap-control-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    min-width: 180px;
}

.swap-arrow {
    font-size: 3rem;
    color: #00ff88;
    margin-bottom: 20px;
    animation: arrowPulse 2s ease-in-out infinite;
}

@keyframes arrowPulse {
    0%, 100% {
        transform: translateX(0);
        opacity: 1;
    }
    50% {
        transform: translateX(10px);
        opacity: 0.7;
    }
}

.btn-process {
    background: linear-gradient(135deg, #00ff88, #00cc66);
    color: #000;
    border: none;
    padding: 15px 30px;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 15px rgba(0, 255, 136, 0.3);
}

.btn-process:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 255, 136, 0.5);
}

.btn-process:disabled {
    background: #444;
    color: #888;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-icon {
    font-size: 1.2rem;
}

.swap-status {
    text-align: center;
}

.status-text {
    font-size: 0.9rem;
    color: #888;
}

.swap-progress {
    width: 100%;
    margin-top: 10px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff88, #00cc66);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-align: center;
}

.face-swap-result {
    margin-top: 30px;
    padding: 20px;
    background: rgba(0, 255, 136, 0.05);
    border: 2px solid rgba(0, 255, 136, 0.2);
    border-radius: 12px;
}

.face-swap-result h4 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    text-align: center;
    color: #00ff88;
}

.result-image-container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto 20px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid rgba(102, 126, 234, 0.3);
}

.result-image-container img {
    width: 100%;
    height: auto;
    display: block;
}

.result-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.face-swap-history {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid var(--border-color);
}

.face-swap-history h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.btn-refresh {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 0.9rem;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.btn-refresh:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.history-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.history-item {
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.history-item:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.history-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    background: #000;
}

.history-item-info {
    padding: 10px;
}

.history-date {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}


/* Email Generation Module */
.email-generation-module {
    margin: 2rem 0;
}

.module-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

/* Список доменов */
.domains-section {
    margin-bottom: 2rem;
}

.domains-section h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.domains-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.domain-item {
    background: var(--bg-secondary);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    border: 2px solid var(--border-color);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.domain-item.active {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.1);
}

.domain-item:hover {
    border-color: var(--primary-color);
}

.domain-name {
    font-weight: 600;
    color: var(--text-primary);
}

.domain-status {
    font-size: 0.9rem;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-weight: 500;
}

.domain-status.online {
    background: var(--success-color);
    color: var(--text-white);
}

.domain-status.offline {
    background: var(--error-color);
    color: var(--text-white);
}

/* Простой генератор */
.simple-generator {
    margin-bottom: 2rem;
    overflow: visible;
}

.generator-row {
    display: flex;
    gap: 1rem;
    align-items: end;
    overflow: visible;
}

.email-input-group {
    width: 30%;
}

.generator-row .form-group:has(#domainSelect) {
    width: 50%;
}

.flex-grow {
    flex: 1;
}

.btn-go {
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius);
    font-weight: bold;
    white-space: nowrap;
    width: 15%;
    max-width: 100px;
    margin-bottom: 1.5rem;
}

/* Модальное окно с письмами */
.inbox-modal-body {
    max-height: 650px;
    overflow-y: auto;
}

.email-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.email-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.email-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.email-date {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.email-subject {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.email-body {
    background: var(--bg-primary);
    padding: 0.8rem;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.85rem;
    line-height: 1.4;
    white-space: pre-wrap;
    max-height: 200px;
    overflow-y: auto;
}

.no-emails {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
    font-style: italic;
}

/* Результат генерации */
.generation-result {
    margin: 2rem 0;
}

.generated-email-display {
    background: var(--success-color);
    color: var(--text-white);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.email-text {
    font-size: 1.2rem;
    font-weight: 600;
    word-break: break-all;
}

/* Кнопка копирования email */
.btn-copy-email {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-copy-email:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* История email */
.email-history {
    margin-top: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.email-history h4 {
    color: var(--primary-color);
    margin-bottom: 0.75rem;
}

.history-list {
    display: grid;
    gap: 0.75rem;
    max-height: 450px;
    overflow-y: auto;
}

.history-item {
    background: var(--bg-secondary);
    padding: 1rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.history-email {
    font-weight: 600;
    color: var(--primary-color);
}

.history-meta {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.history-actions {
    display: flex;
    gap: 0.5rem;
}

/* Адаптивность */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        padding: 1rem;
        box-shadow: var(--shadow-md);
        flex-direction: column;
        gap: 1rem;
    }

    .nav-menu.active {
        display: flex;
    }

    .hero-section h2 {
        font-size: 2rem;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .pricing-card.featured {
        transform: none;
    }

    .section-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }

    .email-item .email-info,
    .email-item .email-stats {
        flex-direction: column;
        gap: 0.5rem;
    }

    .balance-presets {
        justify-content: center;
    }

    .generator-row {
        flex-direction: column;
        gap: 1rem;
    }

    .domains-list {
        flex-direction: column;
    }

    .generated-email-display {
        flex-direction: column;
        text-align: center;
    }

    .history-item {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .hero-section h2 {
        font-size: 1.5rem;
    }

    .hero-section p {
        font-size: 1rem;
    }

    .card {
        padding: 1.5rem;
    }

    .modal-content {
        width: 95%;
    }

    .modal-body {
        padding: 1.5rem;
    }
}

/* Стили админ-панели */
.admin-panel {
    background: linear-gradient(45deg, rgba(255, 69, 0, 0.1), rgba(255, 140, 0, 0.1)) !important;
    border-color: rgba(255, 69, 0, 0.3) !important;
}

.admin-panel:hover:not(.coming-soon) {
    border-color: rgba(255, 69, 0, 0.5) !important;
    box-shadow: 0 20px 40px rgba(255, 69, 0, 0.3) !important;
}

.admin-modal-content {
    max-width: 1200px;
    max-height: 90vh;
}

.admin-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.admin-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.admin-section h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.stat-card {
    background: var(--bg-secondary);
    padding: 1rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-color);
}

.stat-card h5 {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.stat-card .stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

.stat-card .btn-reset-stat {
    margin-top: 0.75rem;
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    background: rgba(255, 69, 58, 0.1);
    color: #ff453a;
    border: 1px solid rgba(255, 69, 58, 0.3);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.stat-card .btn-reset-stat:hover {
    background: rgba(255, 69, 58, 0.2);
    border-color: rgba(255, 69, 58, 0.5);
    transform: translateY(-1px);
}

.stat-card .btn-reset-stat:active {
    transform: translateY(0);
}

.admin-users {
    max-height: 300px;
    overflow-y: auto;
}

.user-search-section {
    margin-bottom: 1rem;
}

.user-search-section input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.user-search-section input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.no-results {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* Вкладки админ-панели - компактный дизайн в 2 строки */
.admin-tabs-grid {
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 2rem;
    padding-bottom: 0.5rem;
}

.admin-tabs-row {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.admin-tabs-row:last-child {
    margin-bottom: 0;
}

.admin-tab {
    flex: 1;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
    color: var(--text-secondary);
    font-size: 0.85rem;
    white-space: nowrap;
    text-align: center;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.admin-tab:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.admin-tab.active {
    background: var(--primary-color);
    color: white;
    font-weight: bold;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
}

.admin-tab-content {
    display: block;
}

/* Заглушки для будущих функций */
.coming-soon-placeholder {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 2px dashed var(--border-color);
}

.placeholder-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.coming-soon-placeholder h5 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.coming-soon-placeholder p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.coming-soon-placeholder ul {
    text-align: left;
    max-width: 300px;
    margin: 0 auto;
    color: var(--text-secondary);
}

.coming-soon-placeholder li {
    margin-bottom: 0.5rem;
    padding-left: 1rem;
    position: relative;
}

.coming-soon-placeholder li:before {
    content: "•";
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

.user-item {
    background: var(--bg-secondary);
    padding: 1rem;
    margin-bottom: 0.5rem;
    border-radius: var(--border-radius);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.user-info {
    flex: 1;
}

.user-email {
    font-weight: 600;
    color: var(--text-primary);
}

.user-details {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.user-actions {
    display: flex;
    gap: 0.5rem;
}

/* Управление балансом */
.balance-operation-row {
    display: flex;
    gap: 1rem;
    align-items: end;
    margin-bottom: 1.5rem;
}

.operation-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.btn-operation {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    border: 2px solid;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    background: transparent;
    min-width: 100px;
}

.btn-success {
    color: var(--success-color);
    border-color: var(--success-color);
}

.btn-success:hover,
.btn-success.active {
    background: var(--success-color);
    color: var(--text-white);
}

.btn-error {
    color: var(--error-color);
    border-color: var(--error-color);
}

.btn-error:hover,
.btn-error.active {
    background: var(--error-color);
    color: var(--text-white);
}

/* Orders Table - Bookmaker Orders Styles (Admin) */
.orders-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.orders-table thead {
    background: var(--bg-primary);
}

.orders-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
}

.orders-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    word-break: break-word;
    white-space: normal;
}

.orders-table tr:hover {
    background: var(--bg-hover);
}

/* Client Orders Table - Compact for client history */
.client-orders-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    table-layout: auto;
}

.client-orders-table thead {
    background: var(--bg-primary);
}

.client-orders-table th {
    padding: 10px 8px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.client-orders-table td {
    padding: 10px 8px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    word-break: break-word;
}

/* Компактные колонки для клиентской таблицы */
.client-orders-table th:nth-child(1),
.client-orders-table td:nth-child(1) {
    width: 12%;
    white-space: nowrap;
}

.client-orders-table th:nth-child(2),
.client-orders-table td:nth-child(2) {
    width: 25%;
}

.client-orders-table th:nth-child(3),
.client-orders-table td:nth-child(3) {
    width: 8%;
    text-align: center;
}

.client-orders-table th:nth-child(4),
.client-orders-table td:nth-child(4) {
    width: 10%;
    white-space: nowrap;
}

.client-orders-table th:nth-child(5),
.client-orders-table td:nth-child(5) {
    width: 15%;
}

.client-orders-table th:nth-child(6),
.client-orders-table td:nth-child(6) {
    width: 30%;
}

.client-orders-table tr:hover {
    background: var(--bg-hover);
}

/* Стили для кнопок в таблице заказов */
.orders-table .btn-small {
    padding: 4px 10px;
    font-size: 0.8rem;
    border-radius: 8px;
    margin-right: 5px;
    min-width: auto;
    white-space: nowrap;
}

.orders-table .btn-success {
    background: var(--success-color);
    color: var(--text-white) !important;
    border: 1px solid var(--success-color);
}

.orders-table .btn-success:hover {
    background: #45a049;
    border-color: #45a049;
    transform: translateY(-1px);
}

.orders-table .btn-error {
    background: var(--error-color);
    color: var(--text-white) !important;
    border: 1px solid var(--error-color);
}

.orders-table .btn-error:hover {
    background: #c82333;
    border-color: #c82333;
    transform: translateY(-1px);
}

/* Статусы заказов */
.order-row-pending {
    background: rgba(255, 193, 7, 0.05);
}

.order-row-completed {
    background: rgba(40, 167, 69, 0.05);
}

.order-row-cancelled {
    background: rgba(220, 53, 69, 0.05);
}

/* ========== Custom Select Dropdown Styles ========== */
.custom-select {
    position: relative;
    width: 100%;
    user-select: none;
}

.select-selected {
    background: var(--bg-secondary);
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    transition: all 0.2s ease;
}

.select-selected:hover {
    border-color: var(--primary-color);
    background: var(--bg-hover);
}

.select-selected span {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-primary);
}

.select-arrow {
    font-size: 0.8rem;
    transition: transform 0.2s ease;
    color: var(--text-secondary);
}

.custom-select.active .select-arrow {
    transform: rotate(180deg);
}

.select-items {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.custom-select.active .select-items {
    display: block;
}

.select-item {
    padding: 10px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background 0.2s ease;
    color: var(--text-primary);
}

.select-item:hover {
    background: var(--bg-hover);
}

.select-item.selected {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary-color);
    font-weight: 500;
}

.select-item img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    flex-shrink: 0;
}

.select-item .bookmaker-icon {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    object-fit: contain;
}

/* Scrollbar для dropdown */
.select-items::-webkit-scrollbar {
    width: 8px;
}

.select-items::-webkit-scrollbar-track {
    background: var(--bg-primary);
    border-radius: 4px;
}

.select-items::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.select-items::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

.status-pending {
    background: rgba(255, 193, 7, 0.2);
    color: #856404;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.status-completed {
    background: rgba(40, 167, 69, 0.2);
    color: #155724;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.status-cancelled {
    background: rgba(220, 53, 69, 0.2);
    color: #721c24;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

/* Стили для формы подтверждения заказа */
#completeBookmakerOrderModal .modal-content {
    max-width: 1260px;
    width: 95%;
}

#completeBookmakerOrderModal .form-group {
    margin-bottom: 1.5rem;
}

#completeBookmakerOrderModal .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

#completeBookmakerOrderModal .form-group small {
    display: block;
    margin-top: 0.3rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

#completeBookmakerOrderModal .form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

#completeBookmakerOrderModal .form-actions button {
    padding: 6px 14px;
    font-size: 0.85rem;
    border-radius: 8px;
    min-width: auto;
}

#completeBookmakerOrderModal .btn-success {
    background: var(--success-color);
    color: var(--text-white) !important;
    border: 1px solid var(--success-color);
}

#completeBookmakerOrderModal .btn-success:hover {
    background: #45a049;
    border-color: #45a049;
}

/* PDF Generation Styles */
.price-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px;
    border-radius: var(--border-radius);
    margin: 15px 0;
    text-align: center;
    box-shadow: var(--shadow-md);
}

.price-info strong {
    font-size: 1.2rem;
}

#docTypeSelect:disabled,
#countrySelect:disabled {
    background-color: var(--bg-hover);
    cursor: not-allowed;
}

input[type="file"] {
    width: 100%;
    padding: 12px;
    border: 2px dashed var(--border-color);
    border-radius: var(--border-radius-lg);
    background: var(--bg-secondary);
    cursor: pointer;
    transition: var(--transition);
}

input[type="file"]:hover {
    border-color: var(--primary-color);
    background: var(--bg-hover);
}

.form-group small {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 5px;
    display: block;
}

/* Document Type Buttons */
.doc-type-buttons {
    display: flex;
    gap: 15px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.doc-type-btn {
    flex: 1;
    min-width: 150px;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    background: white;
    cursor: pointer;
    text-align: center;
    transition: var(--transition);
}

.doc-type-btn:hover {
    border-color: var(--primary-color);
    background: var(--bg-hover);
}

.doc-type-btn.active {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: white;
}

.doc-type-btn h4 {
    margin: 0 0 5px 0;
    font-size: 1rem;
}

.doc-type-btn .count {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Templates List */
.templates-list {
    margin: 20px 0;
}

.template-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin: 10px 0;
    cursor: pointer;
    transition: var(--transition);
}

.template-item:hover {
    border-color: var(--primary-color);
    background: var(--bg-hover);
}

.template-item.selected {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: white;
}

.template-name {
    font-weight: 500;
}

.template-price {
    font-weight: bold;
    color: var(--primary-color);
}

.template-item.selected .template-price {
    color: white;
}

/* Кнопка скачать пример в выбранном шаблоне */
.template-item.selected .download-example-btn {
    background: white !important;
    color: var(--primary-color) !important;
    border: 2px solid white !important;
    font-weight: 600 !important;
}

.template-item.selected .download-example-btn:hover {
    background: var(--bg-hover) !important;
    color: var(--primary-color) !important;
    border-color: var(--bg-hover) !important;
}

/* Animated Flags */
@keyframes flagWave {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(-2deg); }
    75% { transform: rotate(2deg); }
    100% { transform: rotate(0deg); }
}

@keyframes flagBounce {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-2px) scale(1.1); }
}

select option {
    padding: 8px 12px;
    font-size: 14px;
}

/* Country select styling */
#countrySelect {
    font-size: 16px;
    padding: 12px 15px;
    transition: var(--transition);
}

#countrySelect:hover {
    animation: flagBounce 0.6s ease-in-out;
}

#countrySelect:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Animate flags when country dropdown is open */
#countrySelect option:hover {
    background: var(--bg-hover);
}

/* Removed emoji animations on hover */

/* Flag pulse animation */
@keyframes flagPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.country-flag {
    display: inline-block;
    animation: flagPulse 2s ease-in-out infinite;
    margin-right: 8px;
}

/* Country Code Styling */
.country-code {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    margin-right: 8px;
    min-width: 24px;
    text-align: center;
    animation: flagBounce 2s ease-in-out infinite;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Different colors for different countries */
.country-code.UK { background: linear-gradient(135deg, #ff4757, #ff3742); }
.country-code.DE { background: linear-gradient(135deg, #ffa502, #ff6348); }
.country-code.FR { background: linear-gradient(135deg, #3742fa, #2f3542); }
.country-code.IT { background: linear-gradient(135deg, #7bed9f, #70a1ff); }
.country-code.ES { background: linear-gradient(135deg, #ff9ff3, #f368e0); }
.country-code.NL { background: linear-gradient(135deg, #ff9f43, #ff6b35); }
.country-code.BE { background: linear-gradient(135deg, #686de0, #4834d4); }
.country-code.AT { background: linear-gradient(135deg, #badc58, #6c5ce7); }
.country-code.CH { background: linear-gradient(135deg, #fd79a8, #e84393); }
.country-code.PT { background: linear-gradient(135deg, #00b894, #00a085); }

/* Custom Country Dropdown */
.country-dropdown {
    position: relative;
    width: 100%;
}

.country-selected {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: white;
    cursor: pointer;
    transition: var(--transition);
    min-height: 48px;
}

.country-selected:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.dropdown-arrow {
    transition: transform 0.3s ease;
}

.country-selected.open .dropdown-arrow {
    transform: rotate(180deg);
}

.country-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-top: none;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: var(--shadow-lg);
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
}

.country-option {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 1px solid var(--bg-secondary);
}

.country-option:hover {
    background: var(--bg-hover);
}

.country-option:last-child {
    border-bottom: none;
}

.country-flag-img {
    width: 24px;
    height: 24px;
    margin-right: 12px;
    border-radius: 50%;
    animation: flagPulse 3s ease-in-out infinite;
}

.country-name {
    font-size: 14px;
    font-weight: 500;
}

/* ========== PDF ADMIN STYLES ========== */

/* PDF Handler Form */
.pdf-handler-form {
    background: var(--bg-secondary);
    padding: 20px;
    border-radius: var(--border-radius-lg);
    margin-bottom: 30px;
}

.pdf-handler-form h5 {
    margin-bottom: 20px;
    color: var(--text-primary);
    font-size: 18px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* PDF Stats */
.pdf-stats {
    margin-bottom: 30px;
}

.pdf-stats h5 {
    margin-bottom: 15px;
    color: var(--text-primary);
    font-size: 18px;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.stat-card {
    background: var(--bg-primary);
    padding: 20px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-number {
    font-size: 32px;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 14px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* PDF Handlers List */
.pdf-handlers-list {
    margin-top: 30px;
}

.pdf-handlers-list h5 {
    margin-bottom: 15px;
    color: var(--text-primary);
    font-size: 18px;
}

.handlers-controls {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 15px;
}

.handlers-table {
    width: 100%;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
    overflow-x: auto;
}

.handlers-table table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1200px;
}

.handlers-table th {
    background: var(--bg-secondary);
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
}

.handlers-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.handlers-table tr:hover {
    background: var(--bg-hover);
}

.flag-icon {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    vertical-align: middle;
}

.status {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status.active {
    background: rgba(76, 175, 80, 0.1);
    color: var(--success-color);
}

.status.inactive {
    background: rgba(244, 67, 54, 0.1);
    color: var(--error-color);
}

.handlers-table code {
    background: var(--bg-secondary);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.handlers-table .btn-small {
    margin-right: 5px;
    border-radius: var(--border-radius);
    padding: 6px 12px;
    font-size: 0.85rem;
}

.no-data {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-style: italic;
}

/* Form Styling for PDF Admin */
#pdfHandlerForm .form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--text-primary);
}

#pdfHandlerForm .form-group input[type="checkbox"] {
    margin-right: 8px;
}

#pdfHandlerForm select,
#pdfHandlerForm input[type="text"],
#pdfHandlerForm input[type="number"] {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: var(--transition);
}

#pdfHandlerForm select:focus,
#pdfHandlerForm input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

/* Loading States */
.loading {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Tables */
@media (max-width: 768px) {
    .handlers-table {
        overflow-x: auto;
    }

    .handlers-table table {
        min-width: 800px;
    }

    .handlers-table th,
    .handlers-table td {
        padding: 8px;
        font-size: 12px;
    }

    .flag-icon {
        width: 16px;
        height: 16px;
    }
}

/* Custom Dropdown Styles */
.custom-dropdown {
    position: relative;
    width: 100%;
}

.dropdown-selected {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    cursor: pointer;
    min-height: 45px;
    transition: all 0.3s ease;
}

.dropdown-selected:hover {
    border-color: var(--primary-color);
}

.dropdown-arrow {
    margin-left: auto;
    transition: transform 0.3s ease;
    color: var(--text-muted);
}

.dropdown-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-top: none;
    border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
    max-height: 200px;
    overflow-y: auto;
    z-index: 9999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.dropdown-option {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.dropdown-option:hover {
    background-color: var(--hover-bg, #f5f5f5);
}

.dropdown-option .flag-icon {
    margin-right: 8px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
}

.dropdown-selected .flag-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
}

/* Bookmaker icon styles */
.dropdown-option .bookmaker-icon {
    margin-right: 10px;
    width: 24px;
    height: 24px;
    object-fit: contain;
    border-radius: 4px;
}

.dropdown-selected .bookmaker-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    border-radius: 4px;
}

/* Dropdown divider */
.dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 4px 0;
}

.dropdown-option-custom {
    background: rgba(102, 126, 234, 0.05);
    border-top: 2px solid var(--border-color);
}

.dropdown-option-custom:hover {
    background: rgba(102, 126, 234, 0.15);
}

/* Dark theme support */
.dark-theme .dropdown-options {
    background: #2a2a2a;
    border-color: #444;
}

.dark-theme .dropdown-option:hover {
    background-color: var(--dark-hover-bg, #3a3a3a);
}

/* Улучшение кнопки добавления обработчика */
#pdfHandlerForm button[type="submit"] {
    width: 60%;
    margin: 20px auto 0 auto;
    display: block;
    padding: 18px 24px;
    font-size: 1.125rem;
    font-weight: 600;
    border-radius: var(--border-radius-lg);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#pdfHandlerForm button[type="submit"]:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
}

/* PDF History Table Styles */
.files-table {
    width: 100%;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.files-table-header {
    display: grid;
    grid-template-columns: 110px 170px 130px 100px 1fr;
    gap: 0;
    padding: 15px 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    align-items: center;
}

.files-table-header > div {
    padding-right: 10px;
}

.files-table-header > div:last-child {
    padding-right: 0;
}

.files-table-header .col-date {
    color: white !important;
    font-weight: 600;
    font-size: 14px;
}

/* Стили для карточек баланса */
.balance-cards {
    display: flex;
    gap: 12px;
    margin-right: 15px;
}

.balance-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.2) 100%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    cursor: default;
    min-width: 140px;
}

.balance-card-action {
    cursor: pointer;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.balance-card-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    border-color: rgba(255, 255, 255, 0.6);
    background: linear-gradient(135deg, #7b8ceb 0%, #8a5fb8 100%);
}

.balance-card-logout {
    cursor: pointer;
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    position: relative;
    overflow: hidden;
}

.balance-card-logout:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(220, 53, 69, 0.4);
    border-color: rgba(255, 255, 255, 0.6);
    background: linear-gradient(135deg, #e85d6d 0%, #d73757 100%);
}

.balance-card-logout::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.balance-card-logout:hover::before {
    left: 100%;
}

.balance-card-logout .balance-card-icon {
    animation: shake 2s infinite;
}

@keyframes shake {
    0%, 50%, 100% {
        transform: rotate(0deg);
    }
    10%, 30% {
        transform: rotate(-5deg);
    }
    20%, 40% {
        transform: rotate(5deg);
    }
}

/* Стили для уведомления "Функция в разработке" */
.development-notice {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 152, 0, 0.1) 100%);
    border: 2px solid rgba(255, 193, 7, 0.3);
    border-radius: 12px;
    margin: 20px 0;
}

.development-icon {
    font-size: 48px;
    margin-bottom: 20px;
    animation: bounce-warning 2s infinite;
}

.development-notice h4 {
    color: var(--text-primary);
    margin-bottom: 15px;
    font-size: 24px;
    font-weight: 600;
}

.development-notice p {
    color: var(--text-secondary);
    margin-bottom: 25px;
    font-size: 16px;
    line-height: 1.5;
}

@keyframes bounce-warning {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.balance-card:hover {
    border-color: rgba(255, 255, 255, 0.5);
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.3) 100%);
}

.balance-card-icon {
    font-size: 20px;
    width: 24px;
    text-align: center;
    animation: pulse 2s infinite;
}

.balance-card-action .balance-card-icon {
    animation: bounce 1.5s infinite;
}

.balance-card-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.balance-label {
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.balance-amount {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    font-family: 'JetBrains Mono', monospace;
}

.balance-description {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
}


/* Анимации */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-3px);
    }
    60% {
        transform: translateY(-2px);
    }
}

/* Стили для кнопок авторизации в стиле карточек */
.auth-buttons .btn-secondary,
.auth-buttons .btn-primary {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.2) 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    backdrop-filter: blur(10px) !important;
    color: white !important;
    font-weight: 500 !important;
    padding: 10px 20px !important;
    border-radius: 12px !important;
    transition: all 0.3s ease !important;
    position: relative;
    overflow: hidden;
    text-align: center !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.auth-buttons .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

.auth-buttons .btn-secondary:hover,
.auth-buttons .btn-primary:hover {
    transform: translateY(-2px) !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3) !important;
}

.auth-buttons .btn-secondary:hover {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.4) 100%) !important;
}

.auth-buttons .btn-primary:hover {
    background: linear-gradient(135deg, #7b8ceb 0%, #8a5fb8 100%) !important;
}

.auth-buttons .btn-secondary::before,
.auth-buttons .btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.auth-buttons .btn-secondary:hover::before,
.auth-buttons .btn-primary:hover::before {
    left: 100%;
}

/* Адаптивность */
@media (max-width: 768px) {
    .balance-cards {
        flex-direction: column;
        gap: 8px;
        margin-right: 10px;
    }

    .balance-card {
        min-width: auto;
        padding: 10px 12px;
    }

    .balance-card-icon {
        font-size: 18px;
    }

    .balance-amount {
        font-size: 14px;
    }

    .auth-buttons .btn-secondary,
    .auth-buttons .btn-primary {
        padding: 8px 16px !important;
        font-size: 14px !important;
    }
}

/* Стили для кнопок в модальных окнах авторизации */
#authModal .btn-primary,
#authModal .btn-large {
    border-radius: 8px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border: none !important;
    color: white !important;
    font-size: 16px !important;
}

#authModal .btn-primary:hover,
#authModal .btn-large:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4) !important;
    background: linear-gradient(135deg, #7b8ceb 0%, #8a5fb8 100%) !important;
}

.files-table-body {
    background: var(--bg-primary);
}

.files-table-row {
    display: grid;
    grid-template-columns: 110px 170px 130px 100px 1fr;
    gap: 0;
    padding: 15px 15px;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
    align-items: center;
}

.files-table-row > div {
    padding-right: 10px;
}

.files-table-row > div:last-child {
    padding-right: 0;
}

.files-table-row:last-child {
    border-bottom: none;
}

.files-table-row:hover {
    background: var(--bg-hover);
}

.files-table-row.expired-file {
    opacity: 0.6;
    background: #fee;
}

.files-table-row.expired-file:hover {
    background: #fdd;
}

.col-filename {
    display: flex;
    flex-direction: column;
    gap: 4px;
    justify-content: flex-start;
    align-items: flex-start;
}

.file-name {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
    word-break: break-word;
}

.file-size {
    font-size: 12px;
    color: var(--text-secondary);
}

.file-info {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
    font-style: italic;
}

.col-date {
    font-size: 13px;
    color: var(--text-secondary);
}

.col-timer {
    text-align: center;
}

.col-date {
    text-align: center;
}

.col-actions {
    text-align: center;
}

.deletion-timer {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    background: #e3f2fd;
    color: #1976d2;
    border: 1px solid #bbdefb;
}

.deletion-timer.warning {
    background: #fff3e0;
    color: #f57c00;
    border-color: #ffcc02;
    animation: pulse 2s ease-in-out infinite;
}

.deletion-timer.expired {
    background: #ffebee;
    color: #d32f2f;
    border-color: #f8bbd9;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.col-actions {
    display: flex;
    flex-direction: column;
    gap: 4px;
    justify-content: center;
    align-items: center;
}

.col-actions .btn-small {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 6px;
    white-space: nowrap;
}

/* Modal header buttons layout */
.modal-header-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Responsive design for smaller screens */
@media (max-width: 768px) {
    .files-table-header:not(.face-swap-table .files-table-header),
    .files-table-row:not(.face-swap-table .files-table-row) {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 10px 15px;
    }

    .col-actions {
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .files-table-header:not(.face-swap-table .files-table-header) {
        display: none; /* Hide header on mobile, use row labels instead */
    }

    .files-table-row:not(.face-swap-table .files-table-row) {
        display: block;
        border: 1px solid var(--border-color);
        margin-bottom: 10px;
        border-radius: var(--border-radius);
    }

    /* Face Swap таблица всегда остается горизонтальной */
    .face-swap-table .files-table-header {
        display: grid !important;
        grid-template-columns: 2fr 1.5fr 1fr 2fr !important;
    }

    .face-swap-table .files-table-row {
        display: grid !important;
        grid-template-columns: 2fr 1.5fr 1fr 2fr !important;
    }

    .col-filename::before { content: "Файл: "; font-weight: 600; }
    .col-date::before { content: "Создан: "; font-weight: 600; }
    .col-timer::before { content: "Удаление через: "; font-weight: 600; }
    .col-actions::before { content: "Действия: "; font-weight: 600; display: block; margin-bottom: 5px; }
}

/* Face Swap History Table - специальная сетка для 4 колонок */
.face-swap-table .files-table-header {
    display: grid !important;
    grid-template-columns: 2fr 1.5fr 1fr 2fr !important;
}

.face-swap-table .files-table-row {
    display: grid !important;
    grid-template-columns: 2fr 1.5fr 1fr 2fr !important;
}

/* EXIF History Table - специальная сетка для 4 колонок */
.exif-history-table .files-table-header {
    display: grid !important;
    grid-template-columns: 3fr 1.8fr 1.5fr 1.5fr !important;
    gap: 15px;
}

.exif-history-table .files-table-row {
    display: grid !important;
    grid-template-columns: 3fr 1.8fr 1.5fr 1.5fr !important;
    gap: 15px;
    align-items: center;
}

/* Таймеры автоудаления */
.timer,
.deletion-timer {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
}

.timer-safe {
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
    color: white;
}

.timer-warning {
    background: linear-gradient(135deg, #ff9800 0%, #fb8c00 100%);
    color: white;
}

.timer-critical {
    background: linear-gradient(135deg, #f44336 0%, #e53935 100%);
    color: white;
}

/* Кнопки действий в таблице Face Swap */
.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-action.btn-view {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-action.btn-view:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-action.btn-download {
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
    color: white;
}

.btn-action.btn-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
}

/* Переопределение стилей для кнопок в таблице обработчиков */
.handlers-table .btn-error {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
}

.handlers-table .btn-error:hover {
    background: var(--primary-color);
    color: var(--text-white);
}

.handlers-table .btn-secondary {
    border-radius: var(--border-radius);
}

.handlers-table .btn-primary {
    border-radius: var(--border-radius);
}

/* Стили для кнопки добавления букмекера */
.btn-add-container {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.btn-add-bookmaker {
    padding: 12px 30px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    border-radius: 12px !important;
    min-width: 200px;
    transition: all 0.3s ease !important;
}

.btn-add-bookmaker:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4) !important;
}

/* Статусы обработчиков */
.status {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
}

.status.active {
    background: rgba(76, 175, 80, 0.1);
    color: var(--success-color);
    border: 1px solid var(--success-color);
}

.status.inactive {
    background: rgba(244, 67, 54, 0.1);
    color: var(--error-color);
    border: 1px solid var(--error-color);
}

/* Кнопка создать PDF - полная ширина как блок стоимости */
.btn-full-width {
    width: 100% !important;
    padding: 20px !important;
    font-size: 18px !important;
    font-weight: 600 !important;
    border-radius: var(--border-radius-lg) !important;
    margin-top: 20px !important;
}

/* Toggle Switch Styles */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    -webkit-transition: .4s;
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    -webkit-transition: .4s;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--success-color);
}

input:focus + .slider {
    box-shadow: 0 0 1px var(--success-color);
}

input:checked + .slider:before {
    -webkit-transform: translateX(26px);
    -ms-transform: translateX(26px);
    transform: translateX(26px);
}

/* ========== INLINE РЕДАКТИРОВАНИЕ PDF ОБРАБОТЧИКОВ ========== */

/* Стили для редактируемых ячеек */
.handlers-table td.editable-country,
.handlers-table td.editable-category,
.handlers-table td.editable-name,
.handlers-table td.editable-handler,
.handlers-table td.editable-price {
    position: relative;
    min-width: 120px;
}

/* Режим отображения */
.handlers-table .display-mode {
    display: block;
    padding: 4px 0;
}

/* Режим редактирования */
.handlers-table .edit-mode {
    display: none;
    padding: 2px 0;
}

/* Стили для полей ввода в режиме редактирования */
.handlers-table .edit-input,
.handlers-table .edit-country-select,
.handlers-table .edit-category-select,
.handlers-table .edit-handler-select {
    width: 100%;
    padding: 4px 8px;
    border: 2px solid var(--primary-color);
    border-radius: 4px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 12px;
    font-family: var(--font-family);
    transition: var(--transition);
    min-height: 28px;
}

.handlers-table .edit-input:focus,
.handlers-table .edit-country-select:focus,
.handlers-table .edit-category-select:focus,
.handlers-table .edit-handler-select:focus {
    outline: none;
    border-color: var(--primary-dark);
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.2);
}

/* Стили для селектов */
.handlers-table .edit-country-select,
.handlers-table .edit-category-select,
.handlers-table .edit-handler-select {
    cursor: pointer;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 4 5"><path fill="%23666" d="M2 0L0 2h4zm0 5L0 3h4z"/></svg>');
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 8px;
    padding-right: 24px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Стили для кнопки редактирования */
.handlers-table .btn-success {
    background: var(--success-color);
    color: var(--text-white);
    border: 1px solid var(--success-color);
}

.handlers-table .btn-success:hover {
    background: #45a049;
    border-color: #45a049;
}

/* Анимации переходов */
.handlers-table td {
    transition: background-color 0.2s ease;
}

.handlers-table tr:hover td {
    background-color: rgba(102, 126, 234, 0.05);
}

/* Стили для строки в режиме редактирования */
.handlers-table tr.editing {
    background-color: rgba(102, 126, 234, 0.1);
}

.handlers-table tr.editing td {
    background-color: transparent;
}

/* Стили для флагов в селекте стран */
.handlers-table .edit-country-select option {
    padding: 4px 8px;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .handlers-table .edit-input,
    .handlers-table .edit-country-select,
    .handlers-table .edit-category-select,
    .handlers-table .edit-handler-select {
        font-size: 16px; /* Предотвращает зум на iOS */
        min-height: 36px;
    }

    .handlers-table td.editable-country,
    .handlers-table td.editable-category,
    .handlers-table td.editable-name,
    .handlers-table td.editable-handler,
    .handlers-table td.editable-price {
        min-width: 100px;
    }
}

/* Стили для валидации */
.handlers-table .edit-input.error,
.handlers-table .edit-country-select.error,
.handlers-table .edit-category-select.error,
.handlers-table .edit-handler-select.error {
    border-color: var(--error-color);
    box-shadow: 0 0 0 2px rgba(244, 67, 54, 0.2);
}

/* Стили для загрузки */
.handlers-table .edit-mode.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 8px;
    width: 12px;
    height: 12px;
    margin-top: -6px;
    border: 2px solid var(--primary-color);
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Стили для отображения страны и типа документа в одной колонке */
.col-document {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 10px 8px;
}

.doc-country {
    font-weight: 600;
    font-size: 13px;
    color: var(--primary-color);
    margin-bottom: 2px;
}

.doc-type {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.2;
    word-wrap: break-word;
}

/* Стили для кликабельных названий биллов */
.clickable-bill {
    color: var(--primary-color);
    cursor: pointer;
    text-decoration: underline;
    transition: all 0.2s ease;
}

.clickable-bill:hover {
    color: var(--accent-color);
    font-weight: 600;
    text-decoration: none;
}

/* ==========================================
   СИСТЕМА УВЕДОМЛЕНИЙ
   ========================================== */

/* Кнопка уведомлений в navbar */
.balance-card-notifications {
    position: relative;
    cursor: pointer;
    background: linear-gradient(135deg, #06b6d4 0%, #0284c7 100%);
}

.balance-card-notifications:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4);
    border-color: rgba(255, 255, 255, 0.6);
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.3) 100%);
}

.balance-card-notifications .balance-card-icon {
    position: relative;
    font-size: 1.5rem;
    animation: bounce 1.5s infinite;
}

.notification-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: linear-gradient(135deg, #ff3366, #ff0055);
    color: white;
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
    box-shadow: 0 2px 12px rgba(255, 51, 102, 0.6);
    animation: pulse-badge 1.5s ease-in-out infinite, glow-badge 2s ease-in-out infinite;
    z-index: 10;
}

@keyframes pulse-badge {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
}

@keyframes glow-badge {
    0%, 100% {
        box-shadow: 0 2px 12px rgba(255, 51, 102, 0.6), 0 0 0 0 rgba(255, 51, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 20px rgba(255, 51, 102, 0.8), 0 0 20px 5px rgba(255, 51, 102, 0.3);
    }
}

/* Список уведомлений пользователя */
.notifications-user-list {
    max-height: 600px;
    overflow-y: auto;
}

.notification-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.notification-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary-color);
    transform: translateX(5px);
}

.notification-item.unread {
    background: rgba(255, 215, 0, 0.05);
    border-color: rgba(255, 215, 0, 0.3);
}

.notification-item.unread .unread-indicator {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 10px;
    height: 10px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.notification-header h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-primary);
}

.notification-date {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.notification-preview {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Таблица уведомлений пользователя */
.user-notifications-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 4px;
    background: transparent;
}

.user-notifications-table thead {
    background: transparent;
}

.user-notifications-table th {
    padding: 1rem;
    text-align: left;
    color: var(--text-primary);
    font-weight: 600;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.user-notifications-table tbody tr {
    cursor: pointer;
    transition: all 0.2s ease;
    background: transparent;
}

.user-notifications-table tbody tr td:first-child {
    border-radius: 8px 0 0 8px;
}

.user-notifications-table tbody tr td:last-child {
    border-radius: 0 8px 8px 0;
}

.user-notifications-table tbody tr:hover {
    background: rgba(100, 149, 237, 0.15);
    transform: translateX(3px);
}

.user-notifications-table tbody tr.unread {
    background: rgba(100, 149, 237, 0.08) !important;
}

.user-notifications-table tbody tr.unread td {
    font-weight: 400 !important;
    color: #000000 !important;
}

.user-notifications-table tbody tr.read {
    background: transparent !important;
}

.user-notifications-table tbody tr.read td {
    font-weight: 400 !important;
    color: #777777 !important;
}

.user-notifications-table td {
    padding: 0.85rem 1rem;
}

.user-notifications-table td:nth-child(1) {
    width: 25%;
}

.user-notifications-table td:nth-child(2) {
    width: 50%;
}

.user-notifications-table td:nth-child(3) {
    width: 25%;
    white-space: nowrap;
}

/* Детальный просмотр уведомления */
.notification-detail-view {
    padding: 2rem;
}

.btn-back {
    background: linear-gradient(135deg, rgba(100, 149, 237, 0.2), rgba(100, 149, 237, 0.3));
    color: var(--text-primary);
    border: 2px solid rgba(100, 149, 237, 0.4);
    padding: 0.6rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 2rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 2px 8px rgba(100, 149, 237, 0.2);
}

.btn-back:hover {
    background: linear-gradient(135deg, rgba(100, 149, 237, 0.3), rgba(100, 149, 237, 0.4));
    border-color: rgba(100, 149, 237, 0.6);
    transform: translateX(-5px) scale(1.02);
    box-shadow: 0 4px 16px rgba(100, 149, 237, 0.3);
}

.btn-back:active {
    transform: translateX(-3px) scale(0.98);
}

.notification-detail-content {
    color: var(--text-primary);
    font-size: 1.05rem;
    line-height: 1.8;
    white-space: pre-wrap;
    text-align: center;
    padding: 2rem;
    margin-top: 1rem;
}

/* Админские стили для уведомлений */
.notification-form {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.notification-form h5 {
    margin-top: 0;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.notifications-list-admin {
    margin-top: 2rem;
}

.notifications-list-admin h5 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.notifications-controls {
    margin-bottom: 1rem;
    display: flex;
    justify-content: flex-end;
}

.admin-notifications-container {
    max-height: 600px;
    overflow-y: auto;
    overflow-x: auto;
}

.notifications-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.notifications-table thead {
    background: rgba(255, 255, 255, 0.05);
}

.notifications-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

.notifications-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.3s ease;
}

.notifications-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.notifications-table td {
    padding: 0.75rem 1rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
    vertical-align: middle;
}

.notifications-table td:nth-child(1) {
    color: var(--text-primary);
    font-weight: 450;
    width: 240px;
}

.notifications-table td:nth-child(2) {
    white-space: nowrap;
    width: 180px;
}

.notifications-table td:nth-child(3) {
    width: 600px;            /* Самый широкий столбец */
    text-align: left;
    word-wrap: break-word;
    white-space: normal;
    padding-left: 0.5rem;    /* Меньше отступ слева - ближе к дате */
}

.notifications-table td:nth-child(4) {
    text-align: center;
    width: 120px;
}

.notifications-table .btn-error {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.notifications-table .btn-error:hover {
    background: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

/* ==========================================
   АДАПТИВНОСТЬ ДЛЯ МОБИЛЬНЫХ УСТРОЙСТВ
   ========================================== */

/* Планшеты и небольшие экраны */
@media (max-width: 1024px) {
    .container {
        max-width: 95%;
        padding: 0 15px;
    }

    .services-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .service-card {
        width: 100%;
        flex: none;
        height: auto;
        min-height: 180px;
    }
}

/* Мобильные устройства (портретная ориентация) */
@media (max-width: 768px) {
    /* Общие стили */
    body {
        font-size: 14px;
    }

    .container {
        max-width: 100%;
        padding: 0 10px;
    }

    /* Навигация */
    .navbar {
        padding: 10px 0;
        flex-wrap: wrap;
    }

    .navbar .container {
        flex-direction: column;
        gap: 15px;
    }

    .brand h1 {
        font-size: 20px;
    }

    .brand .subtitle {
        font-size: 11px;
    }

    .navbar nav {
        width: 100%;
        justify-content: center;
        gap: 10px;
        flex-wrap: wrap;
    }

    .navbar nav a {
        padding: 8px 12px;
        font-size: 13px;
    }

    /* Hero секция */
    .hero-section {
        padding: 30px 0;
    }

    .hero-section h2 {
        font-size: 24px;
        margin-bottom: 10px;
    }

    .hero-section .subtitle {
        font-size: 14px;
    }

    /* Сетка услуг */
    .services-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 0 5px;
    }

    .service-card {
        width: 100%;
        flex: none;
        height: auto;
        min-height: 150px;
        padding: 20px 15px;
    }

    .service-card h3 {
        font-size: 18px;
        margin-bottom: 10px;
    }

    .service-card p {
        font-size: 13px;
        line-height: 1.5;
    }

    /* Формы */
    .email-form {
        padding: 20px 15px;
    }

    .form-group {
        margin-bottom: 15px;
    }

    .form-group label {
        font-size: 13px;
        margin-bottom: 6px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 16px; /* Предотвращает зум на iOS */
        padding: 12px;
    }

    /* Кнопки */
    .btn {
        padding: 12px 20px;
        font-size: 14px;
        width: 100%;
    }

    .btn-primary,
    .btn-secondary,
    .btn-success {
        width: 100%;
        margin-bottom: 10px;
    }

    /* Email инфо */
    .email-info {
        padding: 15px;
    }

    .email-display {
        font-size: 16px;
        padding: 12px;
        word-break: break-all;
    }

    /* Таблица писем */
    .emails-table {
        font-size: 12px;
    }

    .emails-table th,
    .emails-table td {
        padding: 8px 5px;
    }

    .emails-table .email-subject {
        max-width: 150px;
    }

    /* Модальное окно */
    .modal-content {
        width: 95%;
        max-width: 95%;
        margin: 10px;
        padding: 20px 15px;
    }

    .modal-header h3 {
        font-size: 18px;
    }

    .modal-body {
        font-size: 13px;
    }

    /* Статистика */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .stat-card {
        padding: 20px 15px;
    }

    .stat-card .stat-value {
        font-size: 28px;
    }

    /* Футер */
    footer {
        padding: 20px 0;
        font-size: 12px;
    }

    /* Карточки биллов */
    .bills-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .bill-card {
        padding: 15px;
    }

    /* Поддержка */
    .support-categories {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .category-card {
        padding: 20px 15px;
    }

    /* Табы */
    .tabs {
        flex-direction: column;
        gap: 5px;
    }

    .tab {
        width: 100%;
        text-align: center;
    }
}

/* Очень маленькие мобильные устройства */
@media (max-width: 480px) {
    /* Заголовки */
    .hero-section h2 {
        font-size: 20px;
    }

    .service-card h3 {
        font-size: 16px;
    }

    /* Навигация */
    .brand h1 {
        font-size: 18px;
    }

    .navbar nav a {
        padding: 6px 10px;
        font-size: 12px;
    }

    /* Кнопки */
    .btn {
        padding: 10px 15px;
        font-size: 13px;
    }

    /* Модальное окно */
    .modal-content {
        width: 100%;
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
    }

    /* Таблицы - вертикальная прокрутка */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .emails-table {
        min-width: 500px;
    }

    /* Email display */
    .email-display {
        font-size: 14px;
        padding: 10px;
    }

    /* Статистика */
    .stat-card .stat-value {
        font-size: 24px;
    }

    .stat-card .stat-label {
        font-size: 12px;
    }
}

/* ==========================================
   УПРАВЛЕНИЕ ДОМЕНАМИ
   ========================================== */

.domains-table {
    width: 100%;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.domains-table table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.domains-table th {
    background: var(--bg-secondary);
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
}

.domains-table th:nth-child(1) { width: 40%; } /* Домен */
.domains-table th:nth-child(2) { width: 20%; } /* Статус */
.domains-table th:nth-child(3) { width: 25%; } /* Дата */
.domains-table th:nth-child(4) { width: 15%; } /* Действия */

.domains-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.domains-table tr:hover {
    background: var(--bg-hover);
}

.domains-table .btn-small {
    margin-right: 5px;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 0.85rem;
}

.domains-table .btn-error {
    background: transparent;
    color: var(--error-color);
    border: 2px solid var(--error-color);
    border-radius: 8px;
    transition: all 0.3s ease;
    min-width: 80px;
}

.domains-table .btn-error:hover {
    background: var(--error-color);
    color: var(--text-white);
}

.domain-form {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin-bottom: 2rem;
}

.domain-form h5 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.domains-list-admin {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
}

.domains-list-admin h5 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.domains-controls {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .domains-table {
        overflow-x: auto;
    }

    .domains-table table {
        min-width: 600px;
    }

    .domains-table th,
    .domains-table td {
        padding: 8px;
        font-size: 12px;
    }
}

/* ==========================================
   ПОИСК В ИСТОРИИ EMAIL
   ========================================== */

.email-search-section {
    margin-bottom: 1rem;
}

.email-search-section .form-group {
    margin-bottom: 0;
}

.email-search-section input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.email-search-section input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.email-search-section input::placeholder {
    color: var(--text-muted);
}

/* Анимация подсветки найденного элемента */
@keyframes highlight {
    0% {
        background: transparent;
    }
    50% {
        background: rgba(102, 126, 234, 0.2);
    }
    100% {
        background: transparent;
    }
}

/* ==========================================
   МОДАЛЬНОЕ ОКНО ОТДЕЛЬНОГО ПИСЬМА
   ========================================== */

.single-email-modal-body {
    max-height: 650px;
    overflow-y: auto;
}

.single-email-details {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
}

.email-meta-row {
    padding: 0.5rem 0;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.email-meta-row strong {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

.email-content {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    line-height: 1.6;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Красивый баннер цены */
.pricing-info {
    margin-bottom: 1.5rem;
}

.price-banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.price-banner:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.price-highlight {
    font-size: 1.3rem;
    font-weight: 700;
    color: #ffd700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}



/* ===================================
   PHOTO ADMIN STYLES
   =================================== */

.service-card-admin {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.service-card-admin:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
    border-color: var(--primary-color);
}

.service-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.service-header h5 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.service-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.service-status.active {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
}

.service-status.inactive {
    background: rgba(255, 68, 68, 0.2);
    color: #ff4444;
}

.service-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    min-height: 2.5rem;
}

.service-price-section {
    margin: 1rem 0;
}

.service-price-section label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.price-input-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.currency-symbol {
    font-size: 1.2rem;
    font-weight: 700;
    color: #00ff88;
}

.price-input {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.2);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.price-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.1);
}

.btn-save-price {
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #00ff88, #00cc66);
    color: #1a1a2e;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-save-price:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 255, 136, 0.4);
}

.service-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.btn-toggle {
    flex: 1;
    padding: 0.75rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.8), rgba(118, 75, 162, 0.8));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.5);
}

.btn-delete {
    flex: 1;
    padding: 0.75rem;
    background: linear-gradient(135deg, rgba(255, 68, 68, 0.8), rgba(220, 20, 60, 0.8));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-delete:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 68, 68, 0.5);
}

.add-service-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}


/* Service Price Badge */
.service-price-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #00ff88, #00cc66);
    color: #1a1a2e;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 900;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(0, 255, 136, 0.4);
    z-index: 10;
    animation: pulseBadge 2s infinite;
}

.service-price-badge .price-value {
    font-size: 1.3rem;
}

@keyframes pulseBadge {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(0, 255, 136, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(0, 255, 136, 0.6);
    }
}

.photo-service-card {
    position: relative;
}


/* ===================================
   IMAGE LIGHTBOX STYLES  
   =================================== */

.image-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.image-lightbox.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    cursor: pointer;
}

.lightbox-content {
    position: relative;
    max-width: 95vw;
    max-height: 95vh;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.lightbox-content img {
    max-width: 100%;
    max-height: calc(95vh - 80px);
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    transition: transform 0.3s ease;
}

.lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-size: 2rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close:hover {
    background: rgba(255, 68, 68, 0.8);
    transform: rotate(90deg);
}

.lightbox-controls {
    display: flex;
    gap: 10px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.btn-lightbox-zoom,
.btn-lightbox-reset {
    padding: 10px 20px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.8), rgba(118, 75, 162, 0.8));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-lightbox-zoom:hover,
.btn-lightbox-reset:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.5);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ===================================
   STATISTICS MODAL
   =================================== */

.stats-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card-big {
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.stat-card-big:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.stat-icon {
    font-size: 40px;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 36px;
    font-weight: bold;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 10px 0;
}

.stat-label {
    font-size: 14px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Таблица статистики пользователей */
.users-stats-table {
    margin-top: 30px;
}

.users-stats-table h4 {
    margin-bottom: 15px;
    color: var(--text-primary);
    font-size: 18px;
}

.stats-table {
    background: var(--bg-primary);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.stats-table-header {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 15px;
    padding: 15px 20px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    font-weight: 600;
    font-size: 13px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
}

.stats-table-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s ease;
}

.stats-table-row:hover {
    background-color: rgba(102, 126, 234, 0.05);
}

.stats-table-row:last-child {
    border-bottom: none;
}

.col-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-icon {
    font-size: 20px;
}

.user-email {
    color: var(--text-primary);
    font-weight: 500;
}

.col-generated,
.col-purchased,
.col-revenue {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--text-primary);
}

.col-revenue {
    color: #4caf50;
}

/* Кнопка статистики в карточке сервиса */
.btn-stats {
    flex: 1;
    padding: 0.75rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn-stats:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Модальное окно статистики - широкое */
.modal-wide {
    max-width: 900px;
    width: 90%;
}

/* Состояние загрузки */
.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
    font-size: 16px;
}

/* Состояние ошибки */
.error-state {
    text-align: center;
    padding: 40px;
}

.error-icon {
    font-size: 60px;
    margin-bottom: 15px;
}

.error-state p {
    color: var(--text-secondary);
    font-size: 16px;
}

/* ==================== EXIF Generator Styles ==================== */

.exif-generator-container {
    padding: 1rem;
}

.device-info-card {
    background: rgba(102, 126, 234, 0.05);
    border-radius: 8px;
    padding: 1rem;
    border-left: 3px solid var(--primary-color);
}

.device-info-header {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--primary-color);
}

.device-info-specs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.5rem;
}

.spec-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 4px;
}

.spec-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.spec-value {
    color: var(--text-primary);
    font-weight: 600;
}

.image-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

.image-preview-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(102, 126, 234, 0.05);
    padding: 0.5rem;
}

.image-preview-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 4px;
}

.image-preview-item .btn-remove {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 59, 48, 0.9);
    color: white;
    border: none;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.image-preview-item .btn-remove:hover {
    background: #ff3b30;
    transform: scale(1.1);
}

.image-preview-item .image-name {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.file-upload-label input[type="file"] {
    display: none;
}

.file-upload-label {
    cursor: pointer;
    transition: all 0.3s;
}

.file-upload-label:hover {
    background: rgba(102, 126, 234, 0.1) !important;
    border-color: var(--primary-color) !important;
}


/* EXIF Generator Modal */
#exifGeneratorModal.modal {
    display: none;
}

#exifGeneratorModal .modal-content {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

#exifGeneratorModal.show,
#exifGeneratorModal[style*="display: flex"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* Стили для превью изображений */
.image-preview-item {
    position: relative;
    transition: transform 0.3s ease;
}

.image-preview-item:hover {
    transform: translateY(-4px);
}

/* Адаптация под мобильные */
@media (max-width: 768px) {
    .device-selection-section .form-row {
        grid-template-columns: 1fr !important;
    }
    
    .photo-params-section .form-row {
        grid-template-columns: 1fr !important;
    }
    
    #gpsFields .form-row {
        grid-template-columns: 1fr !important;
    }
}


/* EXIF Generator Modal - исправление прозрачности */
#exifGeneratorModal .modal-content {
    background: #1a1d29 !important;
    backdrop-filter: blur(10px);
}

/* Светлая тема для форм */
#exifGeneratorModal .form-group label {
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 0.5rem;
    display: block;
}

#exifGeneratorModal .form-control,
#exifGeneratorModal select {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(102, 126, 234, 0.3);
    color: var(--text-primary);
}

#exifGeneratorModal .info-banner {
    background: rgba(102, 126, 234, 0.15) !important;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

#exifGeneratorModal h4 {
    color: var(--text-primary);
    margin-bottom: 1rem;
}

/* File upload area */
#exifGeneratorModal .file-upload-label {
    background: rgba(102, 126, 234, 0.1) !important;
    border: 2px dashed rgba(102, 126, 234, 0.4) !important;
    color: var(--text-primary);
}

#exifGeneratorModal .file-upload-label:hover {
    background: rgba(102, 126, 234, 0.2) !important;
    border-color: var(--primary-color) !important;
}


/* EXIF Generator Modal - БЕЛЫЙ фон как у остальных */
#exifGeneratorModal .modal-content {
    background: white !important;
    color: #1a1d29 !important;
}

#exifGeneratorModal .modal-header h3 {
    color: #1a1d29 !important;
}

#exifGeneratorModal .form-group label {
    color: #1a1d29 !important;
}

#exifGeneratorModal .form-control,
#exifGeneratorModal select {
    background: white !important;
    color: #1a1d29 !important;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

#exifGeneratorModal h4 {
    color: #1a1d29 !important;
}

#exifGeneratorModal p {
    color: #1a1d29 !important;
}

#exifGeneratorModal .info-banner p {
    color: #1a1d29 !important;
}

#exifGeneratorModal .spec-label {
    color: #666 !important;
}

#exifGeneratorModal .spec-value {
    color: #1a1d29 !important;
}

#exifGeneratorModal .device-info-card {
    background: rgba(102, 126, 234, 0.1);
}

