/* FILE: /home/andrew/Projects/dsfamilyphoto/static/css/pages/mini_sessions.css */

/* --- CRITICAL FIXES FOR SCROLLING --- */
body.mini_sessions_layout {
    overflow-y: auto !important;
    height: auto !important;
    background-color: #f9fafb;
}

body.mini_sessions_layout .home_layout {
    height: auto !important;
    min-height: 100svh;
    overflow: visible !important;
}

body.mini_sessions_layout .home_content {
    flex: 1;
    height: auto !important;
    overflow: visible !important;
    max-width: 1200px;
    padding-top: 40px;
    padding-bottom: 80px;
    margin: 0 auto;
}

/* --- 1. Header Block --- */
.page_header_block {
    width: 100%;
    text-align: center;
    margin-bottom: 32px;
    position: relative;
}

.session_title {
    font-size: 36px;
    margin: 0 0 8px 0;
    color: var(--color-text-primary);
    font-weight: 700;
}

.session_location {
    font-size: 18px;
    color: var(--color-text-secondary);
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* --- 2. Main Grid --- */
.checkout_grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 0 16px;
    align-items: start;
}

/* --- Booking Column --- */
.booking_column {
    /* On mobile, full width */
    width: 100%;
    scroll-margin-top: 80px;
}

/* --- Details Grid --- */
.details_grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

/* --- Left Column Styling (now part of details_grid) --- */
.info_card,
.location_card {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.highlight_dates {
    background-color: #fff5f5;
    color: #c41e3a;
    padding: 16px;
    border-radius: var(--radius-sm);
    font-size: 18px;
    text-align: center;
    margin-bottom: 24px;
    border: 1px solid #c41e3a;
}

.highlight_dates i {
    margin-right: 6px;
}

.feature_list {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
}

.feature_list li {
    margin-bottom: 16px;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--color-text-primary);
}

.feature_list .icon {
    width: 24px;
    text-align: center;
    color: var(--color-success);
    font-size: 18px;
}

.session_location i {
    color: var(--color-accent);
}

/* Floating Book Now Button */
.floating_book_button {
    position: fixed;
    bottom: 24px;
    right: 24px;
    padding: 14px 24px;
    /* FIX: Ensure opaque background */
    background: #ffffff;
    color: #333;
    border: 2px solid #333;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    /* FIX: Transition visibility and transform */
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
    /* FIX: Lowered z-index (from 1000) to ensure it stays behind mobile menu */
    z-index: 990;
    display: flex;
    align-items: center;
    gap: 8px;
    opacity: 1;
    visibility: visible;
}

/* FIX: Class used by IntersectionObserver to hide the button */
.floating_book_button.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.floating_book_button:hover {
    /* FIX: Ensure opaque background on hover */
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
}

.floating_book_button .button_text {
    font-size: 16px;
    font-weight: 600;
}

.floating_book_button i {
    font-size: 16px;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-4px);
    }

    60% {
        transform: translateY(-2px);
    }
}

.policy_note {
    font-size: 14px;
    color: var(--color-text-light);
    background: #f9fafb;
    padding: 12px;
    border-radius: var(--radius-sm);
    display: flex;
    gap: 10px;
    align-items: flex-start;
    line-height: 1.5;
}

.location_card h3 {
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.location_card p {
    font-size: 15px;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
}

.address {
    font-size: 16px;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}

.arrival_note {
    color: #d32f2f;
    font-weight: 500;
    margin-bottom: 0;
}


/* --- Right Column (Checkout Card) --- */
.checkout_card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--color-border-light);
    overflow: hidden;
}

.checkout_header {
    background-color: #f4f4f4;
    padding: 20px 24px;
    border-bottom: 1px solid var(--color-border);
}

.checkout_header h3 {
    margin: 0 0 6px 0;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-text-light);
}

.price_row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: 600;
    color: var(--color-text-primary);
}

.price_tag {
    font-size: 24px;
    color: #333;
}

.checkout_body {
    padding: 24px;
}

.step_title {
    margin: 0 0 16px 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--color-text-primary);
}

/* Slots */
.slots_grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 24px;
    max-height: 350px;
    overflow-y: auto;
    padding-right: 4px;
}

.slots_grid::-webkit-scrollbar {
    width: 6px;
}

.slots_grid::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.slots_grid::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.slots_date_header {
    grid-column: 1 / -1;
    font-size: 12px;
    color: var(--color-text-light);
    margin-top: 12px;
    margin-bottom: 6px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.slot_btn {
    padding: 10px 4px;
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--color-text-primary);
    transition: all 0.2s ease;
}

.slot_btn:hover:not(:disabled) {
    border-color: var(--color-primary);
    background: #f0f0f0;
}

.slot_btn.selected {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.slot_btn:disabled {
    background: #fafafa;
    color: #ddd;
    border-color: #eee;
    cursor: not-allowed;
    text-decoration: line-through;
}

/* Timer & Selected Display */
.timer_banner {
    background-color: #e3f2fd;
    color: #0d47a1;
    border: 1px solid #bbdefb;
    padding: 12px;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 12px;
    /* Reduced margin */
    display: none;
    animation: fadeIn 0.3s ease;
}

.selected_slot_display {
    background-color: #f0fdf4;
    /* Light green */
    border: 1px solid #bbf7d0;
    color: #15803d;
    padding: 12px;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 24px;
    display: none;
    animation: fadeIn 0.3s ease;
}

/* Form */
.booking_form {
    display: none;
    animation: fadeIn 0.3s ease;
    border-top: 1px solid var(--color-border-light);
    padding-top: 24px;
}

.booking_form.visible {
    display: block;
}

.form_step {
    display: none;
    animation: slideIn 0.3s ease;
}

.form_step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.booking_form .form_group {
    margin-bottom: 16px;
}

.booking_form .form_label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    color: #444;
}

.booking_form .form_input,
.booking_form .form_textarea {
    background: #fcfcfc;
    width: 100%;
    padding: 12px;
    border: 1px solid var(--color-border-dark);
    border-radius: 6px;
    font-size: 15px;
}

.people_count_group {
    display: flex;
    gap: 12px;
}

.people_input_wrapper {
    flex: 1;
}

.checkbox_group {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px;
    background: #f9fafb;
    border-radius: 6px;
    border: 1px solid var(--color-border);
}

.checkbox_group input {
    margin-top: 4px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.checkbox_group label {
    font-size: 13px;
    color: #555;
    margin: 0;
    font-weight: 400;
    line-height: 1.4;
}

.form_actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.form_actions button {
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
}

.btn_spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    /* No margin needed if we rely on flex spacing or just absolute positioning, 
       but here we want it to take space on the left. */
}

.btn_text {
    flex: 1;
    text-align: center;
    /* Offset the spinner width to truly center visually if desired, 
       but simple flex:1 is usually good enough. */
    margin-left: -20px;
    /* Pull back to center since spinner takes space? 
       Actually, let's just let it center in the remaining space. */
    margin-left: 0;
}

/* Refined layout: Spinner on left, text centered in remaining space */
.form_actions button .btn_spinner {
    margin-right: 10px;
}

.form_actions button .btn_text {
    /* To make it look centered relative to the button width, 
       we might need a different approach, but flex:1 centers it in the *remaining* space.
       To center absolute to the button, we'd need absolute positioning for the spinner.
       Let's try the flex approach first as requested. */
    flex: 1;
    text-align: center;
}

.btn_secondary {
    background: #fff;
    border: 1px solid var(--color-border-dark);
    color: #555;
    padding: 12px 24px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 600;
}

.btn_secondary:hover {
    background: #f4f4f4;
}

.payment_group {
    background: #f9fafb;
    padding: 16px;
    border-radius: 6px;
    border: 1px solid var(--color-border);
    margin-bottom: 24px;
}

.secure_badge {
    float: right;
    font-size: 11px;
    color: var(--color-success);
    font-weight: normal;
    display: flex;
    align-items: center;
    gap: 4px;
}

#card-element {
    background: white;
    padding: 12px;
    border: 1px solid var(--color-border-dark);
    border-radius: 4px;
}

.w-100 {
    width: 100%;
}

.secure_footer_text {
    text-align: center;
    font-size: 12px;
    color: #999;
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 6px;
    align-items: center;
}

.error_message {
    color: #d32f2f;
    font-size: 13px;
    margin-top: 8px;
    display: none;
}

/* --- DESKTOP LAYOUT --- */
@media (min-width: 900px) {
    .checkout_grid {
        /* Keep 1 column for main grid */
        grid-template-columns: 1fr;
    }

    .details_grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
        align-items: start;
    }

    .booking_column {
        /* No sticky needed if it's on top */
        position: static;
    }
}

/* --- Preview Image --- */
.preview_image_container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.session_preview_image {
    width: 100%;
    height: auto;
    object-fit: contain;
    object-position: center;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--color-border);
    display: block;
}

/* --- FAQ Section --- */
.faq_section {
    padding: 24px 0;
}

.booking_column {
    max-width: 100%;
    margin: 0;
}

.faq_section h2 {
    text-align: center;
    margin-bottom: 24px;
    font-size: 28px;
    color: var(--color-text-primary);
}

.faq_list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq_item {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.faq_question {
    padding: 16px;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
    position: relative;
    font-size: 16px;
    color: var(--color-text-primary);
}

.faq_question::-webkit-details-marker {
    display: none;
}

.faq_question::after {
    content: '+';
    position: absolute;
    right: 16px;
    font-weight: 400;
    font-size: 20px;
    color: var(--color-text-light);
}

details[open] .faq_question::after {
    content: '-';
}

.faq_answer {
    padding: 0 16px 16px 16px;
    color: var(--color-text-secondary);
    line-height: 1.6;
    font-size: 15px;
}

.faq_answer p {
    margin: 0;
}

/* --- Carousel Styles --- */
.mini_session_carousel {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.session_preview_image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

.session_preview_image.active {
    opacity: 1;
    z-index: 1;
}



/* Carousel Controls & Indicators */
.carousel_controls {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    pointer-events: none;
    padding: 0 16px;
    box-sizing: border-box;
    z-index: 10;
}

.carousel_prev,
.carousel_next {
    background-color: rgba(255, 255, 255, 0.8);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 20px;
    cursor: pointer;
    pointer-events: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    transition: background-color 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.carousel_prev:hover,
.carousel_next:hover {
    background-color: #fff;
}

.carousel_indicators {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.carousel_dot {
    width: 10px;
    height: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
}

.carousel_dot.active {
    background-color: #c41e3a;
}