*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg: #0a0a12;
    --surface: #13131e;
    --surface2: #1a1a28;
    --border: #252538;
    --accent: #e1306c;
    --accent2: #833ab4;
    --gold: #ffd700;
    --silver: #b0b8c8;
    --bronze: #cd7f32;
    --text: #eeeef5;
    --muted: #6b6b88;
    --radius: 14px;
}

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* ── Ticker ──────────────────────────────── */
.ticker-wrap {
    background: linear-gradient(90deg, rgba(225,48,108,0.12), rgba(131,58,180,0.12));
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    padding: 9px 0;
    height: 36px;
}

.ticker-track {
    display: flex;
    gap: 0;
    white-space: nowrap;
    width: max-content;
    animation: ticker-scroll 40s linear infinite;
}

.ticker-track:hover { animation-play-state: paused; }

@keyframes ticker-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    font-weight: 600;
    padding: 0 28px;
    color: var(--text);
}

.ticker-item img {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.ticker-dot {
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    flex-shrink: 0;
    animation: pulse-dot 1.4s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.4; transform: scale(0.7); }
}

.ticker-sep { color: var(--border); padding: 0 4px; }

/* ── Header ─────────────────────────────── */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 24px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    gap: 12px;
}

.logo {
    font-size: 20px;
    font-weight: 900;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #e1306c 0%, #833ab4 50%, #405de6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline { font-size: 12px; color: var(--muted); margin-top: 2px; }
.tagline strong { color: var(--text); }

.bid-btn {
    flex-shrink: 0;
    background: linear-gradient(135deg, #e1306c, #833ab4);
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.15s, transform 0.1s;
}
.bid-btn:hover { opacity: 0.88; transform: scale(1.02); }
.bid-btn:active { transform: scale(0.98); }

/* ── Stats bar ───────────────────────────── */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: 40px;
    padding: 24px 16px 8px;
    text-align: center;
}

.stat span {
    display: block;
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -1px;
    background: linear-gradient(135deg, #e1306c, #833ab4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat small {
    display: block;
    font-size: 10px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-top: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.online-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #00e676;
    border-radius: 50%;
    animation: pulse-dot 1.4s ease-in-out infinite;
    flex-shrink: 0;
}

.stat-online span {
    background: linear-gradient(135deg, #00e676, #00bcd4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Activity Feed ───────────────────────── */
.activity-feed {
    max-width: 600px;
    margin: 16px auto 0;
    padding: 0 16px;
}

.activity-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 10px;
}

.live-badge {
    background: var(--accent);
    color: #fff;
    font-size: 9px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 1px;
    animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.65; }
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 200px;
    overflow: hidden;
    position: relative;
}

.activity-list::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 40px;
    background: linear-gradient(transparent, var(--bg));
    pointer-events: none;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 13px;
    animation: slide-in-left 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes slide-in-left {
    from { opacity: 0; transform: translateX(-24px); }
    to   { opacity: 1; transform: translateX(0); }
}

.activity-item img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--border);
}

.activity-item .act-user { font-weight: 700; color: var(--text); }
.activity-item .act-amount { font-weight: 800; color: var(--accent); margin-left: auto; white-space: nowrap; }
.activity-item .act-time { font-size: 11px; color: var(--muted); white-space: nowrap; }

/* ── Leaderboard ─────────────────────────── */
.leaderboard {
    max-width: 600px;
    margin: 16px auto 0;
    padding: 0 16px 100px;
}

.loading {
    text-align: center;
    color: var(--muted);
    padding: 64px 0;
    font-size: 14px;
}

.bid-item {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    margin-bottom: 8px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, background 0.2s, transform 0.15s;
}
.bid-item:hover { border-color: var(--accent); background: var(--surface2); transform: translateX(3px); }
.bid-item:active { transform: translateX(1px); }

.bid-item.rank-1 {
    border-color: rgba(255, 215, 0, 0.6);
    background: linear-gradient(135deg, rgba(255,215,0,0.06), var(--surface));
}
.bid-item.rank-2 { border-color: rgba(176,184,200,0.5); }
.bid-item.rank-3 { border-color: rgba(205,127,50,0.5); }

.rank-num {
    min-width: 38px;
    text-align: center;
    font-size: 20px;
    line-height: 1;
    flex-shrink: 0;
}
.rank-num.plain { font-size: 13px; font-weight: 700; color: var(--muted); }

.avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    flex-shrink: 0;
    background: var(--surface2);
}
.rank-1 .avatar { border-color: var(--gold); box-shadow: 0 0 10px rgba(255,215,0,0.25); }
.rank-2 .avatar { border-color: var(--silver); }
.rank-3 .avatar { border-color: var(--bronze); }

.bid-info { flex: 1; min-width: 0; }

.bid-username {
    font-weight: 700;
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bid-time {
    font-size: 11px;
    color: var(--muted);
    margin-top: 3px;
}

.bid-amount {
    font-weight: 800;
    font-size: 17px;
    color: #fff;
    white-space: nowrap;
    flex-shrink: 0;
}
.rank-1 .bid-amount { color: var(--gold); }

/* ── Modal ───────────────────────────────── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.modal-overlay.hidden { display: none; }

.modal {
    background: var(--surface2);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px 22px 24px;
    width: 100%;
    max-width: 420px;
    position: relative;
    animation: slideUp 0.2s ease;
}

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

.modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    color: var(--muted);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s;
}
.modal-close:hover { color: var(--text); background: var(--border); }

.modal h2 {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #e1306c, #833ab4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 6px;
}

.modal-sub { font-size: 13px; color: var(--muted); line-height: 1.5; margin-bottom: 22px; }

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

.form-group label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 7px;
}

.input-wrap {
    display: flex;
    align-items: center;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color 0.2s;
}
.input-wrap:focus-within { border-color: var(--accent); }

.prefix {
    padding: 0 10px 0 14px;
    font-weight: 700;
    color: var(--muted);
    font-size: 15px;
    user-select: none;
}

.input-wrap input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    padding: 12px 14px 12px 0;
    font-size: 15px;
    color: var(--text);
}
.input-wrap input::placeholder { color: var(--muted); }

.field-msg {
    margin-top: 6px;
    font-size: 12px;
    color: #ff4d6d;
}
.field-msg.hidden { display: none; }

.field-hint {
    margin-top: 6px;
    font-size: 12px;
    color: var(--muted);
}

.ig-preview {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(0,200,100,0.07);
    border: 1px solid rgba(0,200,100,0.2);
    border-radius: 10px;
    margin-bottom: 16px;
}
.ig-preview.hidden { display: none; }

.ig-preview img {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.ig-preview span { font-weight: 600; font-size: 14px; }

.verified-check {
    margin-left: auto;
    font-size: 11px !important;
    font-weight: 600 !important;
    color: #00c864 !important;
    white-space: nowrap;
}

.pay-btn {
    width: 100%;
    background: linear-gradient(135deg, #e1306c, #833ab4);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 12px;
    transition: opacity 0.15s, transform 0.1s;
}
.pay-btn:hover { opacity: 0.88; transform: scale(1.01); }
.pay-btn:active { transform: scale(0.98); }
.pay-btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }

.secure-note {
    text-align: center;
    font-size: 11px;
    color: var(--muted);
}

/* ── Banners ─────────────────────────────── */
.banner {
    max-width: 600px;
    margin: 12px auto;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}
.banner.success { background: rgba(0,200,100,0.1);  color: #00c864; border: 1px solid rgba(0,200,100,0.25); }
.banner.info    { background: rgba(225,48,108,0.1); color: #e1306c; border: 1px solid rgba(225,48,108,0.25); }

/* ── Mobile ──────────────────────────────── */
@media (max-width: 520px) {
    .site-header { padding: 12px 14px; }
    .tagline { display: none; }
    .bid-btn { font-size: 12px; padding: 9px 14px; }
    .stats-bar { gap: 14px; padding-top: 18px; flex-wrap: wrap; justify-content: center; }
    .stat span { font-size: 20px; }
    .bid-amount { font-size: 15px; }
    .avatar { width: 44px; height: 44px; }
}

