:root {
    --bg-gradient: linear-gradient(135deg, #0f2027 0%, #203a43 50%, #2c5364 100%);
    --primary: #00ffcc;
    --secondary: #00b09b;
    --accent: #ffcc00;
    --danger: #ff5e62;
    --card-bg: rgba(26, 26, 46, 0.85);
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--bg-gradient);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: white;
    overflow-x: hidden;
    user-select: none;
}

.container {
    width: 100%;
    max-width: 480px;
    padding: 20px;
    box-sizing: border-box;
}

.card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(0, 255, 204, 0.3);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    text-align: center;
}

h2 {
    color: var(--primary);
    margin-bottom: 20px;
}

input {
    width: 100%;
    padding: 12px 15px;
    margin: 10px 0;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    box-sizing: border-box;
    outline: none;
}

input:focus {
    border-color: var(--primary);
}

button {
    width: 100%;
    padding: 12px;
    margin-top: 15px;
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: #0f2027;
    font-weight: bold;
    font-size: 1.1rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.2s;
    box-shadow: 0 5px 15px rgba(0,255,204,0.3);
}

button:hover {
    transform: scale(1.02);
    opacity: 0.9;
}

.switch-text {
    margin-top: 15px;
    font-size: 0.9rem;
    color: #aaa;
}

.switch-text a {
    color: var(--primary);
    text-decoration: none;
    font-weight: bold;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.4);
    padding: 15px 20px;
    border-radius: 15px;
    margin-bottom: 20px;
}

.balance-box {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--accent);
}

.menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.menu-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 20px;
    border-radius: 15px;
    cursor: pointer;
    transition: 0.2s;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    margin-top: 0;
}

.menu-btn:hover {
    background: rgba(0, 255, 204, 0.2);
    border-color: var(--primary);
    transform: translateY(-3px);
}

.logout-btn {
    background: var(--danger);
    color: white;
}

#score-display {
    font-size: 3.5rem;
    font-weight: bold;
    text-shadow: 2px 4px 10px rgba(0,0,0,0.3);
    margin-bottom: 5px;
}

#tap-circle {
    width: 140px;
    height: 140px;
    background: radial-gradient(circle, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 0 30px rgba(0, 255, 204, 0.5);
    margin: 20px auto;
    transition: transform 0.1s;
}

#tap-circle:active {
    transform: scale(0.92);
}

#tap-circle span {
    font-size: 1.3rem;
    font-weight: bold;
    color: #0f2027;
}

.back-btn {
    background: rgba(255,255,255,0.2);
    margin-top: 10px;
    color: white;
}

.referral-link-box {
    background: rgba(0,0,0,0.3);
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    word-break: break-all;
    margin: 15px 0;
    color: var(--primary);
    border: 1px dashed var(--primary);
}

.floating-score {
    position: absolute;
    font-size: 2rem;
    font-weight: bold;
    color: var(--accent);
    pointer-events: none;
    animation: floatUp 1s ease-out forwards;
    z-index: 100;
}

@keyframes floatUp {
    0% { opacity: 1; transform: translateY(0) scale(1); }
    100% { opacity: 0; transform: translateY(-80px) scale(1.5); }
}

.error-msg {
    display: none;
    background: rgba(255, 94, 98, 0.2);
    border: 1px solid var(--danger);
    color: #ff8b8e;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 15px;
    text-align: center;
}

.success-msg {
    display: none;
    background: rgba(0, 255, 204, 0.2);
    border: 1px solid var(--primary);
    color: var(--primary);
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 15px;
    text-align: center;
}
/* Referral Notification Banner Style */
.referral-banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    display: none;
    animation: slideDown 0.5s ease-out forwards;
}

@keyframes slideDown {
    0% { opacity: 0; transform: translateY(-10px); }
    100% { opacity: 1; transform: translateY(0); }
}