body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
  overflow: hidden; /* Запрещает прокрутку */
    -webkit-overflow-scrolling: touch; /* Отключаем эффект резинового скролла на iOS */
    touch-action: none; 
    background: linear-gradient(
        135deg,
        #667eea,  /* Голубой */
        #764ba2,  /* Фиолетовый */
        #f472b6,  /* Розовый */
        #fbbf24,  /* Жёлтый */
        #34d399,  /* Зелёный */
        #60a5fa,  /* Светло-голубой */
        #ec4899,  /* Ярко-розовый */
        #10b981,  /* Изумрудный */
        #f97316,  /* Оранжевый */
        #3b82f6   /* Синий */
    );
    background-size: 800% 800%;
    animation: gradientAnimation 60s linear infinite;
    
}

@keyframes gradientAnimation {
    0% { background-position: var(--start-x) var(--start-y); }
    50% { background-position: 100% 100%; }
    100% { background-position: var(--start-x) var(--start-y); }
}

.container {
    max-width: 450px;
    background: rgba(255, 255, 255, 0.85);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    text-align: center;
    max-height: 500px; /* Минимальная высота для пустого контейнера */
    min-height: 500px; /* Гарантируем, что контейнер виден */
    overflow: hidden;
    width: 90%;
    max-width: 600px;
    min-width: 400px;
    margin: 0 auto;
    box-sizing: border-box;
    backdrop-filter: blur(10px);
    scrollbar-width: none;
    -ms-overflow-style: none;
    transition: max-height 0.3s ease, transform 0.3s ease;
     animation: fadeIn 0.6s ease;
}

.container.expanded {
    max-height: 90vh; /* Раскрываем для номеров */
    overflow-y: auto;
}



@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

 .provider-switcher {
            padding: 5px;
            animation: fadeIn 0.6s ease;
            animation-delay: 0.1s;
            animation-fill-mode: both;
        }

        .provider-switcher label {
            display: block;
            font-size: 16px;
            font-weight: 600;
            color: #495057;
            margin-bottom: 12px;
        }

        .provider-tags {
            display: flex;
            gap: 10px;
            justify-content: center;
            align-items: center;
            margin-top: 10px;
        }

        .provider-tag {
             display: flex; /* меняем с inline-block на flex */
    justify-content: center; /* по горизонтали */
    align-items: center;     /* по вертикали */
            background: #f8f9fa;
            padding: 8px 16px;
            border-radius: 8px;
            font-size: 14px;
             width: 65px; /* Ширина 100 пикселей */
        height: 25px; /* Высота 50 пикселей */
            color: #6c757d;
            border: 2px solid transparent;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .provider-tag.active {
            background: #e3f2fd;
            color: #1976d2;
            border-color: #bbdefb;
        }


 .dark-mode .provider-tag {
            background: #33334d;
            color: #adb5bd;
        }

        .dark-mode .provider-tag.active {
            background: #1e3a5f;
            color: #64b5f6;
            border-color: #1976d2;
        }












h1 {
    font-size: 24px;
    color: #1f2937;
    margin: 0 0 20px;
    font-weight: 600;
}

label {
    font-size: 14px;
    color: #4b5563;
    margin: 5px 0;
    display: block;
    text-align: left;
}

.select-wrapper {
    position: relative;
    width: 100%;
}

.select-wrapper.no-arrow::after {
    display: none;
}

select {
    width: 100%;
    padding: 12px 30px 12px 12px; /* Adjusted padding for arrow */
    font-size: 14px;
    border: 1px solid #e2e8f0; /* Subtle border */
    border-radius: 8px;
    box-sizing: border-box;
    margin-top: 8px;
    background: #fcfcfd; /* Fully opaque for white theme */
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none; /* Remove default browser styling */
     box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    /* Плавный переход для тени и других свойств */
    transition: all 0.3s ease, box-shadow 0.3s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.select-wrapper::after {
    content: '';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 5px transparent solid;
    border-right: 5px transparent solid;
    border-top: 5px solid #374151; /* Minimalist arrow */
    pointer-events: none; /* Prevent interaction with arrow */
}

select:focus {
    outline: none;
    border-color: #667eea; /* Highlight on focus */
    box-shadow: 0 0 5px rgba(102, 126, 234, 0.3);
}

button {
    padding: 10px;
    font-size: 14px;
    border: none;
    border-radius: 8px;
    box-sizing: border-box;
    margin: 5px 5px 0 0;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    color: white;
    margin-top: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
     animation: fadeIn 0.6s ease;
animation-fill-mode: both;
}

button[onclick="getNumber()"] {
    width: 60%;
    padding: 10px;
    background: linear-gradient(90deg, #ec4899, #db2777);
    margin: 15px auto 0;
    display: block;
}

button.small-btn {
    padding: 6px 12px;
    font-size: 12px;
    background: linear-gradient(90deg, #10b981, #059669);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    color: white;
    border: none;
    cursor: pointer;
    height: 28px;
    width: 38px;
    line-height: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
}

button.small-btn.close-btn {
    background: linear-gradient(90deg, #ef4444, #dc2626);
}

button:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

button[onclick="getNumber()"]:hover {
    background: linear-gradient(90deg, #db2777, #be185d);
}

button.small-btn:hover {
    background: linear-gradient(90deg, #059669, #047857);
}

button.small-btn.close-btn:hover {
    background: linear-gradient(90deg, #dc2626, #b91c1c);
}

.number, .message, .balance, .error {
    margin-top: 15px;
    font-size: 16px;
    color: #1f2937;
    overflow-y: auto;
    animation: fadeIn 0.6s ease;
    animation-fill-mode: both;
}

.number-item {
    margin: 11px 0;
    padding: 6px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    text-align: center;
    opacity: 1;
    height: auto;
    transition: opacity 0.5s ease, height 0.5s ease;
}


.number-item .header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.number-item .service {
    display: flex;
    align-items: center;
}

.number-item .timer {
    font-size: 12px;
    color: #4b5563;
}

.number-item .phone-line {
    margin: 0;
    line-height: 1.1;
    height: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.number-item .bold-phone {
    font-weight: bold;
}

.number-item .close-icon {
    display: inline-block;
    margin-left: 5px;
    vertical-align: middle;
}

.number-item .close-icon img {
    width: 20px;
    height: 20px;
}

.number-item .sms-line {
    margin: 6px 0 0 0;
}

.number-item .sms-code {
    display: block;
}

.number-item br {
    display: none;
}

.service-icon {
    width: 20px;
    height: 20px;
    vertical-align: middle;
    margin-right: 5px;
    border-radius: 4px;
}

.bold-phone {
    font-weight: 700;
}

.controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 5px 0;
}

.balance {
    font-weight: 500;
    font-weight: bold;
    color: #16a34a;
}

.error {
    color: #dc2626;
    font-size: 14px;
}

html, body {
    overflow: hidden;
    height: 100%;
}

.balance-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.history-icon {
    display: none;
}

.modal {
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: none;
    z-index: 1000; /* поверх всего */
}

.modal.show {
    display: block;
    opacity: 1;
}

.modal-content {
    background: #fff;
    margin: 15% auto;
    padding: 20px;
    border-radius: 11px;
    width: 85%;
    max-width: 400px;
    max-height: 83vh;
    overflow-y: auto;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
      z-index: 1001; /* поверх всего */
          scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

.modal.show .modal-content {
    transform: translateY(0);
}

.right-controls {
    display: flex;
    align-items: center;
}

.close {
    color: #aaa;
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover,
.close:focus {
    color: #000;
    text-decoration: none;
}

.history-item {
    margin: 10px 0;
    padding: 10px;
    background: #f9fafb;
    border-radius: 5px;
    text-align: left;
}

.pagination {
    margin-top: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.pagination button {
    padding: 6px 12px;
    font-size: 12px;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

.pagination button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.sms-code {
    font-weight: 700;
    color: #2c5282;
    background: #e6fffa;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
}

body, .container {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.provider-switcher {
    margin: 10px 0;
    text-align: left;
}

.provider-switcher label {
    margin-bottom: 5px;
}

.provider-switcher .select-wrapper {
    width: 100%;
}

.provider-switcher select {
    width: 100%;
    padding: 12px 30px 12px 12px;
    font-size: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #ffffff; /* Fully opaque */
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
}

.provider-switcher select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 5px rgba(102, 126, 234, 0.3);
}

.select-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin: 10px 0 30px 0;
    padding: 0 10px;
}

.select-group {
    display: flex;
    flex-direction: column;
    width: 45%;
    max-width: 180px;
    align-items: center;
}

.select-group label {
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 5px;
    white-space: nowrap;
    text-align: center;
    width: 100%;
}

.select-group select {
    width: 100%;
            padding: 13px;
            border: 2px solid #e9ecef;
            border-radius: 12px;
            font-size: 14px;
            background: #f8f9fa;
            transition: all 0.2s ease;
            appearance: none;
            cursor: pointer;
            animation: fadeIn 0.6s ease;
animation-fill-mode: both;
}

.select-group .select-wrapper::after {
    right: 8px; /* Adjust arrow position for smaller selects */
}

.search-input {
    width: 100%;
    padding: 10px;
    margin: 5px 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    box-sizing: border-box;
    background: #f9fafb;
    transition: border-color 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    background: #fff;
}

.flag-container {
    display: flex;
    justify-content: center;
    margin: 1px 0;
    height: 20px;
    line-height: 15px;
}

.country-flag {
    width: 20px;
    height: 15px;
}

body.dark-mode {
    background: linear-gradient(
        135deg,
        #1a1a2e,
        #16213e,
        #0f3460,
        #53354a,
        #2d1e2f
    );
    background-size: 800% 800%;
    animation: gradientAnimation 35s linear infinite;
    color: #e0e0e0;
}

body.dark-mode .container {
    background: rgba(30, 30, 46, 0.95);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
}

body.dark-mode select {
    background: #33334d;
    color: #e0e0e0;
    border: 1px solid #444;
    box-shadow: 0 2px 4px rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease, box-shadow 0.3s ease;
}


body.dark-mode .select-wrapper::after {
    border-top-color: #e0e0e0; /* Arrow color for dark mode */
}

body.dark-mode select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 5px rgba(96, 165, 250, 0.3);
}

body.dark-mode button {
    background: #4a4e69;
}

body.dark-mode button:hover {
    background: #5c6287;
}

body.dark-mode button:disabled {
    background: #3a3a4e;
}

body.dark-mode .number {
    color: #e0e0e0;
}

body.dark-mode .number-item {
    background: #2a2a3b;
    border: 1px solid #444;
    color: #e0e0e0;
}

body.dark-mode .balance,
body.dark-mode .error,
body.dark-mode .message,
body.dark-mode label {
    color: #e0e0e0;
}

body.dark-mode .error {
    color: #ff6b6b;
}

body.dark-mode .modal-content {
    background: #2a2a3b;
    color: #e0e0e0;
}

body.dark-mode .history-item {
    border: 1px solid #444;
    background: #33334d;
}

body.dark-mode .bold-phone {
    color: #e0e0e0;
    text-decoration: none;
}

body.dark-mode .sms-code {
    color: #60a5fa;
    background: #1e3a8a;
}

body.dark-mode .search-input {
    background: #33334d;
    border-color: #444;
    color: #e0e0e0;
}

body.dark-mode .search-input:focus {
    border-color: #60a5fa;
    background: #3a3a5c;
}

.error-message {
    color: red;
    font-size: 14px;
    margin-top: 10px;
    text-align: center;
}

#loadingSpinner {
    display: none;
    width: 20px;
    height: 20px;
}


.menu-btn {
    padding: 6px 12px;
    background: linear-gradient(90deg, #10b981, #059669);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: none;
    cursor: pointer;
    height: 28px;
    width: 38px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.menu-btn:hover {
    background: linear-gradient(90deg, #059669, #047857);
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

.burger-icon {
    width: 24px;
    height: 14px;
    position: relative;
    display: block;
}

.burger-icon::before,
.burger-icon::after,
.burger-icon .middle-line {
    content: '';
    position: absolute;
    width: 100%;
    height: 3px;
    background: white;
    border-radius: 5px;
    left: 0;
    transition: all 0.3s ease;
}

.burger-icon::before {
    top: 0;
}

.burger-icon .middle-line {
    top: 5.5px;
}

.burger-icon::after {
    bottom: 0;
}

.menu-btn:hover .burger-icon::before {
    transform: translateY(-1px);
}

.menu-btn:hover .burger-icon::after {
    transform: translateY(1px);
}

body.dark-mode .menu-btn {
    background: #4a4e69;
}

body.dark-mode .menu-btn:hover {
    background: #5c6287;
}

body.dark-mode .burger-icon::before,
body.dark-mode .burger-icon::after,
body.dark-mode .burger-icon .middle-line {
    background: #e0e0e0;
}

.menu-modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0s linear 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
}

.menu-modal.show {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0s linear 0s;
}

.menu-content {
    background: rgba(255, 255, 255, 0.95);
    padding: 25px 20px 20px 20px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    width: 220px;
    height: 240px;
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    backdrop-filter: blur(5px);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.menu-modal.show .menu-content {
    transform: scale(1);
    opacity: 1;
}

.menu-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    text-align: center;
}

.menu-item {
    padding: 10px 15px;
    font-size: 14px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    font-weight: 500;
    width: 100%;
    box-sizing: border-box;
}

.menu-item:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.close {
    color: #aaa;
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 26px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover,
.close:focus {
    color: #000;
}

body.dark-mode .menu-content {
    background: rgba(30, 30, 46, 0.95);
}

body.dark-mode .menu-item {
    background: #4a4e69;
    color: #e0e0e0;
}

body.dark-mode .menu-item:hover {
    background: #5c6287;
}

body.dark-mode .close {
    color: #ccc;
}

body.dark-mode .close:hover,
body.dark-mode .close:focus {
    color: #fff;
}

#loungeModal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: none;
}

#loungeModal.show {
    display: block;
    opacity: 1;
}

.lounge-modal-content {
    background: rgba(255, 255, 255, 0.95);
    margin: 15% auto;
    padding: 20px;
    border-radius: 11px;
    width: 80%;
    max-width: 400px;
    max-height: 75vh;
    overflow-y: auto;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    backdrop-filter: blur(5px);
    text-align: center;
    z-index: 1000;
}

#loungeModal.show .lounge-modal-content {
    transform: translateY(0);
}

.lounge-modal-content .close {
    color: #aaa;
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.lounge-modal-content .close:hover,
.lounge-modal-content .close:focus {
    color: #000;
}

.lounge-modal-content h2 {
    font-size: 20px;
    color: #1f2937;
    margin: 0 0 15px;
    font-weight: 600;
}

.lounge-modal-content p {
    font-size: 14px;
    color: #4b5563;
    margin: 5px 0;
}

.lounge-modal-content input[type="file"] {
    width: 100%;
    max-width: 100%;
    padding: 10px;
    font-size: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin: 10px 0;
    background: #f3f4f6;
    color: #374151;
    cursor: pointer;
    box-sizing: border-box;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lounge-modal-content input[type="file"]::-webkit-file-upload-button {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lounge-modal-content input[type="file"]::-webkit-file-upload-button:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
}

.lounge-info {
    background: #f3f4f6;
    border-radius: 8px;
    padding: 10px;
    margin: 10px 0;
    text-align: left;
}

.lounge-info h3 {
    font-size: 16px;
    color: #1f2937;
    margin: 0 0 5px;
    font-weight: 600;
}

.lounge-info p {
    font-size: 14px;
    color: #4b5563;
    margin: 5px 0;
}

.lounge-card {
    background: linear-gradient(180deg, #ffffff, #f9fafb);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    margin: 10px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    text-align: left;
}

.lounge-card h3 {
    font-size: 18px;
    color: #1f2937;
    margin: 0 0 10px;
    font-weight: 700;
    border-bottom: 2px solid #3b82f6;
    padding-bottom: 5px;
}

.lounge-status {
    font-size: 18px;
    font-weight: 600;
    padding: 10px;
    border-radius: 8px;
    margin: 10px 0;
    text-align: center;
    background: linear-gradient(90deg, #10b981, #059669);
    color: white;
}

.lounge-status.no-access {
    background: linear-gradient(90deg, #ef4444, #dc2626);
}

.lounge-status img {
    width: 24px;
    height: 24px;
    vertical-align: middle;
    margin-right: 5px;
}

.projection-list {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.projection-list li {
    background: #f9fafb;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 10px;
    font-size: 14px;
    color: #4b5563;
}

.projection-list li span.amount {
    font-weight: 600;
    color: #3b82f6;
}

body.dark-mode #loungeModal .lounge-modal-content {
    background: rgba(30, 30, 46, 0.95);
    color: #e0e0e0;
}

body.dark-mode .lounge-modal-content .close {
    color: #ccc;
}

body.dark-mode .lounge-modal-content .close:hover,
body.dark-mode .lounge-modal-content .close:focus {
    color: #fff;
}

body.dark-mode .lounge-modal-content h2 {
    color: #e0e0e0;
}

body.dark-mode .lounge-modal-content p {
    color: #d1d5db;
}

body.dark-mode .lounge-modal-content input[type="file"] {
    background: #2a2a3b;
    color: #e0e0e0;
    border: 1px solid #444;
}

body.dark-mode .lounge-modal-content input[type="file"]::-webkit-file-upload-button {
    background: #4a4e69;
}

body.dark-mode .lounge-modal-content input[type="file"]::-webkit-file-upload-button:hover {
    background: #5c6287;
}

body.dark-mode .lounge-info {
    background: #2a2a3b;
    border: 1px solid #444;
}

body.dark-mode .lounge-info h3 {
    color: #e0e0e0;
}

body.dark-mode .lounge-info p {
    color: #d1d5db;
}

body.dark-mode .lounge-card {
    background: linear-gradient(180deg, #2a2a3b, #33334d);
    border: 1px solid #444;
}

body.dark-mode .lounge-card h3 {
    color: #e0e0e0;
    border-bottom: 2px solid #60a5fa;
}

body.dark-mode .lounge-status {
    background: linear-gradient(90deg, #10b981, #059669);
    color: #e0e0e0;
}

body.dark-mode .lounge-status.no-access {
    background: linear-gradient(90deg, #ef4444, #dc2626);
}

body.dark-mode .projection-list li {
    background: #33334d;
    border: 1px solid #444;
    color: #d1d5db;
}

body.dark-mode .projection-list li span.amount {
    color: #60a5fa;
}

.lounge-info-card {
    padding: 10px;
    font-size: 17px;
}

.lounge-info-card h3 {
    font-size: 14px;
    margin-bottom: 6px;
}

.lounge-access-period {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px;
    margin-top: 10px;
    border-radius: 6px;
    background: #e8eaf6;
    color: #3f51b5;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    max-width: 300px;
    margin: 10px auto 0;
}

.lounge-access-period strong {
    margin-left: 5px;
    color: #1a237e;
}

body.dark-mode .lounge-access-period {
    background: #303f9f;
    color: #bbdefb;
}

body.dark-mode .lounge-access-period strong {
    color: #e3f2fd;
}

body.dark-mode .separator {
    background: #444;
}

.search-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 10px 0;
}

.autocomplete-wrapper {
    position: relative;
    width: 100%;
    max-width: 250px;
}

.search-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    box-sizing: border-box;
    background: #f9fafb;
    transition: border-color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    background: #fff;
    box-shadow: 0 0 5px rgba(102, 126, 234, 0.5);
}

.autocomplete-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 5px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: none;
    transition: opacity 0.2s ease;
}

.autocomplete-list.show {
    display: block;
}

.autocomplete-item {
    padding: 10px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.autocomplete-item:hover,
.autocomplete-item.active {
    background: #f0f0f0;
}

body.dark-mode .search-input {
    background: #33334d;
    border-color: #444;
    color: #e0e0e0;
}

body.dark-mode .search-input:focus {
    border-color: #60a5fa;
    background: #3a3a5c;
    box-shadow: 0 0 5px rgba(96, 165, 250, 0.5);
}

body.dark-mode .autocomplete-list {
    background: #33334d;
    border-color: #444;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

body.dark-mode .autocomplete-item {
    color: #e0e0e0;
}

body.dark-mode .autocomplete-item:hover,
body.dark-mode .autocomplete-item.active {
    background: #444460;
}

@media (max-width: 600px) {
    .autocomplete-wrapper {
        max-width: 100%;
    }

    .search-container {
        flex-direction: column;
        align-items: center;
    }
}

.separator {
    border: 0;
    height: 1px;
    background: #d1d5db;
    margin: 10px 0;
}

.price-row {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px 0;
    min-height: 40px;
    width: 100%; /* Убедимся, что занимает всю ширину контейнера */
     animation: fadeIn 0.6s ease;
animation-fill-mode: both;
}

.price-display {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    background: rgba(230, 255, 250, 0.7); /* Полупрозрачный бирюзовый фон */
    color: #2c5282;
    text-align: center;
    transition: background 0.3s ease, color 0.3s ease;
    width: calc(65% - 40px); /* Почти вся ширина с отступами */
    max-width: 560px; /* Ограничение по ширине контейнера */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(5px); /* Blur-эффект */
    -webkit-backdrop-filter: blur(5px); /* Для совместимости с Safari */
}

.price-display.no-numbers {
    background: rgba(238,79,79, 0.35); /* Полупрозрачный красный фон */
    color: #dc2626;
}

/* Скрываем maxPrice для Online SIM */
#maxPriceSelectWrapper {
    display: none;
}

#maxPriceSelectWrapper.visible {
    display: block;
}

/* Темный режим */
body.dark-mode .price-display {
    background: rgba(30, 58, 138, 0.7); /* Полупрозрачный синий для темного режима */
    color: #60a5fa;
}

body.dark-mode .price-display.no-numbers {
    background: rgba(127, 29, 29, 0.7); /* Полупрозрачный красный для темного режима */
    color: #ff6b6b;
}
/* Стили для активного режима поиска */
#fullListBtn.menu-item.active-search,
body:not(.dark-mode) #fullListBtn.menu-item.active-search,
body.dark-mode #fullListBtn.menu-item.active-search {
    background: #f1c40f !important; /* Жёлтый фон */
    background-image: none !important; /* Убираем градиент */
    color: #000 !important; /* Чёрный текст */
}


.income-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 7px;
}

.total-balance {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    border-radius: 8px;
    padding: 12px;
    text-align: center;
    color: white;
    font-size: 18px;
    font-weight: 600;
}

.balance-display {
    background: #f3f4f6;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 10;
}
.balance-text {
    font-size: 24px;
    font-weight: 800;
    color: #1f2937;
    letter-spacing: 0.5px;
}

.balance-display span {
    font-size: 16px;
    font-weight: 600;
    color: #10b981;
}

.balance-display.negative span {
    color: #ef4444;
}

.income-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: space-between;
}

.toggle-group {
    flex: 1;
    min-width: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.toggle-label {
    font-size: 14px;
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 6px;
}

.toggle-switch {
    display: flex;
    width: 100%;
    max-width: 160px;
    background: #e2e8f0;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
}

.toggle-option {
    flex: 1;
    padding: 8px;
    text-align: center;
    font-size: 14px;
    color: #4b5563;
    transition: all 0.3s ease;
}

.toggle-option.active {
    background: #10b981;
    color: white;
}

.toggle-switch#personToggle .toggle-option.active {
    background: #3b82f6;
}

.toggle-switch#typeToggle .toggle-option[data-value="expense"].active {
    background: #ef4444;
}

.input-group {
    flex: 1;
    min-width: 200px;
    position: relative;
}

.income-form input {
    width: 100%;
    padding: 10px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    box-sizing: border-box;
    background: #f9fafb;
    transition: border-color 0.3s ease;
}

.income-form input:focus {
    outline: none;
    border-color: #667eea;
    background: #fff;
}

.currency {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 14px;
}

.add-btn {
    width: 100%;
    padding: 10px;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.add-btn:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
    transform: translateY(-1px);
}

.error-message {
    color: #ef4444;
    font-size: 12px;
    text-align: center;
    margin-top: 8px;
}

.income-history {
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
}

.income-history h3 {
    font-size: 16px;
    color: #1f2937;
    margin: 0 0 10px;
    font-weight: 600;
}

.income-history-item {
    margin: 8px 0;
    background: #f9fafb;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    color: #4b5563;
    padding: 10px;
    padding-bottom: 24px;
    min-height: 30px;
    position: relative;
    padding-right: 24px;
}

.income-history-item .amount {
    font-weight: 600;
    color: #10b981;
}

.income-history-item.expense .amount {
    color: #ef4444;
}

.loadMoreBtn {
    display: block;
    margin: 15px auto 0;
    padding: 10px 20px;
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.loadMoreBtn:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
    transform: translateY(-1px);
}

body.dark-mode #incomeModal .modal-content {
    background: rgba(30, 30, 46, 0.95);
    color: #e5e7eb;
}

body.dark-mode .total-balance {
    background: linear-gradient(90deg, #4b5563, #374151);
}

body.dark-mode .balance-display {
    background: #2a2a3b;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid #4b5563;
}

body.dark-mode .income-form {
    background: #2d3748;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 1px solid #4b5563;
}

body.dark-mode .income-form input {
    background: #4b5563;
    border-color: #6b7280;
    color: #e5e7eb;
}

body.dark-mode .income-form input:focus {
    border-color: #60a5fa;
    background: #3a3a5c;
}

body.dark-mode .toggle-label {
    color: #e5e7eb;
}

body.dark-mode .toggle-switch {
    background: #4b5563;
}

body.dark-mode .toggle-option {
    color: #e5e7eb;
}

body.dark-mode .toggle-option.active {
    background: #10b981;
}

body.dark-mode .toggle-switch#personToggle .toggle-option.active {
    background: #3b82f6;
}

body.dark-mode .toggle-switch#typeToggle .toggle-option[data-value="expense"].active {
    background: #ef4444;
}

body.dark-mode .add-btn {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

body.dark-mode .add-btn:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
}

body.dark-mode .income-history {
    background: #2d3748;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 1px solid #4b5563;
}

body.dark-mode .income-history h3 {
    color: #e5e7eb;
}

body.dark-mode .income-history-item {
    background: #4b5563;
    border-color: #6b7280;
    color: #e5e7eb;
}

body.dark-mode .income-history-item .amount {
    color: #10b981;
}

body.dark-mode .income-history-item.expense .amount {
    color: #ef4444;
}

body.dark-mode .loadMoreBtn {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

body.dark-mode .loadMoreBtn:hover {
    background: linear-gradient(90deg, #1d4ed8, #1e40af);
}

@media (max-width: 600px) {
    .balance-display {
        padding: 12px;
    }

    .balance-text {
        font-size: 20px;
    }

    .load-more-btn {
        padding: 8px 16px;
        font-size: 13px;
    }
}

.income-history-item .separator {
    display: block;
    height: 1px;
    background: #e2e8f0;
    margin: 8px 0;
}
.icon-income {
    font-size: 32px;
    display: flex;
 color: #ffffff;
    justify-content: center;
    align-items: center;
    width: 20px;
    height: 20px;
}


.dark-mode-btn {
    position: absolute;
    top: 0; /* Поднимаем кнопку максимально вверх */
    width: 43px;
    height: 38px;
    padding: 0;
    font-size: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(90deg, #6b7280, #4b5563);
    border-radius: 12px;
}

.dark-mode-btn:hover {
    background: linear-gradient(90deg, #4b5563, #374151);
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

body.dark-mode .dark-mode-btn {
    background: linear-gradient(90deg, #9ca3af, #6b7280);
}

body.dark-mode .dark-mode-btn:hover {
    background: linear-gradient(90deg, #6b7280, #4b5563);
}




.plus-btn {
    padding: 6px 12px;
    background: linear-gradient(90deg, #10b981, #059669);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: none;
    cursor: pointer;
    height: 28px;
    width: 38px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.plus-btn:hover {
    background: linear-gradient(90deg, #059669, #047857);
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

.plus-icon {
    position: relative;
    width: 16px;
    height: 16px;
}

.plus-icon .horizontal-line,
.plus-icon .vertical-line {
    position: absolute;
    background-color: white;
    border-radius: 3px; /* для скруглённых концов */
}

.plus-icon .horizontal-line {
    top: 50%;
    left: -5%;
    width: 110%;
    height: 3px;
    transform: translateY(-50%);
}

.plus-icon .vertical-line {
    left: 50%;
    top: 0;
    width: 3px;
    height: 100%;
    transform: translateX(-50%);
}

body.dark-mode .plus-btn {
    background: #4a4e69;
}

body.dark-mode .plus-btn:hover {
    background: #5c6287;
}

body.dark-mode .plus-icon .horizontal-line,
body.dark-mode .plus-icon .vertical-line {
    background-color: #e0e0e0;
}
.edit-icon {
    width: 16px;
    height: 16px;
    transition: opacity 0.2s;
}

.edit-icon:hover {
    opacity: 0.7;
}

.income-history-item small.date {
    position: absolute;
    bottom: 5px;
    left: 5px;
    color: #6b7280;
    font-size: 12px;
}

/* Сохраняем стиль для метки "Изменено" (без изменения) */
.income-history-item small {
    position: absolute;
    bottom: 5px;
    right: 5px;
    color: #6b7280;
}


.notification {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #4caf50;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    font-size: 16px;
    font-weight: 500;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    min-width: 300px; /* Увеличиваем минимальную ширину */
    text-align: center; /* Центрируем текст */
    white-space: nowrap; /* Предотвращаем перенос текста */
}

.notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.notification.hide {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
}

@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

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


.number-item.closing {
    animation: slideOut 0.3s ease forwards;
}
.number-item.slide-up {
    animation: slideUp 0.3s ease forwards;
}
body.dark-mode .number-item.closing {
    animation: slideOut 0.3s ease forwards;
}

