/* =====================================================
   Range Reservation System — Frontend Styles
   ===================================================== */

/* --- Booking Form Container --- */
/* Prevent WC/theme styles from affecting the form wrapper */
form.cart:has(.rrs-booking-form) {
    margin: 0;
    padding: 0;
}

.rrs-booking-form {
    margin: 28px 0;
    padding: 28px 28px 28px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-top: 4px solid #2563eb;
    border-radius: 0 0 10px 10px;
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.06),
        0 6px 16px rgba(0, 0, 0, 0.04);
    /* Prevent Divi/theme overrides on inner elements */
    line-height: 1.5;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.rrs-booking-form *,
.rrs-booking-form *::before,
.rrs-booking-form *::after {
    box-sizing: border-box;
}

.rrs-booking-form h3 {
    margin: 0 0 22px 0;
    padding: 0;
    border-bottom: none;
    font-size: 1.3em;
    color: #111827;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

/* --- Form Fields --- */
.rrs-form-field {
    margin-bottom: 20px;
}

.rrs-form-field:last-of-type {
    margin-bottom: 0;
}

/* Hidden fields shouldn't contribute spacing */
.rrs-form-field[style*="display: none"],
.rrs-form-field[style*="display:none"] {
    margin: 0;
}

.rrs-form-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.92em;
    color: #374151;
    letter-spacing: 0.01em;
}

.rrs-form-field .required {
    color: #dc2626;
    margin-left: 1px;
}

.rrs-form-field input[type="date"],
.rrs-form-field input[type="time"],
.rrs-form-field input[type="number"],
.rrs-form-field select,
.rrs-form-field textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.95em;
    color: #1f2937;
    background-color: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
    box-sizing: border-box;
    appearance: auto;
    line-height: 1.4;
    height: 46px;
    font-family: inherit;
}

/* Custom dropdown arrow for selects */
.rrs-form-field select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M2.22 4.47a.75.75 0 0 1 1.06 0L6 7.19l2.72-2.72a.75.75 0 1 1 1.06 1.06l-3.25 3.25a.75.75 0 0 1-1.06 0L2.22 5.53a.75.75 0 0 1 0-1.06z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 12px;
    padding-right: 38px;
}

.rrs-form-field input[type="date"]:hover,
.rrs-form-field input[type="time"]:hover,
.rrs-form-field input[type="number"]:hover,
.rrs-form-field select:hover,
.rrs-form-field textarea:hover {
    border-color: #9ca3af;
}

.rrs-form-field input[type="date"]:focus,
.rrs-form-field input[type="time"]:focus,
.rrs-form-field input[type="number"]:focus,
.rrs-form-field select:focus,
.rrs-form-field textarea:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
    background-color: #fafbff;
}

.rrs-form-field select:disabled,
.rrs-form-field input:disabled {
    background-color: #f8fafc;
    color: #94a3b8;
    cursor: not-allowed;
    border-color: #e2e8f0;
}

/* Placeholder-style text for selects with no value chosen */
.rrs-form-field select option[value=""] {
    color: #94a3b8;
}

.rrs-form-field textarea {
    resize: vertical;
    min-height: 80px;
    height: auto;
}

.rrs-form-field .description {
    display: block;
    margin-top: 6px;
    font-size: 0.82em;
    color: #6b7280;
}

/* --- Availability Message --- */
.rrs-availability-message {
    font-size: 0.875em;
}

/* Collapse the container when it has no content */
.rrs-availability-message:empty {
    display: none;
}

/* Only add spacing when there's actual content */
.rrs-availability-message:not(:empty) {
    margin: 16px 0 4px 0;
}

.rrs-availability-message .loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 8px;
    font-style: normal;
    font-weight: 500;
}

@keyframes rrs-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.rrs-availability-message .loading::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #9ca3af;
    animation: rrs-pulse 1.2s ease-in-out infinite;
}

.rrs-availability-message .success {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: #f0fdf4;
    color: #166534;
    border-radius: 8px;
    font-weight: 600;
    border: 1px solid #bbf7d0;
}

.rrs-availability-message .success::before {
    content: '✓';
    font-size: 1em;
    font-weight: 700;
}

.rrs-availability-message .error {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: #fef2f2;
    color: #991b1b;
    border-radius: 8px;
    font-weight: 600;
    border: 1px solid #fecaca;
}

.rrs-availability-message .error::before {
    content: '✕';
    font-size: 1em;
    font-weight: 700;
}

/* --- No Sessions Message --- */
.rrs-no-sessions {
    color: #6b7280;
    font-style: normal;
    text-align: center;
    padding: 32px 20px;
    margin: 0;
    background: #f9fafb;
    border: 2px dashed #e5e7eb;
    border-radius: 10px;
    font-size: 0.95em;
    line-height: 1.5;
}

/* --- Add to Cart / Book Now Button --- */
.rrs-add-to-cart {
    margin-top: 20px;
    padding-top: 0;
}

.rrs-add-to-cart .single_add_to_cart_button,
.rrs-add-to-cart .button.alt,
.rrs-add-to-cart .rrs-open-modal-btn,
.rrs-booking-form .single_add_to_cart_button {
    display: block;
    width: 100%;
    padding: 14px 24px;
    font-size: 0.95em;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: none;
    text-align: center;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
    line-height: 1.4;
    position: relative;
    z-index: 0;
    min-height: 48px;
    font-family: inherit;

    /* Inherit WooCommerce theme button color via CSS variable with fallback */
    background-color: var(--wc-button-background-color, #2563eb);
    color: var(--wc-button-color, #fff);
}

.rrs-add-to-cart .single_add_to_cart_button:hover:not(:disabled),
.rrs-add-to-cart .button.alt:hover:not(:disabled),
.rrs-add-to-cart .rrs-open-modal-btn:hover:not(:disabled),
.rrs-booking-form .single_add_to_cart_button:hover:not(:disabled) {
    background-color: var(--wc-button-background-color-hover, #1d4ed8);
    color: var(--wc-button-color, #fff);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.rrs-add-to-cart .single_add_to_cart_button:active:not(:disabled),
.rrs-add-to-cart .button.alt:active:not(:disabled),
.rrs-add-to-cart .rrs-open-modal-btn:active:not(:disabled),
.rrs-booking-form .single_add_to_cart_button:active:not(:disabled) {
    box-shadow: none;
    background-color: var(--wc-button-background-color-hover, #1e40af);
}

.rrs-add-to-cart .single_add_to_cart_button:disabled,
.rrs-add-to-cart .button.alt:disabled,
.rrs-add-to-cart .rrs-open-modal-btn:disabled,
.rrs-booking-form .single_add_to_cart_button:disabled {
    cursor: not-allowed;
    box-shadow: none;
    background-color: #e2e8f0;
    color: #94a3b8;
    opacity: 1;
    border: none;
}

/* --- My Account — Reservations Table --- */
.woocommerce-MyAccount-content .status-confirmed {
    color: #2e7d32;
    font-weight: 600;
}

.woocommerce-MyAccount-content .status-pending {
    color: #e65100;
    font-weight: 600;
}

.woocommerce-MyAccount-content .status-cancelled {
    color: #c62828;
    font-weight: 600;
}

/* --- Reservation Details (Order/Cart) --- */
.reservation-details {
    margin-top: 10px;
    padding: 10px 14px;
    background: #f7f9fc;
    border-left: 3px solid #2271b1;
    border-radius: 0 4px 4px 0;
    font-size: 0.88em;
    line-height: 1.7;
    color: #444;
}

.reservation-details strong {
    color: #222;
}

/* --- Calendar View --- */
.rrs-calendar-view .rrs-slot.available {
    background: #006d08;
    border-color: #a5d6a7;
    cursor: pointer;
    transition: background 0.15s ease, box-shadow 0.15s ease;
}

.rrs-calendar-view .rrs-slot.available:hover {
    background: #c8e6c9;
    box-shadow: inset 0 0 0 2px #43a047;
}

.rrs-calendar-view .rrs-slot.selected {
    background: #1565c0 !important;
    color: #fff !important;
    box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.25);
    z-index: 5;
}

.rrs-calendar-view .rrs-slot.held {
    background: #fff8e1;
    border-color: #ffe082;
}

.rrs-calendar-view .rrs-slot.my_hold {
    background: #e3f2fd;
    border-color: #1565c0;
    border-width: 2px;
    cursor: default;
}

.rrs-calendar-view .rrs-slot.pending {
    background: #fd7e14;
    border-color: #e8690a;
    color: #fff;
    cursor: not-allowed;
}

.rrs-calendar-view .rrs-hold-badge {
    position: absolute;
    top: 3px;
    right: 3px;
    background: #1565c0;
    color: #fff;
    font-size: 9px;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .rrs-booking-form {
        padding: 22px 18px 22px;
        margin: 20px 0;
        border-radius: 0 0 8px 8px;
    }

    .rrs-booking-form h3 {
        font-size: 1.15em;
        margin-bottom: 16px;
    }

    .rrs-form-field {
        margin-bottom: 16px;
    }

    .rrs-form-field input[type="date"],
    .rrs-form-field input[type="time"],
    .rrs-form-field input[type="number"],
    .rrs-form-field select,
    .rrs-form-field textarea {
        font-size: 16px; /* Prevents iOS zoom */
        padding: 12px 14px;
        height: 50px; /* Touch-friendly target */
    }

    .rrs-form-field textarea {
        height: auto;
    }

    .rrs-form-field select {
        padding-right: 40px;
    }

    .rrs-add-to-cart .single_add_to_cart_button,
    .rrs-add-to-cart .button.alt,
    .rrs-add-to-cart .rrs-open-modal-btn,
    .rrs-booking-form .single_add_to_cart_button {
        padding: 14px 20px;
        font-size: 0.95em;
        min-height: 50px;
    }

    .rrs-availability-message .loading,
    .rrs-availability-message .success,
    .rrs-availability-message .error {
        font-size: 0.85em;
        padding: 8px 12px;
    }

    .rrs-calendar-view .rrs-calendar-row {
        grid-template-columns: 60px repeat(auto-fit, minmax(80px, 1fr));
    }
}


/* =====================================================
   Waiver Integration Styles (merged from range-waiver-integrations)
   ===================================================== */

/* Waiver status notice (shown on booking calendar) */
.rwi-waiver-status-notice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 18px;
    border-radius: 6px;
    margin-bottom: 20px;
    border: 1px solid transparent;
    font-size: 14px;
    line-height: 1.5;
}

.rwi-waiver-status-notice .rwi-status-icon {
    flex-shrink: 0;
    font-size: 20px;
    line-height: 1;
    margin-top: 1px;
}

.rwi-waiver-status-notice .rwi-status-content {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

/* Status variants */
.rwi-waiver-status-notice.rwi-status-valid {
    background: #f0fdf4;
    border-color: #86efac;
    color: #166534;
}

.rwi-waiver-status-notice.rwi-status-valid .rwi-status-icon { color: #16a34a; }

.rwi-waiver-status-notice.rwi-status-expiring_soon {
    background: #fffbeb;
    border-color: #fcd34d;
    color: #92400e;
}

.rwi-waiver-status-notice.rwi-status-expiring_soon .rwi-status-icon { color: #d97706; }

.rwi-waiver-status-notice.rwi-status-expired,
.rwi-waiver-status-notice.rwi-status-none {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #991b1b;
}

.rwi-waiver-status-notice.rwi-status-expired .rwi-status-icon,
.rwi-waiver-status-notice.rwi-status-none .rwi-status-icon { color: #dc2626; }

/* Buttons inside the status notice */
.rwi-waiver-status-notice .rwi-sign-waiver-btn,
.rwi-waiver-status-notice .rwi-renew-waiver-btn {
    display: inline-block;
    padding: 5px 14px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    background: #2271b1;
    color: #fff;
    border: none;
    cursor: pointer;
    white-space: nowrap;
}

.rwi-waiver-status-notice .rwi-sign-waiver-btn:hover,
.rwi-waiver-status-notice .rwi-renew-waiver-btn:hover {
    background: #135e96;
    color: #fff;
}

/* Refresh / check status button */
.rwi-refresh-status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    background: transparent;
    border: 1px solid currentColor;
    cursor: pointer;
    opacity: 0.7;
    color: inherit;
    white-space: nowrap;
}

.rwi-refresh-status:hover { opacity: 1; }
.rwi-refresh-status:disabled { cursor: not-allowed; opacity: 0.4; }

/* Spinning animation for the refresh icon */
@keyframes rwi-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

.rwi-refresh-status .dashicons.rotating {
    animation: rwi-spin 1s linear infinite;
    display: inline-block;
}

/* Shortcode waiver status box */
.rwi-waiver-status-box {
    padding: 18px 22px;
    border-radius: 6px;
    margin: 15px 0;
    border: 1px solid transparent;
}

.rwi-waiver-status-box h3 { margin: 0 0 8px 0; font-size: 16px; }

.rwi-waiver-status-box.status-valid { background: #f0fdf4; border-color: #86efac; color: #166534; }
.rwi-waiver-status-box.status-expiring_soon { background: #fffbeb; border-color: #fcd34d; color: #92400e; }
.rwi-waiver-status-box.status-expired,
.rwi-waiver-status-box.status-none { background: #fef2f2; border-color: #fca5a5; color: #991b1b; }

/* Sign/renew button inside shortcode box */
.rwi-waiver-status-box .rwi-button {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 18px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    background: #2271b1;
    color: #fff;
}

.rwi-waiver-status-box .rwi-button:hover { background: #135e96; color: #fff; }

/* ==========================================================================
   Party / Guest Support — frontend booking form
   ========================================================================== */

/* Container that appears below the participants selector */
.rrs-guest-list {
    margin-top: 12px;
    padding: 14px 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
}

.rrs-guest-list-title {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* One row per additional participant */
.rrs-guest-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e5e7eb;
}
.rrs-guest-row:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.rrs-guest-label {
    flex: 0 0 60px;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    white-space: nowrap;
}

/* Inputs inside guest rows */
.rrs-guest-row input[type="text"],
.rrs-guest-row input[type="email"] {
    flex: 1 1 130px;
    min-width: 100px;
    padding: 6px 10px;
    font-size: 13px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    background: #fff;
    color: #111827;
    transition: border-color 0.15s;
}
.rrs-guest-row input[type="text"]:focus,
.rrs-guest-row input[type="email"]:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 2px rgba(37,99,235,0.15);
}

/* Remove-guest (×) button */
.rrs-remove-guest {
    flex: 0 0 auto;
    background: none;
    border: none;
    padding: 4px 6px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    color: #9ca3af;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
}
.rrs-remove-guest:hover {
    color: #ef4444;
    background: #fef2f2;
}

/* Waiver badge next to email field */
.rrs-waiver-badge {
    display: inline-block;
    flex: 0 0 auto;
    min-width: 70px;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 600;
    border-radius: 12px;
    text-align: center;
    white-space: nowrap;
}
.rrs-waiver-badge::before {
    margin-right: 3px;
    font-family: dashicons;
}

/* Status variants — colours match admin badge scheme */
.rrs-waiver-unknown {
    background: #f3f4f6;
    color: #6b7280;
}
.rrs-waiver-active,
.rrs-waiver-valid {
    background: #dcfce7;
    color: #166534;
}
.rrs-waiver-active::before { content: '\f147'; } /* dashicons-yes-alt */
.rrs-waiver-valid::before  { content: '\f147'; }
.rrs-waiver-expired {
    background: #fef3c7;
    color: #92400e;
}
.rrs-waiver-expired::before { content: '\f534'; } /* dashicons-warning */
.rrs-waiver-none,
.rrs-waiver-missing {
    background: #fee2e2;
    color: #991b1b;
}
.rrs-waiver-none::before    { content: '\f335'; } /* dashicons-dismiss */
.rrs-waiver-missing::before { content: '\f335'; }

/* Responsive: stack inputs on small screens */
@media (max-width: 480px) {
    .rrs-guest-row {
        flex-direction: column;
        align-items: flex-start;
    }
    .rrs-guest-label {
        flex: 0 0 auto;
    }
    .rrs-guest-row input[type="text"],
    .rrs-guest-row input[type="email"] {
        width: 100%;
        flex: 1 1 auto;
    }
}

/* ==========================================================================
   Party / Guest Support — admin bookings table sub-row
   ========================================================================== */

/* Panel table inside the expandable sub-row */
.rrs-guest-panel-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.rrs-guest-panel-table th,
.rrs-guest-panel-table td {
    padding: 7px 10px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}
.rrs-guest-panel-table thead th {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
    background: #f9fafb;
}
.rrs-guest-panel-table tbody tr:last-child td {
    border-bottom: none;
}
.rrs-guest-panel-table tbody tr:hover {
    background: #f0f9ff;
}

/* Checked-in confirmation text */
.rrs-guest-checked-in {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: #166534;
}
.rrs-guest-checked-in .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: #16a34a;
}

/* Party button active state (sub-row open) */
.rrs-view-guests-btn.rrs-btn-active {
    background: #1e40af;
    color: #fff;
    border-color: #1e40af;
}

/* Success-variant button (Check In) */
.rrs-btn-success {
    background: #16a34a;
    color: #fff;
    border: 1px solid #15803d;
}
.rrs-btn-success:hover {
    background: #15803d;
    border-color: #166534;
}
/* ==========================================================================
        Class list – card layout
   ========================================================================== */
.rrs-class-list {
    max-width: 960px;
    margin: 0 auto;
    font-family: inherit;
}

/* ---- Month tab nav ---- */
.rrs-cl-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
    padding: 0;
    border: none;
    background: none;
}

.rrs-cl-tab {
    padding: 8px 20px;
    font-size: 14px;
    font-weight: 600;
    color: #475569;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
}

.rrs-cl-tab:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.rrs-cl-tab.is-active {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
}

/* ---- Month panels ---- */
.rrs-cl-panel {
    display: none;
}

.rrs-cl-panel.is-active {
    display: block;
}

/* ---- Card ---- */
.rrs-cl-card {
    display: flex;
    align-items: center;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-left: 4px solid #2563eb;
    border-radius: 8px;
    padding: 20px 24px;
    margin-bottom: 12px;
    transition: box-shadow 0.15s ease;
}

.rrs-cl-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* ---- Date badge (DOW / day number / month abbr) ---- */
.rrs-cl-date-badge {
    flex: 0 0 52px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    line-height: 1;
    text-align: center;
}

.rrs-cl-date-dow {
    font-size: 11px;
    font-weight: 700;
    color: #2563eb;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 2px;
}

.rrs-cl-date-day {
    font-size: 30px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1;
}

.rrs-cl-date-month {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

/* ---- Info column ---- */
.rrs-cl-info {
    flex: 1;
    min-width: 0;
}

.rrs-cl-title {
    margin: 0 0 6px 0;
    font-size: 17px;
    font-weight: 600;
    color: #1e293b;
}

.rrs-cl-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.rrs-cl-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: #64748b;
}

.rrs-cl-meta-item svg {
    flex-shrink: 0;
    opacity: 0.55;
}

/* ---- Action column (price + button) ---- */
.rrs-cl-action {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    margin-left: 24px;
    gap: 8px;
    white-space: nowrap;
}

.rrs-cl-price {
    font-size: 17px;
    font-weight: 700;
    color: #1e293b;
}

.rrs-cl-book-btn {
    display: inline-block;
    padding: 10px 22px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    color: #fff;
    background: #2563eb;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s ease, opacity 0.15s ease;
}

.rrs-cl-book-btn:hover {
    background: #1d4ed8;
}

.rrs-cl-book-btn:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

/* Button states */
.rrs-cl-book-btn.is-loading {
    opacity: 0.65;
    cursor: wait;
}

.rrs-cl-book-btn.is-added {
    background: #16a34a;
    cursor: default;
}

.rrs-cl-book-btn.is-added:hover {
    background: #16a34a;
}

/* ---- Prerequisite badge (class list) ---- */
.rrs-cl-prereq-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    color: #92400e;
    background: #fef3c7;
    border: 1px solid #fcd34d;
    border-radius: 6px;
    white-space: nowrap;
}

.rrs-cl-prereq-badge svg {
    flex-shrink: 0;
}

.rrs-cl-prereq-list {
    display: block;
    font-size: 12px;
    color: #78716c;
    line-height: 1.4;
    text-align: right;
    margin-top: 2px;
}

.rrs-cl-prereq-list a {
    color: #2563eb;
    text-decoration: none;
}

.rrs-cl-prereq-list a:hover {
    text-decoration: underline;
}

/* ---- Prerequisite notice (product page) ---- */
.rrs-prereq-notice {
    padding: 14px 18px;
    margin-bottom: 20px;
    border-radius: 8px;
    border: 1px solid #fcd34d;
    background: #fffbeb;
    color: #92400e;
    font-size: 14px;
    line-height: 1.6;
}

.rrs-prereq-notice a {
    color: #d97706;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.rrs-prereq-notice a:hover {
    color: #b45309;
}

/* ---- Responsive ---- */
@media (max-width: 640px) {
    .rrs-cl-card {
        flex-wrap: wrap;
        padding: 16px;
    }

    .rrs-cl-date-badge {
        flex: 0 0 48px;
        margin-right: 14px;
    }

    .rrs-cl-info {
        flex: 1 1 0%;
    }

    .rrs-cl-action {
        flex: 0 0 100%;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        margin-left: 0;
        margin-top: 14px;
        padding-top: 14px;
        border-top: 1px solid #f1f5f9;
    }
}