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

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #64748b;
    --accent: #f59e0b;
    --success: #10b981;
    --danger: #ef4444;
    --background: #0f172a;
    --surface: #1e293b;
    --surface-light: #334155;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --border: #475569;
    --gradient-start: #6366f1;
    --gradient-end: #a855f7;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--background);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
}

.app-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.3);
}

.header h1 {
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.header-stats {
    display: flex;
    gap: 20px;
}

.stat {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    backdrop-filter: blur(10px);
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(99, 102, 241, 0.4);
}

.btn-secondary {
    background: var(--surface-light);
    color: var(--text);
}

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

.btn-accent {
    background: linear-gradient(135deg, var(--accent), #f97316);
    color: white;
    font-size: 1.1rem;
    padding: 14px 32px;
}

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

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    background: #059669;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Upload Section */
.upload-section {
    display: flex;
    justify-content: center;
    padding: 60px 20px;
}

.upload-box {
    background: var(--surface);
    border: 3px dashed var(--border);
    border-radius: 20px;
    padding: 60px;
    text-align: center;
    max-width: 500px;
    width: 100%;
    transition: all 0.3s ease;
}

.upload-box:hover, .upload-box.dragover {
    border-color: var(--primary);
    background: var(--surface-light);
}

.upload-box.dragover {
    transform: scale(1.02);
}

.upload-icon {
    color: var(--primary);
    margin-bottom: 20px;
}

.upload-box h2 {
    margin-bottom: 10px;
    color: var(--text);
}

.upload-box p {
    color: var(--text-muted);
    margin-bottom: 30px;
}

/* Filters Section */
.filters-section {
    background: var(--surface);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
}

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

.filters-header h2 {
    font-size: 1.2rem;
}

.filters-container {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.filter-group {
    background: var(--surface-light);
    border-radius: 12px;
    padding: 16px;
    min-width: 200px;
    flex: 1;
    max-width: 300px;
}

.filter-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text);
}

.filter-group select,
.filter-group input {
    width: 100%;
    padding: 10px 12px;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.95rem;
}

.filter-group select:focus,
.filter-group input:focus {
    outline: none;
    border-color: var(--primary);
}

.filter-checkboxes {
    max-height: 150px;
    overflow-y: auto;
    padding: 8px;
    background: var(--background);
    border-radius: 8px;
}

.filter-checkboxes label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    margin-bottom: 4px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: normal;
}

.filter-checkboxes label:hover {
    background: var(--surface-light);
}

.filter-checkboxes input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

/* Date range filter */
.date-range {
    display: flex;
    gap: 10px;
    align-items: center;
}

.date-range input {
    flex: 1;
}

/* Date preset filter */
.date-filter-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.date-preset-select {
    width: 100%;
    padding: 10px 12px;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.95rem;
    cursor: pointer;
}

.date-preset-select:focus {
    outline: none;
    border-color: var(--primary);
}

.date-custom-range {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
    background: var(--background);
    border-radius: 8px;
    font-size: 0.85rem;
}

.date-custom-range input {
    width: 100%;
    padding: 8px;
    font-size: 0.85rem;
}

/* Table Section */
.table-section {
    background: var(--surface);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
}

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

.table-header h2 {
    font-size: 1.2rem;
}

.table-wrapper {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.participants-table {
    width: 100%;
    border-collapse: collapse;
}

.participants-table th,
.participants-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.participants-table th {
    background: var(--surface-light);
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    position: sticky;
    top: 0;
}

.participants-table tbody tr {
    transition: background 0.2s ease;
}

.participants-table tbody tr:hover {
    background: var(--surface-light);
}

.participants-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.participants-table td {
    color: var(--text-muted);
}

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

.pagination button {
    padding: 8px 14px;
    background: var(--surface-light);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination button:hover:not(:disabled) {
    background: var(--primary);
    border-color: var(--primary);
}

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

.pagination button.active {
    background: var(--primary);
    border-color: var(--primary);
}

/* Winners Section */
.winners-section {
    background: var(--surface);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
}

.winners-section h2 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.winners-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.winner-item {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(168, 85, 247, 0.2));
    border: 1px solid var(--primary);
    border-radius: 12px;
    padding: 16px;
    position: relative;
    overflow: hidden;
}

.winner-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
}

.winner-item .winner-number {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--primary);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
}

.winner-item h3 {
    margin-bottom: 8px;
    padding-right: 30px;
}

.winner-item p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 4px;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: var(--surface);
    border-radius: 20px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-content h2 {
    margin-bottom: 20px;
    text-align: center;
}

.modal-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 24px;
}

/* Raffle Modal */
.raffle-modal {
    max-width: 700px;
    text-align: center;
}

.raffle-animation {
    padding: 40px 0;
}

.slot-machine {
    background: linear-gradient(180deg, var(--background), var(--surface-light));
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: inset 0 5px 15px rgba(0, 0, 0, 0.3);
}

.slot-window {
    background: var(--background);
    border-radius: 12px;
    height: 80px;
    overflow: hidden;
    position: relative;
    border: 3px solid var(--primary);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
}

.slot-reel {
    position: absolute;
    width: 100%;
    transition: transform 0.1s ease-out;
}

.slot-item {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--text);
    padding: 0 20px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.raffle-status {
    font-size: 1.2rem;
    color: var(--text-muted);
    animation: pulse 1s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Winner Display */
.winner-display {
    position: relative;
}

.winner-display h2 {
    font-size: 2.5rem;
    background: linear-gradient(135deg, var(--accent), #f97316);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 30px;
    animation: winnerPop 0.5s ease;
}

@keyframes winnerPop {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.winner-card {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(249, 115, 22, 0.1));
    border: 2px solid var(--accent);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 30px;
    text-align: left;
}

.winner-card .winner-name {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text);
}

.winner-card .winner-details {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.winner-card .detail-item {
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.winner-card .detail-item label {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: block;
    margin-bottom: 4px;
}

.winner-card .detail-item span {
    font-weight: 600;
    color: var(--text);
}

.winner-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Celebration Overlay */
.celebration-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.celebration-overlay.visible {
    opacity: 1;
}

.celebration-content {
    text-align: center;
    transform: scale(0.5);
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.celebration-overlay.visible .celebration-content {
    transform: scale(1);
}

.celebration-icon {
    font-size: 6rem;
    animation: celebrateBounce 0.6s ease infinite;
    margin-bottom: 20px;
}

@keyframes celebrateBounce {
    0%, 100% { transform: scale(1) rotate(-5deg); }
    50% { transform: scale(1.2) rotate(5deg); }
}

.celebration-text {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), #f97316, #fbbf24, var(--accent));
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: celebrateGradient 1s ease infinite;
    text-shadow: 0 0 40px rgba(245, 158, 11, 0.5);
    margin-bottom: 16px;
}

@keyframes celebrateGradient {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.celebration-subtext {
    font-size: 2rem;
    font-weight: 600;
    color: var(--text);
    opacity: 0;
    animation: celebrateFadeIn 0.5s ease 0.3s forwards;
}

@keyframes celebrateFadeIn {
    to { opacity: 1; }
}

/* Winner info panel celebration effect */
.winner-info-panel.celebrate {
    animation: celebratePulse 0.5s ease 3;
}

@keyframes celebratePulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
        border-color: var(--border);
    }
    50% {
        box-shadow: 0 0 30px 10px rgba(245, 158, 11, 0.6);
        border-color: var(--accent);
    }
}

.winner-info-panel.celebrate .winner-info-grid {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(249, 115, 22, 0.1));
}

/* Duplicate Modal */
.duplicate-list {
    max-height: 300px;
    overflow-y: auto;
    margin: 20px 0;
    background: var(--background);
    border-radius: 8px;
    padding: 16px;
}

.duplicate-item {
    padding: 10px;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
}

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

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

/* Responsive */
@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .header-stats {
        flex-wrap: wrap;
        justify-content: center;
    }

    .upload-box {
        padding: 40px 20px;
    }

    .filter-group {
        min-width: 100%;
    }

    .table-header {
        flex-direction: column;
        gap: 16px;
    }

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

    .winner-actions .btn {
        width: 100%;
    }
}

/* Loading animation for filter options */
.loading-filters::after {
    content: 'Cargando...';
    color: var(--text-muted);
    font-style: italic;
}

/* ==========================================
   CONFIG PAGE SPECIFIC STYLES
   ========================================== */

/* Header with actions */
.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-actions {
    display: flex;
    gap: 12px;
}

.mode-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Stats Bar */
.stats-bar {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.stat-item {
    background: var(--surface);
    padding: 20px 30px;
    border-radius: 12px;
    text-align: center;
    flex: 1;
    min-width: 150px;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 8px;
}

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

/* Status Indicator */
.status-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.status-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    margin-bottom: 4px;
}

.status-dot.connected {
    background: var(--success);
    box-shadow: 0 0 10px var(--success);
    animation: status-pulse 2s ease infinite;
}

.status-dot.disconnected {
    background: var(--secondary);
}

@keyframes status-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Config Sections */
.config-panels {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.config-section {
    background: var(--surface);
    border-radius: 16px;
    padding: 24px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}

.section-header h2 {
    font-size: 1.2rem;
    color: var(--text);
}

.section-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 4px;
}

/* Column Selector Grid */
.columns-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.column-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    background: var(--surface-light);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.column-checkbox:hover {
    background: var(--border);
}

.column-checkbox input {
    width: 20px;
    height: 20px;
    accent-color: var(--primary);
    cursor: pointer;
}

.column-checkbox input:checked + span {
    color: var(--primary);
    font-weight: 600;
}

.column-checkbox span {
    color: var(--text);
    font-size: 0.95rem;
}

/* Small Button */
.btn-small {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* Winners Table (Admin View) */
.winners-list-admin {
    overflow-x: auto;
}

.winners-table .winner-row {
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.1), transparent);
}

.winners-table .winner-row:hover {
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.2), rgba(168, 85, 247, 0.1));
}

.winner-badge-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    color: white;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.85rem;
}

.winner-timestamp {
    color: var(--accent) !important;
    font-weight: 500;
    white-space: nowrap;
}

.empty-message {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

/* Raffle Control Panel */
.raffle-control {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(168, 85, 247, 0.2));
    border: 2px solid var(--primary);
    animation: control-pulse 2s ease infinite;
}

@keyframes control-pulse {
    0%, 100% { border-color: var(--primary); }
    50% { border-color: var(--accent); }
}

.raffle-control-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.raffle-control-status {
    display: flex;
    align-items: center;
    gap: 16px;
}

.control-spinner {
    width: 32px;
    height: 32px;
    border: 4px solid var(--surface-light);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.raffle-control-status span {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text);
}

.raffle-control-actions {
    display: flex;
    gap: 12px;
}

.raffle-control-actions .btn:disabled,
.raffle-control-actions .btn.btn-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Winner Info Panel */
.winner-info-panel {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.winner-info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.winner-info-header h3 {
    color: var(--accent);
    font-size: 1.1rem;
}

.winner-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    background: var(--background);
    border-radius: 12px;
    padding: 16px;
}

.winner-info-item {
    padding: 10px 14px;
    background: var(--surface-light);
    border-radius: 8px;
    border-left: 3px solid var(--primary);
}

.winner-info-item .info-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.winner-info-item .info-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    word-break: break-word;
}

/* Raffle Mode Selector */
.raffle-mode-options {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.mode-option {
    flex: 1;
    min-width: 200px;
    cursor: pointer;
}

.mode-option input[type="radio"] {
    display: none;
}

.mode-card {
    background: var(--surface-light);
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    transition: all 0.3s ease;
}

.mode-option input[type="radio"]:checked + .mode-card {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(168, 85, 247, 0.1));
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
}

.mode-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.mode-icon {
    color: var(--text-muted);
    margin-bottom: 12px;
    transition: color 0.3s ease;
}

.mode-option input[type="radio"]:checked + .mode-card .mode-icon {
    color: var(--primary);
}

.mode-title {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
}

.mode-desc {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Highlight when mode not selected */
.raffle-mode-section.highlight-required {
    animation: highlight-pulse 0.5s ease 3;
    border: 2px solid var(--danger);
}

@keyframes highlight-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    50% { box-shadow: 0 0 20px 5px rgba(239, 68, 68, 0.6); }
}

/* Warning Button (for Stop) */
.btn-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

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

.btn-large {
    padding: 16px 32px;
    font-size: 1.2rem;
}

/* Responsive adjustments for config page */
@media (max-width: 768px) {
    .header-left {
        flex-direction: column;
        text-align: center;
    }

    .stats-bar {
        flex-direction: column;
    }

    .stat-item {
        min-width: 100%;
    }

    .columns-grid {
        flex-direction: column;
    }

    .column-checkbox {
        width: 100%;
    }

    .section-header {
        flex-direction: column;
        text-align: center;
    }

    .raffle-mode-options {
        flex-direction: column;
    }

    .mode-option {
        min-width: 100%;
    }
}

/* ==========================================
   PRIZES SECTION STYLES
   ========================================== */

/* Prizes List */
.prizes-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.prize-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(249, 115, 22, 0.1));
    border: 1px solid var(--accent);
    border-radius: 8px;
    padding: 10px 14px;
}

.prize-name {
    color: var(--text);
    font-weight: 500;
}

.btn-remove-prize {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.btn-remove-prize:hover {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.2);
}

/* Prize Selector */
.prize-selector-container {
    max-width: 400px;
}

.prize-select {
    width: 100%;
    padding: 12px 16px;
    background: var(--surface-light);
    border: 2px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.prize-select:focus {
    outline: none;
    border-color: var(--accent);
}

.prize-select:hover {
    border-color: var(--accent);
}

/* Prizes Modal */
.prizes-modal {
    max-width: 600px;
}

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

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.modal-close:hover {
    color: var(--text);
}

.prize-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border);
    padding-bottom: 10px;
}

.prize-tab {
    padding: 10px 20px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    transition: all 0.2s ease;
}

.prize-tab:hover {
    color: var(--text);
    background: var(--surface-light);
}

.prize-tab.active {
    color: var(--primary);
    background: var(--surface-light);
    border-bottom: 2px solid var(--primary);
    margin-bottom: -12px;
}

.prize-tab-content {
    padding: 20px 0;
}

.prize-manual-form {
    display: flex;
    gap: 12px;
}

.prize-input {
    flex: 1;
    padding: 12px 16px;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 1rem;
}

.prize-input:focus {
    outline: none;
    border-color: var(--primary);
}

.prize-textarea {
    width: 100%;
    min-height: 150px;
    padding: 12px 16px;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.95rem;
    resize: vertical;
    font-family: inherit;
    margin-bottom: 12px;
}

.prize-textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.prize-excel-upload {
    text-align: center;
    padding: 30px;
    background: var(--background);
    border-radius: 12px;
    border: 2px dashed var(--border);
}

.prize-excel-hint {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 12px;
}

.modal-prizes-preview {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.modal-prizes-preview h3 {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.modal-prizes-list {
    max-height: 200px;
    overflow-y: auto;
    background: var(--background);
    border-radius: 8px;
    padding: 8px;
}

.modal-prize-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background 0.2s;
}

.modal-prize-item:hover {
    background: var(--surface-light);
}

/* Edit Prize Modal */
.edit-prize-modal {
    max-width: 450px;
}

.edit-prize-winner {
    color: var(--accent);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
}

.edit-prize-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.edit-prize-or {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Winner Prize Cell (in table) */
.winner-prize-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

.winner-prize-text {
    color: var(--accent) !important;
    font-weight: 500;
}

.winner-prize-text em {
    color: var(--text-muted) !important;
    font-weight: normal;
}

.btn-edit-prize {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
    opacity: 0.6;
}

.winner-row:hover .btn-edit-prize {
    opacity: 1;
}

.btn-edit-prize:hover {
    color: var(--primary);
    background: rgba(99, 102, 241, 0.2);
}
