.lb-scheduler,
.lb-scheduler-sessions {
    --lb-ink: var(--wp--preset--color--contrast, #182230);
    --lb-muted: var(--wp--preset--color--accent-4, #667085);
    --lb-accent: var(--lb-scheduler-accent, var(--wp--preset--color--contrast, #6557d9));
    --lb-accent-strong: var(--wp--preset--color--accent-3, var(--lb-accent));
    --lb-accent-soft: var(--wp--preset--color--accent-5, #f2f0ff);
    --lb-border: #e4e7ec;
    --lb-surface: var(--wp--preset--color--base, #ffffff);
    --lb-subtle: var(--wp--preset--color--accent-5, #f8f9fc);
    --lb-radius-lg: var(--wp--preset--spacing--30, 1.25rem);
    --lb-radius-md: var(--wp--preset--spacing--20, .65rem);
    box-sizing: border-box;
    width: 100%;
    max-width: 44rem;
    margin: clamp(1.5rem, 5vw, 3rem) auto;
    padding: clamp(1.25rem, 5vw, 2rem);
    overflow: hidden;
    border: 1px solid var(--lb-border);
    border-radius: var(--lb-radius-lg);
    background: var(--lb-surface);
    color: var(--lb-ink);
    box-shadow: var(--wp--preset--shadow--natural, none);
    font-family: inherit;
}

.lb-scheduler *,
.lb-scheduler-sessions * {
    box-sizing: border-box;
}

.lb-scheduler__header {
    margin-bottom: 1.4rem;
}

.lb-scheduler__eyebrow {
    margin: 0 0 .55rem;
    color: var(--lb-accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .12em;
    line-height: 1.2;
    text-transform: uppercase;
}

.lb-scheduler h2 {
    margin: 0 0 .55rem;
    color: var(--lb-ink);
    font-size: var(--wp--preset--font-size--x-large, clamp(1.65rem, 6vw, 2.2rem));
    line-height: 1.12;
}

.lb-scheduler__message {
    max-width: 34rem;
    margin: 0;
    color: var(--lb-muted);
    font-size: .98rem;
    line-height: 1.55;
}

.lb-scheduler__notice {
    display: flex;
    align-items: center;
    gap: .65rem;
    margin: 0 0 1.35rem;
    padding: .8rem .9rem;
    border: 1px solid #e5e1ff;
    border: 1px solid color-mix(in srgb, var(--lb-accent) 24%, var(--lb-surface));
    border-radius: .85rem;
    background: var(--lb-accent-soft);
    color: var(--lb-accent-strong);
    font-size: .84rem;
    line-height: 1.35;
}

.lb-scheduler__notice--ready {
    border-color: #cce9dc;
    background: #effaf4;
    color: #166534;
}

.lb-scheduler__notice-icon {
    display: grid;
    flex: 0 0 1.55rem;
    place-items: center;
    width: 1.55rem;
    height: 1.55rem;
    border-radius: 50%;
    background: rgba(101, 87, 217, .14);
    background: color-mix(in srgb, var(--lb-accent) 14%, transparent);
    color: var(--lb-accent-strong);
    font-size: .8rem;
    font-weight: 800;
}

.lb-scheduler__notice--ready .lb-scheduler__notice-icon {
    background: #cce9dc;
    color: #166534;
}

.lb-scheduler__login-link {
    flex: 0 0 auto;
    margin-left: auto;
    color: var(--lb-accent-strong);
    font-weight: 750;
    text-decoration: underline;
    text-underline-offset: .16em;
}

.lb-scheduler__controls {
    display: grid;
    gap: .95rem;
    margin-bottom: 1.6rem;
}

.lb-scheduler__field {
    display: grid;
    gap: .32rem;
    color: var(--lb-ink);
    font-size: .86rem;
    font-weight: 700;
}

.lb-scheduler__label {
    line-height: 1.25;
}

.lb-scheduler__field small {
    color: var(--lb-muted);
    font-size: .8rem;
    font-weight: 500;
}

.lb-scheduler__hint {
    color: var(--lb-muted);
    font-size: .76rem;
    font-weight: 450;
}

.lb-scheduler input {
    box-sizing: border-box;
    width: 100%;
    min-height: 3rem;
    margin-top: .12rem;
    padding: .7rem .8rem;
    border: 1px solid #cbd3df;
    border-radius: var(--lb-radius-md);
    outline: 0;
    background: var(--lb-surface);
    color: var(--lb-ink);
    font: inherit;
    font-size: .95rem;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.lb-scheduler input::placeholder {
    color: #9aa3af;
}

.lb-scheduler input:focus {
    border-color: var(--lb-accent);
    box-shadow: 0 0 0 .22rem rgba(101, 87, 217, .16);
    box-shadow: 0 0 0 .22rem color-mix(in srgb, var(--lb-accent) 16%, transparent);
}

.lb-scheduler__slots-header {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: .75rem;
}

.lb-scheduler__slots-header > div {
    display: flex;
    align-items: center;
    gap: .5rem;
}

.lb-scheduler__step {
    display: grid;
    flex: 0 0 1.5rem;
    place-items: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    background: var(--lb-accent);
    color: #fff;
    font-size: .75rem;
    font-weight: 800;
}

.lb-scheduler h3 {
    margin: 0;
    color: var(--lb-ink);
    font-size: var(--wp--preset--font-size--medium, 1.05rem);
}

.lb-scheduler__timezone {
    color: var(--lb-muted);
    font-size: .72rem;
    line-height: 1.3;
    text-align: right;
}

.lb-scheduler__slots {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .7rem;
    min-height: 4.4rem;
}

.lb-scheduler__slot,
.lb-scheduler-session__action {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    font: inherit;
    cursor: pointer;
}

.lb-scheduler__slot {
    display: flex;
    min-height: 4.35rem;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: .15rem;
    padding: .72rem .8rem;
    border: 1px solid #ded9fa;
    border: 1px solid color-mix(in srgb, var(--lb-accent) 22%, var(--lb-surface));
    border-radius: var(--lb-radius-md);
    background: color-mix(in srgb, var(--lb-accent) 3%, var(--lb-surface));
    color: var(--lb-accent-strong);
    text-align: left;
    transition: transform .15s ease, border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.lb-scheduler__slot:hover {
    transform: translateY(-1px);
    border-color: #b8aff3;
    border-color: color-mix(in srgb, var(--lb-accent) 48%, var(--lb-surface));
    background: #f6f4ff;
    background: color-mix(in srgb, var(--lb-accent) 8%, var(--lb-surface));
    box-shadow: 0 .45rem 1rem rgba(81, 68, 198, .1);
}

.lb-scheduler__slot:focus-visible,
.lb-scheduler-session__action:focus-visible,
.lb-scheduler__login-link:focus-visible {
    outline: 3px solid rgba(101, 87, 217, .28);
    outline: 3px solid color-mix(in srgb, var(--lb-accent) 28%, transparent);
    outline-offset: 2px;
}

.lb-scheduler__slot.is-selected,
.lb-scheduler__slot.is-selected:hover {
    border-color: var(--lb-accent);
    background: var(--lb-accent);
    color: var(--lb-surface);
    box-shadow: 0 .45rem 1rem rgba(81, 68, 198, .2);
}

.lb-scheduler__slot:disabled {
    cursor: wait;
    opacity: .7;
}

.lb-scheduler__slot-time {
    font-size: 1.02rem;
    font-weight: 800;
    letter-spacing: -.015em;
}

.lb-scheduler__slot-duration {
    color: var(--lb-muted);
    font-size: .75rem;
    font-weight: 550;
}

.lb-scheduler__slot.is-selected .lb-scheduler__slot-duration {
    color: rgba(255, 255, 255, .82);
}

.lb-scheduler__empty,
.lb-scheduler__loading,
.lb-scheduler__error {
    grid-column: 1 / -1;
    width: 100%;
    margin: 0;
    padding: 1rem;
    border-radius: .85rem;
    font-size: .86rem;
    line-height: 1.45;
    text-align: center;
}

.lb-scheduler__empty,
.lb-scheduler__loading {
    background: var(--lb-subtle);
    color: var(--lb-muted);
}

.lb-scheduler__loading {
    animation: lb-scheduler-pulse 1.2s ease-in-out infinite alternate;
}

.lb-scheduler__error {
    background: #fff1ef;
    color: #a52e24;
}

.lb-scheduler__footnote {
    margin: 1.1rem 0 0;
    color: var(--lb-muted);
    font-size: .75rem;
    line-height: 1.45;
}

.lb-scheduler-sessions__list {
    display: grid;
    gap: .7rem;
}

.lb-scheduler-session {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: .8rem;
    align-items: center;
    padding: .9rem;
    border: 1px solid var(--lb-border);
    border-radius: .85rem;
    background: var(--lb-subtle);
}

.lb-scheduler-session__details {
    display: grid;
    gap: .25rem;
    min-width: 0;
}

.lb-scheduler-session__date {
    color: var(--lb-ink);
    font-size: .9rem;
    font-weight: 750;
    text-transform: capitalize;
}

.lb-scheduler-session__meta {
    color: var(--lb-muted);
    font-size: .78rem;
}

.lb-scheduler-session__status {
    padding: .3rem .55rem;
    border-radius: 999px;
    background: #e7e9ee;
    color: #4b5563;
    font-size: .7rem;
    font-weight: 750;
    white-space: nowrap;
}

.lb-scheduler-session__status--confirmed_paid,
.lb-scheduler-session__status--confirmed_external,
.lb-scheduler-session__status--rescheduled {
    background: #dcf5e7;
    color: #166534;
}

.lb-scheduler-session__status--pending_payment,
.lb-scheduler-session__status--refund_pending,
.lb-scheduler-session__status--refund_requested {
    background: #fff1cf;
    color: #8a5b00;
}

.lb-scheduler-session__status--cancelled,
.lb-scheduler-session__status--expired,
.lb-scheduler-session__status--refunded {
    background: #eceef2;
    color: #667085;
}

.lb-scheduler-session__actions {
    display: flex;
    grid-column: 1 / -1;
    flex-wrap: wrap;
    gap: .45rem;
}

.lb-scheduler-session__action {
    min-height: 2.25rem;
    padding: .45rem .65rem;
    border: 1px solid #d7dbe4;
    border-radius: .6rem;
    background: #fff;
    color: var(--lb-accent-strong);
    font-size: .76rem;
    font-weight: 700;
}

.lb-scheduler-session__action:hover {
    border-color: #b8aff3;
    background: var(--lb-accent-soft);
}

.lb-scheduler__login {
    max-width: 44rem;
    margin: 1.5rem auto;
}

.lb-scheduler-sessions--locked {
    margin-top: 1rem;
}

@keyframes lb-scheduler-pulse {
    from { opacity: .6; }
    to { opacity: 1; }
}

@media (min-width: 600px) {
    .lb-scheduler__controls {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .lb-scheduler__slots {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 420px) {
    .lb-scheduler__slots-header {
        align-items: flex-start;
        flex-direction: column;
        gap: .35rem;
    }

    .lb-scheduler__timezone {
        text-align: left;
    }
}
