/* Premium Currency Entry Styles - Leaderboard Style */
.premium-currency-entry {
    position: relative;
    margin-top: 10px;
}

.currency-display.leaderboard-entry {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    padding: 12px 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    font-weight: 600;
    margin-bottom: 5px;
    border: 1px solid rgba(102, 126, 234, 0.6);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.currency-display.leaderboard-entry:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #7c8ef5 0%, #8b5cb2 100%) !important;
}

.premium-label {
    font-size: 14px;
    font-weight: 600;
    opacity: 0.95;
    color: white !important;
}

.currency-amount {
    display: flex;
    align-items: center;
    gap: 6px;
    color: white !important;
}

.currency-icon {
    font-size: 18px;
}

.currency-balance {
    font-size: 16px;
    font-weight: 700;
    color: white !important;
}

@keyframes currencyPop {
    0%   { transform: scale(1); }
    30%  { transform: scale(1.6); color: #ffd700; text-shadow: 0 0 12px #ffd700; }
    60%  { transform: scale(0.9); }
    100% { transform: scale(1); color: white; text-shadow: none; }
}

@keyframes buttonGlow {
    0%   { box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3); }
    40%  { box-shadow: 0 0 24px 6px rgba(255, 215, 0, 0.7); }
    100% { box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3); }
}

.currency-balance.pop {
    animation: currencyPop 0.6s ease forwards;
}

.currency-display.leaderboard-entry.glow {
    animation: buttonGlow 0.8s ease forwards;
}

/* Dropdown Styles */
.premium-dropdown {
    position: fixed;
    width: 340px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    max-height: 500px;
    overflow-y: auto;
    padding: 16px;
    visibility: visible;
    opacity: 1;
}

.premium-dropdown[style*="display: none"] {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.dropdown-header {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.dropdown-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-header h3 {
    margin: 0;
    font-size: 18px;
    color: #1f2937;
}

.dropdown-balance-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f3f4f6;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 14px;
    color: #374151;
}

.dropdown-balance-label {
    font-weight: 500;
}

.dropdown-balance-amount {
    font-weight: 700;
    font-size: 15px;
}

.buy-more-btn {
    background: #10b981;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.buy-more-btn:hover {
    background: #059669;
}

/* Premium Mode Cards */
.modes-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.premium-mode-card {
    background: #f9fafb;
    border-radius: 8px;
    padding: 16px;
    transition: background 0.2s;
}

.premium-mode-card:not(.disabled):hover {
    background: #f3f4f6;
}

.premium-mode-card.disabled {
    opacity: 0.6;
}

.mode-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.mode-icon {
    font-size: 24px;
}

.mode-name {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.mode-description {
    font-size: 14px;
    color: #6b7280;
    margin: 8px 0;
}

.mode-pricing {
    margin: 12px 0;
    font-size: 14px;
}

.cost-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
}

.cost-row.boost {
    color: #8b5cf6;
    font-weight: 600;
}

.cost {
    font-weight: 600;
}

.mode-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.activate-btn,
.boost-btn {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s, opacity 0.2s;
}

.activate-btn {
    background: #3b82f6;
    color: white;
}

.activate-btn:hover:not(:disabled) {
    background: #2563eb;
    transform: translateY(-1px);
}

.boost-btn {
    background: #8b5cf6;
    color: white;
}

.boost-btn:hover:not(:disabled) {
    background: #7c3aed;
    transform: translateY(-1px);
}

.activate-btn:disabled,
.boost-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

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

.loading, .no-modes {
    text-align: center;
    padding: 20px;
    color: #6b7280;
}

/* Notification Toast */
.premium-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    z-index: 9999;
    opacity: 0;
    transform: translateX(100px);
    transition: all 0.3s;
}

.premium-notification.show {
    opacity: 1;
    transform: translateX(0);
}

.premium-notification.success {
    background: #10b981;
}

.premium-notification.error {
    background: #ef4444;
}

/* Lobby Transition Overlay */
.lobby-transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s;
}

.lobby-transition-overlay.active {
    opacity: 1;
}

.lobby-transition-content {
    text-align: center;
    color: white;
}

.mode-title {
    font-size: 48px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: bold;
}

.boost-badge {
    display: inline-block;
    background: #8b5cf6;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    margin-bottom: 30px;
    font-weight: 600;
}

.countdown-circle {
    position: relative;
    margin: 30px auto;
    width: 200px;
    height: 200px;
}

.countdown-svg {
    transform: rotate(-90deg);
}

.countdown-bg {
    fill: none;
    stroke: #374151;
    stroke-width: 8;
}

.countdown-progress {
    fill: none;
    stroke: #667eea;
    stroke-width: 8;
    stroke-dasharray: 565.48; /* 2 * π * 90 */
    stroke-dashoffset: 0;
    transition: stroke-dashoffset 1s linear;
    stroke-linecap: round;
}

.countdown-number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 72px;
    font-weight: bold;
    color: #667eea;
}

.activated-by {
    font-size: 18px;
    color: #9ca3af;
    margin-top: 20px;
}

.mode-info {
    margin-top: 30px;
    font-size: 16px;
    color: #d1d5db;
}

/* ── Tutorial Modal ─────────────────────────────────────────── */
.tutorial-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.tutorial-overlay.active {
    opacity: 1;
}

.tutorial-content {
    background: #1e1e2e;
    border: 1px solid #3b3b5c;
    border-radius: 12px;
    padding: 32px;
    max-width: 480px;
    width: 90%;
    position: relative;
    color: #e2e8f0;
}

.tutorial-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 1.2em;
    cursor: pointer;
    padding: 4px 8px;
    line-height: 1;
}

.tutorial-close:hover {
    color: #e2e8f0;
}

.tutorial-header {
    text-align: center;
    margin-bottom: 24px;
}

.tutorial-emoji {
    font-size: 2.5em;
    display: block;
    margin-bottom: 8px;
}

.tutorial-header h2 {
    margin: 0 0 6px;
    font-size: 1.4em;
    color: #f1f5f9;
}

.tutorial-subtitle {
    margin: 0;
    color: #94a3b8;
    font-size: 0.9em;
}

.tutorial-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 28px;
}

.tutorial-step {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.tutorial-step-icon {
    font-size: 1.4em;
    flex-shrink: 0;
    margin-top: 1px;
}

.tutorial-step strong {
    display: block;
    margin-bottom: 3px;
    color: #f1f5f9;
    font-size: 0.95em;
}

.tutorial-step p {
    margin: 0;
    color: #94a3b8;
    font-size: 0.85em;
    line-height: 1.5;
}

.tutorial-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: #6d28d9;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s;
}

.tutorial-btn:hover {
    background: #7c3aed;
}

/* Kviztali tutorial tooltip — slides down from top on first banner collapse */
.kviztali-tutorial {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10002;
    transform: translateY(-100%);
    transition: transform 0.25s ease;
    pointer-events: none;
}

.kviztali-tutorial.active {
    transform: translateY(0);
    pointer-events: auto;
}

.kviztali-tutorial-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(30, 18, 72, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
}

.kviztali-tutorial-text {
    flex: 1;
}

.kviztali-tutorial-text strong {
    display: block;
    color: #fff;
    font-size: 13px;
    margin-bottom: 2px;
}

.kviztali-tutorial-text p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    margin: 0;
    line-height: 1.4;
}

.kviztali-tutorial-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 16px;
    cursor: pointer;
    padding: 4px 6px;
    flex-shrink: 0;
}
