/* === VISUAL CODE: HIPPIE ZEN === */
:root {
    --bg-gradient: linear-gradient(135deg, #fff9c4 0%, #ffecb3 50%, #ffe0b2 100%);
    --card-bg: rgba(255, 255, 255, 0.85);
    --text-main: #4e342e;
    --text-muted: #795548;
    --accent: #ff9800;
    --accent-hover: #f57c00;
    --green: #66bb6a;
    --border-radius: 24px;
    --btn-radius: 50px;
    --shadow: 0 8px 32px rgba(78, 52, 46, 0.08);
    --font-main: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --container-width: 1100px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background: var(--bg-gradient);
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* === NAVIGATION === */
.navbar-wrapper {
    background: rgba(255, 249, 196, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(78, 52, 46, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.logo img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.nav-links { display: flex; gap: 24px; }
.nav-link {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    transition: color 0.2s;
    cursor: pointer;
}
.nav-link:hover, .nav-link.active { color: var(--accent); }

.auth-buttons { display: flex; gap: 12px; }

.btn {
    padding: 10px 24px;
    border-radius: var(--btn-radius);
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    font-size: 0.95rem;
}
.btn-primary {
    background: var(--accent);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-2px); }
.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 2px solid rgba(78, 52, 46, 0.2);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

/* === MAIN CONTAINER === */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 40px 24px;
}

/* === SPA LOGIC === */
.page { display: none; animation: fadeIn 0.4s ease; }
.page.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* === HERO === */
.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    margin-bottom: 60px;
}
.hero-text h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 20px;
    color: var(--text-main);
}
.hero-text p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 32px;
    max-width: 480px;
}
.hero-img {
    width: 100%;
    max-width: 500px;
    height: auto;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.1));
    animation: float 6s ease-in-out infinite;
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

/* === MARQUEE === */
.marquee-container {
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50px;
    padding: 12px 0;
    margin-bottom: 60px;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.03);
}
.marquee-content {
    display: inline-block;
    animation: scroll 30s linear infinite;
}
.marquee-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-right: 40px;
    font-weight: 700;
    color: var(--text-main);
    font-size: 1.1rem;
}
.marquee-item img { width: 32px; height: 32px; object-fit: contain; }
@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* === STATS === */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}
.stat-card {
    background: var(--card-bg);
    padding: 24px;
    border-radius: var(--border-radius);
    text-align: center;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}
.stat-card:hover { transform: translateY(-5px); }
.stat-value {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 8px;
    font-family: monospace;
}
.stat-label { font-size: 0.9rem; color: var(--text-muted); font-weight: 600; }

/* === WITHDRAWALS TABLE === */
.withdrawals-section {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 30px;
    margin-bottom: 80px;
    box-shadow: var(--shadow);
}
.withdrawals-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.live-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--green);
    font-weight: bold;
}
.pulse-dot {
    width: 8px;
    height: 8px;
    background: var(--green);
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(102, 187, 106, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(102, 187, 106, 0); }
    100% { box-shadow: 0 0 0 0 rgba(102, 187, 106, 0); }
}

.table-responsive { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 600px; }
th { text-align: left; padding: 12px; color: var(--text-muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; border-bottom: 2px solid rgba(0,0,0,0.05); }
td { padding: 14px 12px; border-bottom: 1px solid rgba(0,0,0,0.05); font-size: 0.95rem; }
tr:last-child td { border-bottom: none; }
.coin-badge {
    background: rgba(255, 152, 0, 0.1);
    color: var(--accent);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
}
.new-row { animation: highlight 2s ease; }
@keyframes highlight {
    0% { background: rgba(102, 187, 106, 0.2); }
    100% { background: transparent; }
}

/* === FEATURES === */
.features { margin-bottom: 80px; }
.section-title { font-size: 2rem; margin-bottom: 12px; text-align: center; }
.section-subtitle { text-align: center; color: var(--text-muted); margin-bottom: 40px; }
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}
.feature-card {
    background: var(--card-bg);
    padding: 32px 24px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: transform 0.2s;
    text-align: center;
}
.feature-card:hover { transform: translateY(-5px); }
.feature-icon { 
    width: 80px; 
    height: 80px; 
    margin: 0 auto 20px; 
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}
.feature-title { font-size: 1.2rem; font-weight: 700; margin-bottom: 12px; }
.feature-desc { font-size: 0.95rem; color: var(--text-muted); }

/* === STEPS === */
.steps { margin-bottom: 80px; }
.steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    position: relative;
}
.step-item { text-align: center; position: relative; z-index: 2; }
.step-img {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}
.step-num {
    font-size: 3rem;
    font-weight: 900;
    color: rgba(255, 152, 0, 0.15);
    line-height: 1;
    margin-bottom: -15px;
}
.step-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 12px; }
.step-desc { color: var(--text-muted); font-size: 0.95rem; }

/* === CTA SECTION === */
.cta-section {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 60px 40px;
    text-align: center;
    box-shadow: var(--shadow);
    margin-bottom: 60px;
    position: relative;
    overflow: hidden;
}
.cta-content {
    position: relative;
    z-index: 2;
    max-width: 500px;
    margin: 0 auto;
    padding: 0 20px;
}
.cta-section h2 { font-size: 2.2rem; margin-bottom: 16px; }
.cta-section p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 32px; }

.faucet-decor {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 280px;
    height: auto;
    opacity: 0.9;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.1));
    z-index: 1;
    pointer-events: none;
}
.faucet-left { left: 20px; }
.faucet-right { right: 20px; }

/* === INNER PAGES STYLES === */
.inner-page { max-width: 800px; margin: 0 auto; }
.inner-page h2 { font-size: 2rem; margin-bottom: 16px; }
.inner-page h3 { font-size: 1.3rem; margin: 32px 0 12px; color: var(--text-main); }
.inner-page p { margin-bottom: 16px; color: var(--text-muted); line-height: 1.7; }
.inner-page ul { margin-bottom: 16px; padding-left: 24px; color: var(--text-muted); }
.inner-page li { margin-bottom: 8px; }

.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; font-size: 0.9rem; }
.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(78, 52, 46, 0.2);
    border-radius: 12px;
    background: rgba(255,255,255,0.8);
    font-size: 1rem;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.2s;
}
.form-input:focus { border-color: var(--accent); }
.form-btn { width: 100%; margin-top: 10px; }

.faq-item { margin-bottom: 16px; border-bottom: 1px solid rgba(0,0,0,0.05); padding-bottom: 16px; }
.faq-q { font-weight: 700; margin-bottom: 8px; color: var(--text-main); }
.faq-a { color: var(--text-muted); font-size: 0.95rem; }

.page-art {
    width: 100%;
    max-width: 400px;
    margin: 30px auto;
    display: block;
    filter: drop-shadow(0 8px 16px rgba(0,0,0,0.1));
}

/* === AD BANNERS GRID (FIXED SIZE 468x60 + PERFECT BUTTONS) === */
.ad-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 60px;
    margin-bottom: 40px;
    justify-items: center;
}

.ad-slot {
    width: 468px;
    height: 60px;
    background: rgba(255, 255, 255, 0.5);
    border: 2px dashed var(--accent);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    
    /* Разрешаем контенту выходить за рамки для кнопки */
    overflow: visible !important; 
    
    transition: all 0.3s ease;
}

/* Кнопка-крестик (ИДЕАЛЬНО ЦЕНТРИРОВАННАЯ ЧЕРЕЗ CSS) */
.ad-close-btn {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 20px;
    height: 20px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    
    /* ГЛАВНОЕ: слой поверх всего */
    z-index: 100;    
    
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    text-decoration: none;
    
    /* Обводка цветом фона страницы для чистого визуального разделения */
    border: 2px solid #ffecb3; 
    
    /* Убираем текст и делаем контейнер гибким */
    font-size: 0; 
    line-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Рисуем идеальный крестик через CSS */
.ad-close-btn::before,
.ad-close-btn::after {
    content: '';
    position: absolute;
    background: white;
    width: 10px;   /* Длина лучей крестика */
    height: 2px;   /* Толщина лучей крестика */
    border-radius: 1px;
}

.ad-close-btn::before { transform: rotate(45deg); }
.ad-close-btn::after { transform: rotate(-45deg); }

.ad-close-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.1);
    z-index: 105;
}

/* Стили для содержимого внутри слота */
.ad-slot img, 
.ad-slot iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
    position: relative;
    z-index: 1; /* Картинка ниже кружочка */
}

/* === FOOTER === */
footer {
    border-top: 1px solid rgba(78, 52, 46, 0.1);
    padding: 40px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}
.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 12px;
    font-size: 1.2rem;
}
.footer-logo img { width: 28px; height: 28px; }

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .hero { grid-template-columns: 1fr; text-align: center; }
    .hero-text p { margin: 0 auto 32px; }
    .hero-img { margin: 0 auto; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .steps-container { grid-template-columns: 1fr; gap: 40px; }
    
    .faucet-decor { width: 180px; }
    .faucet-left { left: 10px; }
    .faucet-right { right: 10px; }
}

@media (max-width: 768px) {
    .nav-links { display: none; }
    .hero-text h1 { font-size: 2.5rem; }
    
    .faucet-decor { display: none !important; }
    
    /* На планшетах и мобильных баннеры становятся в 1 колонку */
    .ad-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    /* Адаптив для баннеров на узких экранах */
    .ad-slot {
        width: 100%;
        max-width: 468px;
        height: auto;
        aspect-ratio: 468 / 60;
    }
}

@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr; }
    .hero-text h1 { font-size: 2rem; }
    .btn { width: 100%; margin-bottom: 10px; }
    .auth-buttons { flex-direction: column; width: 100%; }
    .navbar { padding: 12px 16px; }
    .container { padding: 24px 16px; }
    .cta-section { padding: 40px 20px; }
}

.alert {
  background: rgba(255, 83, 112, 0.1);
  border: 1px solid rgba(255, 83, 112, 0.25);
  color: var(--red);
  padding: 8px;
}

.eye {
  position: absolute;
  right: 13px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 16px;
  padding: 3px;
  line-height: 1;
  transition: color 0.2s;
}
.eye:hover {
  color: #fff;
}
.strength-bars {
  display: flex;
  gap: 4px;
  margin-top: 7px;
}
.sb {
  height: 3px;
  flex: 1;
  border-radius: 2px;
  background: var(--border);
  transition: background 0.25s;
}
.sh {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
  min-height: 14px;
}