/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Button styles */
.btn-primary {
    background-color: #c84119;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

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

.btn-primary:disabled {
    background-color: #9ca3af;
    cursor: not-allowed;
}

.btn-secondary {
    background-color: white;
    color: #111827;
    border: 1px solid #d1d5db;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    background-color: #f9fafb;
    border-color: #c84119;
}

.close-btn {
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 0.25rem;
    transition: color 0.2s ease;
}

.close-btn:hover {
    color: #111827;
}

/* Modal styles */
.modal-overlay {
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

.modal-overlay.hidden {
    display: none;
}

.modal-container {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    width: 100%;
    max-width: 70rem;
    /* max-height: 90vh; */
    overflow: hidden;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: bold;
    color: #111827;
}

.modal-content {
    /* overflow-y: auto;
    max-height: calc(90vh - 80px); */
    padding: 1.5rem;
}

/* Step indicator styles */
.step-indicator {
    display: flex;
    gap: 2rem;
    justify-content: space-between;
    margin-bottom: 2rem;
    position: relative;
}

.step-indicator::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 1.5rem;
    right: 1.5rem;
    height: 2px;
    transform: translateY(-50%);
    background-color: #e5e7eb;
    z-index: 1;
}

.step {
    display: flex;
    align-items: center;
    background: white;
    padding: 0.5rem;
    position: relative;
    z-index: 2;
    flex: 1;
    max-width: 200px;
}

.step-number {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background-color: #f3f4f6;
    color: #9ca3af;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 0.75rem;
    transition: all 0.2s ease;
}

.step.active .step-number,
.step.completed .step-number {
    background-color: #c84119;
    color: white;
}

.step-info {
    flex: 1;
}

.step-title {
    font-weight: 600;
    color: #111827;
    font-size: 0.75rem;
}

.step-description {
    font-size: 0.65rem;
    color: #6b7280;
}

/* Step content styles */
.step-content {
    display: none;
}

.step-content.active {
    display: block;
}

.step-header {
    text-align: center;
    margin-bottom: 2rem;
}

.step-header h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: #111827;
    margin-bottom: 0.5rem;
}

.step-header p {
    color: #6b7280;
}

/* Utility classes */
/* .modal-overlay .hidden {
    display: none !important;
} */

/* Club selection styles */
.clubs-grid {
    display: grid;
    gap: 1rem;
}

.club-card {
    background: white;
    border: 2px solid #ffffff;
    border-radius: 0.5rem;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: rgba(0, 0, 0, 0.1) 0px 0px 5px 0px, rgba(0, 0, 0, 0.1) 0px 0px 1px 0px;
}

.club-card:hover {
    border-color: #c84119;
    background-color: #fef7f0;
}

.club-card.selected {
    border-color: #c84119;
    background-color: #c84119;
    color: white;
}

.club-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.club-header h4 {
    font-size: 1.125rem;
    font-weight: 600;
}

.club-badge {
    background-color: #fbbf24;
    color: #111827;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.club-card.selected .club-badge {
    color: white;
    background-color: rgba(255, 255, 255, 0.2);
}

.club-address {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: #6b7280;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.club-card.selected .club-address {
    color: rgba(255, 255, 255, 0.8);
}

.club-features {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.feature {
    background-color: #f3f4f6;
    color: #374151;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
}

.club-card.selected .feature {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.club-hours {
    font-size: 0.875rem;
    color: #059669;
    font-weight: 500;
}

.club-card.selected .club-hours {
    color: rgba(255, 255, 255, 0.9);
}

/* Date and event selection styles */
.date-event-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 1024px) {
    .date-event-container {
        grid-template-columns: 1fr;
    }
}

.date-selection,
.event-selection,
.time-selection {
    background: white;
    border-radius: 0.5rem;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.section-header svg {
    color: #c84119;
    margin-right: 0.5rem;
}

.section-header h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
}

.dates-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.date-item {
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    background: white;
}

.date-item:hover {
    background-color: #fef7f0;
    border-color: #c84119;
}

.date-item.selected {
    background-color: #c84119;
    border-color: #c84119;
    color: white;
}

.date-main,
.time-slot-main {
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.date-sub {
    font-size: 0.875rem;
    color: #6b7280;
}

.date-item.selected .date-sub {
    color: rgba(255, 255, 255, 0.8);
}

.time-slot-item {
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    background: white;
}

.time-slot-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.time-slot-list:has(> .step-status-message:only-child) {
    display: grid;
    place-items: center;
    grid-template-columns: 1fr;
}

.time-slot-item:hover {
    background-color: #fef7f0;
    border-color: #c84119;
}

.time-slot-item.selected {
    background-color: #c84119;
    border-color: #c84119;
    color: white;
}

.events-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.step-status-message {
    text-align: center;
    padding: 1.5rem;
    color: #6b7280;
}

.event-item {
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    background: white;
    width: 100%;
}

.event-item:hover:not(.full):not(.selected) {
    background-color: #fef7f0;
    border-color: #c84119;
}

.event-item.selected {
    background-color: #c84119;
    border-color: #c84119;
    color: white;
}

.event-item.full {
    background-color: #f9fafb;
    color: #9ca3af;
    border-color: #e5e7eb;
    cursor: not-allowed;
}

.event-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.event-name {
    font-weight: 600;
    font-size: 1.125rem;
}

.event-price {
    color: #065f46;
    background-color: #d1fae5;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.event-spots {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.spots-available {
    background-color: #d1fae5;
    color: #065f46;
}

.spots-low {
    background-color: #fef3c7;
    color: #92400e;
}

.spots-full {
    background-color: #fee2e2;
    color: #991b1b;
}

.event-description {
    font-size: 0.875rem;
    color: #6b7280;
}

.event-item .toggle-link {
    color: #c84119;
    font-weight: 600;
}

.event-item .toggle-link:hover {
    text-decoration: underline;
    transition: all 0.2s ease;
}

.event-item.selected .toggle-link {
    color: rgba(255, 255, 255, 0.8);
}

.event-item.selected .event-description {
    color: rgba(255, 255, 255, 0.8);
}

/* Form styles */
.user-form {
    max-width: 500px;
    margin: 0 auto 2rem auto;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-weight: 500;
    color: #111827;
    margin-bottom: 0.5rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #c84119;
    box-shadow: 0 0 0 3px rgba(200, 65, 25, 0.1);
}

.form-group input.error {
    border-color: #ef4444;
}

/* Confirmation styles */
.confirmation-card {
    background: white;
    border-radius: 0.5rem;
    padding: 2rem;
    border: 1px solid #e5e7eb;
    margin-bottom: 2rem;
}

.confirmation-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f3f4f6;
}

.confirmation-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.confirmation-section h4 {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.75rem;
}

.confirmation-section h4 svg {
    color: #c84119;
    margin-right: 0.5rem;
}

.confirmation-content {
    background-color: #f2f2f2;
    padding: 1rem;
    border-radius: 0.5rem;
}

.detail-main {
    font-weight: 500;
    color: #111827;
    margin-bottom: 0.25rem;
}

.detail-sub {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.detail-sub:last-child {
    margin-bottom: 0;
}

.important-note {
    background-color: #fef7f0;
    border: 1px solid #fed7aa;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1.5rem;
}

.important-note p {
    font-size: 0.875rem;
    color: #c84119;
    margin: 0;
}

/* Success view styles */
.success-content {
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
}

.success-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #10b981;
    margin-bottom: 1.5rem;
}

.success-content h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: #111827;
    margin-bottom: 0.5rem;
}

.success-content p {
    color: #6b7280;
    margin-bottom: 2rem;
}

.success-details {
    background-color: #fef7f0;
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
    text-align: left;
}

.success-details h4 {
    font-weight: 600;
    color: #c84119;
    margin-bottom: 1rem;
}

.success-detail-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.success-detail-item svg {
    color: #c84119;
    margin-right: 0.5rem;
}

.success-detail-item:last-child {
    margin-bottom: 0;
}

.success-details-action {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(2, 1fr);
}

/* Step navigation */
.step-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
}

/* Loading state for confirm button */
.btn-primary.loading {
    position: relative;
    color: transparent;
}

.btn-primary.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1.25rem;
    height: 1.25rem;
    margin: -0.65rem 0 0 -0.65rem;
    border: 3px solid transparent;
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Responsive design */
@media (max-width: 768px) {
    .modal-container {
        margin: 0.5rem;
        max-width: calc(100vw - 1rem);
    }

    .hero-section h2 {
        font-size: 2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .step-indicator {
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }

    .step {
        min-width: 150px;
    }

    .step-navigation {
        flex-direction: column;
        gap: 1rem;
    }

    .step-navigation .btn-primary,
    .step-navigation .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .time-slot-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
}
