/* ═══════════════════ CHECK TICKET STYLES ═══════════════════ */

/* Check Ticket Button */
.check-ticket-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: linear-gradient(135deg, #00e676 0%, #00c853 100%);
    color: #0a1929;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-right: 10px;
}

.check-ticket-btn:hover {
    background: linear-gradient(135deg, #00ff88 0%, #00d65a 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 230, 118, 0.3);
}

.check-ticket-btn:active {
    transform: translateY(0);
}

.check-ticket-btn svg {
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .check-ticket-label {
        display: none;
    }
    .check-ticket-btn {
        padding: 8px 10px;
        margin-right: 6px;
    }
}

/* Check Ticket Overlay */
#check-ticket-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(6, 10, 15, 0.85);
    backdrop-filter: blur(4px);
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

#check-ticket-overlay.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Check Ticket Modal */
.check-ticket-modal {
    background: #0f1c2e;
    border: 1px solid #1a2942;
    border-radius: 12px;
    width: 92%;
    max-width: 620px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
    animation: slideUp 0.25s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Modal Header */
.check-ticket-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid #1a2942;
}

.check-ticket-title {
    font-size: 14px;
    font-weight: 700;
    color: #e3e9f0;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.check-ticket-close {
    background: none;
    border: none;
    color: #7a8b9d;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.check-ticket-close:hover {
    background: #1a2942;
    color: #e3e9f0;
}

/* Search Form */
.check-ticket-search {
    padding: 14px 18px;
    border-bottom: 1px solid #1a2942;
    display: flex;
    gap: 8px;
    align-items: center;
}

.check-ticket-search-input {
    flex: 1;
    min-width: 0;
    padding: 10px 14px;
    background: #0a1521;
    border: 1px solid #1a2942;
    border-radius: 7px;
    color: #e3e9f0;
    font-size: 13px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.check-ticket-search-input:focus {
    outline: none;
    border-color: #00e676;
    box-shadow: 0 0 0 3px rgba(0, 230, 118, 0.08);
}

.check-ticket-search-btn {
    flex-shrink: 0;
    padding: 10px 20px;
    background: linear-gradient(135deg, #00e676 0%, #00c853 100%);
    color: #0a1929;
    border: none;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.check-ticket-search-btn:hover {
    background: linear-gradient(135deg, #00ff88 0%, #00d65a 100%);
    box-shadow: 0 4px 12px rgba(0, 230, 118, 0.25);
}

.check-ticket-search-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

/* Ticket Content */
.check-ticket-content {
    padding: 16px 18px;
}

.ticket-info-header {
    background: #0a1521;
    border: 1px solid #1a2942;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 14px;
}

.ticket-serial {
    font-size: 13px;
    font-weight: 700;
    color: #00e676;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Ticket Info Table */
.ticket-info-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 18px;
    background: #0a1521;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #1a2942;
}

.ticket-info-table thead {
    background: #142236;
}

.ticket-info-table th {
    padding: 9px 14px;
    text-align: center;
    font-size: 10px;
    font-weight: 700;
    color: #5a7080;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.ticket-info-table td {
    padding: 10px 14px;
    color: #c8d6e0;
    font-size: 13px;
    border-top: 1px solid #1a2942;
    text-align: center;
}

/* Jugadas Section */
.jugadas-section {
    margin-top: 18px;
}

.jugadas-header {
    font-size: 11px;
    font-weight: 700;
    color: #5a7080;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.jugadas-table {
    width: 100%;
    border-collapse: collapse;
    background: #0a1521;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 16px;
    border: 1px solid #1a2942;
}

.jugadas-table thead {
    background: #142236;
}

.jugadas-table th {
    padding: 8px 10px;
    text-align: center;
    font-size: 10px;
    font-weight: 700;
    color: #5a7080;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.jugadas-table td {
    padding: 9px 10px;
    color: #c8d6e0;
    font-size: 12px;
    border-top: 1px solid #1a2942;
    text-align: center;
}

.jugadas-table td:first-child,
.jugadas-table td:nth-child(3) {
    text-align: left;
}

/* Team Cell */
.team-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

.team-logo {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.team-name {
    font-weight: 500;
}

/* Status Badge */
.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-cancelado {
    background: rgba(255, 107, 107, 0.15);
    color: #ff6b6b;
}

.status-pendiente {
    background: rgba(255, 184, 0, 0.15);
    color: #ffb800;
}

.status-ganador {
    background: rgba(0, 230, 118, 0.15);
    color: #00e676;
}

.status-perdedor {
    background: rgba(158, 158, 158, 0.15);
    color: #9e9e9e;
}

/* Clickable Event Row */
.event-clickable {
    cursor: pointer;
    transition: background 0.2s ease;
}

.event-clickable:hover {
    background: #1a2942;
}

/* Loading State */
.ticket-loading {
    text-align: center;
    padding: 40px;
    color: #7a8b9d;
}

.ticket-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #1a2942;
    border-top-color: #00e676;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Error State */
.ticket-error {
    text-align: center;
    padding: 40px;
    color: #ff6b6b;
}

.ticket-error-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

/* Empty State */
.ticket-empty {
    text-align: center;
    padding: 40px;
    color: #7a8b9d;
}

.ticket-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

/* Responsive */
@media (max-width: 640px) {
    .check-ticket-modal {
        width: 97%;
        max-height: 95vh;
        border-radius: 10px;
    }

    .check-ticket-search {
        flex-direction: column;
        gap: 8px;
    }

    .check-ticket-search-btn {
        width: 100%;
        text-align: center;
    }
    
    .ticket-info-table th,
    .ticket-info-table td,
    .jugadas-table th,
    .jugadas-table td {
        padding: 7px 6px;
        font-size: 11px;
    }
    
    .team-logo {
        width: 15px;
        height: 15px;
    }
}
