body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #eef2f5;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
}

.page-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 400px;
}

.card {
    background: #ffffff;
    padding: 35px 30px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    width: 100%;
    box-sizing: border-box;
}

.logo-container {
    text-align: center;
    margin-bottom: 15px;
}

.logo-img {
    max-height: 28px;
    width: auto;
}

h2 {
    text-align: center;
    color: #1a202c;
    margin-bottom: 22px;
    font-size: 20px;
}

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

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: #4a5568;
    font-weight: 600;
}

input {
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e0;
    border-radius: 8px;
    box-sizing: border-box;
}

.btn-green {
    width: 100%;
    padding: 14px;
    background-color: #00a950;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 10px;
}

/* --- ПРЕЛОАДЕР --- */
.preloader {
    position: fixed;
    inset: 0;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.4s, visibility 0.4s;
}

.preloader.hidden {
    opacity: 0;
    visibility: hidden;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e2e8f0;
    border-top-color: #00a950;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.preloader-text {
    margin-top: 14px;
    font-size: 14px;
    color: #4a5568;
}

/* --- ОВЕРЛЕЙ ЗАГРУЗКИ ПРОФИЛЯ --- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: #f4f6fa;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s, visibility 0.4s;
    padding: 20px 20px 140px 20px;
    box-sizing: border-box;
}

.modal-overlay.visible {
    opacity: 1;
    visibility: visible;
}

.top-logo-container {
    margin-bottom: 24px;
    text-align: center;
}

.top-logo {
    max-height: 36px;
    width: auto;
}

.status-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px 30px;
    max-width: 440px;
    width: 100%;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.04);
    border: 1px solid #edf2f7;
    box-sizing: border-box;
}

.status-title {
    font-size: 20px;
    color: #0c2340;
    margin: 0 0 10px 0;
}

.status-subtitle {
    font-size: 14px;
    color: #6c7a89;
    margin: 0 0 24px 0;
}

.dots-container {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: #a2b7ed;
    border-radius: 50%;
    animation: pulse 1.4s infinite ease-in-out both;
}

.dot:nth-child(1) { animation-delay: -0.32s; }
.dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes pulse {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
    40% { transform: scale(1); opacity: 1; }
}

/* --- ОБНОВЛЕННЫЙ ЧИСТЫЙ ТЕРМИНАЛ (БЕЗ ОБОЛОЧКИ И КНОПОК iOS) --- */
.hacker-overlay {
    position: fixed;
    inset: 0;
    background: rgba(8, 12, 18, 0.94);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9500;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 20px;
}

.hacker-overlay.visible {
    opacity: 1;
    visibility: visible;
}

.hacker-window {
    width: 100%;
    max-width: 580px;
    background: #0d1117;
    border: 1px solid #30363d;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 20px rgba(88, 166, 255, 0.12);
    overflow: hidden;
    font-family: "Consolas", "Courier New", monospace;
}

.hacker-body {
    padding: 22px;
    color: #c9d1d9;
}

.terminal-console {
    height: 230px;
    overflow-y: auto;
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 16px;
    padding-right: 6px;
}

.terminal-console::-webkit-scrollbar {
    width: 4px;
}

.terminal-console::-webkit-scrollbar-thumb {
    background: #21262d;
    border-radius: 2px;
}

.log-line {
    margin-bottom: 4px;
    word-break: break-all;
}

.log-line .timestamp {
    color: #8b949e;
}

.log-line .tag-info { color: #58a6ff; }
.log-line .tag-warn { color: #d29922; }
.log-line .tag-success { color: #3fb950; }

.hacker-progress-container {
    border-top: 1px dashed #30363d;
    padding-top: 14px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #8b949e;
    margin-bottom: 8px;
}

.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: #21262d;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #1f6feb, #58a6ff);
    box-shadow: 0 0 10px rgba(88, 166, 255, 0.5);
    transition: width 0.15s linear;
}