/* The Daily Thunder - Main Stylesheet */

:root {
    --bg-primary: #0a0e1a;
    --bg-secondary: #161b36;
    --bg-tertiary: #1a2332;
    --bg-dark: #161b36;
    --bg-light: #1a2332;
    --primary: #f59e0b;
    --secondary: #0a0e1a;
    --tertiary: #1a2332;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --border: #2a2f52;
    --text-light: #94a3b8;
    --radius: 8px;
    --transition: all 0.3s ease;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --gradient-primary: linear-gradient(135deg, #f59e0b, #d97706);
    --gradient-secondary: linear-gradient(135deg, #1a2332, #161b36);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: #ffffff;
    line-height: 1.6;
    background-image: radial-gradient(circle at center, #1a1f3a 0%, #0a0e1a 70%);
    min-height: 100vh;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.5rem;
}

h5 {
    font-size: 1.25rem;
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: 1rem;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.text-light {
    color: var(--text-light);
}

.text-primary {
    color: var(--primary);
}

.text-success {
    color: var(--success);
}

.text-warning {
    color: var(--warning);
}

.text-danger {
    color: var(--danger);
}

.mb-1 {
    margin-bottom: 0.25rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-3 {
    margin-bottom: 1rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.mb-5 {
    margin-bottom: 2rem;
}

.mt-1 {
    margin-top: 0.25rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-3 {
    margin-top: 1rem;
}

.mt-4 {
    margin-top: 1.5rem;
}

.mt-5 {
    margin-top: 2rem;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.grid {
    display: grid;
    gap: 1rem;
}

.grid-2 {
    grid-template-columns: 1fr 1fr;
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Cards */
.card {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Forms */
.input-group {
    margin-bottom: 1.5rem;
}

.input-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-light);
    font-weight: 500;
}

.input-field {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: #ffffff;
    font-family: inherit;
    transition: var(--transition);
}

.input-field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
}

/* Textarea group for ticket numbers */
.textarea-group {
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.4;
    resize: vertical;
    min-height: 80px;
    transition: var(--transition);
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
}

.golden-ticket-textarea {
    background: linear-gradient(135deg, var(--bg-tertiary), var(--bg-secondary));
    border: 2px solid rgba(245, 158, 11, 0.3);
}

.golden-ticket-textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.random-btn {
    align-self: flex-start;
    padding: 0.6rem 1.2rem;
    background: linear-gradient(135deg, var(--primary), #d97706);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.random-btn:hover {
    background: linear-gradient(135deg, #d97706, #b45309);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.random-btn:active {
    transform: translateY(0);
}

.input-field::placeholder,
.form-textarea::placeholder {
    color: var(--text-light);
    opacity: 0.8;
}

/* Profile Dropdown Styles */
.profile-dropdown {
    position: relative;
}

.profile-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(30, 30, 30, 0.8);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 8px;
    color: #e5e7eb;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
}

.profile-button:hover {
    background: rgba(40, 40, 40, 0.9);
    border-color: rgba(245, 158, 11, 0.5);
}

.profile-avatar {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
}

.profile-name {
    font-weight: 500;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 1000;
    min-width: 200px;
    background: rgba(18, 18, 18, 0.95);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    margin-top: 0.5rem;
    padding: 0.5rem 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 0.75rem 1rem;
    color: #e5e7eb;
    text-decoration: none;
    background: none;
    border: none;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.dropdown-divider {
    height: 1px;
    background: rgba(156, 163, 175, 0.2);
    border: none;
    margin: 0.5rem 0;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: #ffffff;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    font-family: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(245, 158, 11, 0.3);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: var(--gradient-primary);
}

.btn-secondary {
    background: var(--gradient-secondary);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #059669);
}

.btn-warning {
    background: linear-gradient(135deg, var(--warning), #d97706);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #dc2626);
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

/* Tables */
.table-responsive {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-tertiary);
    border-radius: var(--radius);
    overflow: hidden;
}

.table th {
    background: #374151;
    color: #e2e8f0;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
}

.table td {
    padding: 1rem;
    border-bottom: 1px solid #374151;
    color: #e2e8f0;
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:hover {
    background: rgba(245, 158, 11, 0.05);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--primary);
    color: #ffffff;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    border: 1px solid;
}

.alert.success {
    background: rgba(16, 185, 129, 0.1);
    border-color: var(--success);
    color: var(--success);
}

.alert.warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: var(--warning);
    color: var(--warning);
}

.alert.error {
    background: rgba(239, 68, 68, 0.1);
    border-color: var(--danger);
    color: var(--danger);
}

.alert.info {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
    color: #3b82f6;
}

/* Mobile Navigation Styles */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #ffffff;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* Mobile Menu Dropdown */
.mobile-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    min-width: 250px;
    max-width: 300px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    z-index: 10000;
    margin-top: 0.5rem;
}

.mobile-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-nav-list li {
    border-bottom: 1px solid var(--border);
}

.mobile-nav-list li:last-child {
    border-bottom: none;
}

.mobile-nav-list a {
    display: block;
    padding: 0.875rem 1rem;
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
    cursor: pointer;
}

.mobile-nav-list a:hover {
    background-color: rgba(245, 158, 11, 0.1);
    color: var(--primary);
}



/* Better Touch Targets */
.btn,
.input-field,
.form-textarea,
.tab-btn,
.nav-menu a,
.profile-button,
.bet-button,
.heatmap-cell,
.place-bet-btn,
.tab-generate-btn,
.random-btn,
.close-btn,
.hamburger {
    min-height: 44px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(245, 158, 11, 0.2);
}

/* Enhanced button styling for mobile */
@media (max-width: 768px) {

    .btn,
    .place-bet-btn {
        min-height: 48px;
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
        border-radius: 8px;
    }

    .tab-btn {
        min-height: 44px;
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }

    .nav-menu a {
        min-height: 48px;
        display: flex;
        align-items: center;
        padding: 0.75rem 1rem;
    }

    .bet-button {
        min-height: 44px;
        padding: 0.75rem 1rem;
        touch-action: manipulation;
    }

    .heatmap-cell {
        min-height: 60px;
        cursor: pointer;
    }

    /* Improve spacing between clickable elements */
    .tab-navigation {
        gap: 0.75rem;
    }

    .active-bets-grid {
        gap: 0.75rem;
    }

    /* Better touch feedback */
    .btn:active,
    .place-bet-btn:active,
    .tab-btn:active,
    .bet-button:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}

/* Responsive Tables */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-mobile {
    display: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 1.5rem;
        margin-bottom: 1rem;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    /* Mobile Navigation */
    .hamburger {
        display: flex;
    }

    .navbar .nav-menu {
        display: none !important;
    }

    .navbar .auth-container {
        display: none !important;
    }

    #user-info {
        display: none !important;
    }


    /* Mobile-specific button sizing */
    .btn {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }

    .btn:not(.btn-small):not(.tab-btn):not(.random-btn) {
        width: 100%;
        justify-content: center;
    }

    /* Main container mobile layout */
    .main-container {
        grid-template-columns: 1fr;
        padding: 1rem;
        gap: 2rem;
    }

    /* Jackpot banner mobile */
    .jackpot-content {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
        padding: 0 1rem;
    }

    .jackpot-left,
    .jackpot-right {
        font-size: 0.9rem;
    }

    .jackpot-amount {
        font-size: 1rem;
    }

    /* Clock responsive */
    .clock-container {
        width: 300px;
        height: 300px;
    }

    .clock-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }

    .clock-stat-value {
        font-size: 1.25rem;
    }

    /* Betting phase explanation mobile */
    .betting-phase-grid {
        grid-template-columns: 1fr !important;
        gap: 0.75rem !important;
    }

    /* Tables responsive */
    .table {
        font-size: 0.85rem;
    }

    .table th,
    .table td {
        padding: 0.625rem 0.5rem;
    }

    /* Hide some table columns on mobile */
    .table .hide-mobile {
        display: none;
    }

    /* Stack table layout for very small content */
    .table-stack {
        display: block;
    }

    .table-stack thead {
        display: none;
    }

    .table-stack tr {
        display: block;
        border: 1px solid var(--border);
        margin-bottom: 1rem;
        border-radius: 8px;
        background: var(--bg-tertiary);
    }

    .table-stack td {
        display: block;
        text-align: right;
        border: none;
        padding: 0.5rem 1rem;
    }

    .table-stack td:before {
        content: attr(data-label) ": ";
        float: left;
        font-weight: 600;
        color: var(--primary);
    }

    /* Form improvements */
    .input-field,
    .form-textarea {
        font-size: 16px;
        /* Prevents zoom on iOS */
    }

    /* Tab navigation mobile */
    .tab-navigation {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        display: flex;
        gap: 0.5rem;
        padding-bottom: 0.5rem;
    }

    .tab-btn {
        white-space: nowrap;
        min-width: auto;
        flex-shrink: 0;
    }

    /* Mobile Table Responsiveness */
    .winners-table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .winners-table {
        min-width: 600px;
        font-size: 0.85rem;
    }

    .winners-table th,
    .winners-table td {
        padding: 0.625rem 0.5rem;
        white-space: nowrap;
    }

    /* Stack table for very small screens */
    @media (max-width: 600px) {
        .winners-table-container {
            overflow: visible;
        }

        .winners-table {
            min-width: auto;
            display: block;
            width: 100%;
        }

        .winners-table thead {
            display: none;
        }

        .winners-table tbody {
            display: block;
        }

        .winners-table tr {
            display: block;
            border: 1px solid var(--border);
            margin-bottom: 1rem;
            border-radius: 8px;
            background: var(--bg-tertiary);
            padding: 1rem;
        }

        .winners-table td {
            display: block;
            text-align: left;
            border: none;
            padding: 0.5rem 0;
            position: relative;
            padding-left: 40%;
        }

        .winners-table td:before {
            content: attr(data-label) ":";
            position: absolute;
            left: 0;
            top: 0.5rem;
            font-weight: 600;
            color: var(--primary);
            width: 35%;
        }

        .winners-table td:last-child {
            border-bottom: none;
        }
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 0.5rem;
    }

    .card {
        padding: 1rem;
        border-radius: 12px;
    }

    /* Enhanced Typography for Small Screens */
    h1 {
        font-size: 1.5rem;
        line-height: 1.3;
    }

    h2 {
        font-size: 1.25rem;
        line-height: 1.3;
    }

    h3 {
        font-size: 1.1rem;
        line-height: 1.3;
    }

    h4 {
        font-size: 1rem;
        line-height: 1.3;
    }

    /* Body text optimization */
    body {
        font-size: 0.9rem;
        line-height: 1.5;
    }

    p {
        font-size: 0.9rem;
        line-height: 1.5;
        margin-bottom: 1rem;
    }

    /* Navigation typography */
    .logo {
        font-size: 0.9rem;
    }

    .tagline {
        font-size: 0.75rem;
    }

    /* Section titles */
    .section-title {
        font-size: 1.25rem;
        line-height: 1.3;
    }

    .section-subtitle {
        font-size: 0.85rem;
        line-height: 1.4;
    }

    /* Form labels and text */
    .form-label,
    .tab-label {
        font-size: 0.85rem;
    }

    .tab-help {
        font-size: 0.75rem;
        line-height: 1.4;
    }

    /* Button text */
    .btn {
        font-size: 0.9rem;
        padding: 0.625rem 1.25rem;
    }

    .tab-btn {
        font-size: 0.8rem;
    }

    /* Table typography */
    .table {
        font-size: 0.8rem;
    }

    .table th,
    .table td {
        padding: 0.5rem;
        font-size: 0.8rem;
    }

    /* Input fields */
    .input-field,
    .form-input {
        padding: 0.625rem 0.875rem;
        font-size: 0.9rem;
    }

    /* Clock stats */
    .clock-stat-label {
        font-size: 0.75rem;
    }

    .clock-stat-value {
        font-size: 1rem;
    }

    /* Jackpot banner */
    .jackpot-left,
    .jackpot-right {
        font-size: 0.8rem;
    }

    .jackpot-amount {
        font-size: 0.9rem;
    }

    /* Active bets */
    .active-bets-title {
        font-size: 1.1rem;
    }

    /* Winners section */
    .winners-title {
        font-size: 1.1rem;
    }

    /* Better line height for readability */
    .betting-phase-item {
        font-size: 0.8rem;
        line-height: 1.4;
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }

    to {
        transform: translateX(0);
    }
}

@keyframes pulse {
    from {
        text-shadow: 0 0 5px #f59e0b, 0 0 10px #f59e0b;
        transform: translate(-50%, -50%) scale(1);
    }

    to {
        text-shadow: 0 0 10px #f59e0b, 0 0 20px #f59e0b;
        transform: translate(-50%, -50%) scale(1.05);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease-out;
}

.slide-in {
    animation: slideIn 0.3s ease-out;
}

.pulse {
    animation: pulse 2s infinite;
}

/* Admin Specific Styles */
.admin-header {
    background: linear-gradient(135deg, #dc3545, #b02a37);
    color: white;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.admin-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-title {
    font-size: 1.5rem;
    font-weight: 700;
}

.logout-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    text-decoration: none;
    transition: var(--transition);
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 12px;
    border-left: 4px solid var(--primary);
    text-align: center;
    border: 1px solid var(--border);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Font Face Declarations */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* Payment Popup Overlay Styling */
.payment-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(10, 14, 26, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
    backdrop-filter: blur(5px);
}

.payment-popup {
    background-color: #161b36;
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: fadeIn 0.3s ease-out;
    border: 1px solid #2a2f52;
}

.popup-header {
    padding: 1.25rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.popup-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.popup-title i {
    font-size: 1.5rem;
}

.popup-title h3 {
    margin: 0;
    font-weight: 700;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.75rem;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.close-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.payment-details {
    padding: 1.5rem;
}

.payment-amount {
    text-align: center;
    margin-bottom: 1.5rem;
}

.amount-label {
    font-size: 0.875rem;
    color: #94a3b8;
    margin-bottom: 0.25rem;
}

.amount-value {
    font-size: 2rem;
    font-weight: 700;
    color: #f59e0b;
    margin-bottom: 0.25rem;
}

.amount-desc {
    font-size: 0.875rem;
    color: white;
}

.qr-section {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.qr-container {
    background-color: white;
    padding: 1rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#qr-code img {
    width: 180px;
    height: 180px;
    max-width: 100%;
}

.qr-label {
    color: #1e293b;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

.invoice-section {
    margin-bottom: 1.5rem;
}

.invoice-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    color: #cbd5e1;
    font-weight: 600;
}

.invoice-container {
    position: relative;
}

#lightning-invoice {
    width: 100%;
    padding: 0.75rem;
    border-radius: 8px;
    background-color: #1a2332;
    border: 1px solid #2a2f52;
    color: #cbd5e1;
    font-family: monospace;
    font-size: 0.75rem;
    resize: none;
    height: 70px;
    word-break: break-all;
}

.copy-btn {
    position: absolute;
    bottom: 8px;
    right: 8px;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    background-color: #2a2f52;
    color: #cbd5e1;
    font-size: 0.75rem;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: all 0.2s;
}

.copy-btn:hover {
    background-color: #3a3f62;
}

.payment-status {
    margin-bottom: 1.5rem;
}

.status-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background-color: #1a2332;
    border-radius: 8px;
    padding: 1rem;
    border: 1px solid #2a2f52;
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(245, 158, 11, 0.2);
    border-top-color: #f59e0b;
    border-radius: 50%;
    animation: spinner-rotate 1s linear infinite;
}

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

.status-text {
    color: #cbd5e1;
    font-size: 0.875rem;
}

.payment-actions {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.payment-btn {
    flex: 1;
    padding: 0.75rem;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.2s;
    font-family: inherit;
    text-decoration: none;
}

.payment-btn.primary {
    background-color: #f59e0b;
    color: #1e293b;
}

.payment-btn.primary:hover {
    background-color: #d97706;
}

.payment-btn.secondary {
    background-color: #2a2f52;
    color: #cbd5e1;
}

.payment-btn.secondary:hover {
    background-color: #3a3f62;
}

.payment-footer {
    border-top: 1px solid #2a2f52;
    padding-top: 1rem;
}

.security-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #94a3b8;
    font-size: 0.75rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 576px) {
    .payment-popup {
        max-width: 100%;
        border-radius: 12px;
    }

    .payment-actions {
        flex-direction: column;
    }

    #qr-code img {
        width: 150px;
        height: 150px;
    }
}

/* Payment Popup Overlay Styling */
.payment-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(10, 14, 26, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
    backdrop-filter: blur(5px);
}

.payment-popup {
    background-color: #161b36;
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: fadeIn 0.3s ease-out;
    border: 1px solid #2a2f52;
}

.popup-header {
    padding: 1.25rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.popup-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.popup-title i {
    font-size: 1.5rem;
}

.popup-title h3 {
    margin: 0;
    font-weight: 700;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.75rem;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.close-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.payment-details {
    padding: 1.5rem;
}

.payment-amount {
    text-align: center;
    margin-bottom: 1.5rem;
}

.amount-label {
    font-size: 0.875rem;
    color: #94a3b8;
    margin-bottom: 0.25rem;
}

.amount-value {
    font-size: 2rem;
    font-weight: 700;
    color: #f59e0b;
    margin-bottom: 0.25rem;
}

.amount-desc {
    font-size: 0.875rem;
    color: white;
}

.qr-section {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.qr-container {
    background-color: white;
    padding: 1rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#qr-code img {
    width: 180px;
    height: 180px;
    max-width: 100%;
}

.qr-label {
    color: #1e293b;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

.invoice-section {
    margin-bottom: 1.5rem;
}

.invoice-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    color: #cbd5e1;
    font-weight: 600;
}

.invoice-container {
    position: relative;
}

#lightning-invoice {
    width: 100%;
    padding: 0.75rem;
    border-radius: 8px;
    background-color: #1a2332;
    border: 1px solid #2a2f52;
    color: #cbd5e1;
    font-family: monospace;
    font-size: 0.75rem;
    resize: none;
    height: 70px;
    word-break: break-all;
}

.copy-btn {
    position: absolute;
    bottom: 8px;
    right: 8px;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    background-color: #2a2f52;
    color: #cbd5e1;
    font-size: 0.75rem;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: all 0.2s;
}

.copy-btn:hover {
    background-color: #3a3f62;
}

.payment-status {
    margin-bottom: 1.5rem;
}

.status-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background-color: #1a2332;
    border-radius: 8px;
    padding: 1rem;
    border: 1px solid #2a2f52;
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(245, 158, 11, 0.2);
    border-top-color: #f59e0b;
    border-radius: 50%;
    animation: spinner-rotate 1s linear infinite;
}

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

.status-text {
    color: #cbd5e1;
    font-size: 0.875rem;
}

.payment-actions {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.payment-btn {
    flex: 1;
    padding: 0.75rem;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.payment-btn.primary {
    background-color: var(--primary);
    color: #1e293b;
    text-decoration: none;
}

.payment-btn.primary:hover {
    background-color: #d97706;
}

.payment-btn.secondary {
    background-color: var(--bg-tertiary);
    color: white;
    border: 1px solid var(--border);
}

.payment-btn.secondary:hover {
    background-color: var(--bg-secondary);
}

.payment-footer {
    margin-top: 1rem;
    text-align: center;
}

.security-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--text-light);
    font-size: 0.875rem;
}

/* Betting Heat Map Styles */
.betting-heatmap-section {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--border);
    margin-bottom: 2rem;
}

.heatmap-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.heatmap-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
    letter-spacing: 0.05em;
}

.heatmap-legend {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-light);
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    border: 1px solid var(--border);
}

.legend-color.cold {
    background: #374151;
}

.legend-color.warm {
    background: #ea580c;
}

.legend-color.hot {
    background: #fbbf24;
}

.heatmap-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    grid-template-rows: repeat(8, 1fr);
    gap: 4px;
    width: 600px;
    height: 600px;
    margin: 0 auto;
    position: relative;
    padding: 1rem;
    background: rgba(26, 35, 50, 0.3);
    border-radius: 8px;
    overflow: hidden;
}

.heatmap-cell {
    aspect-ratio: 1;
    background: #374151;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.heatmap-cell:hover {
    transform: scale(1.05);
    z-index: 10;
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.heatmap-cell.heat-0 {
    background: #374151;
    color: #9ca3af;
}

.heatmap-cell.heat-1 {
    background: #ea580c;
    color: #ffffff;
}

.heatmap-cell.heat-2 {
    background: #f59e0b;
    color: #ffffff;
}

.heatmap-cell.heat-3 {
    background: #fbbf24;
    color: #000000;
}

.heatmap-cell-range {
    font-size: 0.625rem;
    font-weight: 600;
    line-height: 1;
    margin-bottom: 2px;
}

.heatmap-cell-count {
    font-size: 0.5rem;
    opacity: 0.8;
    line-height: 1;
}

.heatmap-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--text-light);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.heatmap-tooltip {
    position: absolute;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.875rem;
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.heatmap-tooltip.show {
    opacity: 1;
}

.heatmap-tooltip-range {
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.heatmap-tooltip-stats {
    color: var(--text-light);
    font-size: 0.75rem;
}

/* Pulse animation for updated cells */
@keyframes heatmap-pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7);
    }

    70% {
        transform: scale(1.02);
        box-shadow: 0 0 0 8px rgba(245, 158, 11, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
    }
}

.heatmap-cell.updated {
    animation: heatmap-pulse 1s ease-out;
}

/* Order Box Styles for Heat Map */
.order-box {
    background: var(--bg-tertiary);
    border-radius: 0;
    padding: 0.25rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.order-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
    border-color: var(--primary);
}

/* Footer Styles */
.footer {
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid var(--border);
    margin-top: 4rem;
    padding: 3rem 0 1rem;
    backdrop-filter: blur(10px);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-logo h3 {
    color: var(--primary);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.footer-description {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-tertiary);
    border-radius: 50%;
    color: var(--text-light);
    transition: var(--transition);
    text-decoration: none;
}

.social-link:hover {
    background: var(--primary);
    color: var(--bg-primary);
    transform: translateY(-2px);
}

.footer-title {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
    padding-left: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 2rem;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-copyright {
    color: var(--text-light);
    font-size: 0.9rem;
    margin: 0;
}

.footer-info {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.footer-badge {
    background: var(--bg-tertiary);
    color: var(--primary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid var(--border);
}

/* Footer Bottom Styles */
.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.footer-copyright-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border-top: 1px solid var(--border);
    padding-top: 1rem;
}

/* Footer Responsive Design */
@media (max-width: 768px) {
    .footer {
        padding: 2rem 0 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .footer-section {
        text-align: center;
    }

    .footer-social {
        justify-content: center;
    }

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .footer-copyright-section {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .footer-info {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 1.5rem 0 1rem;
    }

    .footer-content {
        gap: 1rem;
    }

    .footer-logo h3 {
        font-size: 1.25rem;
    }

    .footer-description {
        font-size: 0.85rem;
    }

    .footer-title {
        font-size: 1rem;
    }

    .footer-links a {
        font-size: 0.85rem;
    }

    .footer-badge {
        font-size: 0.7rem;
        padding: 0.2rem 0.6rem;
    }
}
}

/* Order Box Sizes - All fit within grid cells */
.order-tiny {
    width: 100%;
    height: 100%;
    min-height: 40px;
    font-size: 0.6rem;
}

.order-small {
    width: 100%;
    height: 100%;
    min-height: 50px;
    font-size: 0.7rem;
}

.order-medium {
    width: 100%;
    height: 100%;
    min-height: 60px;
    font-size: 0.75rem;
}

.order-large {
    width: 100%;
    height: 100%;
    min-height: 70px;
    font-size: 0.8rem;
    grid-column: span 2;
    grid-row: span 2;
}

.order-huge {
    width: 100%;
    height: 100%;
    min-height: 80px;
    font-size: 0.9rem;
    grid-column: span 3;
    grid-row: span 3;
}

/* Order Status Colors */
.order-pending {
    background: linear-gradient(135deg, #374151, #4b5563);
}

.order-paid {
    background: linear-gradient(135deg, #ea580c, #f59e0b);
    color: #ffffff;
}

.order-paid .order-status {
    color: #fbbf24;
    font-weight: 600;
}

/* Order Box Content */
.order-id {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7em;
    opacity: 0.8;
    margin-bottom: 0.2rem;
    font-weight: 600;
}

.order-tickets {
    font-size: 0.85em;
    font-weight: 600;
    margin-bottom: 0.15rem;
    color: var(--primary);
}

.order-paid .order-tickets {
    color: #fbbf24;
}

.order-status {
    font-size: 0.6em;
    text-transform: uppercase;
    opacity: 0.7;
    font-weight: 500;
}

/* Empty state for heat map */
.heatmap-empty {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--text-light);
    font-size: 0.875rem;
}

/* Loading animation for order boxes */
@keyframes order-appear {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.order-box {
    animation: order-appear 0.5s ease-out;
}

/* Responsive Design for Order Heat Map */
@media (max-width: 768px) {
    .heatmap-grid {
        grid-template-columns: repeat(6, 1fr);
        grid-template-rows: repeat(6, 1fr);
        width: 100%;
        max-width: 450px;
        height: auto;
        aspect-ratio: 1;
        gap: 3px;
        padding: 0.75rem;
        margin: 0 auto;
    }

    .heatmap-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .heatmap-legend {
        flex-wrap: wrap;
        gap: 0.75rem;
        justify-content: center;
        width: 100%;
    }

    .heatmap-title {
        font-size: 1.25rem;
    }

    .order-large {
        grid-column: span 2;
        grid-row: span 2;
    }

    .order-huge {
        grid-column: span 2;
        grid-row: span 2;
    }

    .betting-heatmap-section {
        padding: 1.5rem 1rem;
    }

    .heatmap-cell {
        font-size: 0.7rem;
    }

    .heatmap-cell-range {
        font-size: 0.55rem;
    }

    .heatmap-cell-count {
        font-size: 0.45rem;
    }
}

@media (max-width: 480px) {
    .heatmap-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(4, 1fr);
        width: 100%;
        max-width: 320px;
        height: auto;
        aspect-ratio: 1;
        gap: 2px;
        padding: 0.5rem;
        margin: 0 auto;
    }

    .heatmap-header {
        text-align: center;
    }

    .heatmap-title {
        font-size: 1.1rem;
    }

    .heatmap-legend {
        justify-content: center;
        gap: 0.5rem;
    }

    .legend-item {
        font-size: 0.75rem;
    }

    .order-large,
    .order-huge {
        grid-column: span 1;
        grid-row: span 1;
    }

    .order-id {
        font-size: 0.55em;
    }

    .order-tickets {
        font-size: 0.75em;
    }

    .order-status {
        font-size: 0.5em;
    }

    .heatmap-cell {
        font-size: 0.6rem;
        min-height: 60px;
    }

    .heatmap-cell-range {
        font-size: 0.5rem;
    }

    .heatmap-cell-count {
        font-size: 0.4rem;
    }

    .betting-heatmap-section {
        padding: 1rem 0.5rem;
    }

    /* Hide tooltip on very small screens */
    .heatmap-tooltip {
        display: none;
    }
}

/* Extra small screens */
@media (max-width: 360px) {
    .heatmap-grid {
        max-width: 280px;
        gap: 1px;
        padding: 0.25rem;
    }

    .heatmap-cell {
        min-height: 50px;
        font-size: 0.55rem;
    }

    .betting-heatmap-section {
        padding: 0.75rem 0.25rem;
    }
}