/* Global Book Demo Page Styles */
:root {
    --demo-primary: #0030DB;
    --demo-accent: #0028b8;
    --demo-light-blue: #00BEFF;
    --demo-purple: #9E5EE5;
    --demo-gradient: linear-gradient(135deg, #00BEFF, #0030DB 50%, #9E5EE5);
    --demo-bg: #f8fafc;
    --demo-card: #ffffff;
    --demo-border: #e2e8f0;
}

.demo-hero {
    min-height: 90vh;
    padding: 6rem 0;
    display: flex;
    align-items: center;
    background: radial-gradient(circle at top right, rgba(0, 48, 219, 0.03), transparent),
                radial-gradient(circle at bottom left, rgba(0, 48, 219, 0.02), transparent);
}

.demo-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.demo-info h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: #1a202c;
}

.demo-info h1 span {
    color: var(--demo-primary);
}

.demo-info p {
    font-size: 1.25rem;
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

.benefit-list {
    list-style: none;
    padding: 0;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.2rem;
    font-weight: 500;
    color: #2d3748;
}

.benefit-item i {
    color: var(--demo-primary);
    font-size: 1.2rem;
}

/* Form Card Styling */
.demo-card {
    background: var(--demo-card);
    border: 1px solid var(--demo-border);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 48, 219, 0.08);
    position: relative;
    overflow: hidden;
}

.demo-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00BEFF, #0030DB, #9E5EE5);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    border: 1px solid var(--demo-border);
    background: #fff;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--demo-primary);
    box-shadow: 0 0 0 4px rgba(0, 48, 219, 0.1);
    background: #fff;
}

.form-group textarea {
    resize: none;
    height: 100px;
}

.submit-btn {
    width: 100%;
    background: #0030DB;
    color: #ffffff;
    padding: 14px;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    margin-top: 2rem;
    text-transform: none;
}

.submit-btn:hover {
    background: #0025A8;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 48, 219, 0.2);
}

.form-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.85rem;
    color: #718096;
}

.form-footer i {
    color: var(--demo-primary);
    margin-right: 4px;
}

/* Responsive Overrides */
@media (max-width: 1024px) {
    .demo-hero {
        padding: 2rem 0 3rem;
    }
    .demo-container {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }
    /* Form first on mobile — users were landing on the marketing copy, not seeing
       the form, and bouncing. Reverse order so the CTA is the first thing visible. */
    .demo-card {
        order: -1;
    }
    .demo-info {
        order: 1;
    }
    .demo-info h1 {
        font-size: 2.4rem;
    }
    .benefit-item {
        justify-content: center;
    }
    .demo-info p {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 640px) {
    .demo-hero {
        padding: 1.25rem 0 2.5rem;
    }
    .demo-card {
        padding: 1.75rem 1.25rem;
    }
    .demo-info h1 {
        font-size: 2rem;
    }
    .demo-info p {
        font-size: 1.05rem;
    }
}

/* ============================================================
   BOOKER — Dual-pane modal (Time Champ style)
   ============================================================ */

/* Page shell */
.jb-page {
    min-height: 100vh;
    background: #f5f7fb;
    background-image:
        radial-gradient(at 10% 0%, rgba(0, 48, 219, 0.06) 0%, transparent 40%),
        radial-gradient(at 90% 100%, rgba(158, 94, 229, 0.06) 0%, transparent 45%);
    padding: 24px 20px 40px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.jb-topbar {
    margin: 0 0 28px;
    padding: 0 12px;
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
}

.jb-topbar-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.jb-topbar-logo img {
    height: 32px;
    width: auto;
}

.jb-topbar-name {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-weight: 700;
    font-size: 20px;
    color: #0f172a;
    letter-spacing: -0.3px;
}

.jb-intro {
    max-width: 1100px;
    margin: 0 auto 28px;
    padding: 0 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.jb-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: #ffffff;
    border: 1px solid rgba(0, 48, 219, 0.14);
    border-radius: 999px;
    color: var(--demo-primary);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.2px;
    box-shadow: 0 4px 12px rgba(0, 48, 219, 0.06);
}

.jb-eyebrow-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
    animation: jbEyebrowPulse 1.8s infinite;
}

@keyframes jbEyebrowPulse {
    0%   { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6); }
    70%  { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.jb-heading {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-size: 36px !important;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
    letter-spacing: -1px;
    line-height: 1.1;
    white-space: nowrap;
}

.jb-heading-accent {
    color: #0030DB;
}

.jb-sub-heading {
    font-size: 14px;
    color: #64748b;
    margin: 0;
    max-width: 520px;
    line-height: 1.55;
}

.jb-legal {
    max-width: 960px;
    margin: 20px auto 0;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
}

.jb-legal a {
    color: var(--demo-primary);
    text-decoration: none;
    font-weight: 600;
}

.jb-legal a:hover { text-decoration: underline; }

/* Modal card */
.jb-booker {
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 16px;
    box-shadow:
        0 40px 80px rgba(15, 23, 42, 0.08),
        0 12px 24px rgba(15, 23, 42, 0.04),
        0 0 0 1px rgba(15, 23, 42, 0.04);
    overflow: hidden;
}

.jb {
    display: grid;
    grid-template-columns: 48% 52%;
    min-height: 580px;
}

/* ---- LEFT PANE (brand color + calendar) ---- */
.jb-left {
    background: linear-gradient(180deg, #2c4adf 0%, #1e3a8a 100%);
    color: #ffffff;
    padding: 36px 32px;
    display: flex;
    flex-direction: column;
    position: relative;
}

.jb-left-inner {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
}

.jb-left-mark {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    margin-bottom: 18px;
}

.jb-left-logo {
    margin-bottom: 18px;
}

.jb-left-logo img {
    height: 32px;
    width: auto;
    filter: brightness(0) invert(1);
}

.jb-left-title {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    line-height: 1.3;
    margin-bottom: 28px;
    letter-spacing: -0.2px;
}

.jb-left-title span {
    display: block;
    font-weight: 400;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 4px;
}

.jb-month-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 18px;
}

.jb-month {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    min-width: 140px;
    text-align: center;
}

.jb-month-nav {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    transition: all 0.15s ease;
}

.jb-month-nav:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

.jb-month-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.jb-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin-bottom: 6px;
}

.jb-weekdays span {
    text-align: center;
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    letter-spacing: 0.6px;
    padding: 10px 0;
}

.jb-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.jb-day {
    aspect-ratio: 1;
    border: none;
    background: transparent;
    border-radius: 50%;
    font-size: 13px;
    font-weight: 500;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.12s ease, color 0.12s ease;
    padding: 0;
}

.jb-day:hover:not(:disabled):not(.selected) {
    background: rgba(255, 255, 255, 0.15);
}

.jb-day.disabled {
    color: rgba(255, 255, 255, 0.3);
    cursor: not-allowed;
}

.jb-day-empty {
    aspect-ratio: 1;
    pointer-events: none;
    cursor: default;
    background: transparent;
}

.jb-day.today:not(.selected) {
    background: rgba(255, 255, 255, 0.1);
    font-weight: 700;
}

.jb-day.selected {
    background: #ffffff;
    color: #1e3a8a;
    font-weight: 700;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* ---- RIGHT PANE (white) ---- */
.jb-right {
    padding: 36px 32px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.jb-meta-row {
    margin-bottom: 16px;
}

.jb-meta-label {
    font-size: 13px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 8px;
}

.jb-meta-box {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 14px;
    background: #f1f5f9;
    border-radius: 10px;
    font-size: 14px;
    color: #334155;
    font-weight: 500;
}

.jb-meta-box i {
    color: #64748b;
    font-size: 13px;
    flex-shrink: 0;
}

.jb-time-head {
    margin-top: 6px;
    margin-bottom: 14px;
}

.jb-time-title {
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 4px;
}

.jb-time-showing {
    font-size: 13px;
    color: #475569;
    margin-bottom: 10px;
}

.jb-time-showing strong {
    color: #0f172a;
    font-weight: 600;
}

/* Timezone dropdown */
.jb-tz {
    position: relative;
    margin-top: 6px;
}

.jb-tz-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 13px;
    color: #334155;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    transition: border-color 0.15s ease;
}

.jb-tz-btn:hover {
    border-color: #94a3b8;
}

.jb-tz-btn > i:first-child {
    font-size: 11px;
    color: #94a3b8;
}

.jb-tz-btn-label {
    color: #0f172a;
    font-weight: 500;
}

.jb-tz-chev {
    margin-left: 2px;
    color: #94a3b8;
    transition: transform 0.15s ease;
}

.jb-tz-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    z-index: 10;
    width: 300px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.12);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 340px;
}

.jb-tz-search-wrap {
    position: relative;
    border-bottom: 1px solid #f1f5f9;
}

.jb-tz-search-wrap i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 12px;
    pointer-events: none;
}

.jb-tz-search {
    width: 100%;
    padding: 11px 12px 11px 34px;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 13px;
    color: #0f172a;
    outline: none;
}

.jb-tz-search::placeholder { color: #94a3b8; }

.jb-tz-list {
    overflow-y: auto;
    padding: 4px;
    flex: 1;
}

.jb-tz-list::-webkit-scrollbar { width: 4px; }
.jb-tz-list::-webkit-scrollbar-track { background: transparent; }
.jb-tz-list::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }

.jb-tz-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
    padding: 8px 12px;
    border: none;
    background: transparent;
    border-radius: 6px;
    font-family: inherit;
    font-size: 13px;
    color: #334155;
    cursor: pointer;
    text-align: left;
    transition: background 0.12s ease;
}

.jb-tz-item:hover {
    background: #f1f5f9;
}

.jb-tz-item.selected {
    background: #f8fafc;
    color: #0f172a;
    font-weight: 600;
}

.jb-tz-item-label {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.jb-tz-item-tag {
    font-size: 9.5px;
    font-weight: 700;
    color: #64748b;
    background: #e2e8f0;
    padding: 2px 7px;
    border-radius: 999px;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}

.jb-tz-item-check {
    color: #94a3b8;
    font-size: 11px;
}

.jb-tz-empty {
    padding: 20px 14px;
    text-align: center;
    color: #94a3b8;
    font-size: 13px;
}

/* Slots */
.jb-slots {
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
    padding-right: 4px;
    margin-right: -4px;
    max-height: 340px;
    flex: 1;
    min-height: 0;
}

.jb-slots::-webkit-scrollbar { width: 4px; }
.jb-slots::-webkit-scrollbar-track { background: transparent; }
.jb-slots::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }

.jb-slot {
    padding: 13px 14px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #334155;
    cursor: pointer;
    transition: border-color 0.12s ease, background 0.12s ease, color 0.12s ease;
    font-family: inherit;
    text-align: center;
}

.jb-slot:hover:not(:disabled) {
    border-color: #94a3b8;
    color: #0f172a;
    background: #fafbfc;
}

.jb-slot:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    color: #cbd5e1;
}

.jb-no-slots {
    padding: 28px 16px;
    text-align: center;
    color: #94a3b8;
    font-size: 13.5px;
    background: #f8fafc;
    border-radius: 10px;
}

/* ---- FORM PHASE (right pane swap) ---- */
.jb-back {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 0;
    margin-bottom: 18px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    transition: color 0.15s ease;
}

.jb-back:hover { color: var(--demo-primary); }
.jb-back i { font-size: 10px; }

.jb-form-head {
    margin-bottom: 18px;
}

.jb-form-title {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-size: 19px;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: -0.3px;
    margin-bottom: 4px;
}

.jb-form-when {
    font-size: 13px;
    color: #64748b;
}

.jb-form-tz {
    margin-top: 4px;
    font-size: 12px;
    color: var(--demo-primary);
    font-weight: 600;
}

.jb-done-tz {
    font-size: 12.5px;
    color: var(--demo-primary);
    font-weight: 600;
    margin-bottom: 10px;
}

.jb-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.jb-field {
    position: relative;
}

.jb-field input,
.jb-field textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    color: #0f172a;
    background: #ffffff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.jb-field-required input {
    padding-right: 28px;
}

.jb-required {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #dc2626;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    pointer-events: none;
}

.jb-field input::placeholder,
.jb-field textarea::placeholder {
    color: #94a3b8;
}

.jb-field input:focus,
.jb-field textarea:focus {
    outline: none;
    border-color: var(--demo-primary);
    box-shadow: 0 0 0 3px rgba(0, 48, 219, 0.08);
}

.jb-field textarea {
    resize: none;
    min-height: 72px;
    font-family: inherit;
}

.jb-error {
    padding: 10px 12px;
    background: rgba(239, 68, 68, 0.06);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    color: #b91c1c;
    font-size: 13px;
}

.jb-submit {
    margin-top: 8px;
    padding: 13px 16px;
    background: var(--demo-primary);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
    font-family: inherit;
}

.jb-submit:hover:not(:disabled) { background: var(--demo-accent); }
.jb-submit:disabled { opacity: 0.6; cursor: wait; }

/* ---- DONE PHASE (full card) ---- */
.jb-done {
    grid-column: 1 / -1;
    padding: 60px 40px;
    text-align: center;
    background: #ffffff;
}

.jb-done-check {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #10b981;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 22px;
    animation: jbPop 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes jbPop {
    0% { transform: scale(0.4); opacity: 0; }
    70% { transform: scale(1.06); }
    100% { transform: scale(1); opacity: 1; }
}

.jb-done-title {
    font-family: 'Poppins', 'Ubuntu', sans-serif;
    font-size: 24px;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: -0.4px;
    margin-bottom: 8px;
}

.jb-done-when {
    font-size: 15px;
    color: #0f172a;
    font-weight: 500;
    margin-bottom: 4px;
}

.jb-done-sub {
    font-size: 13px;
    color: #94a3b8;
    margin-bottom: 24px;
}

.jb-gcal {
    display: inline-block;
    padding: 12px 20px;
    border-radius: 8px;
    background: var(--demo-primary);
    color: #ffffff;
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s ease;
}

.jb-gcal:hover {
    background: var(--demo-accent);
}

/* Responsive */
@media (max-width: 860px) {
    .jb {
        grid-template-columns: 1fr;
        min-height: 0;
    }
    .jb-left {
        padding: 28px 22px 24px;
    }
    .jb-right {
        padding: 24px 22px 28px;
    }
    .jb-slots {
        max-height: 260px;
    }
    .jb-heading {
        font-size: 26px !important;
        letter-spacing: -0.6px;
        white-space: normal;
    }
    .jb-sub-heading {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .jb-topbar {
        margin-bottom: 18px;
    }
    .jb-left {
        padding: 24px 18px 22px;
    }
    .jb-right {
        padding: 20px 18px 24px;
    }
    .jb-left-title {
        font-size: 16px;
        margin-bottom: 18px;
    }
    .jb-month {
        font-size: 16px;
    }
    .jb-day {
        font-size: 12px;
    }
}

/* Hide the legacy left-info column when present */
body.jb-standalone {
    padding-top: 0 !important;
}
body.jb-standalone .header-wrapper,
body.jb-standalone #header-placeholder,
body.jb-standalone #product-header-placeholder,
body.jb-standalone #footer-placeholder,
body.jb-standalone footer {
    display: none !important;
}
