/**
 * Ticket Exchange Styles
 */

/* General */
.tex-my-tickets,
.tex-marketplace {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
}

.tex-error,
.tex-no-tickets,
.tex-no-listings {
    padding: 20px;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    text-align: center;
}

/* My Tickets */
.tex-tickets-list {
    display: grid;
    gap: 20px;
    margin-top: 20px;
}

.tex-ticket-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #fff;
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.tex-ticket-item:hover {
    border-color: #0073aa;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.tex-ticket-item.tex-listed {
    border-color: #46b450;
    background: #f7fcf7;
}

.tex-ticket-info h3 {
    margin: 0 0 10px 0;
    font-size: 20px;
    color: #23282d;
}

.tex-ticket-date,
.tex-ticket-seat,
.tex-ticket-type,
.tex-ticket-price {
    margin: 5px 0;
    color: #555;
}

.tex-ticket-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-end;
}

.tex-listed-badge {
    display: inline-block;
    padding: 5px 15px;
    background: #46b450;
    color: #fff;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
}

/* Marketplace */
.tex-listings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.tex-listing-card {
    background: #fff;
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.tex-listing-card:hover {
    border-color: #0073aa;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tex-listing-header {
    padding: 20px;
    background: #f7f7f7;
    border-bottom: 1px solid #e1e1e1;
}

.tex-listing-header h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #23282d;
}

.tex-listing-date {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.tex-listing-body {
    padding: 20px;
}

.tex-listing-seat,
.tex-listing-type,
.tex-listing-price,
.tex-listing-notes {
    margin: 10px 0;
    font-size: 14px;
    color: #555;
}

.tex-listing-footer {
    padding: 0 20px 20px 20px;
}

/* Buttons */
.tex-btn {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
}

.tex-btn-primary {
    background: #0073aa;
    color: #fff;
}

.tex-btn-primary:hover {
    background: #005177;
}

.tex-btn-secondary {
    background: #fff;
    color: #555;
    border: 1px solid #ccc;
}

.tex-btn-secondary:hover {
    background: #f7f7f7;
}

.tex-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Modal */
.tex-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
}

.tex-modal-content {
    position: relative;
    background-color: #fff;
    margin: 5% auto;
    padding: 30px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.tex-modal-close {
    position: absolute;
    right: 15px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
}

.tex-modal-close:hover {
    color: #000;
}

.tex-modal h3 {
    margin-top: 0;
    margin-bottom: 20px;
}

/* Form */
.tex-form-group {
    margin-bottom: 20px;
}

.tex-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #23282d;
}

.tex-form-group input[type="text"],
.tex-form-group input[type="email"],
.tex-form-group input[type="tel"],
.tex-form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
}

.tex-form-group textarea {
    resize: vertical;
}

.tex-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* Loading */
.tex-loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.8);
    color: #fff;
    padding: 20px 40px;
    border-radius: 8px;
    z-index: 10000;
}

/* Responsive */
@media (max-width: 768px) {
    .tex-ticket-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .tex-ticket-actions {
        width: 100%;
        align-items: stretch;
        margin-top: 15px;
    }

    .tex-ticket-actions .tex-btn {
        width: 100%;
    }

    .tex-listings-grid {
        grid-template-columns: 1fr;
    }

    .tex-modal-content {
        margin: 10% auto;
        padding: 20px;
    }
}
