/* =========================================================================
   Book Trip modal + CTAs
   ========================================================================= */

/* -------------------------------------------------------------------------
   Bootstrap 4 modal CSS shim.
   We removed Bootstrap's bundled CSS from the new header.php, but we still
   drive this modal with Bootstrap 4 modal JS (loaded via CDN in footer.php).
   These are the minimum rules Bootstrap's modal JS expects to see. Without
   them the modal renders as inline content at the bottom of the page.
   ------------------------------------------------------------------------- */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1050;
    display: none;
    width: 100%;
    height: 100%;
    overflow: hidden;
    outline: 0;
}
.modal-open { overflow: hidden; }
.modal-open .modal { overflow-x: hidden; overflow-y: auto; }

.modal.fade .modal-dialog {
    transition: transform 0.3s ease-out;
    transform: translate(0, -50px);
}
.modal.show { display: block; }
.modal.show .modal-dialog { transform: none; }

.modal-dialog {
    position: relative;
    width: auto;
    margin: 0.5rem;
    pointer-events: none;
}
@media (min-width: 576px) {
    .modal-dialog { max-width: 500px; margin: 1.75rem auto; }
    .modal-lg    { max-width: 800px; }
}
@media (min-width: 992px) {
    .modal-lg    { max-width: 880px; }
}
.modal-dialog-centered {
    display: flex;
    align-items: center;
    min-height: calc(100% - 1rem);
}
@media (min-width: 576px) {
    .modal-dialog-centered { min-height: calc(100% - 3.5rem); }
}
.modal-dialog-centered::before {
    display: block;
    height: calc(100vh - 1rem);
    content: "";
}
@media (min-width: 576px) {
    .modal-dialog-centered::before { height: calc(100vh - 3.5rem); }
}

.modal-content {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    pointer-events: auto;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0,0,0,0.2);
    border-radius: 0.3rem;
    outline: 0;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1040;
    width: 100vw;
    height: 100vh;
    background-color: #000;
}
.modal-backdrop.fade { opacity: 0; }
.modal-backdrop.show { opacity: 0.5; }

.modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid #dee2e6;
    border-top-left-radius: calc(0.3rem - 1px);
    border-top-right-radius: calc(0.3rem - 1px);
}
.modal-header .close { padding: 1rem; margin: -1rem -1rem -1rem auto; }
.modal-body {
    position: relative;
    flex: 1 1 auto;
    padding: 1rem;
}

/* Close button (Bootstrap 4's .close) */
button.close,
.modal .close {
    padding: 0;
    background-color: transparent;
    border: 0;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    float: right;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
    color: #000;
    text-shadow: 0 1px 0 #fff;
    opacity: 0.5;
    cursor: pointer;
}
button.close:hover { opacity: 0.75; }

/* Screen reader helper used by aria-label fallbacks */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Logo-matched tokens. Primary = forest teal from the logo's palm + NIGHTS
   wordmark; accent/CTA = sunset orange from the logo's sun + ANY 3 wordmark.
   These override the old green/red pair. */
:root {
    --bt-primary: #2F6F5E;       /* forest teal */
    --bt-primary-dark: #275E4F;
    --bt-accent: #E8833B;        /* sunset orange */
    --bt-accent-dark: #C86C28;
    --bt-text: #1B2A32;          /* ink */
    --bt-muted: #67757f;
    --bt-border: #e1e6ec;
    --bt-bg-soft: #F9F7F3;       /* ivory surface */
    --bt-shadow: 0 30px 60px -20px rgba(27, 42, 50, 0.30);

    --bt-font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --bt-font-display: 'Fraunces', ui-serif, Georgia, serif;
}

.book-trip-modal .modal-content,
.book-trip-exit-modal .modal-content,
.book-trip-modal .modal-title,
.book-trip-exit-modal .modal-title,
.book-trip-sidebar-card h4,
.book-trip-thanks h3 {
    font-family: var(--bt-font-sans);
}
.book-trip-modal .modal-title,
.book-trip-exit-modal .modal-title,
.book-trip-thanks h3,
.book-trip-sidebar-card h4 {
    font-family: var(--bt-font-display);
    letter-spacing: -0.01em;
    font-weight: 500;
}

/* ---- Modal shell --------------------------------------------------------- */
.book-trip-modal .modal-dialog,
.book-trip-exit-modal .modal-dialog {
    max-width: 880px;
}
.book-trip-modal .modal-content,
.book-trip-exit-modal .modal-content {
    border: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--bt-shadow);
    color: var(--bt-text);
}
.book-trip-modal .modal-header,
.book-trip-exit-modal .modal-header {
    padding: 22px 28px 18px;
    border-bottom: 1px solid var(--bt-border);
    align-items: flex-start;
    background: linear-gradient(135deg, #fff 0%, #f8fbff 100%);
}
.book-trip-modal .modal-title,
.book-trip-exit-modal .modal-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    color: var(--bt-text);
    line-height: 1.2;
}
.book-trip-subtitle {
    margin: 4px 0 0;
    font-size: 14px;
    color: var(--bt-muted);
}
.book-trip-modal .close,
.book-trip-exit-modal .close {
    font-size: 28px;
    line-height: 1;
    opacity: 0.6;
    margin-left: 16px;
}
.book-trip-modal .close:hover,
.book-trip-exit-modal .close:hover {
    opacity: 1;
}
.book-trip-modal .modal-body,
.book-trip-exit-modal .modal-body {
    padding: 24px 28px 28px;
    background: #fff;
}

/* ---- Two-column grid (form + aside) ------------------------------------- */
.book-trip-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    gap: 28px;
}
@media (max-width: 768px) {
    .book-trip-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }
}

/* ---- Progress bar -------------------------------------------------------- */
.book-trip-progress {
    margin-bottom: 20px;
}
.book-trip-progress-bar {
    height: 4px;
    background: var(--bt-border);
    border-radius: 99px;
    overflow: hidden;
}
.book-trip-progress-fill {
    height: 100%;
    background: var(--bt-primary);
    transition: width 0.25s ease;
    border-radius: 99px;
}
.book-trip-steps {
    list-style: none;
    padding: 0;
    margin: 10px 0 0;
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--bt-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.book-trip-steps li {
    display: flex;
    align-items: center;
    gap: 6px;
}
.book-trip-steps li span {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--bt-border);
    color: #fff;
    font-size: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.book-trip-steps li.is-active span,
.book-trip-steps li.is-complete span {
    background: var(--bt-primary);
}
.book-trip-steps li.is-active {
    color: var(--bt-text);
}

/* ---- Form fields --------------------------------------------------------- */
.book-trip-form label {
    font-size: 13px;
    font-weight: 600;
    color: var(--bt-text);
    margin-bottom: 6px;
    display: block;
}
.book-trip-optional {
    color: var(--bt-muted);
    font-weight: 400;
    font-size: 12px;
}
.book-trip-form .form-control {
    border: 1px solid var(--bt-border);
    border-radius: 8px;
    padding: 10px 12px;
    height: 42px;
    font-size: 14px;
    color: var(--bt-text);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    background: #fff;
}
.book-trip-form .form-control:focus {
    border-color: var(--bt-primary);
    box-shadow: 0 0 0 3px rgba(47, 111, 94, 0.18);
    outline: none;
}
.book-trip-form .form-control.is-invalid {
    border-color: #D13434;
}
.book-trip-error { color: #D13434; }
.book-trip-form select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'><path d='M1 1l5 5 5-5' stroke='%236a7885' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 34px;
}
.book-trip-form .form-row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -8px;
    margin-left: -8px;
}
.book-trip-form .form-group {
    padding: 0 8px;
    margin-bottom: 14px;
}
.book-trip-form .col-12 { flex: 0 0 100%; max-width: 100%; }
@media (min-width: 576px) {
    .book-trip-form .col-md-6 { flex: 0 0 50%; max-width: 50%; }
}

.book-trip-error {
    color: var(--bt-accent);
    font-size: 12px;
    margin: 6px 0 0;
    display: none;
}
.book-trip-form.is-showing-errors .is-invalid + .book-trip-error,
.book-trip-form .book-trip-error.is-active {
    display: block;
}

/* ---- Yes/No radio pills -------------------------------------------------- */
.book-trip-yesno {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}
.book-trip-yesno-option {
    flex: 1;
    border: 1px solid var(--bt-border);
    border-radius: 8px;
    padding: 14px 12px;
    text-align: center;
    cursor: pointer;
    font-weight: 600;
    transition: border-color 0.15s ease, background 0.15s ease;
    margin: 0;
}
.book-trip-yesno-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.book-trip-yesno-option:hover {
    border-color: var(--bt-primary);
}
.book-trip-yesno-option.is-selected {
    border-color: var(--bt-primary);
    background: rgba(47, 111, 94, 0.08);
    color: var(--bt-primary-dark);
}

/* ---- TCPA checkbox ------------------------------------------------------- */
.book-trip-tcpa {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    background: var(--bt-bg-soft);
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 12px;
    line-height: 1.45;
    color: var(--bt-muted);
    font-weight: 400;
    cursor: pointer;
}
.book-trip-tcpa input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
}

/* ---- Step navigation ----------------------------------------------------- */
.book-trip-step { display: none; }
.book-trip-step.is-active { display: block; animation: btFade 0.18s ease-out; }
@keyframes btFade { from { opacity: 0; transform: translateY(4px);} to {opacity:1; transform:none;} }

.book-trip-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    gap: 10px;
}
.book-trip-actions .btn {
    border-radius: 8px;
    font-weight: 600;
    padding: 11px 20px;
}
.book-trip-actions .btn-primary {
    background: var(--bt-accent);
    border-color: var(--bt-accent);
    color: #fff;
}
.book-trip-actions .btn-primary:hover {
    background: var(--bt-accent-dark);
    border-color: var(--bt-accent-dark);
    color: #fff;
}
.book-trip-actions .btn-link {
    color: var(--bt-muted);
    text-decoration: none;
    padding: 11px 4px;
}
.book-trip-actions .btn-link:hover {
    color: var(--bt-text);
}

/* ---- Aside --------------------------------------------------------------- */
.book-trip-aside {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.book-trip-aside-card {
    background: var(--bt-bg-soft);
    border-radius: 10px;
    padding: 18px;
}
.book-trip-aside-card h5 {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bt-muted);
}
.book-trip-checklist {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 14px;
    color: var(--bt-text);
}
.book-trip-checklist li {
    position: relative;
    padding: 6px 0 6px 22px;
}
.book-trip-checklist li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 6px;
    color: var(--bt-primary);
    font-weight: 700;
}

/* Activity ticker */
.book-trip-ticker {
    background: #fff;
    border: 1px solid var(--bt-border);
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 13px;
    color: var(--bt-text);
    min-height: 52px;
    position: relative;
    overflow: hidden;
}
.book-trip-ticker::before {
    content: "";
    width: 8px; height: 8px;
    background: #F5A623; /* amber pulse (logo's sun) */
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
    box-shadow: 0 0 0 0 rgba(245, 166, 35, 0.5);
    animation: btPulse 1.8s infinite;
    vertical-align: middle;
}
@keyframes btPulse {
    0%   { box-shadow: 0 0 0 0 rgba(245, 166, 35, 0.5); }
    70%  { box-shadow: 0 0 0 10px rgba(245, 166, 35, 0); }
    100% { box-shadow: 0 0 0 0 rgba(245, 166, 35, 0); }
}
.book-trip-ticker-text {
    transition: opacity 0.3s ease;
}
.book-trip-ticker-text.is-swapping { opacity: 0; }

/* Testimonials */
.book-trip-testimonials {
    background: #fff;
    border: 1px solid var(--bt-border);
    border-radius: 10px;
    padding: 18px;
    position: relative;
    min-height: 130px;
}
.book-trip-testimonial {
    margin: 0;
    display: none;
    font-size: 14px;
    line-height: 1.5;
    color: var(--bt-text);
}
.book-trip-testimonial.is-active {
    display: block;
    animation: btFade 0.25s ease-out;
}
.book-trip-testimonial p { margin: 0 0 8px; font-style: italic; }
.book-trip-testimonial cite {
    display: block;
    font-style: normal;
    font-size: 12px;
    color: var(--bt-muted);
    font-weight: 600;
}

.book-trip-aside-call {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border: 1px dashed var(--bt-border);
    border-radius: 10px;
    font-size: 14px;
    color: var(--bt-muted);
}
.book-trip-aside-call a {
    color: var(--bt-primary);
    font-weight: 700;
    font-size: 15px;
}

/* ---- Thanks state -------------------------------------------------------- */
.book-trip-thanks {
    text-align: center;
    padding: 20px 12px 8px;
}
.book-trip-thanks-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(47, 111, 94, 0.15);
    color: var(--bt-primary);
    font-size: 28px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}
.book-trip-thanks h3 {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    color: var(--bt-text);
}
.book-trip-thanks p {
    color: var(--bt-muted);
    font-size: 14px;
    margin: 0 auto 18px;
    max-width: 420px;
}
.book-trip-call-cta {
    background: var(--bt-accent);
    border-color: var(--bt-accent);
    color: #fff !important;
    padding: 14px 28px;
    border-radius: 999px;
    font-weight: 700;
}
.book-trip-call-cta:hover {
    background: var(--bt-accent-dark);
    border-color: var(--bt-accent-dark);
    color: #fff !important;
}
.book-trip-thanks-phone {
    margin-top: 12px !important;
    font-weight: 700;
    color: var(--bt-text) !important;
    font-size: 15px !important;
}

/* ---- Nav button ---------------------------------------------------------- */
#main_menu .book-trip-cta > a,
#main_menu li.book-trip-cta > a {
    background: var(--bt-accent);
    color: #fff !important;
    border-radius: 999px;
    padding: 8px 18px !important;
    margin-left: 10px;
    font-weight: 700;
    transition: background 0.15s ease;
}
#main_menu .book-trip-cta > a:hover {
    background: var(--bt-accent-dark);
    color: #fff !important;
}

/* ---- Sidebar CTA card (replaces legacy sidebar form) -------------------- */
.sidebar_wrapper .book-trip-sidebar-card,
.book-trip-sidebar-card {
    background: #fff;
    border: 1px solid var(--bt-border);
    border-radius: 14px;
    padding: 26px 24px;
    box-shadow: 0 14px 40px -16px rgba(27, 42, 50, 0.22);
}
.book-trip-sidebar-card h4 {
    font-size: 18px;
    margin: 0 0 6px;
    font-weight: 700;
    color: var(--bt-text);
}
.book-trip-sidebar-card p {
    margin: 0 0 14px;
    font-size: 14px;
    color: var(--bt-muted);
    line-height: 1.45;
}
.book-trip-sidebar-card .btn-book-trip {
    display: block;
    width: 100%;
    background: var(--bt-accent);
    color: #fff !important;
    border: 0;
    border-radius: 999px;
    padding: 14px 18px;
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s ease, transform 0.15s ease;
}
.book-trip-sidebar-card .btn-book-trip:hover {
    background: var(--bt-accent-dark);
    color: #fff !important;
    transform: translateY(-1px);
}
.book-trip-sidebar-card .book-trip-sidebar-call {
    display: block;
    text-align: center;
    margin-top: 12px;
    font-size: 13px;
    color: var(--bt-muted);
}
.book-trip-sidebar-card .book-trip-sidebar-call a {
    color: var(--bt-primary);
    font-weight: 700;
}
.book-trip-sidebar-card .book-trip-sidebar-assurances {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--bt-border);
    font-size: 12px;
    color: var(--bt-muted);
    line-height: 1.5;
}

/* ---- Hero mini form (homepage) ----------------------------------------- */
.book-trip-hero-miniform {
    margin-top: 24px;
    background: rgba(255,255,255,0.94);
    backdrop-filter: blur(4px);
    border-radius: 14px;
    padding: 14px;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    max-width: 720px;
    box-shadow: 0 16px 40px rgba(20, 35, 50, 0.2);
}
.book-trip-hero-miniform select,
.book-trip-hero-miniform input {
    border: 1px solid var(--bt-border);
    border-radius: 8px;
    padding: 10px 12px;
    height: 44px;
    font-size: 14px;
    color: var(--bt-text);
    background: #fff;
    width: 100%;
}
.book-trip-hero-miniform .btn {
    background: var(--bt-accent);
    border: 0;
    color: #fff;
    border-radius: 999px;
    padding: 0 24px;
    height: 44px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}
.book-trip-hero-miniform .btn:hover { background: var(--bt-accent-dark); }
@media (max-width: 640px) {
    .book-trip-hero-miniform {
        grid-template-columns: 1fr;
    }
}

/* ---- Destination card extras (home) ------------------------------------ */
.book-trip-card-cta {
    display: inline-block;
    background: var(--bt-accent);
    color: #fff !important;
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    margin-bottom: 10px;
    cursor: pointer;
    border: 0;
    transition: background 0.15s ease;
}
.book-trip-card-cta:hover {
    background: var(--bt-accent-dark);
    color: #fff !important;
}
.book-trip-availability-pill {
    display: inline-block;
    background: rgba(232, 131, 59, 0.12);
    color: var(--bt-accent-dark);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    margin-right: 8px;
    margin-bottom: 8px;
    border: 1px solid rgba(232, 131, 59, 0.2);
}

/* ---- Sticky floating CTA (desktop) ------------------------------------- */
.book-trip-fab {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 9998;
    background: var(--bt-accent);
    color: #fff;
    border: 0;
    border-radius: 999px;
    padding: 14px 22px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 14px 30px rgba(232, 131, 59, 0.36);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transform: translateY(0);
    transition: transform 0.2s ease, background 0.15s ease;
}
.book-trip-fab:hover {
    background: var(--bt-accent-dark);
    transform: translateY(-2px);
    color: #fff;
}
.book-trip-fab-icon {
    font-size: 18px;
    transform: rotate(-45deg);
    display: inline-block;
}
@media (max-width: 768px) {
    .book-trip-fab { display: none; }
}

/* ---- Mobile sticky footer bar ------------------------------------------ */
.book-trip-mobile-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9998;
    display: none;
    background: #fff;
    border-top: 1px solid var(--bt-border);
    box-shadow: 0 -10px 30px rgba(20, 35, 50, 0.08);
    padding: 8px;
    gap: 8px;
}
.book-trip-mobile-bar .book-trip-mobile-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 8px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 14px;
    border: 0;
    cursor: pointer;
    text-decoration: none;
    background: var(--bt-accent);
    color: #fff;
}
.book-trip-mobile-bar .book-trip-mobile-call {
    background: var(--bt-primary);
}
@media (max-width: 768px) {
    .book-trip-mobile-bar { display: flex; }
    body { padding-bottom: 64px; }
}

/* ---- Exit intent polish ------------------------------------------------- */
.book-trip-exit-thanks {
    text-align: center;
    padding: 20px 0 4px;
    color: var(--bt-primary-dark);
    font-weight: 600;
}

/* ---- Small screen modal padding ---------------------------------------- */
@media (max-width: 640px) {
    .book-trip-modal .modal-body,
    .book-trip-exit-modal .modal-body { padding: 18px 18px 22px; }
    .book-trip-modal .modal-header,
    .book-trip-exit-modal .modal-header { padding: 18px 18px 12px; }
    .book-trip-modal .modal-title { font-size: 19px; }
}
