/* Telegram WebApp - force compact centered header (wins over inline) */
html.telegram-webapp body.telegram-webapp .header {
    position: fixed !important;
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    bottom: 20px !important;
    top: auto !important;
    width: auto !important;
    max-width: 360px !important;
    padding: 0.5rem 0.7rem !important;
    border-radius: 999px !important;
    border-top: none !important;
    border-bottom: none !important;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.35) !important;
    background-color: #1e1e1e !important;
    z-index: 10000 !important;
}

@media (min-width: 769px) {
    html.telegram-webapp body.telegram-webapp .header {
        top: 20px !important;
        bottom: auto !important;
        max-width: 420px !important;
    }
}

/* Tighten inner spacing for Telegram header */
html.telegram-webapp body.telegram-webapp .header-left,
html.telegram-webapp body.telegram-webapp .header-right {
    gap: 0.5rem !important;
    /* padding-left: 0.5rem !important; */
    /* padding-right: 0.5rem !important; */
}

html.telegram-webapp body.telegram-webapp .hamburger {
    padding: 0.5rem !important; /* equal L/R */
    border-radius: 16px !important;
}

html.telegram-webapp body.telegram-webapp .generations-counter {
    gap: 0.35rem !important;
    padding: 0.5rem !important; /* equal L/R */
    border-radius: 16px !important;
}

html.telegram-webapp body.telegram-webapp .btn-signup {
    padding: 0.5rem !important; /* equal L/R */
    max-width: 100px !important;
}

html.telegram-webapp body.telegram-webapp .btn-language {
    padding: 0.5rem !important; /* equal L/R */
    max-width: 100px !important;
    font-size: 0.85rem !important;
    z-index: 10002 !important;
    cursor: pointer !important;
    pointer-events: auto !important;
}

/* Ensure equal gap between left/right groups too */
html.telegram-webapp body.telegram-webapp .header {
    gap: 0.5rem !important;
}
Reset and Base Styles
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


/* Telegram WebApp - восстанавливаем нормальные стили */
.telegram-webapp * {
    box-sizing: border-box;
}



/* Telegram WebApp - восстанавливаем внутренние отступы для контента */
.telegram-webapp .hero-section,
.telegram-webapp .feature-section,
.telegram-webapp .gallery-section {
    padding: 1rem;
}


body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #ffffff; /* Простой белый фон */
    color: #2c2c2c;
    line-height: 1.5;
    font-weight: 400;
    font-size: 14px;
    min-height: 100vh;
    margin: 89px; /* Отступы 39px с каждой стороны (78px общий отступ) */
    border: 5px solid #ffffff; /* Увеличиваем толщину белого border вокруг всего сайта */
    border-radius: 0; /* Убираем скругления углов */
    box-shadow: 0 0 20px rgba(44, 44, 44, 0.3); /* Тень для border */
    box-sizing: border-box; /* Включаем border в общий размер */
    width: calc(100vw - 178px); /* Ширина с учетом отступов слева и справа */
    max-width: calc(100vw - 78px); /* Максимальная ширина */
}

/* Telegram WebApp - восстанавливаем нормальные размеры body */
body.telegram-webapp {
    margin: 0 !important; /* Убираем отступы для Telegram WebApp */
    border: none !important; /* Убираем border для Telegram WebApp */
    width: 100vw !important; /* Полная ширина для Telegram WebApp */
    max-width: 100vw !important; /* Максимальная ширина для Telegram WebApp */
    box-shadow: none !important; /* Убираем тень для Telegram WebApp */
    padding: 0 !important;
    overflow-x: hidden !important;
}

.container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0 12px; /* Небольшой горизонтальный отступ для контента */
    background-color: #1e1e1e; /* Темно-серый фон контейнера */
}

/* Telegram WebApp - восстанавливаем нормальный контейнер */
.telegram-webapp .container {
    padding: 0 12px; /* Возвращаем нормальные отступы */
    min-height: 100vh;
}


/* Header - Kling.ai Style Bottom Navigation */
.header {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0.6rem 0.9rem;
    display: flex;
    justify-content: center;
    align-items: center;
    border: none;
    border-radius: 999px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 2px 8px rgba(0, 0, 0, 0.2);
    gap: 0.6rem;
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: slideInFromTop 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 0;
    width: auto;
    max-width: 560px;
}

/* Glowing border around the entire header */
.header::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow:
        0 0 8px rgba(255, 255, 255, 0.6),
        0 0 16px rgba(255, 255, 255, 0.35),
        0 0 24px rgba(255, 255, 255, 0.2);
}

@keyframes slideInFromBottom {
    0% {
        transform: translateY(100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
}

/* Telegram WebApp - Kling.ai Style Bottom Navigation для мобильных устройств */
.telegram-webapp .header {
    position: fixed;
    bottom: 20px; /* Отступ от низа экрана */
    left: 20px;
    right: 20px;
    top: auto;
    z-index: 9999;
    border: none;
    border-radius: 30px; /* Полностью закругленные углы как у kling.ai */
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 2px 8px rgba(0, 0, 0, 0.3);
    padding: 1rem 1.5rem;
    background: rgba(0, 0, 0, 0.8); /* Темный полупрозрачный фон */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    margin: 0;
    width: calc(100vw - 40px);
    max-width: calc(100vw - 40px);
}

/* Для десктопа - header остается вверху с kling.ai дизайном */
@media (min-width: 769px) {
    .telegram-webapp .header {
        top: 20px; /* Отступ от верха экрана */
        bottom: auto;
        left: 20px;
        right: 20px;
        border: none;
        border-radius: 30px; /* Полностью закругленные углы */
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 2px 8px rgba(0, 0, 0, 0.2);
        background: rgba(0, 0, 0, 0.8); /* Темный полупрозрачный фон */
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        width: calc(100vw - 40px);
        max-width: calc(100vw - 40px);
        margin: 0;
        animation: slideInFromTop 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    }
}

@keyframes slideInFromTop {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}


/* Увеличиваем отступы для элементов header */
.telegram-webapp .header-left {
    padding-left: 1rem;
}

.telegram-webapp .header-right {
    padding-right: 1rem;
    gap: 1.5rem;
}

/* Десктопная версия - обычные отступы (только НЕ для Telegram WebApp) */
body:not(.telegram-webapp) .main-content {
    padding-bottom: 0;
}

body:not(.telegram-webapp) .content-area {
    padding-bottom: 0;
}

/* Telegram WebApp - отступы для kling.ai стиля навигации */
.telegram-webapp .main-content {
    padding-top: 0; /* Убираем отступ сверху для мобильных */
    padding-bottom: 6rem; /* Увеличиваем отступ снизу для плавающей панели */
}

.telegram-webapp .content-area {
    padding: 0; /* Убираем все отступы */
}

/* Для десктопа - отступы для kling.ai стиля навигации */
@media (min-width: 769px) {
    .telegram-webapp .main-content {
        padding-top: 6rem; /* Увеличиваем отступ сверху для плавающей панели */
        padding-bottom: 0; /* Убираем отступ снизу */
    }
    
    .telegram-webapp .content-area {
        padding: 0; /* Убираем все отступы */
    }
}

/* Telegram WebApp notification positioning */
.telegram-webapp .notification {
    top: 7rem; /* Уведомления под header */
    bottom: auto;
}

/* Image Modal Overlay */
.image-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.image-modal-overlay.show {
    display: flex;
}

.image-modal-content {
    position: relative;
    max-width: 90%;
    max-height: 80%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.image-modal-image {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.image-modal-actions {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.image-modal-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.image-modal-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.image-modal-btn.download {
    background: rgba(0, 136, 204, 0.8);
    border-color: rgba(0, 136, 204, 1);
}

.image-modal-btn.download:hover {
    background: rgba(0, 136, 204, 1);
}

.image-modal-btn.share {
    background: rgba(34, 197, 94, 0.8);
    border-color: rgba(34, 197, 94, 1);
}

.image-modal-btn.share:hover {
    background: rgba(34, 197, 94, 1);
}

.image-modal-btn.close {
    background: rgba(239, 68, 68, 0.8);
    border-color: rgba(239, 68, 68, 1);
}

.image-modal-btn.close:hover {
    background: rgba(239, 68, 68, 1);
}

.image-modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.image-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Telegram WebApp specific modal styles */
.telegram-webapp .image-modal-overlay {
    padding: 20px;
}

.telegram-webapp .image-modal-content {
    max-width: 95%;
    max-height: 85%;
}

.telegram-webapp .image-modal-actions {
    margin-top: 15px;
    gap: 10px;
}

.telegram-webapp .image-modal-btn {
    padding: 10px 16px;
    font-size: 14px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .image-modal-actions {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
    }
    
    .image-modal-btn {
        width: 100%;
        justify-content: center;
    }
    
    .image-modal-close {
        top: -40px;
        right: 10px;
    }
}


.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: fadeInLeft 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.2s both;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: fadeInRight 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.4s both;
}

@keyframes fadeInLeft {
    0% {
        transform: translateX(-30px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeInRight {
    0% {
        transform: translateX(30px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Мобильные устройства - унифицируем gap между элементами */
@media (max-width: 768px) {
    body {
        margin: 12px; /* Увеличиваем отступ для мобильных устройств */
    }
    
    .container {
        padding: 0 8px; /* Меньший отступ для мобильных устройств */
    }
    
    .header-left {
        gap: 0.3rem;
    }
}

@media (max-width: 480px) {
    .header-left {
        gap: 0.3rem !important;
    }
}

/* Десктопная версия - кнопка меню в header (только НЕ для Telegram WebApp) */
body:not(.telegram-webapp) .header-left .hamburger {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    z-index: auto;
}

/* Telegram WebApp - убираем кнопку меню из обычного потока header */
.telegram-webapp .header-left .hamburger {
    position: fixed;
    top: 50%;
    left: 20px;
    transform: translateY(-50%);
    z-index: 10000;
}

/* Десктопная версия - современная кнопка меню (только НЕ для Telegram WebApp) */
body:not(.telegram-webapp) .hamburger {
    cursor: pointer;
    padding: 0.75rem;
    border-radius: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: auto;
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2);
}

/* Telegram WebApp - перетаскиваемая кнопка меню */
.telegram-webapp .hamburger {
    cursor: move;
    position: fixed;
    z-index: 10000;
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 0.75rem;
}

/* Десктопная версия - hover эффект (только НЕ для Telegram WebApp) */
body:not(.telegram-webapp) .hamburger:hover {
    background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
}

/* Telegram WebApp - hover эффект */
.telegram-webapp .hamburger:hover {
    background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 12px 35px rgba(44, 44, 44, 0.4);
}

/* Telegram WebApp - активное состояние кнопки меню (когда меню открыто) */
.telegram-webapp .hamburger.active,
.telegram-webapp .hamburger:active,
.hamburger.active {
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.8) 0%, rgba(26, 26, 26, 0.8) 100%) !important; /* Полупрозрачный градиент */
    backdrop-filter: blur(20px) !important; /* Размытие фона */
    border: 1px solid rgba(255, 255, 255, 0.3) !important; /* Полупрозрачная граница */
    box-shadow: 0 12px 40px rgba(44, 44, 44, 0.4) !important; /* Современная тень */
    transform: translateY(-1px) scale(0.98) !important; /* Небольшое сжатие */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important; /* Плавная анимация */
}

.telegram-webapp .hamburger.active i,
.telegram-webapp .hamburger:active i,
.hamburger.active i {
    color: rgba(255, 255, 255, 0.9) !important; /* Полупрозрачная иконка */
    transform: rotate(90deg) !important; /* Поворот иконки */
    transition: all 0.3s ease !important;
}

.hamburger i {
    font-size: 1.2rem;
    color: white;
    pointer-events: none;
}

.logo {
    font-size: 1.3rem;
    font-weight: 500;
    color: #2c2c2c;
    letter-spacing: -0.02em;
}

.logo-image {
    height: 50px;
    width: 50px;
    object-fit: cover;
    border-radius: 8px;
}


/* Generations Counter - Modern Panel Style */
.generations-counter {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.2rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
}

.generations-counter:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
    background: linear-gradient(135deg, rgba(102, 126, 234, 1) 0%, rgba(118, 75, 162, 1) 100%);
}

.generations-counter i {
    font-size: 1rem;
    color: white;
}

.counter-info {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.counter-label {
    font-size: 0.85rem;
    color: white;
}

.counter-value {
    font-size: 0.85rem;
    font-weight: 600;
    color: white;
}

.language-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.2rem;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: white;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2);
}

.language-selector:hover {
    background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
}

.flag {
    font-size: 1rem;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    justify-content: center;
}

.btn-primary {
    background: linear-gradient(135deg, #2c2c2c, #1a1a1a);
    color: white;
    box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2);
    font-weight: 500;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(44, 44, 44, 0.3);
    background: linear-gradient(135deg, #1a1a1a, #000000);
}

.btn-signup {
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: white;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-signup:hover {
    background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
}

.btn-language {
    /* background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%) !important; */
    background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: white !important;
    max-width: 120px !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0.75rem 1.5rem !important;
    border-radius: 25px !important;
    font-size: 0.85rem !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    text-decoration: none;
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.5rem;
    justify-content: center !important;
    pointer-events: auto !important;
    z-index: 10002 !important;
    position: relative;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.btn-language:active {
    transform: scale(0.95);
}

.btn-language:hover {
    background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
}

.btn-generate {
    background: linear-gradient(135deg, #2c2c2c, #1a1a1a);
    color: white;
    padding: 1rem 2rem;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: 30px;
    box-shadow: 0 6px 20px rgba(44, 44, 44, 0.2);
}

.btn-generate:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3);
    background: linear-gradient(135deg, #1a1a1a, #000000);
}

.btn-download, .btn-share {
    background-color: rgba(44, 44, 44, 0.1);
    color: #2c2c2c;
    border: 2px solid rgba(44, 44, 44, 0.2);
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

.btn-download:hover, .btn-share:hover {
    background-color: rgba(44, 44, 44, 0.15);
    border-color: rgba(44, 44, 44, 0.3);
    transform: translateY(-1px);
}

/* Main Content */
.main-content {
    display: flex;
    flex: 1;
    min-height: calc(100vh - 140px);
    background-color: #1e1e1e; /* Темно-серый фон основного контента */
}


/* Sidebar */
.sidebar {
    width: 250px;
    background-color: #f8f8f8;
    padding: 2rem 1rem;
    border-right: 1px solid #ffffff;
    transition: transform 0.3s ease;
    z-index: 1000;
    position: fixed;
    height: 100vh;
    top: 0;
    left: 0;
}

/* White text for sidebar navigation items on dark background */
.sidebar .nav-item,
.sidebar .nav-item span,
.sidebar .nav-item i {
    color: #ffffff !important;
}

/* Darken requested panels/containers */
.instructions-panel,
.upload-panels,
.controls,
.product-model-container {
    background-color: #1e1e1e !important;
    border-color: #1e1e1e !important;
}

/* Dark theme for product-model prompt group */
.product-model-container {
    border: 2px solid #1e1e1e !important;
}

.prompt-input-group {
    background: #1e1e1e !important;
    border: 2px solid #1e1e1e !important;
}

.prompt-input-group label {
    color: #ffffff !important;
}

.prompt-hint {
    color: #cccccc !important;
}

/* Category label on dark background */
.category-select label {
    color: #ffffff !important;
}

/* Generate buttons: white background with dark text */
.btn-generate {
    background: #ffffff !important;
    background-color: #ffffff !important;
    color: #1e1e1e !important;
    border: 1px solid #e5e5e5 !important;
}

.btn-generate:hover {
    background: #f0f0f0 !important;
}

.sidebar-hidden {
    transform: translateX(-100%);
}

.sidebar-visible {
    transform: translateX(0);
}

/* Sidebar overlay for mobile */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
}

.sidebar-overlay.active {
    display: block;
}

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

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #2c2c2c;
}

.nav-item:hover {
    background-color: rgba(74, 158, 255, 0.1);
}

.nav-item.active {
    background-color: rgba(74, 158, 255, 0.15);
    color: #1f1f20;
}

.nav-item i {
    font-size: 1.1rem;
    width: 20px;
}

.nav-item span {
    font-weight: 400;
    font-size: 0.9rem;
}

.nav-divider {
    height: 1px;
    background-color: #ffffff;
    margin: 1rem 0;
}

/* Content Area */
.content-area {
    flex: 1;
    padding: 0;
    background-color: #1e1e1e; /* Темно-серый фон области контента */
    margin-left: 0;
    transition: margin-left 0.3s ease;
}

/* Dark backgrounds for requested sections */
.feature-section {
    background-color: #1e1e1e !important;
}

.hero-section#hero-section,
.hero-section {
    background-color: #1e1e1e !important;
}

aside.sidebar,
aside.sidebar.sidebar-hidden,
aside.sidebar.sidebar-visible {
    background-color: #1e1e1e !important;
    border-right: 1px solid #1e1e1e !important;
}


/* Hero Section */
.hero-section {
    min-height: 90vh;
    display: flex;
    flex-direction: column; /* Располагаем hero-images под hero-buttons */
    align-items: center;
    justify-content: flex-start; /* Начинаем с верха, чтобы padding-top работал */
    background: #ffffff; /* Белый фон вместо градиента */
    padding: 3rem 0 0 0; /* Добавляем верхний padding для опускания контента */
    position: relative;
    overflow: hidden;
    margin: 1rem !important; /* Центрируем секцию по горизонтали */
    width: 100%;
    max-width: 1200px; /* Ограничиваем ширину для центрирования */
    border-radius: 15px; /* Скругленные углы для hero секции */
}

/* Десктопная версия - увеличенные размеры для hero секции */
@media (min-width: 769px) {
    .hero-section {
        padding: 4rem 0 0 0 !important; /* Добавляем верхний padding для опускания контента */
        margin: 2rem auto !important; /* Равные внешние отступы, центрирование */
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start; /* Начинаем с верха, чтобы padding-top работал */
        text-align: center; /* Центрируем весь контент */
    }
    
    .hero-content {
        max-width: 800px; /* Увеличиваем максимальную ширину контента */
        margin-bottom: 3rem; /* Увеличиваем отступ снизу */
        margin-top: 3rem !important; /* Отступ сверху для опускания контента */
        text-align: center; /* Центрируем текстовый контент */
        width: 100%; /* Занимаем всю доступную ширину */
        display: flex;
        flex-direction: column;
        align-items: center; /* Центрируем элементы по горизонтали */
    }
    
    .hero-title {
        font-size: 3.5rem; /* Увеличиваем размер заголовка */
        margin-bottom: 1.5rem; /* Увеличиваем отступ снизу */
        text-align: center; /* Центрируем заголовок */
        width: 100%; /* Занимаем всю ширину */
    }
    
    .hero-subtitle {
        font-size: 1.4rem; /* Увеличиваем размер подзаголовка */
        margin-bottom: 2rem; /* Увеличиваем отступ снизу */
        text-align: center; /* Центрируем подзаголовок */
        width: 100%; /* Занимаем всю ширину */
        max-width: 600px; /* Ограничиваем ширину для лучшей читаемости */
    }
    
    .hero-buttons {
        gap: 2rem; /* Увеличиваем расстояние между кнопками */
        margin-bottom: 2rem; /* Добавляем отступ снизу */
        display: flex;
        justify-content: center; /* Центрируем кнопки */
        align-items: center;
        flex-wrap: wrap; /* Позволяем перенос на новую строку */
        width: 100%; /* Занимаем всю ширину */
    }
    
    .btn-hero-primary,
    .btn-hero-secondary {
        padding: 1.75rem 4rem; /* еще больше и вытянутее на десктопе */
        font-size: 1.25rem; /* немного больше шрифт */
        min-height: 90px; /* немного ниже, чтобы визуально вытянуть по ширине */
        min-width: 380px; /* шире на десктопе */
        border-radius: 44px; /* более вытянутая форма */
        flex: 0 0 auto; /* Не растягиваем кнопки */
    }
    
    .hero-images {
        grid-template-columns: repeat(2, minmax(240px, 320px)); /* Чуть меньше размеры карточек */
        gap: 1.25rem; /* Чуть меньше расстояние между карточками */
        max-width: 300px; /* Чуть меньше максимальная ширина */
        justify-content: center; /* Центрируем карточки в сетке */
        justify-items: center; /* Центрируем содержимое каждой ячейки */
        width: 80%; /* Занимаем всю ширину */
        display: grid; /* Явно указываем display: grid */
        place-items: center; /* Центрируем все элементы в сетке */
    }

    .hero-image-card .image-overlay p {
        font-size: 1rem; /* Увеличиваем размер текста в overlay */
        text-align: center; /* Центрируем текст */
    }
}

/* Telegram WebApp - восстанавливаем нормальные размеры hero секции */
.telegram-webapp .hero-section {
    padding: 4rem 1rem 2rem 1rem !important; /* Увеличиваем верхний padding для опускания контента */
    margin: 1rem 1rem; /* Добавляем отступы по бокам для Telegram WebApp */
    border-radius: 15px; /* Скругленные углы для hero секции */
}

.hero-content {
    text-align: center;
    max-width: 700px;
    margin-bottom: 2rem;
    margin-top: 2rem !important;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 300;
    color: #ffffff !important;
    margin-bottom: 1rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: #f0f0f0 !important;
    margin-bottom: 1.5rem;
    font-weight: 400;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-hero-primary {
    background: linear-gradient(135deg, #2c2c2c, #1a1a1a);
    color: white;
    padding: 1.25rem 3.5rem; /* больше и более вытянутые */
    font-size: 1rem;
    font-weight: 500;
    border-radius: 40px; /* более пилюлеобразная форма */
    min-width: 320px; /* делаем кнопки длиннее */
    box-shadow: 0 8px 25px rgba(44, 44, 44, 0.2);
    transition: all 0.3s ease;
}

.btn-hero-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(44, 44, 44, 0.3);
}

.btn-hero-secondary {
    background-color: transparent;
    color: #ffffff !important;
    border: 2px solid #2c2c2c;
    padding: 1.25rem 3.5rem; /* больше и более вытянутые */
    font-size: 1rem;
    font-weight: 500;
    border-radius: 40px; /* более пилюлеобразная форма */
    min-width: 320px; /* делаем кнопки длиннее */
    transition: all 0.3s ease;
}

.btn-hero-secondary:hover {
    background-color: #2c2c2c;
    color: #ffffff !important;
    transform: translateY(-3px);
}

/* Ensure text inside hero secondary button is white */
.btn.btn-hero-secondary.hero-btn-with-image .btn-title,
.btn.btn-hero-secondary.hero-btn-with-image .btn-subtitle {
    color: #ffffff !important;
}

.hero-images {
    display: grid;
    grid-template-columns: repeat(2, minmax(180px, 240px));
    gap: 1.25rem;
    max-width: 560px;
    margin: 0 auto;
    justify-content: center;
    padding: 0 1rem;
}

.hero-image-card {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    background: linear-gradient(135deg, #f8f9fa, #ffffff);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    height: 220px;
    margin: 0 1rem;
}

.hero-image-card:hover {
    transform: translateY(-5px);
}

.hero-card-image {
    width: 100%;
    height: 100%;
    border-radius: 15px;
    overflow: hidden;
}

.hero-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.hero-image-card:hover .hero-card-image img {
    transform: scale(1.05);
}

.hero-image-card .image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
    color: white;
    padding: 1.5rem;
    border-radius: 0 0 15px 15px;
}

.hero-image-card .image-overlay h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.hero-image-card .image-overlay p {
    font-size: 0.85rem;
    opacity: 0.95;
    margin: 0;
}

.image-placeholder {
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e9ecef, #f8f9fa);
    position: relative;
}

.image-placeholder i {
    font-size: 4rem;
    color: #6c757d;
    opacity: 0.7;
}

/* API Key Section */
.api-key-section {
    margin-bottom: 3rem;
}

.api-key-section.hidden {
    display: none;
}

.api-key-card {
    background-color: #f8f8f8;
    padding: 2rem;
    border-radius: 20px;
    border: 2px solid #e5e5e5;
    max-width: 600px;
}

.api-key-card h3 {
    color: #2c2c2c;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.api-key-card p {
    color: #666;
    margin-bottom: 1.5rem;
}

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

.input-group input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e5e5;
    border-radius: 15px;
    font-size: 0.9rem;
    background-color: white;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #4a9eff;
}

.status-message {
    margin-top: 1rem;
    padding: 0.75rem;
    border-radius: 10px;
    font-size: 0.9rem;
}

.status-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Feature Sections */
.feature-section {
    margin: 1rem 2rem 4rem 2rem; /* Добавляем отступы сверху, снизу и по бокам */
    padding: 4rem 2rem;
    background-color: #ffffff; /* Белый фон для padding области */
    border-radius: 15px; /* Скругленные углы для feature секций */
}

/* Telegram WebApp - восстанавливаем нормальные размеры feature секций */
.telegram-webapp .feature-section {
    padding: 4rem 2rem; /* Нормальные отступы */
    margin: 1rem 1rem 4rem 1rem; /* Добавляем отступы по бокам для Telegram WebApp */
    border-radius: 15px; /* Скругленные углы для feature секций */
}

.feature-section h2 {
    color: #ffffff !important;
    font-size: 1.6rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.tryon-container, .product-model-container {
    background-color: #ffffff;
    padding: 1rem;
    border-radius: 15px;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin: 1rem 0; /* Добавляем отступы сверху и снизу */
}

/* Telegram WebApp - восстанавливаем нормальные размеры контейнеров */
.telegram-webapp .tryon-container, 
.telegram-webapp .product-model-container {
    padding: 1rem; /* Нормальные отступы */
    margin: 1rem 0; /* Нормальные отступы */
}

.upload-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
    width: 100%;
}

.upload-panel {
    background-color: white;
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px solid #ffffff;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.upload-panel h3 {
    color: #2c2c2c;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.upload-area {
    border: 2px dashed #ccc;
    border-radius: 15px;
    padding: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #fafafa;
}

.upload-area:hover {
    border-color: #545455;
    background-color: rgba(74, 158, 255, 0.05);
}

.upload-area i {
    font-size: 2rem;
    color: #999;
    margin-bottom: 0.5rem;
}

.upload-area p {
    color: #666;
    font-size: 0.85rem;
    font-weight: 400;
}

.image-preview {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    background-color: white;
    border: 2px solid #ffffff;
}

.image-preview img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    background-color: #f8f8f8;
    border-radius: 10px;
}

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

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

.controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background-color: white;
    border-radius: 15px;
    border: 2px solid #ffffff;
}

.category-select {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.category-select label {
    color: #2c2c2c;
    font-weight: 500;
    font-size: 0.9rem;
}

.category-select select {
    padding: 0.5rem 1rem;
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    background-color: white;
    color: #2c2c2c;
    font-size: 0.9rem;
}

.result-preview {
    background-color: white;
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px solid #ffffff;
    text-align: center;
}

.result-preview h3 {
    color: #2c2c2c;
    margin-bottom: 1rem;
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.result-preview img {
    max-width: 400px;
    max-height: 500px;
    width: 100%;
    height: auto;
    display: block;
    margin: 0 auto 2rem auto;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    background-color: #f8f8f8;
}

.result-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Gallery */
.gallery-section {
    margin: 1rem 2rem 4rem 2rem; /* Добавляем отступы сверху, снизу и по бокам */
    padding: 4rem 2rem;
    background-color: #ffffff; /* Белый фон для padding области */
    border-radius: 15px; /* Скругленные углы для gallery секции */
}

/* Telegram WebApp - восстанавливаем нормальные размеры gallery секции */
.telegram-webapp .gallery-section {
    padding: 4rem 2rem; /* Нормальные отступы */
    margin: 1rem 1rem 4rem 1rem; /* Добавляем отступы по бокам для Telegram WebApp */
    border-radius: 15px; /* Скругленные углы для gallery секции */
}

.gallery-section h2 {
    color: #ffffff !important;
    font-size: 1.6rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.gallery-item {
    background-color: white;
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid #ffffff;
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    width: 100%;
    height: 180px;
    object-fit: contain;
    background-color: #f8f8f8;
}

.gallery-item-info {
    padding: 1rem;
}

.gallery-item-type {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.gallery-item-type.tryon {
    background-color: rgba(74, 158, 255, 0.1);
    color: #357abd;
}

.gallery-item-type.product-model {
    background-color: rgba(34, 197, 94, 0.1);
    color: #16a34a;
}

.gallery-item-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.gallery-item-actions button {
    flex: 1;
    padding: 0.5rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 400;
    transition: background-color 0.3s ease;
}

.btn-gallery-download {
    background-color: rgba(44, 44, 44, 0.1);
    color: #2c2c2c;
}

.btn-gallery-download:hover {
    background-color: rgba(44, 44, 44, 0.2);
}

.btn-gallery-delete {
    background-color: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

.btn-gallery-delete:hover {
    background-color: rgba(239, 68, 68, 0.2);
}

/* Gallery fade in animation */
@keyframes fadeInGallery {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Footer */
.footer {
    background-color: #1e1e1e !important;
    padding: 2rem;
    border-top: 1px solid #1e1e1e !important;
    margin-top: auto;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #1e1e1e !important;
}

.footer-left .logo {
    font-size: 1.1rem;
    font-weight: 500;
    color: #2c2c2c;
}

.footer-left .logo-image {
    height: 50px;
    width: 50px;
    object-fit: cover;
    border-radius: 8px;
}

.footer-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
    color: #666;
    font-weight: 400;
}

.footer-right a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-right a:hover {
    color: #2c2c2c;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-spinner {
    text-align: center;
    background-color: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.loading-spinner i {
    font-size: 3rem;
    color: #4a9eff;
    margin-bottom: 1rem;
}

.loading-spinner p {
    color: #2c2c2c;
    font-size: 1rem;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        padding: 1rem;
        gap: 1rem;
    }
    
    .btn {
        padding: 15px 25px;
        font-size: 16px;
        margin-bottom: 0px !important;
    }
    
    /* Telegram WebApp mobile styles */
    .telegram-webapp .header {
        padding: 0.4rem 0.5rem; /* Компактный padding для мобильных */
        gap: 0.8rem;
    }
}

@media (max-width: 480px) {
    /* Общие стили для всех мобильных устройств */
    .header-right {
        gap: 0.3rem !important;
        padding: 0 0.3rem;
        justify-content: space-between !important;
        width: 100% !important;
    }
    
    /* Унифицированные стили для всех кнопок в header на очень маленьких экранах как современные панели */
    .generations-counter,
    .language-selector,
    /* .btn-signup, */
    .btn-signup {
        padding: 0.5rem 0.8rem;
        font-size: 0.75rem;
        border-radius: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
        width: 80px;
        background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .generations-counter:hover,
    .language-selector:hover,
    .btn-signup:hover,
    .btn-language:hover {
        background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%) !important;
        transform: translateY(-2px) scale(1.02) !important;
        box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3) !important;
    }
    
    .generations-counter {
        gap: 0.3rem !important;
        background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%) !important;
    }
    
    .generations-counter i {
        font-size: 0.8rem !important;
        color: white !important;
    }
    
    .counter-label {
        font-size: 0.65rem !important;
        color: rgba(255, 255, 255, 0.8) !important;
    }
    
    .counter-value {
        font-size: 0.65rem !important;
        color: white !important;
        font-weight: 600 !important;
    }
    
    .language-selector {
        gap: 0.3rem !important;
    }
    
    .language-selector .flag {
        font-size: 0.8rem !important;
    }
    
    .language-selector #languageCode {
        font-size: 0.65rem !important;
        font-weight: 600 !important;
    }
    
    .btn-signup {
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        font-weight: 600 !important;
    }
    
    .telegram-webapp .header {
        padding: 0.4rem 2rem !important;
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
        gap: 0.6rem !important;
    }
    
    .telegram-webapp .header-left {
        padding-left: 0.3rem !important;
        gap: 0.3rem !important;
    }
    
    .telegram-webapp .header-right {
        padding-right: 0.3rem !important;
        gap: 0.8rem !important;
    }
    
    .telegram-webapp .main-content {
        padding-top: 0 !important; /* Убираем отступ сверху для мобильных */
        padding-bottom: 6rem !important; /* Увеличиваем отступ снизу для плавающей панели */
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .telegram-webapp .content-area {
        padding: 0 !important; /* Убираем все отступы */
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .telegram-webapp .hero-section {
        padding: 1.5rem 0.5rem !important;
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .telegram-webapp .feature-section {
        padding: 0 !important;
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .telegram-webapp .gallery-section {
        padding: 1.5rem 0.5rem !important;
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .header-right {
        gap: 0.4rem;
        padding: 0 0.5rem;
        justify-content: space-between;
        width: 100%;
    }
    
    /* Унифицированные стили для всех кнопок в header как маленькие панели */
    .generations-counter,
    .language-selector,
    .btn-signup {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
        width: 90px;
        background-color: #2c2c2c;
        color: white;
        border: 1px solid #1a1a1a;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
        transition: all 0.2s ease;
    }
    
    .generations-counter:hover,
    .language-selector:hover,
    .btn-signup:hover {
        background-color: #1a1a1a;
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    }
    
    .generations-counter {
        gap: 0.4rem;
    }
    
    .generations-counter i {
        font-size: 0.9rem;
        color: white;
    }
    
    .counter-label {
        font-size: 0.7rem;
        color: #cccccc;
    }
    
    .counter-value {
        font-size: 0.7rem;
        color: white;
        font-weight: 600;
    }
    
    .language-selector {
        gap: 0.4rem;
    }
    
    .language-selector .flag {
        font-size: 0.9rem;
    }
    
    .language-selector #languageCode {
        font-size: 0.7rem;
        font-weight: 600;
    }
    
    .btn-signup {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        font-weight: 600;
    }
    
    /* Telegram WebApp - специальные стили для кнопки пользователя */
    .telegram-webapp .btn-signup {
        max-width: 80px;
        font-size: 0.75rem;
        padding: 0.4rem 0.8rem;
        display: flex;
        align-items: center;
    }
    
    /* Telegram WebApp - специальные стили для generations counter */
    .telegram-webapp .generations-counter {
        padding: 0.4rem 0.8rem !important;
        font-size: 0.75rem !important;
        display: flex !important;
        align-items: center !important;
    }
    
    .telegram-webapp .generations-counter i {
        font-size: 0.75rem !important;
    }
    
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 280px;
        padding: 1rem;
    }
    
    .nav {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .nav-item {
        white-space: nowrap;
        min-width: fit-content;
    }
    
    .nav-divider {
        display: block;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-images {
        grid-template-columns: 1fr;
        gap: 1.25rem;
        padding: 0 1rem;
    }
    
    .feature-section {
        padding: 2rem 1rem;
        margin: 0.5rem 1rem 2rem 1rem; /* Добавляем отступы по бокам для мобильных */
        background-color: #ffffff; /* Белый фон для padding области */
        border-radius: 15px; /* Скругленные углы для feature секций */
    }
    
    .gallery-section {
        padding: 2rem 1rem;
        margin: 0.5rem 1rem 2rem 1rem; /* Добавляем отступы по бокам для мобильных */
        background-color: #ffffff; /* Белый фон для padding области */
        border-radius: 15px; /* Скругленные углы для gallery секции */
    }
    
    .upload-panels {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .controls {
        flex-direction: column;
        gap: 1rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    /* Telegram WebApp extra small screens */
    .telegram-webapp .header {
        padding: 0.8rem 1.5rem !important; /* Оптимизированные отступы */
        width: calc(100vw - 40px) !important;
        max-width: calc(100vw - 40px) !important;
        gap: 0.5rem !important;
        border-radius: 25px !important; /* Немного меньше радиус для маленьких экранов */
        bottom: 15px !important; /* Меньший отступ от низа */
    }
    
    .telegram-webapp .header-left {
        padding-left: 0.2rem !important;
        gap: 0.3rem !important;
    }
    
    .telegram-webapp .header-right {
        padding-right: 0.3rem !important;
        gap: 0.3rem !important;
        justify-content: space-between !important;
        width: 100% !important;
    }
    
    .telegram-webapp .main-content {
        padding-top: 0 !important; /* Убираем отступ сверху */
        padding-bottom: 6rem !important; /* Увеличиваем отступ снизу для плавающей панели */
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    .telegram-webapp .content-area {
        padding: 0 !important; /* Убираем все отступы */
        width: calc(100vw - 178px) !important;
        max-width: calc(100vw - 178px) !important;
    }
    
    /* Унифицированные стили для всех кнопок в header на очень маленьких экранах как современные панели */
    .telegram-webapp .generations-counter,
    .telegram-webapp .language-selector,
    .telegram-webapp .btn-signup,
    .telegram-webapp .hamburger {
        padding: 0.5rem 0.8rem !important;
        font-size: 0.75rem !important;
        border-radius: 18px !important; /* Современные закругленные углы */
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-height: 50px !important; /* Оптимальная высота */
        width: 80px !important;
        background: linear-gradient(135deg, rgba(44, 44, 44, 0.9) 0%, rgba(26, 26, 26, 0.9) 100%) !important;
        backdrop-filter: blur(10px) !important;
        -webkit-backdrop-filter: blur(10px) !important;
        color: white !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        box-shadow: 0 4px 15px rgba(44, 44, 44, 0.2) !important;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        position: relative !important; /* Для кнопки меню */
        top: auto !important;
        left: auto !important;
        transform: none !important;
        z-index: auto !important;
    }
    
    .telegram-webapp .generations-counter:hover,
    .telegram-webapp .language-selector:hover,
    .telegram-webapp .btn-signup:hover,
    /* .telegram-webapp .btn-language:hover, */
    .telegram-webapp .hamburger:hover {
        background: linear-gradient(135deg, rgba(44, 44, 44, 1) 0%, rgba(26, 26, 26, 1) 100%) !important;
        transform: translateY(-2px) scale(1.02) !important;
        box-shadow: 0 8px 25px rgba(44, 44, 44, 0.3) !important;
    }
    
    /* Активное состояние кнопки меню на мобильных */
    .telegram-webapp .hamburger.active,
    .telegram-webapp .hamburger:active {
        background: linear-gradient(135deg, rgba(44, 44, 44, 0.8) 0%, rgba(26, 26, 26, 0.8) 100%) !important; /* Полупрозрачный градиент */
        backdrop-filter: blur(20px) !important; /* Размытие фона */
        border: 1px solid rgba(255, 255, 255, 0.3) !important; /* Полупрозрачная граница */
        box-shadow: 0 12px 40px rgba(44, 44, 44, 0.4) !important; /* Современная тень */
        transform: translateY(-1px) scale(0.98) !important; /* Небольшое сжатие */
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important; /* Плавная анимация */
    }
    
    .telegram-webapp .hamburger.active i,
    .telegram-webapp .hamburger:active i {
        color: rgba(255, 255, 255, 0.9) !important; /* Полупрозрачная иконка */
        transform: rotate(90deg) !important; /* Поворот иконки */
        transition: all 0.3s ease !important;
    }
    
    .telegram-webapp .generations-counter {
        gap: 0.3rem !important;
        background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%) !important;
    }
    
    .telegram-webapp .generations-counter i {
        font-size: 0.8rem !important;
        color: white !important;
    }
    
    .telegram-webapp .language-selector {
        gap: 0.3rem !important;
    }
    
    .telegram-webapp .language-selector .flag {
        font-size: 0.8rem !important;
    }
    
    .telegram-webapp .language-selector #languageCode {
        font-size: 0.65rem !important;
        font-weight: 600 !important;
    }
    
    .telegram-webapp .btn-signup {
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        font-weight: 600 !important;
    }
    
    .telegram-webapp .hamburger i {
        font-size: 0.8rem !important;
        color: white !important;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
    }
    
    .hero-images {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 0 1rem;
    }
    
    .feature-section h2 {
        font-size: 1.5rem;
    }
    
    .tryon-container, .product-model-container {
        padding: 1rem;
        margin: 0.5rem 0; /* Меньшие отступы для мобильных */
    }
    
    .upload-panel {
        padding: 1rem;
    }
    
    .upload-area {
        padding: 1rem;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* Progress Bar & Notification Styles */
.progress-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    padding: 1.5rem;
    width: 350px;
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

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

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

.progress-header h4 {
    font-size: 1rem;
    font-weight: 500;
    color: #2c2c2c;
}

.progress-close {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.progress-close:hover {
    background-color: #f0f0f0;
}

.progress-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.progress-image-box {
    text-align: center;
}

.progress-image-box label {
    font-size: 0.75rem;
    color: #666;
    display: block;
    margin-bottom: 0.25rem;
}

.progress-image-box img {
    width: 100%;
    height: 80px;
    object-fit: contain;
    border-radius: 8px;
    background-color: #f8f8f8;
    border: 1px solid #e5e5e5;
}

.progress-bar-container {
    margin: 1rem 0;
}

.progress-bar-bg {
    width: 100%;
    height: 6px;
    background-color: #e5e5e5;
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #2c2c2c, #555);
    border-radius: 3px;
    transition: width 0.3s ease;
    animation: pulse 2s infinite;
}

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



.progress-status {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.progress-message {
    font-size: 0.8rem;
    color: #999;
    line-height: 1.4;
    padding: 0.75rem;
    background-color: #f8f8f8;
    border-radius: 8px;
    border-left: 3px solid #2c2c2c;
}

.progress-success {
    background-color: #e8f5e9;
    border-left-color: #4caf50;
    color: #2e7d32;
}

.progress-error {
    background-color: #ffebee;
    border-left-color: #f44336;
    color: #c62828;
}

/* Instructions Panel */
.instructions-panel {
    background: #1e1e1e !important;
    padding: 1rem;
    border-radius: 15px;
    margin-bottom: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    color: #ffffff !important;
    position: relative;
    overflow: hidden;
    border: 2px solid #1e1e1e !important;
}


.instructions-panel h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
    justify-content: center;
    color: #ffffff !important;
}

.instructions-panel h3 i {
    font-size: 1.1rem;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 0.3rem;
    border-radius: 50%;
}

.instructions-steps {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.instruction-step {
    background: #f5f5f5 !important;
    border-radius: 10px;
    padding: 0.75rem;
    border: 2px solid #ffffff;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    overflow: hidden;
}

.instruction-step::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.1;
    pointer-events: none;
}

/* Remove individual step backgrounds - keeping clean design */

/* Hero Buttons with Images */
.hero-btn-with-image {
    display: flex !important;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 2rem !important;
    min-height: 80px;
    text-align: center; /* центрируем текст */
    justify-content: center; /* центрируем содержимое кнопки */
    border-radius: 20px !important;
    transition: all 0.3s ease;
}

.hero-btn-with-image:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.btn-image {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    padding: 8px;
}

.btn-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.btn-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: center; /* центрируем столбец текста */
}

.btn-title {
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: center; /* центрируем заголовок */
}

.btn-subtitle {
    font-size: 0.85rem;
    opacity: 0.8;
    line-height: 1.0;
    text-align: center; /* центрируем подзаголовок */
}

.btn-hero-primary .btn-image {
    background: rgba(255, 255, 255, 0.25);
}

.btn-hero-secondary .btn-image {
    background: rgba(44, 44, 44, 0.1);
}

.instruction-step:hover {
    transform: translateY(-2px);
    border-color: #d0d0d0;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    background: #f0f0f0 !important;
}

.step-number {
    background: #ffffff;
    color: #2c2c2c;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 2px solid #e0e0e0;
    position: relative;
    z-index: 1;
}

.step-content {
    flex: 1;
    position: relative;
    z-index: 1;
}

.step-content h4 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: #2c2c2c;
}

.step-content p {
    font-size: 0.75rem;
    color: #666;
    line-height: 1.3;
    margin: 0;
}

/* Category Icons */
.category-icons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-top: 0.5rem;
}

.category-icon {
    background: #f8f8f8;
    color: #666;
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid #ffffff;
    position: relative;
}

.category-icon:hover {
    transform: translateY(-2px);
    border-color: #f0f1f7;
    background: #020203;
    color: #f7f8fe;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
}

.category-icon.active {
    background: linear-gradient(135deg, #000000 0%, #070707 100%);
    border-color: #0c0c0c;
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.category-icon i {
    font-size: 1.2rem;
}

.category-icon::after {
    content: attr(title);
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.category-icon:hover::after {
    opacity: 1;
}

/* Result Preview */
.result-preview-panel {
    background: linear-gradient(135deg, #3c3c3c 0%, #4e4f4f 100%);
    border-radius: 20px;
    padding: 1.5rem;
    margin-top: 1rem;
    text-align: center;
    color: white;
    box-shadow: 0 8px 30px rgba(79, 172, 254, 0.3);
}

.result-preview-panel h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.result-preview-panel h4 i {
    font-size: 1.3rem;
}

.result-preview-image {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    padding: 1rem;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.result-preview-image img {
    max-width: 100%;
    max-height: 180px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.result-preview-placeholder {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.result-preview-placeholder i {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    display: block;
}

/* Prompt Input Styles */
.prompt-input-group {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px solid #ffffff;
    margin: 1.5rem 0;
}

.prompt-input-group label {
    display: block;
    color: #2c2c2c;
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
}

.prompt-input-group label i {
    color: #667eea;
    margin-right: 0.5rem;
}

.prompt-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    font-size: 0.9rem;
    font-family: inherit;
    transition: all 0.3s ease;
    background-color: #f8f8f8;
}

.prompt-input:focus {
    outline: none;
    border-color: #667eea;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.prompt-hint {
    display: block;
    margin-top: 0.5rem;
    color: #666;
    font-size: 0.8rem;
    font-style: italic;
}

.generate-button-container {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
}

.generate-button-container .btn-generate {
    min-width: 250px;
}

/* Pricing Section Styles */
.pricing-section {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.pricing-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: rgb(96, 95, 95);
}

.pricing-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: rgba(102, 126, 234, 0.1);
    margin-bottom: 2rem;
}

/* Current Usage Info */
.current-usage-info {
    background: linear-gradient(135deg, #434344 0%, #575758 100%);
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.usage-info-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    color: white;
    text-align: center;
}

.usage-info-content i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.usage-stats {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Pricing Grid */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

/* Pricing Card */
.pricing-card {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    transform: translateY(-5px);
    border-color: rgba(102, 126, 234, 0.1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.pricing-card-popular {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.1);
    box-shadow: 0 5px 30px rgba(102, 126, 234, 0.3);
}

/* Pricing Badge */
.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: rgb(89, 86, 86);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.pricing-badge-popular {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Pricing Header */
.pricing-header {
    text-align: center;
    margin-bottom: 2rem;
}

.pricing-header h3 {
    color: rgb(108, 106, 106);
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.pricing-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.5rem;
}

.price-amount {
    font-size: 3rem;
    font-weight: 700;
    color: rgb(11, 11, 11);
}

.price-currency {
    font-size: 1.5rem;
    color: rgba(54, 52, 52, 0.7);
}

/* Pricing Features */
.pricing-features {
    flex: 1;
    margin-bottom: 2rem;
}

.pricing-feature {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    color: rgba(57, 56, 56, 0.9);
}

.pricing-feature i {
    color: #4CAF50;
    font-size: 1.2rem;
}

.pricing-feature strong {
    color: rgb(61, 60, 60);
}

/* Pricing Button */
.btn-pricing {
    width: 100%;
    padding: 1rem;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(57, 56, 56, 0.9);
}

.btn-pricing:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.02);
}

.btn-pricing:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

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

.btn-pricing-primary:hover {
    background: linear-gradient(135deg, #5568d3 0%, #653a8b 100%);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

/* Responsive Design for Pricing */
@media (max-width: 768px) {
    .pricing-grid {
        grid-template-columns: 1fr;
        gap: 1rem; /* Уменьшаем расстояние между карточками */
    }
    
    .pricing-section {
        padding: 1rem; /* Уменьшаем отступы секции */
        max-width: 100%;
    }
    
    .pricing-section h2 {
        font-size: 1.8rem; /* Уменьшаем размер заголовка */
        margin-bottom: 0.5rem;
    }
    
    .pricing-subtitle {
        font-size: 1rem; /* Уменьшаем размер подзаголовка */
        margin-bottom: 1rem;
    }
    
    .pricing-card {
        padding: 1.5rem; /* Уменьшаем отступы карточек */
        border-radius: 15px; /* Уменьшаем радиус */
    }
    
    .pricing-header h3 {
        font-size: 1.5rem; /* Уменьшаем размер заголовка карточки */
        margin-bottom: 0.5rem;
    }
    
    .price-amount {
        font-size: 2rem; /* Уменьшаем размер цены */
    }
    
    .pricing-features {
        margin-bottom: 1rem; /* Уменьшаем отступ */
    }
    
    .pricing-feature {
        padding: 0.5rem 0; /* Уменьшаем отступы элементов */
        font-size: 0.9rem; /* Уменьшаем размер шрифта */
    }
    
    .btn-pricing {
        padding: 0.8rem; /* Уменьшаем отступы кнопки */
        font-size: 1rem; /* Уменьшаем размер шрифта кнопки */
    }
}

/* Telegram WebApp - еще более компактные стили для pricing */
.telegram-webapp .pricing-section {
    padding: 0.8rem; /* Еще меньше отступы для Telegram */
}

.telegram-webapp .pricing-section h2 {
    font-size: 1.6rem; /* Еще меньше заголовок для Telegram */
    margin-bottom: 0.3rem;
}

.telegram-webapp .pricing-subtitle {
    font-size: 0.9rem; /* Еще меньше подзаголовок для Telegram */
    margin-bottom: 0.8rem;
}

.telegram-webapp .pricing-card {
    padding: 1.2rem; /* Еще меньше отступы карточек для Telegram */
    border-radius: 12px; /* Еще меньше радиус для Telegram */
}

.telegram-webapp .pricing-header h3 {
    font-size: 1.3rem; /* Еще меньше заголовок карточки для Telegram */
    margin-bottom: 0.3rem;
}

.telegram-webapp .price-amount {
    font-size: 1.8rem; /* Еще меньше цена для Telegram */
}

.telegram-webapp .pricing-features {
    margin-bottom: 0.8rem; /* Еще меньше отступ для Telegram */
}

.telegram-webapp .pricing-feature {
    padding: 0.4rem 0; /* Еще меньше отступы элементов для Telegram */
    font-size: 0.85rem; /* Еще меньше размер шрифта для Telegram */
}

.telegram-webapp .btn-pricing {
    padding: 0.7rem; /* Еще меньше отступы кнопки для Telegram */
    font-size: 0.9rem; /* Еще меньше размер шрифта кнопки для Telegram */
}

/* Telegram WebApp - стили для pricing-page-container (запасной вариант, основной приоритет в pricing.html) */
body.telegram-webapp .pricing-page-container {
    max-width: 95% !important;
    width: 95% !important;
    padding: 1rem !important;
    margin: 0 auto !important;
}

/* Telegram WebApp - делаем pricing-grid шире */
body.telegram-webapp .pricing-grid {
    max-width: 100% !important;
    width: 100% !important;
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
    margin-top: 1rem !important;
}

/* Telegram WebApp - делаем pricing-card на всю ширину */
body.telegram-webapp .pricing-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* ======================================== */
/* Mobile Navigation Styles (moved from JS) */
/* ======================================== */

/* Mobile Navigation Panel */
.mobile-navigation {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-right: 1px solid rgba(255, 255, 255, 0.3);
    z-index: 10000;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.1);
    overflow-y: auto;
}

.mobile-navigation.open {
    left: 0;
}

/* Telegram WebApp specific mobile styles */
.telegram-webapp .mobile-navigation {
    top: 0;
}

.mobile-nav-header {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 20px;
    background: transparent;
    backdrop-filter: none;
}

.mobile-nav-title {
    display: none;
}

.mobile-nav-close {
    background: none;
    border: none;
    color: #000000;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.mobile-nav-close:hover {
    background-color: rgba(49, 48, 48, 0.08);
}

.mobile-nav-content {
    padding: 20px 0;
}

.mobile-nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px 20px;
    color: #2c2c2c;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    font-weight: 500;
    background-color: #ffffff;
    margin: 8px 15px;
    border-radius: 15px;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.mobile-nav-item:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.mobile-nav-item i {
    display: none;
}

.mobile-nav-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 0, 0, 0.1), transparent);
    margin: 15px 20px;
}

.contacts-item {
    background-color: #f8f9fa;
}

.contacts-item:hover {
    background-color: #e9ecef;
}

/* Mobile Navigation Overlay */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    backdrop-filter: blur(2px);
}
/* Styles for Make yourself a photo - small upload areas */
.upload-area-small {
    min-height: 120px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.upload-area-small i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.upload-area-small p {
    font-size: 0.8rem;
    margin: 0;
}

.image-preview-small {
    position: relative;
    min-height: 120px;
    border-radius: 8px;
    overflow: hidden;
}

.image-preview-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.image-preview-small .btn-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 24px;
    height: 24px;
    font-size: 16px;
    padding: 0;
    line-height: 24px;
}
