@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

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

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    color: #e4e4e7;
    background: #0f0f0f;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(255, 213, 0, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 219, 255, 0.05) 0%, transparent 50%);
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 100px,
            rgba(255, 213, 0, 0.02) 100px,
            rgba(255, 213, 0, 0.02) 101px
        );
    pointer-events: none;
    z-index: 1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 2;
}

header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
    padding: 40px 0;
}

header h1 {
    font-family: 'Inter', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #ffffff;
    letter-spacing: -0.02em;
    position: relative;
}

header h1::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #ffd500, #00dbff);
}

header p {
    font-size: 1.1rem;
    font-weight: 400;
    color: #a1a1aa;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 20px;
}

.lottery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.lottery-card {
    background: rgba(24, 24, 27, 0.8);
    border: 1px solid #3f3f46;
    border-radius: 12px;
    padding: 24px;
    backdrop-filter: blur(12px);
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.lottery-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #ffd500, transparent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.lottery-card:hover::before {
    opacity: 1;
}

.lottery-card:hover {
    transform: translateY(-2px);
    border-color: #52525b;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.lottery-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.lottery-id {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 500;
    color: #ffd500;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
}

.lottery-status {
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.status-active {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.status-completed {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.status-cancelled {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.lottery-info h3 {
    color: #ffffff;
    margin-bottom: 16px;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.lottery-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 15px 0;
}

.stat {
    text-align: center;
    padding: 16px;
    background: rgba(39, 39, 42, 0.5);
    border: 1px solid #3f3f46;
    border-radius: 8px;
    position: relative;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    color: #ffffff;
    margin-bottom: 4px;
    letter-spacing: -0.01em;
}

.stat-label {
    font-size: 0.8rem;
    color: #a1a1aa;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

/* Entry Progress Styles */
.entry-progress {
    margin: 20px 0;
    background: rgba(39, 39, 42, 0.5);
    border: 1px solid #3f3f46;
    border-radius: 8px;
    padding: 16px;
    position: relative;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #e4e4e7;
    letter-spacing: 0.02em;
}

.progress-bar-container {
    height: 8px;
    background: rgba(24, 24, 27, 0.8);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.progress-bar {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-building {
    background: linear-gradient(90deg, #ffd500, #00dbff);
}

.progress-guaranteed {
    background: linear-gradient(90deg, #22c55e, #00dbff);
}

.progress-full {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.8), rgba(255, 165, 0, 0.8));
}

.lottery-card.full {
    border: 2px solid rgba(255, 213, 0, 0.6);
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.1), rgba(255, 165, 0, 0.05));
    animation: pulse-gold 2s infinite;
}

@keyframes pulse-gold {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 213, 0, 0.4); }
    50% { box-shadow: 0 0 0 10px rgba(255, 213, 0, 0); }
}

.progress-subtext {
    font-size: 0.8rem;
    color: #a1a1aa;
    text-align: center;
    margin-top: 5px;
}

/* Timer Styles */
.lottery-timer {
    background: rgba(39, 39, 42, 0.5);
    border: 1px solid #3f3f46;
    border-radius: 8px;
    padding: 16px;
    margin: 20px 0;
    text-align: center;
    position: relative;
}

.timer-label {
    font-size: 0.85rem;
    color: #a1a1aa;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.timer-value {
    font-size: 1.25rem;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.02em;
}

.time-normal .timer-value {
    color: #ffffff;
}

.time-warning {
    border-color: #f59e0b;
}

.time-warning .timer-value {
    color: #f59e0b;
}

.time-critical {
    border-color: #ef4444;
    animation: critical-pulse 2s ease-in-out infinite;
}

.time-critical .timer-value {
    color: #ef4444;
}

@keyframes critical-pulse {
    0%, 100% { 
        border-color: #ef4444;
    }
    50% { 
        border-color: #fca5a5;
    }
}

/* Status Message Styles */
.lottery-status-message {
    background: rgba(59, 130, 246, 0.1);
    border-left: 3px solid #3b82f6;
    padding: 16px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: #e4e4e7;
}

/* Guaranteed Lottery Card */
.lottery-card.guaranteed {
    border-color: #22c55e;
    box-shadow: 0 8px 32px rgba(34, 197, 94, 0.2);
}

.lottery-card.guaranteed::after {
    content: "GUARANTEED";
    position: absolute;
    top: -8px;
    right: 16px;
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: #ffffff;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.lottery-card {
    position: relative;
}

.entry-instructions {
    background: rgba(255, 213, 0, 0.1);
    border-left: 3px solid #ffd500;
    padding: 16px;
    margin-top: 20px;
    border-radius: 0 8px 8px 0;
    color: #e4e4e7;
}

.entry-instructions strong {
    display: block;
    margin-bottom: 8px;
    color: #ffd500;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.how-to-play, .transparency {
    background: rgba(24, 24, 27, 0.6);
    border: 1px solid #3f3f46;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 40px;
    backdrop-filter: blur(12px);
    position: relative;
}

.how-to-play h2, .transparency h2 {
    color: #ffffff;
    margin-bottom: 32px;
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    position: relative;
}

.how-to-play h2::after, .transparency h2::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 2px;
    background: linear-gradient(90deg, #ffd500, #00dbff);
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

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

.step-number {
    background: linear-gradient(135deg, #ffd500, #00dbff);
    color: #000;
    border-radius: 8px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.step-content h3 {
    color: #ffffff;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 1.1rem;
    letter-spacing: -0.01em;
}

.step-content p {
    color: #a1a1aa;
    line-height: 1.6;
    font-size: 0.95rem;
}

.transparency p {
    text-align: center;
    font-size: 1.1rem;
    color: #d4d4d8;
    line-height: 1.7;
    max-width: 600px;
    margin: 0 auto;
}

footer {
    text-align: center;
    color: #71717a;
    margin-top: 60px;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    border-top: 1px solid #27272a;
    padding-top: 24px;
    font-weight: 400;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
}

.modal-content {
    background: rgba(24, 24, 27, 0.95);
    border: 1px solid #3f3f46;
    margin: 5% auto;
    padding: 32px;
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.close {
    color: #a1a1aa;
    float: right;
    font-size: 24px;
    font-weight: 400;
    cursor: pointer;
    position: absolute;
    right: 24px;
    top: 24px;
    transition: color 0.2s ease;
}

.close:hover {
    color: #ffffff;
}

.entries-list {
    margin-top: 20px;
}

.entry-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #3f3f46;
    color: #d4d4d8;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
}

.entry-item:last-child {
    border-bottom: none;
}

.winner-highlight {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.2), rgba(0, 219, 255, 0.2));
    border: 1px solid rgba(255, 213, 0, 0.3);
    color: #ffffff;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
}

/* Tab Navigation */
.main-nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.nav-btn {
    padding: 12px 24px;
    background: rgba(39, 39, 42, 0.8);
    border: 1px solid rgba(255, 213, 0, 0.2);
    color: #e4e4e7;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    background: rgba(39, 39, 42, 1);
    border-color: rgba(255, 213, 0, 0.4);
}

.nav-btn.active {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.2), rgba(0, 219, 255, 0.2));
    border-color: rgba(255, 213, 0, 0.6);
    color: #ffffff;
}

/* Results specific styling */
.result-card {
    border: 1px solid rgba(34, 197, 94, 0.3);
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(34, 197, 94, 0.05));
}

.result-details {
    margin-top: 15px;
    font-size: 0.9rem;
    color: #a1a1aa;
}

.result-details p {
    margin-bottom: 5px;
}

.winner-badge {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
}

.pagination button {
    padding: 8px 16px;
    background: rgba(39, 39, 42, 0.8);
    border: 1px solid rgba(255, 213, 0, 0.2);
    color: #e4e4e7;
    border-radius: 6px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.pagination button:hover:not(:disabled) {
    background: rgba(39, 39, 42, 1);
    border-color: rgba(255, 213, 0, 0.4);
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#page-info {
    color: #a1a1aa;
    font-weight: 500;
}

/* Verification Section */
.verification-section {
    max-width: 800px;
    margin: 0 auto;
}

.verify-form {
    background: rgba(39, 39, 42, 0.6);
    border: 1px solid rgba(255, 213, 0, 0.2);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 40px;
}

.form-group {
    text-align: center;
}

.form-group label {
    display: block;
    margin-bottom: 15px;
    font-weight: 600;
    color: #ffffff;
}

.lottery-id-input {
    width: 100%;
    max-width: 400px;
    padding: 12px 16px;
    margin-bottom: 20px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 213, 0, 0.3);
    border-radius: 8px;
    color: #e4e4e7;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
}

.lottery-id-input:focus {
    outline: none;
    border-color: rgba(255, 213, 0, 0.6);
    box-shadow: 0 0 0 2px rgba(255, 213, 0, 0.2);
}

.verify-submit-btn, .verify-btn {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.8), rgba(0, 219, 255, 0.8));
    border: none;
    color: #000;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.verify-submit-btn:hover, .verify-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 213, 0, 0.3);
}

.verification-info {
    background: rgba(39, 39, 42, 0.4);
    border: 1px solid rgba(255, 213, 0, 0.1);
    border-radius: 12px;
    padding: 30px;
}

.verification-info h3, .verification-info h4 {
    color: #ffffff;
    margin-bottom: 15px;
}

.verification-info ol {
    margin-left: 20px;
    margin-bottom: 20px;
}

.verification-info li {
    margin-bottom: 8px;
    color: #d4d4d8;
}

.verification-example {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 213, 0, 0.2);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.verification-example pre {
    color: #a1a1aa;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    overflow-x: auto;
}

/* Verification Results */
.verification-status {
    text-align: center;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.verification-valid {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(34, 197, 94, 0.1));
    border: 1px solid rgba(34, 197, 94, 0.4);
}

.verification-invalid {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(239, 68, 68, 0.1));
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.verification-details {
    background: rgba(39, 39, 42, 0.4);
    border: 1px solid rgba(255, 213, 0, 0.1);
    border-radius: 12px;
    padding: 30px;
}

.verification-details h3 {
    color: #ffffff;
    margin: 25px 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 213, 0, 0.2);
}

.verification-details h3:first-child {
    margin-top: 0;
}

.verification-details code {
    background: rgba(0, 0, 0, 0.4);
    padding: 4px 8px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: #fbbf24;
    word-break: break-all;
}

.transaction-list {
    max-height: 200px;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 8px;
    border: 1px solid rgba(255, 213, 0, 0.1);
}

.verification-instructions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 213, 0, 0.2);
}

.verification-instructions ol {
    margin-left: 20px;
}

.verification-instructions li {
    margin-bottom: 8px;
    color: #d4d4d8;
}

.verification-actions {
    margin-top: 15px;
    text-align: center;
}

.error-details {
    font-size: 0.9rem;
    color: #f87171;
    font-family: 'JetBrains Mono', monospace;
    margin-top: 10px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
        max-width: 100%;
    }
    
    header {
        margin-bottom: 40px;
        padding: 20px 0;
    }
    
    header h1 {
        font-size: 2.5rem;
        margin-bottom: 10px;
    }
    
    header p {
        font-size: 1rem;
        margin-top: 15px;
    }
    
    /* User section improvements for mobile */
    .user-section {
        position: relative;
        top: auto;
        right: auto;
        margin-top: 20px;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .login-options {
        flex-direction: row;
        gap: 10px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .login-btn, .logout-btn {
        font-size: 0.85rem;
        padding: 8px 16px;
    }
    
    /* Navigation improvements */
    .main-nav {
        flex-wrap: wrap;
        gap: 10px;
        margin-bottom: 30px;
    }
    
    .nav-btn {
        padding: 10px 18px;
        font-size: 0.9rem;
        flex: 1;
        min-width: 120px;
    }
    
    /* Lottery grid improvements */
    .lottery-grid {
        grid-template-columns: 1fr;
        gap: 15px;
        margin-bottom: 30px;
    }
    
    .lottery-card {
        padding: 20px;
        margin: 0;
    }
    
    .lottery-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        margin-bottom: 12px;
    }
    
    .lottery-id {
        font-size: 0.8rem;
    }
    
    .lottery-status {
        align-self: flex-end;
        padding: 3px 10px;
        font-size: 0.7rem;
    }
    
    .lottery-info h3 {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    .lottery-stats {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin: 12px 0;
    }
    
    .stat {
        padding: 12px;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    /* Entry progress improvements */
    .entry-progress {
        margin: 15px 0;
        padding: 12px;
    }
    
    .progress-header {
        font-size: 0.8rem;
        margin-bottom: 10px;
    }
    
    .progress-subtext {
        font-size: 0.75rem;
    }
    
    /* Timer improvements */
    .lottery-timer {
        padding: 12px;
        margin: 15px 0;
    }
    
    .timer-label {
        font-size: 0.8rem;
        margin-bottom: 6px;
    }
    
    .timer-value {
        font-size: 1.1rem;
    }
    
    /* Button improvements */
    .transfer-btn {
        padding: 12px 20px;
        font-size: 0.95rem;
        margin-top: 12px;
    }
    
    .entry-instructions-enhanced {
        padding: 15px;
        margin-top: 15px;
    }
    
    .entry-instructions-enhanced h4 {
        font-size: 1rem;
        margin-bottom: 12px;
    }
    
    .manual-instructions {
        padding: 12px;
        margin-top: 12px;
    }
    
    .manual-instructions h5 {
        font-size: 0.9rem;
        margin-bottom: 8px;
    }
    
    .manual-instructions p {
        font-size: 0.85rem;
    }
    
    .manual-instructions code {
        font-size: 0.8rem;
        word-break: break-all;
    }
    
    /* Steps section improvements */
    .steps {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 25px;
    }
    
    .step {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 12px;
    }
    
    .step-number {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .step-content h3 {
        font-size: 1rem;
        margin-bottom: 8px;
    }
    
    .step-content p {
        font-size: 0.9rem;
    }
    
    /* How to play and transparency sections */
    .how-to-play, .transparency {
        padding: 25px;
        margin-bottom: 30px;
    }
    
    .how-to-play h2, .transparency h2 {
        font-size: 1.75rem;
        margin-bottom: 25px;
    }
    
    .transparency p {
        font-size: 1rem;
    }
    
    /* Modal improvements */
    .modal-content {
        margin: 5% auto;
        width: 95%;
        padding: 20px;
        max-height: 90vh;
    }
    
    .close {
        font-size: 20px;
        right: 20px;
        top: 20px;
    }
    
    /* Entry item improvements */
    .entry-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        padding: 10px 0;
        font-size: 0.85rem;
    }
    
    .entry-item span {
        word-break: break-all;
    }
    
    /* Verification section improvements */
    .verification-section {
        max-width: 100%;
        padding: 0 10px;
    }
    
    .verify-form {
        padding: 20px;
        margin-bottom: 30px;
    }
    
    .lottery-id-input {
        width: 100%;
        max-width: 100%;
        margin-bottom: 15px;
        font-size: 0.85rem;
    }
    
    .verify-submit-btn, .verify-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
        width: 100%;
    }
    
    .verification-info {
        padding: 20px;
    }
    
    .verification-info h3, .verification-info h4 {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    .verification-example {
        padding: 15px;
        margin-top: 15px;
    }
    
    .verification-example pre {
        font-size: 0.8rem;
    }
    
    /* Result card improvements */
    .result-details {
        margin-top: 12px;
        font-size: 0.85rem;
    }
    
    .result-details p {
        margin-bottom: 4px;
    }
    
    /* Pagination improvements */
    .pagination {
        flex-wrap: wrap;
        gap: 10px;
        margin-top: 25px;
    }
    
    .pagination button {
        padding: 8px 14px;
        font-size: 0.85rem;
        min-width: 80px;
    }
    
    #page-info {
        font-size: 0.85rem;
        width: 100%;
        text-align: center;
        order: -1;
        margin-bottom: 10px;
    }
    
    /* Footer improvements */
    footer {
        margin-top: 40px;
        padding-top: 20px;
        font-size: 0.8rem;
    }
}

/* Rules Section */
.rules-section {
    max-width: 1000px;
    margin: 0 auto;
}

.rules-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.rule-card {
    background: rgba(24, 24, 27, 0.8);
    border: 1px solid #3f3f46;
    border-radius: 12px;
    padding: 25px;
    backdrop-filter: blur(12px);
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.rule-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ffd500, transparent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.rule-card:hover::before {
    opacity: 1;
}

.rule-card:hover {
    transform: translateY(-2px);
    border-color: #52525b;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.rule-card h3 {
    color: #ffffff;
    margin-bottom: 15px;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rule-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.rule-card li {
    color: #d4d4d8;
    margin-bottom: 12px;
    padding-left: 15px;
    position: relative;
    line-height: 1.6;
    font-size: 0.95rem;
}

.rule-card li::before {
    content: '•';
    color: #ffd500;
    position: absolute;
    left: 0;
    top: 0;
    font-weight: bold;
}

.rule-card li strong {
    color: #ffffff;
    font-weight: 600;
}

.rule-card code {
    background: rgba(0, 0, 0, 0.4);
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: #fbbf24;
    word-break: break-all;
}

.rule-card.important {
    border-color: #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(239, 68, 68, 0.05));
}

.rule-card.important::before {
    background: linear-gradient(90deg, transparent, #ef4444, transparent);
}

.rule-card.important h3 {
    color: #fca5a5;
}

.rule-card.important li::before {
    color: #ef4444;
}

/* Responsive Rules Section */
@media (max-width: 768px) {
    .rules-content {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-bottom: 30px;
    }
    
    .rule-card {
        padding: 20px;
    }
    
    .rule-card h3 {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    .rule-card li {
        font-size: 0.9rem;
        margin-bottom: 10px;
    }
    
    .rule-card code {
        font-size: 0.8rem;
        word-break: break-all;
    }
}

@media (max-width: 480px) {
    .rules-content {
        gap: 15px;
    }
    
    .rule-card {
        padding: 15px;
    }
    
    .rule-card h3 {
        font-size: 1rem;
    }
    
    .rule-card li {
        font-size: 0.85rem;
        margin-bottom: 8px;
    }
}

/* Extra small mobile devices */
@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    header p {
        font-size: 0.95rem;
    }
    
    .lottery-stats {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    .stat {
        padding: 10px;
    }
    
    .stat-value {
        font-size: 1.1rem;
    }
    
    .nav-btn {
        padding: 8px 12px;
        font-size: 0.85rem;
        min-width: 100px;
    }
    
    .transfer-btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }
    
    .modal-content {
        margin: 2% auto;
        width: 98%;
        padding: 15px;
        max-height: 95vh;
    }
    
    .how-to-play h2, .transparency h2 {
        font-size: 1.5rem;
    }
    
    .how-to-play, .transparency {
        padding: 20px;
    }
}

/* Loading Animation */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
}

.spinner {
    border: 3px solid #3f3f46;
    border-top: 3px solid #ffd500;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

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

/* User Authentication Section */
.user-section {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 8px 16px;
    font-weight: 500;
}

.login-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.login-method {
    font-size: 0.75rem;
    opacity: 0.7;
    font-weight: 400;
}

.keychain-method {
    color: #10b981;
}

.hivesigner-method {
    color: #3b82f6;
}

.login-btn, .logout-btn {
    background: linear-gradient(135deg, #ffd500 0%, #ffb800 100%);
    color: #000;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.keychain-btn {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.keychain-btn:hover {
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3);
}

.keychain-btn:disabled {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: #9ca3af;
    cursor: not-allowed;
    opacity: 0.6;
}

.keychain-btn:disabled:hover {
    transform: none;
    box-shadow: none;
}

.hivesigner-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.hivesigner-btn:hover {
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
}

/* Login to enter buttons */
.login-to-enter {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.keychain-enter {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.keychain-enter:hover {
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3);
}

.keychain-enter:disabled {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    opacity: 0.6;
    cursor: not-allowed;
}

.keychain-enter:disabled:hover {
    transform: none;
    box-shadow: none;
}

.hivesigner-enter {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

.hivesigner-enter:hover {
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.3);
}

@media (max-width: 768px) {
    .login-to-enter {
        flex-direction: column;
        gap: 6px;
    }
    
    .keychain-enter, .hivesigner-enter {
        font-size: 0.85rem;
        padding: 10px 16px;
    }
}

.login-btn:hover, .logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 213, 0, 0.3);
}

.logout-btn {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    padding: 6px 12px;
    font-size: 0.8rem;
}

.logout-btn:hover {
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.3);
}

/* Transfer Button */
.transfer-btn {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
    width: 100%;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.transfer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3);
}

.transfer-btn:disabled {
    background: #374151;
    color: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.transfer-btn .icon {
    font-size: 1.2rem;
}

/* Entry Instructions Enhanced */
.entry-instructions-enhanced {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

.entry-instructions-enhanced h4 {
    color: #10b981;
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

/* User Entry Status */
.user-entry-status {
    margin-bottom: 15px;
}

.user-entries-info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    padding: 12px;
    color: #93c5fd;
    font-size: 0.9rem;
    font-weight: 500;
}

.user-entries-maxed {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    padding: 12px;
    color: #fca5a5;
    font-size: 0.9rem;
    font-weight: 500;
}

.transfer-btn.disabled {
    background: #374151 !important;
    color: #9ca3af !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.manual-instructions {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
}

.manual-instructions h5 {
    color: #e4e4e7;
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.manual-instructions p {
    font-size: 0.9rem;
    line-height: 1.4;
}

.manual-instructions code {
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
}
