/**
 * Concerq — "Submit a route" CTA + request modal (deals page)
 *
 * For visitors whose route isn't in the deals table: a hero call-to-action and
 * a band under the table, both opening the same popup form. The form posts to
 * the existing concerq_flight_enquiry endpoint, so it emails the team and
 * creates a Zoho lead exactly like the contact form does.
 *
 * Same design language as the rest of the theme — Montserrat, #d6b97c gold,
 * 50px pill buttons, 20px panels — but everything is scoped to .cqrr* so it
 * cannot reach the hero, the deals table, or anything in style.css. This file
 * is deliberately independent of css/flight-search.css: the search widget is
 * currently switched off, and this must keep working without it.
 */

.cqrr-cta,
.cqrr-hero-hint,
.cqrr-strip,
.cqrr-backdrop {
    /* Theme palette */
    --gold: #d6b97c;
    --gold-2: #e4cb92;
    --gold-dim: rgba(214, 185, 124, .35);
    --gold-faint: rgba(214, 185, 124, .08);
    --panel: linear-gradient(135deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .02));
    --sunk: rgba(255, 255, 255, .03);
    --field-bg: rgba(255, 255, 255, .05);
    --line: rgba(255, 255, 255, .1);
    --line-2: rgba(255, 255, 255, .2);
    --bone: #ffffff;
    --ash: rgba(255, 255, 255, .7);
    --ash-2: #888888;
    --danger: #ff6b6b;
    --radius: 20px;
    --radius-sm: 10px;
    --ui: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Local reset — the theme styles bare elements globally. */
.cqrr-strip *,
.cqrr-backdrop * {
    box-sizing: border-box;
}

.cqrr-strip p,
.cqrr-strip h3,
.cqrr-backdrop p,
.cqrr-backdrop h3,
.cqrr-backdrop label {
    margin: 0;
    color: inherit;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    letter-spacing: normal;
}

.cqrr-strip button,
.cqrr-backdrop button,
.cqrr-backdrop input,
.cqrr-backdrop select,
.cqrr-backdrop textarea {
    font-family: var(--ui);
}

/* ==========================================================================
   Hero call-to-action
   Sits alongside the two ACF hero buttons. Those are solid gold; this one is
   outlined so the third action reads as an alternative, not a duplicate.
   ========================================================================== */

/* A <button> among the ACF <a> hero links — the theme has no global
   `button { font-family: inherit }`, so say it here or it renders in the
   browser's UI font while its neighbours are in Montserrat. */
.cqrr-cta {
    font-family: var(--ui);
    line-height: 1;
    cursor: pointer;
}

.service-hero-buttons .cta-button.cqrr-cta {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
    box-shadow: none;
}

.service-hero-buttons .cta-button.cqrr-cta:hover {
    background: var(--cq-btn-fill);
    color: #000000;
    border-color: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(214, 185, 124, .35);
}

.cqrr-cta .ic {
    font-size: 1rem;
    line-height: 1;
}

.cqrr-hero-hint {
    font-family: var(--ui);
    font-size: .85rem;
    font-weight: 300;
    line-height: 1.6;
    color: var(--ash);
    margin: 1rem 0 0;
    max-width: 46ch;
}

/* ==========================================================================
   "Don't see your route?" band, under the deals table
   ========================================================================== */

.cqrr-strip {
    font-family: var(--ui);
    color: var(--bone);
    line-height: 1.6;
    margin-top: 2.5rem;
    padding: clamp(1.75rem, 4vw, 2.5rem);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.cqrr-strip .cqrr-eyebrow {
    display: block;
    font-size: 11px;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 600;
    margin: 0 0 .6rem;
}

.cqrr-strip h3 {
    font-weight: 200;
    font-size: clamp(1.4rem, 3vw, 1.9rem);
    line-height: 1.2;
    margin: 0 0 .6rem;
    background: linear-gradient(180deg, #e4cb92, #c7a667);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: var(--gold);
}

.cqrr-strip p {
    color: var(--ash);
    font-size: .95rem;
    line-height: 1.7;
    max-width: 60ch;
}

.cqrr-strip .cqrr-strip-btn {
    flex: none;
    background: var(--cq-btn-fill);
    color: #000000;
    font-weight: 600;
    font-size: .9rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    border: none;
    border-radius: 10px;
    height: 56px;
    padding: 0 2rem;
    cursor: pointer;
    transition: all .3s ease;
    box-shadow: 0 10px 30px rgba(214, 185, 124, .3);
    white-space: nowrap;
}

.cqrr-strip .cqrr-strip-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(214, 185, 124, .4);
    background: var(--cq-btn-fill);
}

/* ==========================================================================
   Modal
   ========================================================================== */

.cqrr-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .8);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: clamp(1rem, 5vh, 3.5rem) 1rem;
    /* Above the header (theme tops out at 1001). */
    z-index: 99999;
    overflow-y: auto;
    font-family: var(--ui);
    line-height: 1.6;
    color: var(--bone);
}

.cqrr-backdrop.open {
    display: flex;
}

.cqrr-backdrop .cqrr-modal {
    width: 100%;
    max-width: 620px;
    background: linear-gradient(135deg, #131313, #0a0a0a);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 30px 80px rgba(0, 0, 0, .7);
    position: relative;
    animation: cqrrPop .4s ease;
}

@keyframes cqrrPop {
    from { opacity: 0; transform: translateY(14px) scale(.98); }
    to   { opacity: 1; transform: none; }
}

.cqrr-backdrop .cqrr-x {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--line-2);
    background: var(--field-bg);
    color: var(--ash);
    cursor: pointer;
    font-size: 1rem;
    transition: all .3s ease;
    z-index: 2;
    padding: 0;
}

.cqrr-backdrop .cqrr-x:hover {
    color: #000000;
    background: var(--gold);
    border-color: var(--gold);
}

.cqrr-backdrop .cqrr-body {
    padding: clamp(2rem, 5vw, 3rem);
}

.cqrr-backdrop .eyebrow {
    font-size: 11px;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 600;
    margin: 0 0 .75rem;
}

/* "eyebrow" is also the theme's own class for front-page section labels, and
   that rule draws a dash in front of the text. Ours is just the label, so kill
   whatever it generates. Scoped tightly enough to outrank a bare .eyebrow. */
.cqrr-backdrop .eyebrow::before,
.cqrr-backdrop .eyebrow::after {
    content: none;
    display: none;
}

.cqrr-backdrop h3 {
    font-weight: 200;
    font-size: clamp(1.6rem, 5vw, 2rem);
    line-height: 1.2;
    margin: 0 0 .75rem;
    background: linear-gradient(180deg, #e4cb92, #c7a667);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: var(--gold);
}

.cqrr-backdrop .sub {
    color: var(--ash);
    font-size: .95rem;
    line-height: 1.6;
    margin: 0 0 1.75rem;
}

.cqrr-backdrop .field {
    margin-bottom: 1.25rem;
}

.cqrr-backdrop .field > label {
    display: block;
    font-size: 12px;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--bone);
    font-weight: 500;
    margin: 0 0 .5rem;
}

.cqrr-backdrop .field > label .req {
    color: var(--gold);
}

.cqrr-backdrop .txt,
.cqrr-backdrop select.txt,
.cqrr-backdrop textarea.txt {
    width: 100%;
    background: var(--field-bg);
    border: 1px solid var(--line-2);
    border-radius: var(--radius-sm);
    color: var(--bone);
    font-size: 1rem;
    transition: all .3s ease;
}

.cqrr-backdrop .txt {
    height: 56px;
    padding: 0 1rem;
}

.cqrr-backdrop select.txt {
    /* Native arrow is invisible on a dark field, so draw our own. */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 2.5rem;
    cursor: pointer;
    background-image: linear-gradient(45deg, transparent 50%, var(--gold) 50%),
                      linear-gradient(135deg, var(--gold) 50%, transparent 50%);
    background-position: calc(100% - 20px) 25px, calc(100% - 14px) 25px;
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}

.cqrr-backdrop select.txt option {
    background: #131313;
    color: var(--bone);
}

.cqrr-backdrop textarea.txt {
    padding: 1rem;
    min-height: 96px;
    resize: vertical;
    line-height: 1.6;
}

.cqrr-backdrop .txt::placeholder,
.cqrr-backdrop textarea.txt::placeholder {
    color: var(--ash-2);
}

.cqrr-backdrop .txt:focus,
.cqrr-backdrop textarea.txt:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(214, 185, 124, .1);
}

/* Date inputs render a near-black glyph on the dark field by default. */
.cqrr-backdrop input[type=date].txt::-webkit-calendar-picker-indicator {
    filter: invert(1);
    opacity: .55;
    cursor: pointer;
}

.cqrr-backdrop .two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.cqrr-backdrop .field.invalid .txt {
    border-color: var(--danger);
}

.cqrr-backdrop .err {
    display: none;
    color: var(--danger);
    font-size: .8rem;
    margin-top: .5rem;
}

.cqrr-backdrop .err.show {
    display: block;
}

/* Honeypot — never shown to a human. */
.cqrr-backdrop .hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.cqrr-backdrop .news {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: .25rem 0;
    cursor: pointer;
    line-height: 1.5;
}

.cqrr-backdrop .news input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.cqrr-backdrop .news .cb {
    width: 20px;
    height: 20px;
    flex: none;
    border: 1px solid var(--line-2);
    border-radius: 4px;
    background: var(--field-bg);
    position: relative;
    transition: all .3s ease;
    margin-top: 2px;
}

.cqrr-backdrop .news input:checked + .cb {
    background: var(--gold);
    border-color: var(--gold);
}

.cqrr-backdrop .news input:checked + .cb::after {
    content: "";
    position: absolute;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid #000000;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.cqrr-backdrop .news input:focus-visible + .cb {
    box-shadow: 0 0 0 3px rgba(214, 185, 124, .2);
}

.cqrr-backdrop .news .tl {
    font-size: .95rem;
    color: var(--bone);
}

.cqrr-backdrop .actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.75rem;
}

/* Sized and coloured to match the hero's "Enquire Now" pill rather than the
   56px form fields above — as a pair of actions they were reading heavier than
   the button that opened the popup. */
.cqrr-backdrop .btn {
    font-weight: 600;
    font-size: .85rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 10px;
    height: 44px;
    padding: 0 1.5rem;
    transition: all .3s ease;
    border: none;
}

/* The hero button's exact gradient: white into gold, not gold into gold. */
.cqrr-backdrop .btn-primary {
    background: var(--cq-btn-fill);
    color: #000000;
    box-shadow: 0 4px 15px rgba(214, 185, 124, .3);
    flex: 1;
}

.cqrr-backdrop .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(214, 185, 124, .5);
    background: var(--cq-btn-fill);
    color: #000000;
}

.cqrr-backdrop .btn[disabled] {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 1px, not 2px — at 44px tall the thicker ring was competing with the primary. */
.cqrr-backdrop .btn-ghost {
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
}

.cqrr-backdrop .btn-ghost:hover {
    background: var(--gold);
    color: #000000;
}

.cqrr-backdrop .consent {
    font-size: 11px;
    line-height: 1.7;
    color: var(--ash-2);
    margin-top: 1rem;
    text-align: center;
}

.cqrr-backdrop .consent a {
    color: var(--gold);
    text-decoration: none;
}

.cqrr-backdrop .consent a:hover {
    color: var(--gold-2);
}

.cqrr-backdrop .form-error {
    display: none;
    margin-top: 1rem;
    padding: 1rem;
    border: 1px solid rgba(255, 107, 107, .3);
    background: rgba(255, 107, 107, .1);
    color: var(--danger);
    font-size: .9rem;
    line-height: 1.5;
    border-radius: var(--radius-sm);
    text-align: center;
}

.cqrr-backdrop .form-error.show {
    display: block;
}

/* Success screen */
.cqrr-backdrop .done {
    text-align: center;
}

.cqrr-backdrop .done .seal {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 1px solid var(--gold-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--gold);
    font-size: 1.6rem;
    background: var(--gold-faint);
}

.cqrr-backdrop .done p {
    color: var(--ash);
    font-size: .95rem;
    line-height: 1.7;
    margin: 0 auto 1.75rem;
    max-width: 42ch;
}

.cqrr-backdrop .done .send {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Same size as the form's actions, so the modal keeps one button scale. */
.cqrr-backdrop .done .send a {
    text-decoration: none;
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    padding: 0 1.5rem;
    height: 44px;
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    border-radius: 10px;
    transition: all .3s ease;
}

.cqrr-backdrop .send .wa {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: #ffffff;
}

.cqrr-backdrop .send .wa:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(37, 211, 102, .3);
    color: #ffffff;
}

.cqrr-backdrop .send .em {
    background: var(--cq-btn-fill);
    color: #000000;
    box-shadow: 0 4px 15px rgba(214, 185, 124, .3);
}

.cqrr-backdrop .send .em:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(214, 185, 124, .5);
    background: var(--cq-btn-fill);
    color: #000000;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 700px) {
    .cqrr-strip {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }

    .cqrr-strip .cqrr-strip-btn {
        width: 100%;
        font-size: .85rem;
        padding: 0 1.25rem;
    }

    .cqrr-backdrop .two {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .cqrr-backdrop .actions {
        flex-direction: column-reverse;
    }

    .cqrr-backdrop .btn-ghost {
        width: 100%;
    }

    .cqrr-backdrop .done .send a {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .cqrr-hero-hint {
        font-size: .8rem;
        margin-top: .85rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cqrr-backdrop *,
    .cqrr-strip * {
        animation: none !important;
        transition: none !important;
    }
}

/* ==========================================================================
   The return date, revealed by the Trip select (client preview)

   Trip is a plain select.txt, styled by the Cabin rules above -- it needs
   nothing of its own. Only the panel it opens is defined here.
   ========================================================================== */

.cqrr-backdrop .cqrr-reveal[hidden] {
    display: none;
}

.cqrr-backdrop .cqrr-reveal {
    animation: cqrrReveal .28s ease both;
}

@keyframes cqrrReveal {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .cqrr-backdrop .cqrr-reveal { animation: none; }
}
