/* === Aquatique Vacances PoC — Style === */

@font-face {
    font-family: 'Pogonia';
    src: url('assets/fonts/Pogonia-Regular.otf') format('opentype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Charte Aquatique Vacances */
    --bleu-roi: #062170;
    --bleu-ciel: #8bb7cd;
    --rose-poudre: #d889a7;
    --bleu-delave: #eef6ff;

    /* Semantic mappings */
    --primary: var(--bleu-roi);
    --primary-light: #1a3a8f;
    --primary-lighter: var(--bleu-delave);
    --accent: var(--rose-poudre);
    --accent-light: #fdf0f4;
    --bg: #f4f7fb;
    --surface: #FFFFFF;
    --text: #1a1a2e;
    --text-secondary: #5a6a7a;
    --border: #d6dfe8;
    --shadow-sm: 0 1px 3px rgba(6, 33, 112, 0.06);
    --shadow-md: 0 4px 12px rgba(6, 33, 112, 0.08);
    --shadow-lg: 0 8px 24px rgba(6, 33, 112, 0.1);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);

    --font-brand: 'Pogonia', 'Inter', sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* === HEADER === */
.tunnel-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-md);
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: 24px;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.logo-icon {
    font-size: 28px;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand {
    font-family: var(--font-brand);
    font-weight: 400;
    font-size: 17px;
    letter-spacing: 0.5px;
}

.logo-img {
    height: 36px;
    width: auto;
}

.sub {
    font-size: 11px;
    opacity: 0.8;
    font-weight: 300;
}

.steps-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.step {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 24px;
    font-size: 13px;
    font-weight: 500;
    opacity: 0.6;
    transition: var(--transition);
    cursor: default;
}

.step.active {
    background: rgba(255, 255, 255, 0.2);
    opacity: 1;
}

.step-num {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.step.active .step-num {
    background: white;
    color: var(--primary);
}

.step-divider {
    width: 20px;
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
}

.secure-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    opacity: 0.8;
    flex-shrink: 0;
}

/* === LOADING === */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 200;
    transition: opacity 0.4s;
}

.loading-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 44px;
    height: 44px;
    border: 4px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-overlay p {
    margin-top: 16px;
    color: var(--text-secondary);
    font-size: 14px;
}

/* === CONTAINER === */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
}

/* === SEARCH MODE === */
.search-panel {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow-md);
}

.search-panel h2 {
    margin-bottom: 8px;
    font-size: 22px;
}

.search-subtitle {
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.search-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.form-group {
    flex: 1;
    min-width: 140px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group select,
.form-group input {
    padding: 10px 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
    background: var(--surface);
    transition: var(--transition);
    cursor: pointer;
}

.form-group select:focus,
.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-lighter);
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(6, 33, 112, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(6, 33, 112, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-search {
    padding: 10px 32px;
    height: 42px;
}

.btn-book {
    background: linear-gradient(135deg, var(--accent) 0%, #c06b8a 100%);
    color: white;
    padding: 8px 20px;
    box-shadow: 0 2px 8px rgba(216, 137, 167, 0.3);
}

.btn-book:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(216, 137, 167, 0.4);
}

/* === SEARCH RESULTS === */
.search-results {
    margin-top: 32px;
    border-top: 1px solid var(--border);
    padding-top: 24px;
}

.search-results h3 {
    margin-bottom: 16px;
    font-size: 18px;
}

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

.result-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 16px 20px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    transition: var(--transition);
}

.result-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.result-info {
    flex: 1;
}

.result-info h4 {
    font-size: 15px;
    margin-bottom: 4px;
}

.result-meta {
    font-size: 13px;
    color: var(--text-secondary);
}

.result-pricing {
    text-align: right;
    flex-shrink: 0;
}

.result-old-price {
    font-size: 13px;
    color: var(--text-secondary);
    text-decoration: line-through;
}

.result-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
}

.result-price-unit {
    font-size: 12px;
    color: var(--text-secondary);
    display: block;
}

/* === TUNNEL LAYOUT === */
.tunnel-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 24px;
    align-items: start;
}

/* === ACCORDION === */
.accordion {
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 16px;
    overflow: hidden;
    transition: var(--transition);
}

.accordion:hover {
    box-shadow: var(--shadow-md);
}

.accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px;
    cursor: pointer;
    user-select: none;
    transition: var(--transition);
}

.accordion-header:hover {
    background: var(--primary-lighter);
}

.accordion-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.accordion-title h2 {
    font-size: 17px;
    font-weight: 600;
}

.section-icon {
    font-size: 20px;
}

.accordion-arrow {
    font-size: 18px;
    transition: transform var(--transition);
    color: var(--text-secondary);
}

.accordion:not(.open) .accordion-arrow {
    transform: rotate(-90deg);
}

.accordion-body {
    padding: 0 24px 20px;
    max-height: 2000px;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
}

.accordion:not(.open) .accordion-body {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
}

/* === RESERVATION CARD === */
.reservation-summary-card {
    display: flex;
    gap: 20px;
    padding: 16px;
    background: linear-gradient(135deg, var(--bleu-delave) 0%, #d8e8f5 100%);
    border-radius: var(--radius-sm);
    border-left: 4px solid var(--primary);
}

.res-card-img {
    width: 100px;
    height: 80px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    flex-shrink: 0;
    background: var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
}

.res-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.placeholder-img {
    font-size: 32px;
    opacity: 0.5;
}

.res-card-info h3 {
    font-size: 16px;
    margin-bottom: 8px;
}

.res-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.res-detail {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.detail-icon {
    font-size: 14px;
}

/* === PARTICIPANTS === */
.participants-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.participant-control {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg);
    border-radius: var(--radius-sm);
    border: 1.5px solid var(--border);
    flex-wrap: wrap;
}

.participant-control label {
    font-size: 14px;
    font-weight: 500;
}

.participant-control .form-hint {
    width: 100%;
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
    color: var(--text-secondary);
    font-weight: 400;
    font-size: 12px;
    line-height: 1.5;
}

.counter {
    display: flex;
    align-items: center;
    gap: 4px;
}

.counter-btn {
    width: 32px;
    height: 32px;
    border: 1.5px solid var(--border);
    border-radius: 50%;
    background: var(--surface);
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    color: var(--text);
    font-weight: 300;
}

.counter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-lighter);
}

.counter-value {
    width: 36px;
    text-align: center;
    font-size: 16px;
    font-weight: 700;
}

.occupants-list {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.occupant-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: var(--primary-lighter);
    border-radius: 20px;
    font-size: 13px;
    color: var(--primary);
    font-weight: 500;
}

/* === PRODUCTS === */
.products-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-category {
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.product-category-header {
    padding: 10px 16px;
    background: var(--bg);
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.product-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 16px;
    border-top: 1px solid var(--border);
    transition: var(--transition);
}

.product-item:hover {
    background: var(--primary-lighter);
}

.product-item.mandatory {
    background: var(--accent-light);
    border-left: 3px solid var(--accent);
}

.product-info {
    flex: 1;
}

.product-name {
    font-size: 14px;
    font-weight: 500;
}

.product-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.product-price {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
}

.product-action {
    flex-shrink: 0;
}

.product-toggle {
    width: 42px;
    height: 24px;
    border-radius: 12px;
    border: none;
    background: var(--border);
    cursor: pointer;
    position: relative;
    transition: var(--transition);
}

.product-toggle::after {
    content: '';
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    position: absolute;
    top: 3px;
    left: 3px;
    transition: var(--transition);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.product-toggle.active {
    background: var(--primary);
}

.product-toggle.active::after {
    left: 21px;
}

/* === GA INSURANCE TOGGLE === */
.ga-toggle-card {
    padding: 16px;
}

.ga-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0 0 16px 0;
    line-height: 1.5;
}

.ga-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ga-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
    background: var(--bg);
}

.ga-option:hover {
    border-color: var(--primary-light);
    background: rgba(0, 51, 102, 0.03);
}

.ga-option.selected {
    border-color: var(--primary);
    background: rgba(0, 51, 102, 0.06);
    box-shadow: 0 0 0 1px var(--primary);
}

.ga-option input[type="radio"] {
    accent-color: var(--primary);
    width: 18px;
    height: 18px;
    margin: 0;
    flex-shrink: 0;
}

.ga-option-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 1;
    gap: 8px;
}

.ga-option-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.ga-option-price {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
}

.empty-state {
    text-align: center;
    padding: 24px;
    color: var(--text-secondary);
    font-size: 14px;
}

/* === STEP 2: IDENTIFICATION FORM === */
.step2-section {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}

.step2-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1.5px solid var(--border);
}

.step2-header .section-icon {
    font-size: 28px;
}

.step2-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.step2-subtitle {
    margin: 4px 0 0;
    font-size: 13px;
    color: var(--text-secondary);
}

.step2-form .form-group {
    margin-bottom: 20px;
}

.step2-form label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 6px;
}

.step2-form .required {
    color: #e74c3c;
    font-weight: 600;
}

.step2-form input[type="text"],
.step2-form input[type="email"],
.step2-form input[type="tel"],
.step2-form input[type="date"],
.step2-form select {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 14px;
    color: var(--text);
    background: var(--bg);
    transition: var(--transition);
    box-sizing: border-box;
}

.step2-form input:focus,
.step2-form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-lighter);
    background: var(--surface);
}

.step2-form input:invalid:not(:placeholder-shown) {
    border-color: #e74c3c;
}

.form-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.form-row-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.step2-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1.5px solid var(--border);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1.5px solid var(--border);
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary:hover {
    background: var(--bg);
    color: var(--text);
    border-color: var(--text-secondary);
}

/* Step nav — completed state */
.step.completed .step-num {
    background: var(--success);
    color: white;
    border-color: var(--success);
}

.step.completed .step-num::after {
    content: '✓';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.step.completed .step-num {
    font-size: 0;
    position: relative;
}

@media (max-width: 768px) {
    .form-row-2col {
        grid-template-columns: 1fr;
    }

    .step2-actions {
        flex-direction: column;
    }

    .step2-actions .btn {
        width: 100%;
    }
}

/* === SIDEBAR === */
.tunnel-sidebar {
    position: relative;
}

.sidebar-sticky {
    position: sticky;
    top: 80px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sidebar-card {
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.sidebar-header {
    padding: 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    text-align: center;
}

.sidebar-img {
    width: 100%;
    height: 120px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-header h3 {
    font-size: 16px;
    font-weight: 600;
}

.sidebar-section {
    padding: 16px 20px;
}

.sidebar-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 13px;
}

.sidebar-label {
    color: var(--text-secondary);
}

.sidebar-value {
    font-weight: 500;
}

.sidebar-value.price {
    color: var(--primary);
    font-weight: 600;
}

.sidebar-divider {
    height: 1px;
    background: var(--border);
    margin: 0 20px;
}

.sidebar-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 600;
}

.total-price {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

.sidebar-actions {
    padding: 16px 20px 20px;
}

.cgv-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    cursor: pointer;
}

.cgv-check input {
    margin-top: 2px;
    accent-color: var(--primary);
}

.cgv-check a {
    color: var(--primary);
}

.btn-next {
    width: 100%;
    padding: 14px;
    font-size: 15px;
}

/* === Lyra Krypton SmartForm === */
.lyra-smartform-section {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.lyra-smartform-section h3 {
    margin-bottom: 16px;
    font-size: 16px;
}

.lyra-smartform-container {
    min-height: 200px;
}

/* Ensure Krypton form elements are visible and properly sized */
.kr-embedded {
    width: 100% !important;
    min-height: 300px;
}

.kr-embedded .kr-field-element {
    margin-bottom: 12px;
}

.kr-embedded .kr-field-component,
.kr-embedded .kr-iframe-wrapper {
    min-height: 40px;
    height: 40px;
}

.kr-embedded .kr-field-wrapper {
    display: flex;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0 8px;
    min-height: 44px;
    background: #fff;
}

.kr-embedded .kr-field-wrapper:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(30, 75, 130, 0.15);
}

.kr-embedded .kr-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

/* Krypton payment button */
.kr-payment-button {
    width: 100%;
    padding: 14px 24px;
    margin-top: 16px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.kr-payment-button:hover {
    background: var(--primary-dark);
}

/* Krypton form error */
.kr-form-error {
    color: var(--error);
    margin-top: 8px;
    font-size: 13px;
}

/* Card holder name / email input fields */
.kr-embedded input.kr-input-field {
    width: 100%;
    border: none;
    outline: none;
    font-size: 14px;
    padding: 8px 0;
    background: transparent;
}

/* Hide representation divs (used internally by Krypton) */
.krFieldRepresentation,
.krFieldRepresentationError,
.krFieldRepresentationDisabled {
    position: absolute;
    left: -9999px;
}

/* Lyra status messages */
.lyra-status {
    padding: 16px;
    border-radius: var(--radius);
    margin-top: 16px;
    text-align: center;
    font-weight: 600;
}

.lyra-success {
    background: #e8f5e9;
    color: #2e7d32;
}

.lyra-error {
    background: #fce4ec;
    color: #c62828;
}

/* Loading spinner */
.lyra-loading {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

.lyra-loading .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--border);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 12px;
}

/* === DEBUG === */
.debug-panel {
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.debug-panel summary {
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-secondary);
}

.debug-content {
    padding: 0 16px 16px;
    font-size: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.debug-content code {
    background: var(--bg);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    word-break: break-all;
}

.debug-log {
    max-height: 200px;
    overflow-y: auto;
    margin-top: 8px;
    font-family: monospace;
    font-size: 11px;
    background: #1a1a2e;
    color: #a3ffae;
    padding: 8px;
    border-radius: 6px;
}

.debug-log .log-entry {
    padding: 2px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.debug-log .log-error {
    color: #ff6b6b;
}

.debug-log .log-success {
    color: #a3ffae;
}

.debug-log .log-info {
    color: #74b9ff;
}

/* === TOAST === */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 300;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease, fadeOut 0.3s ease 3s forwards;
    max-width: 360px;
}

.toast-success {
    background: var(--primary);
    color: white;
}

.toast-error {
    background: #D32F2F;
    color: white;
}

.toast-info {
    background: var(--bleu-ciel);
    color: var(--text);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

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

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(10px);
    }
}

/* === RESPONSIVE === */

/* --- Tablet: ≤ 900px --- */
@media (max-width: 900px) {
    .tunnel-layout {
        grid-template-columns: 1fr;
    }

    .tunnel-sidebar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 90;
        background: var(--surface);
        box-shadow: 0 -4px 16px rgba(6, 33, 112, 0.12);
        border-top: 1px solid var(--border);
    }

    .sidebar-sticky {
        position: static;
    }

    .sidebar-card {
        border-radius: 0;
        box-shadow: none;
        display: flex;
        flex-direction: column;
    }

    /* Hide sidebar details by default on mobile, show only total + actions */
    .sidebar-header,
    .sidebar-section,
    .sidebar-divider {
        display: none;
    }

    /* CTA + CGV always visible on mobile — reorder via flexbox */
    .sidebar-total {
        order: 1;
        padding: 10px 16px;
        font-size: 14px;
        cursor: pointer;
        user-select: none;
    }

    .sidebar-actions {
        order: 2;
        display: block;
        padding: 8px 16px 12px;
        border-top: 1px solid var(--border);
    }

    .sidebar-actions .cgv-check {
        margin-bottom: 8px;
        font-size: 11px;
    }

    .sidebar-actions .btn-next {
        width: 100%;
        padding: 12px;
        font-size: 14px;
    }

    .sidebar-total::after {
        content: '▲';
        font-size: 10px;
        margin-left: 8px;
        color: var(--text-secondary);
        transition: transform var(--transition);
    }

    /* When expanded via JS toggle class — drawer panel style */
    .tunnel-sidebar.mobile-expanded {
        z-index: 100;
    }

    .tunnel-sidebar.mobile-expanded .sidebar-header,
    .tunnel-sidebar.mobile-expanded .sidebar-section,
    .tunnel-sidebar.mobile-expanded .sidebar-divider {
        display: block;
    }

    .tunnel-sidebar.mobile-expanded .sidebar-total::after {
        transform: rotate(180deg);
    }

    .tunnel-sidebar.mobile-expanded .sidebar-card {
        max-height: 60vh;
        overflow-y: auto;
        border-radius: 16px 16px 0 0;
        box-shadow: 0 -8px 32px rgba(6, 33, 112, 0.2);
    }

    /* Backdrop overlay — styles moved outside @media at end of file */

    @keyframes fadeInBackdrop {
        from {
            opacity: 0;
        }

        to {
            opacity: 1;
        }
    }

    /* Debug panel hidden on mobile sidebar */
    .tunnel-sidebar .debug-panel {
        display: none !important;
    }

    /* Add bottom padding to main content to prevent sidebar overlap */
    .tunnel-main {
        padding-bottom: 150px;
    }

    .header-inner {
        flex-wrap: wrap;
        height: auto;
        padding: 12px 0;
        gap: 8px;
    }

    .steps-nav {
        order: 3;
        width: 100%;
        justify-content: center;
    }

    .step-label {
        display: none;
    }

    .secure-badge {
        display: none;
    }
}

/* --- Mobile: ≤ 600px --- */
@media (max-width: 600px) {
    .container {
        padding: 12px;
    }

    .search-panel {
        padding: 20px;
    }

    .search-panel h2 {
        font-size: 18px;
    }

    .form-row {
        flex-direction: column;
    }

    .participants-grid {
        grid-template-columns: 1fr;
    }

    .reservation-summary-card {
        flex-direction: column;
    }

    .res-card-img {
        width: 100%;
        height: 120px;
    }

    .result-card {
        flex-direction: column;
        align-items: flex-start;
        padding: 14px;
    }

    .result-pricing {
        align-self: flex-end;
    }

    /* Accordion compact on mobile */
    .accordion-header {
        padding: 14px 16px;
    }

    .accordion-body {
        padding: 0 16px 16px;
    }

    .accordion-title h2 {
        font-size: 15px;
    }

    /* Buttons — better touch targets */
    .btn {
        padding: 12px 20px;
        font-size: 15px;
        min-height: 44px;
    }

    .counter-btn {
        width: 36px;
        height: 36px;
        font-size: 20px;
    }

    /* Step 2 form compact */
    .step2-section {
        padding: 20px 16px;
    }

    /* Step 3 actions */
    .step3-actions {
        flex-direction: column;
    }

    .step3-actions .btn {
        width: 100%;
    }

    .step3-section {
        max-width: 100%;
    }

    /* Payment recap grid on mobile */
    .recap-grid {
        grid-template-columns: 1fr;
    }

    /* Dues table compact */
    .dues-row {
        padding: 10px 12px;
        font-size: 13px;
    }

    .dues-row .dues-date {
        width: auto;
        font-size: 12px;
    }

    .dues-row .dues-amount {
        width: auto;
    }

    /* Toast centered on mobile */
    .toast-container {
        left: 12px;
        right: 12px;
        bottom: 80px;
        /* above sticky sidebar */
    }

    .toast {
        max-width: 100%;
    }

    /* Modal full-screen on mobile */
    .modal-overlay {
        padding: 0;
        align-items: flex-end;
    }

    .modal-content {
        border-radius: 16px 16px 0 0;
        max-height: 90vh;
        max-width: 100%;
    }

    /* Login panel */
    .login-panel-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .login-panel-actions .btn-login {
        width: 100%;
    }

    /* Promo input stack on small screens */
    .promo-input-row {
        flex-direction: column;
    }

    .btn-promo {
        width: 100%;
    }

    /* Lyra payment form */
    .lyra-smartform-container {
        padding: 16px;
    }

    /* Additional stay cards */
    .additional-stay-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .additional-stay-price {
        margin-left: 0;
    }

    /* Header compact */
    .tunnel-header {
        padding: 0 12px;
    }

    .logo-img {
        height: 28px;
    }

    .brand {
        font-size: 14px;
    }

    .sub {
        display: none;
    }

    .step-num {
        width: 22px;
        height: 22px;
        font-size: 11px;
    }

    .step-divider {
        width: 12px;
    }
}

/* --- Small phones: ≤ 380px --- */
@media (max-width: 380px) {
    .container {
        padding: 8px;
    }

    .search-panel {
        padding: 16px;
    }

    .accordion-header {
        padding: 12px;
    }

    .accordion-body {
        padding: 0 12px 12px;
    }

    .sidebar-total {
        padding: 10px 16px;
    }

    .logo-text {
        display: none;
    }
}

/* === Login Toggle (Step 2) === */
.login-toggle {
    background: var(--primary-lighter);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    overflow: hidden;
}

.login-toggle-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    cursor: pointer;
    font-weight: 500;
    color: var(--primary);
    transition: background var(--transition);
}

.login-toggle-header:hover {
    background: rgba(6, 33, 112, 0.04);
}

.login-toggle-arrow {
    transition: transform var(--transition);
    font-size: 14px;
}

.login-toggle-arrow.open {
    transform: rotate(90deg);
}

.login-panel {
    padding: 0 18px 18px;
}

.login-panel .form-group {
    margin-bottom: 12px;
}

.login-panel-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.forgot-password-link {
    font-size: 13px;
    color: var(--primary);
    text-decoration: none;
    opacity: 0.7;
    transition: opacity var(--transition);
}

.forgot-password-link:hover {
    opacity: 1;
    text-decoration: underline;
}

.btn-login {
    padding: 10px 24px;
    font-size: 14px;
}

.login-status {
    font-size: 13px;
    color: var(--text-secondary);
}

.login-status.success {
    color: #16a34a;
    font-weight: 500;
}

.login-status.error {
    color: #dc2626;
}

.login-toggle.logged-in {
    border-color: #16a34a;
    background: #f0fdf4;
}

.login-toggle.logged-in .login-toggle-header {
    color: #16a34a;
}

/* === Step 3: Payment === */
.step3-section {
    max-width: 700px;
}

.step3-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.step3-header h2 {
    margin: 0;
    font-family: var(--font-brand);
    color: var(--primary);
}

.step3-subtitle {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 2px 0 0;
}

.payment-recap {
    background: var(--primary-lighter);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 18px;
    margin-bottom: 24px;
}

.recap-loading {
    color: var(--text-secondary);
    font-style: italic;
}

.recap-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.recap-item {
    font-size: 14px;
}

.recap-item .recap-label {
    color: var(--text-secondary);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.recap-item .recap-value {
    font-weight: 600;
    color: var(--text);
    margin-top: 2px;
}

.recap-total {
    grid-column: 1 / -1;
    text-align: right;
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    padding-top: 12px;
    border-top: 1px solid var(--border);
    margin-top: 4px;
}

.payment-plans-section,
.payment-dues-section,
.payment-method-section {
    margin-bottom: 24px;
}

.payment-plans-section h3,
.payment-dues-section h3,
.payment-method-section h3 {
    font-size: 16px;
    margin-bottom: 12px;
    color: var(--text);
}

.payment-plans-grid,
.payment-methods-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.plan-card,
.method-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 18px;
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: border-color var(--transition), box-shadow var(--transition);
    position: relative;
}

.plan-card:hover,
.method-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.plan-card.selected,
.method-card.selected {
    border-color: var(--primary);
    background: var(--primary-lighter);
    box-shadow: var(--shadow-md);
}

.plan-card input[type="radio"],
.method-card input[type="radio"] {
    accent-color: var(--primary);
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    margin-top: 2px;
}

.plan-info,
.method-info {
    flex: 1;
}

.plan-label,
.method-label {
    font-weight: 600;
    font-size: 14px;
}

.plan-detail,
.method-detail {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.plan-badge-default {
    position: absolute;
    top: 10px;
    right: 12px;
    font-size: 11px;
    background: var(--primary);
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 500;
}

.payment-dues-table {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.dues-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 18px;
    font-size: 14px;
    border-bottom: 1px solid var(--border);
}

.dues-row:last-child {
    border-bottom: none;
}

.dues-row.dues-header {
    background: var(--primary-lighter);
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: var(--text-secondary);
}

.dues-row .dues-label {
    flex: 1;
}

.dues-row .dues-date {
    width: 120px;
    text-align: center;
    color: var(--text-secondary);
}

.dues-row .dues-amount {
    width: 100px;
    text-align: right;
    font-weight: 600;
}

.step3-actions {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 24px;
}

/* === LYRA SMARTFORM === */
.lyra-smartform-section {
    margin-top: 24px;
}

.lyra-smartform-section h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.lyra-smartform-container {
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    background: var(--white);
    min-height: 200px;
}

.lyra-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px;
    color: var(--text-secondary);
}

.lyra-loading .spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.lyra-status {
    margin-top: 16px;
    padding: 24px;
    border-radius: var(--radius);
    text-align: center;
}

.lyra-success {
    background: #ecfdf5;
    border: 2px solid #10b981;
    color: #065f46;
}

.lyra-result-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.lyra-status h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.lyra-status p {
    font-size: 14px;
    margin: 4px 0;
    color: inherit;
    opacity: 0.85;
}

/* Make Lyra iframe responsive */
#myLyraPaymentSmartForm {
    width: 100%;
}

#myLyraPaymentSmartForm iframe {
    max-width: 100% !important;
}

/* === Promo Code Section === */
.promo-code-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.promo-input-row {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.promo-input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid #dde3eb;
    border-radius: 8px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: border-color 0.2s;
}

.promo-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 33, 112, 0.1);
}

.promo-input:disabled {
    background: #f5f7fa;
    opacity: 0.6;
}

.btn-promo {
    padding: 10px 20px;
    white-space: nowrap;
    font-size: 13px;
    font-weight: 600;
}

.active-promo {
    margin-top: 4px;
}

.promo-active-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
    border: 1px solid #81c784;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 14px;
    color: #2e7d32;
}

.promo-active-badge strong {
    letter-spacing: 1px;
}

.promo-remove-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    color: #c62828;
    padding: 2px 6px;
    border-radius: 4px;
    transition: background 0.2s;
    line-height: 1;
}

.promo-remove-btn:hover {
    background: rgba(198, 40, 40, 0.1);
}

/* === Occupant Form Cards === */
.occupant-form-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 10px;
    transition: box-shadow 0.2s;
}

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

.occupant-form-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.occupant-number {
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
}

.occupant-type-badge {
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    white-space: nowrap;
}

.occupant-type-badge.adult {
    background: #e3f2fd;
    color: #1565c0;
}

.occupant-type-badge.children1 {
    background: #fff3e0;
    color: #e65100;
}

.occupant-type-badge.children2 {
    background: #fce4ec;
    color: #c62828;
}

.occupant-type-badge.baby {
    background: #f3e5f5;
    color: #7b1fa2;
}

.occupant-form-fields {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

.occupant-field label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.occupant-field input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #dde3eb;
    border-radius: 6px;
    font-size: 13px;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.occupant-field input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(6, 33, 112, 0.08);
}

/* DOB 3-dropdown selects */
.dob-selects {
    display: flex;
    gap: 6px;
}

.dob-selects select {
    flex: 1;
    padding: 8px 6px;
    border: 1px solid #dde3eb;
    border-radius: 6px;
    font-size: 13px;
    background: #fff;
    color: #334155;
    cursor: pointer;
    transition: border-color 0.2s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%2394a3b8'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    padding-right: 22px;
}

.dob-selects select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(6, 33, 112, 0.08);
}

.dob-day {
    max-width: 75px;
}

.dob-month {
    min-width: 0;
}

.dob-year {
    max-width: 85px;
}

.occupant-field-dob {
    min-width: 0;
}

/* Responsive occupant fields */
@media (max-width: 600px) {
    .occupant-form-fields {
        grid-template-columns: 1fr 1fr;
    }

    .occupant-form-fields .occupant-field-dob {
        grid-column: 1 / -1;
    }
}

/* Prefill checkbox wrapper */
.prefill-checkbox-wrapper {
    background: #f0f4fa;
    border: 1px solid #dde3eb;
    border-radius: 8px;
    padding: 12px 16px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #334155;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
}

.checkbox-label input[type="checkbox"]:disabled {
    cursor: not-allowed;
    opacity: 0.8;
}

.vacaf-prefill-notice {
    display: block;
    margin-top: 8px;
    padding: 8px 12px;
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 6px;
    color: #92400e;
    font-size: 12.5px;
    line-height: 1.4;
}

/* Inline payment plan dues */
.plan-dues-inline {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #e2e8f0;
}

.plan-due-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 3px 0;
    font-size: 12.5px;
    color: #64748b;
}

.plan-due-num {
    font-weight: 600;
    color: #475569;
    min-width: 20px;
}

.plan-due-date {
    flex: 1;
}

.plan-due-amount {
    font-weight: 600;
    color: #334155;
}

/* === Multi-Accommodation: "+" Button === */
.btn-add-accommodation {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    background: transparent;
    color: var(--primary);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-left: 8px;
    padding: 0;
    line-height: 1;
    transition: all var(--transition);
    flex-shrink: 0;
}

.btn-add-accommodation:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

/* === Modal === */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 24px;
}

.modal-content {
    background: white;
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    position: relative;
}

.modal-content h3 {
    padding: 20px 24px 0;
    margin: 0;
    font-size: 18px;
    color: var(--text-primary);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 28px;
    color: #94a3b8;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all var(--transition);
}

.modal-close:hover {
    background: #f1f5f9;
    color: #334155;
}

.modal-body {
    padding: 16px 24px 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 40px 0;
    color: #64748b;
}

.modal-empty {
    text-align: center;
    padding: 32px 0;
    color: #64748b;
}

/* Modal proposal cards */
.modal-proposal-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 10px;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.modal-proposal-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.modal-proposal-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.modal-proposal-price {
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-old-price {
    text-decoration: line-through;
    color: #94a3b8;
    font-size: 13px;
}

.modal-price {
    font-weight: 700;
    font-size: 16px;
    color: var(--primary);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
    white-space: nowrap;
}

/* Additional stay cards */
.additional-stay-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    background: #f0f4fa;
    border: 1px solid #dde3eb;
    border-radius: 8px;
    margin-top: 10px;
}

.additional-stay-info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.additional-stay-name {
    font-weight: 500;
    font-size: 14px;
    color: var(--text-primary);
}

.additional-stay-price {
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
    margin-left: auto;
}

.btn-remove-stay {
    border: none;
    background: none;
    color: #ef4444;
    font-size: 16px;
    cursor: pointer;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background var(--transition);
    flex-shrink: 0;
}

.btn-remove-stay:hover {
    background: #fef2f2;
}

/* Per-stay section titles */
.stay-subsection-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-secondary);
    margin: 16px 0 8px 0;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border);
}

.stay-subsection-title:first-of-type {
    margin-top: 0;
}

.per-stay-section {
    margin-bottom: 12px;
}

.per-stay-section .accordion-title h2 {
    font-size: 16px;
}

/* Sidebar per-stay breakdown */
.sidebar-stay-header {
    font-weight: 600;
    font-size: 13px;
    color: var(--primary);
    padding: 8px 0 4px;
    margin-top: 6px;
    border-bottom: 1px solid var(--border);
}

.sidebar-stay-header:first-child {
    margin-top: 0;
}

.sidebar-row-indented {
    padding-left: 12px;
}

/* === Mobile sidebar backdrop overlay (outside media queries for reliability) === */
.sidebar-mobile-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.5);
    z-index: 89;
    animation: fadeInBackdrop 0.2s ease;
    cursor: pointer;
}

/* =====================================================
   STEP 4: Confirmation Page
   ===================================================== */
.step4-section {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 50vh;
    padding: 2rem 1rem;
}

.step4-card {
    background: var(--surface);
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
    padding: 3rem 2.5rem;
    max-width: 560px;
    width: 100%;
    text-align: center;
    animation: step4FadeIn 0.5s ease;
}

.step4-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.step4-card h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.75rem;
}

.step4-thanks {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.step4-email {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.step4-ref,
.step4-amount {
    background: var(--bg);
    border-radius: 10px;
    padding: 0.75rem 1.25rem;
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.step4-ref-label,
.step4-amount-label {
    color: var(--text-secondary);
}

.step4-ref-value,
.step4-amount-value {
    color: var(--primary);
    font-size: 1.05rem;
}

.step4-error-msg {
    font-size: 1.05rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.step4-error-detail {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

.step4-actions {
    margin-top: 2rem;
}

.step4-actions .btn {
    min-width: 200px;
    padding: 0.85rem 2rem;
    font-size: 1rem;
}

/* Recap section */
.step4-recap {
    margin-top: 1.5rem;
    text-align: left;
    width: 100%;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}

.step4-recap-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.step4-recap-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.step4-recap-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.step4-recap-row:last-child {
    border-bottom: none;
}

.step4-recap-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.step4-recap-value {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    text-align: right;
}

.step4-recap-total {
    margin-top: 0.25rem;
    padding-top: 0.75rem;
    border-top: 2px solid var(--primary);
    border-bottom: none;
}

.step4-recap-total .step4-recap-label {
    font-weight: 600;
    color: var(--text);
    font-size: 0.95rem;
}

.step4-recap-total .step4-recap-value {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.1rem;
}

@keyframes step4FadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

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

@media (max-width: 600px) {
    .step4-card {
        padding: 2rem 1.5rem;
    }

    .step4-icon {
        font-size: 2.5rem;
    }

    .step4-card h2 {
        font-size: 1.25rem;
    }
}

/* === UX REASSURANCE — Header Phone === */
.header-phone {
    color: white;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    opacity: 0.9;
    white-space: nowrap;
    flex-shrink: 0;
    transition: var(--transition);
}

.header-phone:hover {
    opacity: 1;
}

/* === UX REASSURANCE — Section Help Text === */
.section-help-text {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
    padding: 10px 14px;
    background: var(--bleu-delave);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--bleu-ciel);
}

/* === UX REASSURANCE — Help Tooltip (ⓘ) === */
.help-tooltip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--bleu-ciel);
    color: white;
    font-size: 12px;
    cursor: help;
    vertical-align: middle;
    margin-left: 6px;
    position: relative;
    font-weight: 400;
}

.help-tooltip:hover {
    background: var(--primary);
}

/* === UX REASSURANCE — Reassurance Banner (Step 2) === */
.reassurance-banner {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 16px 20px;
    background: linear-gradient(135deg, #e8f5e9 0%, #f1f8e9 100%);
    border: 1px solid #a5d6a7;
    border-radius: var(--radius);
    margin-bottom: 24px;
}

.reassurance-icon {
    font-size: 28px;
    flex-shrink: 0;
    margin-top: 2px;
}

.reassurance-content strong {
    font-size: 15px;
    color: #2e7d32;
    display: block;
    margin-bottom: 4px;
}

.reassurance-content p {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    margin: 0;
}

/* === UX REASSURANCE — Security Badge (Step 3) === */
.security-badge {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 16px 20px;
    background: linear-gradient(135deg, #e8f5e9 0%, #f1f8e9 100%);
    border: 1px solid #a5d6a7;
    border-radius: var(--radius);
    margin-bottom: 20px;
}

.security-badge-icon {
    font-size: 28px;
    flex-shrink: 0;
}

.security-badge-content strong {
    font-size: 15px;
    color: #2e7d32;
    display: block;
    margin-bottom: 8px;
}

.security-badge-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.security-badge-content li {
    font-size: 13px;
    color: #555;
    padding: 3px 0;
    padding-left: 16px;
    position: relative;
}

.security-badge-content li::before {
    content: "✓";
    color: #2e7d32;
    font-weight: 700;
    position: absolute;
    left: 0;
}

/* === UX REASSURANCE — Inline Validation === */
.field-error input,
.field-error select,
.field-error textarea {
    border-color: #e53e3e !important;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.15) !important;
}

.field-error .form-hint {
    color: #e53e3e;
}

.field-error-msg {
    color: #e53e3e;
    font-size: 0.82rem;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
    animation: fadeInError 0.3s ease;
}

.field-error-msg::before {
    content: "⚠️";
    font-size: 14px;
}

@keyframes fadeInError {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

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

.field-success input,
.field-success select {
    border-color: #38a169 !important;
}

.field-success::after {
    content: "✓";
    color: #38a169;
    font-weight: 700;
    font-size: 16px;
    position: absolute;
    right: 12px;
    bottom: 10px;
}

.form-group {
    position: relative;
}

/* === UX REASSURANCE — Progress Checklist (Step 1 sidebar) === */
.progress-checklist {
    padding: 12px 0;
    margin: 8px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.progress-item {
    font-size: 13px;
    color: var(--text-secondary);
    padding: 5px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.progress-item.done {
    color: #2e7d32;
}

.progress-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
    flex-shrink: 0;
    transition: var(--transition);
}

.progress-item.done .progress-dot {
    background: #2e7d32;
}

.progress-summary {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 8px;
    font-weight: 600;
    text-align: center;
}

/* === UX REASSURANCE — Help CTA Block === */
.help-cta-block {
    background: var(--surface);
    border: 2px solid var(--bleu-ciel);
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
    margin: 24px;
}

.help-cta-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.help-cta-text {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.4;
}

.btn-help {
    background: linear-gradient(135deg, #2e7d32 0%, #388e3c 100%);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(46, 125, 50, 0.3);
    min-height: 48px;
}

.btn-help:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(46, 125, 50, 0.4);
}

.help-cta-phone {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 12px;
}

.help-cta-phone a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

/* === UX REASSURANCE — Callback Modal === */
.callback-modal {
    max-width: 480px;
    padding: 24px;
}

.callback-modal h3 {
    margin-bottom: 8px;
}

.callback-modal-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.callback-status {
    margin-top: 16px;
    font-size: 14px;
    text-align: center;
}

.callback-status.success {
    color: #2e7d32;
}

.callback-status.error {
    color: #e53e3e;
}

/* === UX REASSURANCE — Trust Footer === */
.trust-footer {
    background: var(--primary);
    color: white;
    padding: 16px 24px;
    margin-top: 32px;
}

.trust-badges {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 24px;
}

.trust-badge {
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.trust-badge a {
    color: white;
    text-decoration: none;
}

/* === UX REASSURANCE — Step 4 Next Steps === */
.step4-next-steps {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.step4-next-steps h3 {
    font-size: 16px;
    margin-bottom: 12px;
}

.step4-next-steps ul {
    list-style: none;
    padding: 0;
}

.step4-next-steps li {
    font-size: 14px;
    padding: 8px 0;
    color: var(--text-secondary);
}

.step4-next-steps a {
    color: var(--primary);
    text-decoration: none;
}

.step4-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

/* === PRINT === */
@media print {

    .tunnel-header,
    .tunnel-sidebar,
    .help-cta-block,
    .trust-footer,
    .toast-container,
    .step4-actions,
    #debugPanel {
        display: none !important;
    }

    .tunnel-layout {
        grid-template-columns: 1fr;
    }

    .step4-card {
        box-shadow: none;
        border: 1px solid #ccc;
    }

    body {
        background: white;
    }
}

/* === UX REASSURANCE — Mobile === */
@media (max-width: 768px) {
    .header-phone {
        display: none;
    }

    .help-cta-block {
        margin: 16px;
        padding: 16px;
    }

    .progress-checklist {
        display: flex;
        flex-wrap: nowrap;
        gap: 6px;
        padding: 6px 0;
        margin: 4px 0;
        border-top: 1px solid var(--border);
        border-bottom: none;
    }

    .progress-checklist .progress-item {
        font-size: 11px;
        padding: 3px 8px;
        background: var(--bg);
        border: 1px solid var(--border);
        border-radius: 20px;
        gap: 4px;
    }

    .progress-checklist .progress-item.done {
        background: #e8f5e9;
        border-color: #2e7d32;
    }

    #progressCGV {
        display: none;
    }

    .progress-checklist .progress-dot {
        width: 6px;
        height: 6px;
    }

    .progress-checklist .progress-summary {
        display: none;
    }

    .cgv-check.checked span {
        color: #2e7d32;
    }


    .help-cta-text {
        display: none;
    }

    .trust-badges {
        gap: 12px;
    }

    .trust-badge {
        font-size: 11px;
    }

    .reassurance-banner {
        flex-direction: column;
        gap: 8px;
    }

    .security-badge {
        flex-direction: column;
        gap: 8px;
    }
}