/* Egypt Tour Builder — Front-end Widget Styles
   All classes prefixed with .etb- to avoid conflicts */

:root {
    --etb-cream:   #FAF4E8;
    --etb-cream2:  #F2E8D0;
    --etb-cream3:  #E6D4B0;
    --etb-gold:    #B8860B;
    --etb-gold2:   #D4A017;
    --etb-ink:     #2C1A0E;
    --etb-ink2:    #5C3D1E;
    --etb-muted:   #9C7A52;
    --etb-white:   #FFFFFF;
    --etb-r:       12px;
}

/* ── TRIGGER ── */
.etb-trigger-wrap { text-align: center; padding: 2rem 1rem; }

.etb-trigger {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    padding: 16px 38px;
    background: var(--etb-gold);
    color: #fff;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 17px;
    font-style: italic;
    border: none;
    border-radius: 100px;
    cursor: pointer;
    letter-spacing: .3px;
    box-shadow: 0 6px 28px rgba(184,134,11,.38);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.etb-trigger:hover {
    background: var(--etb-gold2);
    transform: translateY(-2px);
    box-shadow: 0 10px 36px rgba(184,134,11,.48);
}
.etb-trigger svg { flex-shrink: 0; }

/* ── MODAL OVERLAY ── */
.etb-modal {
    display: none;
    visibility: hidden;
    position: fixed;
    inset: 0;
    z-index: 9999999;
    background: rgba(44,26,14,.7);
    overflow-y: auto;
    padding: 20px 16px;
    box-sizing: border-box;
}
.etb-modal.etb-open {
    visibility: visible;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    animation: etbFadeIn .3s ease;
}
@keyframes etbFadeIn { from { opacity:0 } to { opacity:1 } }

/* ── MODAL SHELL ── */
.etb-shell {
    width: 100%;
    max-width: 1080px;
    background: var(--etb-cream);
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 80px rgba(44,26,14,.35);
    animation: etbSlideUp .4s cubic-bezier(.4,0,.2,1);
    border: 1px solid rgba(184,134,11,.18);
    min-height: 640px;
}
@keyframes etbSlideUp {
    from { transform: translateY(50px); opacity:0 }
    to   { transform: translateY(0);    opacity:1 }
}

/* ── HERO ── */
.etb-hero {
    position: relative;
    height: 260px;
    flex-shrink: 0;
    overflow: hidden;
}
.etb-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: opacity .5s ease;
}
.etb-hero-ov {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 25%, rgba(250,244,232,.55) 65%, var(--etb-cream) 100%);
}
.etb-hero-txt {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 0 36px 24px;
    z-index: 2;
}
.etb-eyebrow {
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--etb-gold);
    font-weight: 600;
    margin-bottom: 5px;
    text-shadow: 0 1px 8px rgba(255,255,255,.6);
    font-family: inherit;
}
.etb-htitle {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: clamp(22px, 3.5vw, 34px);
    font-weight: 400;
    color: var(--etb-ink);
    line-height: 1.2;
    text-shadow: 0 2px 12px rgba(255,255,255,.5);
}
.etb-htitle em { font-style: italic; color: var(--etb-gold); }
.etb-close {
    position: absolute;
    top: 14px; right: 16px;
    z-index: 10;
    width: 34px; height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,.82);
    border: 1px solid rgba(184,134,11,.2);
    color: var(--etb-ink);
    font-size: 15px;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
}
.etb-close:hover { background:#fff; border-color: var(--etb-gold); color: var(--etb-gold); }

/* ── PROGRESS ── */
.etb-progress {
    display: flex;
    align-items: center;
    padding: 0 36px;
    background: var(--etb-white);
    border-bottom: 1.5px solid var(--etb-cream3);
    overflow-x: auto;
    scrollbar-width: none;
    flex-shrink: 0;
}
.etb-progress::-webkit-scrollbar { display: none; }
.etb-ps {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 13px 14px 13px 0;
    opacity: .32;
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
    border-bottom: 2.5px solid transparent;
    margin-bottom: -1.5px;
    white-space: nowrap;
    cursor: default;
}
.etb-ps.etb-done { opacity: .6; cursor: pointer; }
.etb-ps.etb-active { opacity: 1; border-bottom-color: var(--etb-gold); }
.etb-ps.etb-done .etb-pnum,
.etb-ps.etb-active .etb-pnum { background: var(--etb-gold); color: #fff; }
.etb-pnum {
    width: 21px; height: 21px;
    border-radius: 50%;
    background: var(--etb-cream3);
    display: flex; align-items: center; justify-content: center;
    font-size: 9px; font-weight: 600;
    color: var(--etb-muted);
    flex-shrink: 0;
}
.etb-plabel { font-size: 11px; font-weight: 500; color: var(--etb-ink2); }
.etb-psep { width: 18px; height: 1.5px; background: var(--etb-cream3); flex-shrink: 0; }

/* ── BODY ── */
.etb-body {
    display: flex;
    flex: 1;
    overflow: hidden;
    min-height: 440px;
}

/* ── ANUBIS SIDEBAR ── */
.etb-sidebar {
    width: 190px;
    flex-shrink: 0;
    background: linear-gradient(160deg, #f5ecd8 0%, #ede0c4 100%);
    border-right: 1.5px solid var(--etb-cream3);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding: 16px 10px 0;
    position: relative;
    overflow: hidden;
}
.etb-sidebar::before {
    content: '';
    position: absolute;
    bottom: 0; left: 50%;
    transform: translateX(-50%);
    width: 150px; height: 150px;
    background: radial-gradient(circle, rgba(184,134,11,.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.etb-anubis-quote {
    font-family: Georgia, serif;
    font-size: 11px;
    font-style: italic;
    color: var(--etb-muted);
    text-align: center;
    line-height: 1.65;
    padding: 0 8px 14px;
    min-height: 56px;
    transition: opacity .35s;
    position: relative;
    z-index: 2;
}
.etb-anubis-fig { width: 100%; position: relative; z-index: 2; }
#etb-anubis {
    width: 100%;
    display: block;
    animation: none;
    filter: drop-shadow(0 4px 16px rgba(184,134,11,.22));
    transition: filter .5s;
}
/* Only animate when modal is open */
.etb-modal.etb-open #etb-anubis {
    animation: etbFloat 6s ease-in-out infinite;
}
#etb-anubis.etb-react { filter: drop-shadow(0 6px 28px rgba(184,134,11,.5)); }
#etb-anubis.etb-honeymoon { filter: drop-shadow(0 6px 24px rgba(200,80,100,.25)) sepia(.15); }
@keyframes etbFloat {
    0%,100% { transform: translateY(0); }
    50%      { transform: translateY(-10px); }
}

/* ── CONTENT AREA ── */
.etb-content {
    flex: 1;
    overflow-y: auto;
    padding: 28px 30px 36px;
    background: var(--etb-cream);
    scrollbar-width: thin;
    scrollbar-color: var(--etb-cream3) transparent;
}
.etb-content::-webkit-scrollbar { width: 4px; }
.etb-content::-webkit-scrollbar-thumb { background: var(--etb-cream3); border-radius: 2px; }

/* ── LOADING (permanently hidden) ── */
.etb-loading { display: none !important; }

/* ── STEPS ── */
.etb-step { display: none; animation: etbStepIn .3s ease; }
.etb-step.etb-active { display: block; }
@keyframes etbStepIn {
    from { opacity: 0; transform: translateX(14px); }
    to   { opacity: 1; transform: translateX(0); }
}
.etb-step-h2 {
    font-family: Georgia, serif;
    font-size: 24px;
    font-weight: 400;
    color: var(--etb-ink);
    margin: 0 0 4px;
    line-height: 1.2;
}
.etb-step-sub { font-size: 13px; color: var(--etb-muted); margin-bottom: 22px; line-height: 1.65; }

/* ── SECTION LABEL ── */
.etb-sec-label {
    display: block;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--etb-gold);
    margin: 20px 0 10px;
}
.etb-sec-label:first-child { margin-top: 0; }
.etb-optional-tag {
    font-size: 10px;
    color: var(--etb-muted);
    text-transform: none;
    letter-spacing: 0;
    font-weight: 400;
    font-style: normal;
}

/* ── PHOTO CARDS ── */
.etb-photo-grid {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}
.etb-grid-2 { grid-template-columns: repeat(2, 1fr); }
.etb-grid-3 { grid-template-columns: repeat(3, 1fr); }
.etb-grid-4 { grid-template-columns: repeat(4, 1fr); }

.etb-pcard {
    position: relative;
    border-radius: var(--etb-r);
    overflow: hidden;
    cursor: pointer;
    border: 3px solid transparent;
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
    aspect-ratio: 4/3;
    background: var(--etb-cream3);
    box-shadow: 0 2px 12px rgba(44,26,14,.08);
}
.etb-pcard.etb-wide { aspect-ratio: 16/7; }
.etb-pcard:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(44,26,14,.12); border-color: rgba(212,160,23,.5); }
.etb-pcard.etb-sel { border-color: var(--etb-gold); box-shadow: 0 4px 20px rgba(184,134,11,.3); }
.etb-pcard.etb-sel::after {
    content: '✓';
    position: absolute; top: 9px; right: 9px;
    width: 23px; height: 23px;
    background: var(--etb-gold);
    color: #fff;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700;
    z-index: 3;
    line-height: 23px; text-align: center;
}
.etb-pcard img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0;
    transition: opacity .5s, transform .5s;
}
.etb-pcard img.etb-loaded { opacity: 1; }
.etb-pcard:hover img { transform: scale(1.06); }
.etb-pcard-placeholder {
    width: 100%; height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--etb-cream2);
    color: var(--etb-muted);
    font-size: 28px;
}
.etb-pcard-placeholder span { font-size: 11px; margin-top: 6px; text-align: center; padding: 0 8px; }
.etb-card-ov {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(44,26,14,.72) 0%, rgba(44,26,14,.08) 45%, transparent 100%);
}
.etb-card-lbl { position: absolute; bottom: 0; left: 0; right: 0; padding: 10px 12px; z-index: 2; }
.etb-card-title { font-size: 12px; font-weight: 500; color: #fff; line-height: 1.3; text-shadow: 0 1px 4px rgba(0,0,0,.45); }
.etb-card-sub   { font-size: 10px; color: rgba(255,255,255,.72); margin-top: 2px; text-shadow: 0 1px 3px rgba(0,0,0,.4); }

/* ── CHIP OPTIONS ── */
.etb-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 16px; }
.etb-chip {
    padding: 7px 15px;
    border-radius: 100px;
    border: 1.5px solid var(--etb-cream3);
    font-size: 12px;
    cursor: pointer;
    color: var(--etb-ink2);
    background: var(--etb-white);
    transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
    white-space: nowrap;
    box-shadow: 0 1px 4px rgba(44,26,14,.05);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.etb-chip:hover { border-color: var(--etb-gold2); color: var(--etb-gold); }
.etb-chip.etb-sel { background: #FFFBEE; border-color: var(--etb-gold); color: var(--etb-gold); font-weight: 500; }
.etb-chip img { width: 16px; height: 16px; object-fit: contain; }

/* ── SLIDER ── */
.etb-slider-wrap { margin-bottom: 22px; }
.etb-slider-val {
    font-family: Georgia, serif;
    font-size: 40px;
    font-weight: 400;
    color: var(--etb-ink);
    margin-bottom: 10px;
}
.etb-slider-val span { font-size: 18px; color: var(--etb-muted); margin-left: 4px; }
.etb-range {
    width: 100%;
    -webkit-appearance: none;
    height: 3px;
    background: var(--etb-cream3);
    border-radius: 3px;
    outline: none;
}
.etb-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: var(--etb-gold);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(184,134,11,.35);
}
.etb-range-ticks { display: flex; justify-content: space-between; margin-top: 5px; }
.etb-range-ticks span { font-size: 10px; color: var(--etb-muted); }

/* ── TEXT INPUTS ── */
.etb-field { margin-bottom: 14px; }
.etb-field-label {
    display: block;
    font-size: 10px; font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--etb-muted);
    margin-bottom: 6px;
}
.etb-input,
.etb-textarea {
    width: 100%;
    padding: 11px 14px;
    background: var(--etb-white);
    border: 1.5px solid var(--etb-cream3);
    border-radius: 10px;
    color: var(--etb-ink);
    font-size: 13px;
    font-family: inherit;
    outline: none;
    transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
    box-shadow: 0 1px 4px rgba(44,26,14,.05);
    box-sizing: border-box;
}
.etb-input:focus,
.etb-textarea:focus { border-color: var(--etb-gold); background: #FFFDF5; box-shadow: 0 0 0 3px rgba(184,134,11,.1); }
.etb-input::placeholder,
.etb-textarea::placeholder { color: rgba(92,61,30,.28); }
.etb-textarea { min-height: 74px; resize: vertical; }
.etb-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* ── HONEYMOON BANNER ── */
.etb-hm-banner {
    display: none;
    background: linear-gradient(135deg, #fff5f7, #fffbee);
    border: 1.5px solid rgba(184,134,11,.3);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 18px;
    font-family: Georgia, serif;
    font-style: italic;
    font-size: 13px;
    color: var(--etb-ink2);
    line-height: 1.65;
}
/* etb-hm-banner now uses inline style */
.etb-hm-banner strong { color: var(--etb-gold); font-style: normal; }
.etb-surprise-wrap { display: none; }
.etb-surprise-wrap.etb-show { display: block; }
.etb-hm-only { display: none; }
.etb-hm-active .etb-hm-only { display: block; }

/* ── NAVIGATION ── */
.etb-nav {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1.5px solid var(--etb-cream3);
}
.etb-btn-next {
    padding: 12px 30px;
    background: var(--etb-gold);
    color: #fff;
    border: none;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
    letter-spacing: .3px;
    box-shadow: 0 4px 16px rgba(184,134,11,.3);
}
.etb-btn-next:hover { background: var(--etb-gold2); transform: translateY(-1px); box-shadow: 0 6px 22px rgba(184,134,11,.4); }
.etb-btn-back {
    padding: 12px 22px;
    background: var(--etb-white);
    border: 1.5px solid var(--etb-cream3);
    border-radius: 100px;
    font-size: 13px;
    color: var(--etb-muted);
    cursor: pointer;
    font-family: inherit;
    transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
}
.etb-btn-back:hover { border-color: var(--etb-gold2); color: var(--etb-gold); }
.etb-step-ctr { margin-left: auto; font-size: 11px; color: var(--etb-muted); }

/* ── CONTACT STEP ── */
.etb-disclaimer {
    margin-top: 16px;
    background: var(--etb-cream2);
    border-radius: 10px;
    padding: 11px 15px;
    font-size: 11px;
    color: var(--etb-muted);
    line-height: 1.7;
    font-style: italic;
}
.etb-surprise-note {
    display: none;
    background: #FFFBEE;
    border: 1.5px solid rgba(184,134,11,.25);
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 11px;
    color: var(--etb-muted);
    line-height: 1.7;
    font-style: italic;
    margin-top: 8px;
}
.etb-surprise-note.etb-show { display: block; }

/* ── SUCCESS SCREEN ── */
.etb-success { display: none; text-align: center; padding: 52px 32px; }
.etb-success.etb-show { display: block; animation: etbStepIn .4s ease; }
.etb-success-icon {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #fffbee, #fff5dc);
    border: 2px solid #F0C040;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 20px;
    font-size: 26px;
    color: var(--etb-gold);
    box-shadow: 0 4px 20px rgba(184,134,11,.2);
}
.etb-success-h2 { font-family: Georgia, serif; font-size: 30px; font-weight: 400; color: var(--etb-ink); margin-bottom: 10px; }
.etb-success-p  { font-size: 13px; color: var(--etb-muted); line-height: 1.8; max-width: 420px; margin: 0 auto 20px; }
.etb-success-note { background: var(--etb-white); border: 1.5px solid var(--etb-cream3); border-radius: 12px; padding: 12px 18px; font-size: 11px; color: var(--etb-muted); max-width: 400px; margin: 0 auto; line-height: 1.7; font-style: italic; }

/* ── RESPONSIVE ── */
@media (max-width: 720px) {
    /* Sidebar hidden — full width for content */
    .etb-sidebar { display: none; }
    .etb-body { flex-direction: column; }
    .etb-content { padding: 18px 16px 24px; }

    /* Hero */
    .etb-hero { height: 180px; }
    .etb-hero-txt { padding: 0 16px 16px; }
    .etb-htitle { font-size: 22px; }

    /* Progress */
    .etb-progress { padding: 0 12px; }
    .etb-plabel { display: none; }
    .etb-ps { padding: 10px 8px 10px 0; }

    /* Grids */
    .etb-grid-3 { grid-template-columns: repeat(2, 1fr); }
    .etb-grid-4 { grid-template-columns: repeat(2, 1fr); }

    /* Chips — natural wrap */
    .etb-chips { gap: 6px; }
    .etb-chip {
        padding: 8px 12px;
        font-size: 12px;
        white-space: normal;
        text-align: center;
    }

    /* Fields */
    .etb-field-row { grid-template-columns: 1fr; }

    /* Card labels */
    .etb-card-title { font-size: 11px; }
    .etb-card-sub { display: none; }
}

@media (max-width: 480px) {
    /* Modal fills the full screen */
    .etb-modal.etb-open { padding: 0; align-items: stretch; }
    .etb-shell { border-radius: 0; min-height: 100dvh; min-height: 100svh; }
    .etb-grid-2 { grid-template-columns: 1fr 1fr; }

    /* Content padding — extra at bottom so nav clears floating WhatsApp / chatbot buttons */
    .etb-content { padding: 16px 14px 120px; }

    /* Modal must be above WhatsApp (z:9999) and Thoth */
    .etb-modal { z-index: 9999999 !important; }

    /* Nav — NOT sticky, just flows naturally */
    /* Floats above chat widgets by having high z-index */
    .etb-nav {
        position: relative;
        margin-top: 24px;
        padding: 14px 0 12px;
        border-top: 1.5px solid var(--etb-cream3);
        gap: 8px;
        flex-wrap: wrap;
    }

    /* Big tappable buttons */
    .etb-btn-next {
        flex: 1;
        min-width: 120px;
        padding: 14px 16px;
        font-size: 14px;
        min-height: 50px;
        text-align: center;
        justify-content: center;
    }
    .etb-btn-back {
        padding: 14px 16px;
        font-size: 14px;
        min-height: 50px;
    }
    .etb-step-ctr {
        width: 100%;
        text-align: center;
        order: -1;
        margin-left: 0;
    }
}
/* ── NO-PHOTO CARD (before images uploaded) ── */
.etb-pcard-noimg {
    width: 100%; height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--etb-cream2), var(--etb-cream3));
    padding: 12px;
    text-align: center;
}
.etb-pcard-noimg-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--etb-ink2);
    line-height: 1.3;
    margin-bottom: 4px;
}
.etb-pcard-noimg-sub {
    font-size: 10px;
    color: var(--etb-muted);
    line-height: 1.4;
}
/* Selected state for no-photo cards */
.etb-pcard.etb-sel .etb-pcard-noimg {
    background: linear-gradient(135deg, #fff8e8, #fef3d0);
}
.etb-pcard.etb-sel .etb-pcard-noimg-label {
    color: var(--etb-gold);
}

/* ── HIDE FLOATING CHAT WIDGETS WHILE TOUR BUILDER IS OPEN ──
   Prevents WhatsApp / chatbot buttons from overlapping the modal nav */
.etb-modal.etb-open ~ * .wpwl-whatsapp-button,
.etb-modal.etb-open ~ * .tidio-chat,
.etb-modal.etb-open ~ * #tidio-chat,
.etb-modal.etb-open ~ * .crisp-client,
.etb-modal.etb-open ~ * #crisp-chatbox,
.etb-modal.etb-open ~ * [class*="whatsapp"],
.etb-modal.etb-open ~ * [id*="whatsapp"],
.etb-modal.etb-open ~ * [class*="WAStickyBtn"],
.etb-modal.etb-open ~ * [id*="WAStickyBtn"] {
    display: none !important;
}
