/*
* demo.css
* File include item demo only specific css only
******************************************************************************/

.light-style .menu .app-brand.demo {
  height: 64px;
}

.dark-style .menu .app-brand.demo {
  height: 64px;
}

.app-brand-logo.demo {
  -ms-flex-align: center;
  align-items: center;
  -ms-flex-pack: center;
  justify-content: center;
  display: -ms-flexbox;
  display: flex;
  width: 30px;
  height: 30px;
}

.app-brand-logo.demo svg {
  width: 1.7rem;
  height: 1.7rem;
}

.app-brand-text.demo {
  font-size: 1.75rem;
  letter-spacing: -0.45px;
}

/* ! For .layout-navbar-fixed added fix padding top tpo .layout-page */
.layout-navbar-fixed .layout-wrapper:not(.layout-without-menu) .layout-page {
  padding-top: 62px !important;
}

/* Navbar page z-index issue solution */
.content-wrapper .navbar {
  z-index: auto;
}

/*
* Content
******************************************************************************/

.demo-blocks > * {
  display: block !important;
}

.demo-inline-spacing > * {
  margin: 1rem 0.375rem 0 0 !important;
}

/* ? .demo-vertical-spacing class is used to have vertical margins between elements. To remove margin-top from the first-child, use .demo-only-element class with .demo-vertical-spacing class. For example, we have used this class in forms-input-groups.html file. */
.demo-vertical-spacing > * {
  margin-top: 1rem !important;
  margin-bottom: 0 !important;
}
.demo-vertical-spacing.demo-only-element > :first-child {
  margin-top: 0 !important;
}

.demo-vertical-spacing-lg > * {
  margin-top: 1.875rem !important;
  margin-bottom: 0 !important;
}
.demo-vertical-spacing-lg.demo-only-element > :first-child {
  margin-top: 0 !important;
}

.demo-vertical-spacing-xl > * {
  margin-top: 5rem !important;
  margin-bottom: 0 !important;
}
.demo-vertical-spacing-xl.demo-only-element > :first-child {
  margin-top: 0 !important;
}

.rtl-only {
  display: none !important;
  text-align: left !important;
  direction: ltr !important;
}

[dir='rtl'] .rtl-only {
  display: block !important;
}

/* Dropdown buttons going out of small screens */
@media (max-width: 576px) {
  #dropdown-variation-demo .btn-group .text-truncate {
    width: 231px;
    position: relative;
  }
  #dropdown-variation-demo .btn-group .text-truncate::after {
    position: absolute;
    top: 45%;
    right: 0.65rem;
  }
}

/*
* Layout demo
******************************************************************************/

.layout-demo-wrapper {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
  margin-top: 1rem;
}
.layout-demo-placeholder img {
  width: 900px;
}
.layout-demo-info {
  text-align: center;
  margin-top: 1rem;
}

/* ==========================================================================
   СВЕТЛОЕ МОДАЛЬНОЕ ОКНО VPN (СТИЛЬ HAPP / CROBOX)
   ========================================================================== */

/* 1. Модальный оверлей (Мягкое светлое затемнение фона сайта) */
.vpn-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.3); /* Легкая воздушная вуаль */
    backdrop-filter: blur(6px); /* Размытие заднего плана */
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease-out;
    padding: 20px;
}

/* Класс активации модального окна */
.vpn-modal-overlay.is-active {
    opacity: 1;
    pointer-events: auto;
}

/* 2. Главный контейнер виджета (Светлый стиль с мягкой тенью) */
.vpn-modal-overlay .widget-container {
    max-width: 440px;
    width: 100%;
    position: relative;
    background-color: #ffffff; /* Белоснежный фон */
    border: 1px solid #e2e8f0; /* Легкая серая граница */
    border-radius: 16px; /* Закругления как у ваших блоков */
    padding: 32px 24px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    transform: scale(0.96);
    transition: transform 0.2s ease-out;
}

/* Анимация при открытии */
.vpn-modal-overlay.is-active .widget-container {
    transform: scale(1);
}

/* Кнопка-крестик закрытия окна */
.modal-close-x {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease;
}
.modal-close-x:hover { color: #64748b; }

/* 3. Шапка виджета */
.vpn-modal-overlay .header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 24px;
    text-align: center;
}

.vpn-modal-overlay .logo-box {
    width: 48px;
    height: 48px;
    background: #f0f7ff; /* Светло-синий нежный фон */
    border: 1px solid #e0f2fe;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.vpn-modal-overlay .logo-icon {
    width: 22px;
    height: 22px;
    color: #3b82f6; /* Синий цвет иконки */
}

.vpn-modal-overlay .title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b; /* Темный текст заголовка */
    letter-spacing: -0.5px;
}

.vpn-modal-overlay .subtitle {
    font-size: 13px;
    color: #64748b;
    margin-top: 4px;
}

/* 4. Сетка аккуратных светлых плашек лимитов (2x2) */
.vpn-modal-overlay .stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 24px;
}

.vpn-modal-overlay .stat-card {
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 66px;
    background-color: #f8fafc; /* Светло-серый фон плашек */
    border: 1px solid #f1f5f9;
}

.vpn-modal-overlay .stat-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.vpn-modal-overlay .stat-icon {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.vpn-modal-overlay .stat-label {
    font-size: 11px;
    font-weight: 600;
}

.vpn-modal-overlay .stat-value {
    font-size: 14px;
    font-weight: 700;
}

/* Цветовые акценты плашек (адаптировано под светлую тему) */
.card-traffic { border-left: 3px solid #f59e0b; }
.card-traffic .stat-header { color: #b45309; }
.card-traffic .stat-value { color: #d97706; }

.card-expire { border-left: 3px solid #ef4444; }
.card-expire .stat-header { color: #b91c1c; }
.card-expire .stat-value { color: #dc2626; }

.card-devices { border-left: 3px solid #3b82f6; }
.card-devices .stat-header { color: #1d4ed8; }
.card-devices .stat-value { color: #2563eb; }

.card-status { border-left: 3px solid #10b981; }
.card-status .stat-header { color: #047857; }
.card-status .stat-value { color: #059669; }

/* 5. Элементы формы ввода */
.vpn-modal-overlay .form-group {
    margin-bottom: 18px;
    position: relative;
}

.vpn-modal-overlay .form-label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
}

.vpn-modal-overlay .label-hint {
    font-size: 11px;
    color: #94a3b8;
    font-weight: 400;
}

.vpn-modal-overlay .input-wrapper {
    position: relative;
}

.vpn-modal-overlay .form-input {
    width: 100%;
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 12px 40px 12px 14px;
    font-size: 14px;
    color: #1e293b;
    outline: none;
    transition: all 0.2s ease;
}

.vpn-modal-overlay .form-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.vpn-modal-overlay .form-input::placeholder {
    color: #94a3b8;
}

.vpn-modal-overlay .input-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    display: flex;
    align-items: center;
}

/* Текстовый разделитель ИЛИ */
.vpn-modal-overlay .divider {
    display: flex;
    align-items: center;
    text-align: center;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin: 16px 0;
}
.vpn-modal-overlay .divider::before, .vpn-modal-overlay .divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e2e8f0;
}
.vpn-modal-overlay .divider:not(:empty)::before { margin-right: 14px; }
.vpn-modal-overlay .divider:not(:empty)::after { margin-left: 14px; }

/* Главная синяя кнопка (В цвет кнопок «Скачать для ПК» на вашем сайте) */
.vpn-modal-overlay .submit-btn {
    width: 100%;
    background-color: #4285f4; /* Фирменный синий Happ */
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 14px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
    box-shadow: 0 4px 6px -1px rgba(66, 133, 244, 0.2);
}
.vpn-modal-overlay .submit-btn:hover {
    background-color: #3370d4;
    box-shadow: 0 6px 12px -1px rgba(66, 133, 244, 0.3);
}
.vpn-modal-overlay .submit-btn:disabled {
    background-color: #cbd5e1;
    color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
}

/* 6. Блок успешного вывода ключа */
.vpn-modal-overlay .result-block {
    margin-top: 20px;
    padding: 16px;
    background-color: #f0fdf4; /* Светло-зеленый фон успеха */
    border: 1px solid #bbf7d0;
    border-radius: 12px;
}

.vpn-modal-overlay .result-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #16a34a;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 12px;
}

.vpn-modal-overlay .pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #16a34a;
    border-radius: 50%;
    animation: vpnPulseLight 2s infinite;
}

.vpn-modal-overlay .result-body-layout {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vpn-modal-overlay .result-label {
    font-size: 12px;
    color: #475569;
}

.vpn-modal-overlay .result-input-full {
    width: 100%;
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    color: #2563eb;
    font-family: monospace;
    outline: none;
    text-align: center;
    font-weight: 600;
}

/* Две кнопки под ключом */
.vpn-modal-overlay .result-buttons-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.vpn-modal-overlay .action-btn {
    border-radius: 8px;
    padding: 11px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: center;
}
.vpn-modal-overlay .action-btn:active { transform: scale(0.98); }

/* Копировать (Нейтральная серая кнопка) */
.vpn-modal-overlay .copy-action {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
}
.vpn-modal-overlay .copy-action:hover { background-color: #e2e8f0; }

/* Открыть (Нежно-синяя кнопка) */
.vpn-modal-overlay .open-action {
    background-color: #eff6ff;
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
}
.vpn-modal-overlay .open-action:hover { background-color: #dbeafe; }

/* Блок ошибок */
.vpn-modal-overlay .error-block {
    margin-top: 16px;
    padding: 12px;
    background-color: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 12px;
    font-size: 12px;
    color: #dc2626;
    text-align: center;
    font-weight: 600;
}

.vpn-modal-overlay .hidden { display: none !important; }

@keyframes vpnPulseLight {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.5); }
    70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(22, 163, 74, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

/* ==========================================================================
   СТИЛИ ИНФОРМАЦИОННОГО БЛОКА ПОСЛЕ ВЫДАЧИ КЛЮЧА
   ========================================================================== */

.vpn-modal-overlay .info-block {
    margin-top: 14px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Строка предупреждения */
.vpn-modal-overlay .info-warning {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 12px;
    background-color: #fffbeb; /* Нежно-желтый фоновый оттенок */
    border: 1px solid #fef3c7;
    border-radius: 10px;
    color: #b45309; /* Приглушенный янтарный цвет текста */
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
}

.vpn-modal-overlay .warning-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-top: 1px;
}

/* Секция покупки */
.vpn-modal-overlay .purchase-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.vpn-modal-overlay .purchase-label {
    font-size: 13px;
    color: #475569;
    font-weight: 500;
}

/* Две кнопки покупки в ряд */
.vpn-modal-overlay .purchase-buttons-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

/* Стилизация ссылок-кнопок аналогично кнопкам действий */
.vpn-modal-overlay .purchase-buttons-row .action-btn {
    text-decoration: none;
    display: block;
    border-radius: 8px;
    padding: 11px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    transition: all 0.15s ease;
}

/* Кнопка TG-бот (Светло-синяя, брендовая) */
.vpn-modal-overlay .bot-action {
    background-color: #eff6ff;
    color: #2563eb;
    border: 1px solid #bfdbfe;
}
.vpn-modal-overlay .bot-action:hover {
    background-color: #dbeafe;
}

/* Кнопка WEB-кабинет (Нейтральная серая с акцентом) */
.vpn-modal-overlay .web-action {
    background-color: #f8fafc;
    color: #334155;
    border: 1px solid #e2e8f0;
}
.vpn-modal-overlay .web-action:hover {
    background-color: #f1f5f9;
}

/* Подвал с поддержкой */
.vpn-modal-overlay .support-footer {
    text-align: center;
    font-size: 12px;
    color: #64748b;
    border-top: 1px solid #f1f5f9;
    padding-top: 14px;
    margin-top: 4px;
    line-height: 1.4;
}

.vpn-modal-overlay .support-link {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.15s ease;
}

.vpn-modal-overlay .support-link:hover {
    color: #1d4ed8;
    text-decoration: underline;
}


