/**
 * Manage Booking portal — shortcode styles
 *
 * Designed against the True Blue Tour theme's brand tokens:
 *   --tbt-bg:        #f7f4ef (warm cream — page background)
 *   --tbt-ink:       #111111
 *   --tbt-primary:   #1479b8 (signature brand blue)
 *   --tbt-secondary: #e6ded2 (warm beige — decorative panel)
 *   --tbt-muted:     #6b7a84
 *   --tbt-border:    #e0dbd3
 *   --tbt-card:      #ffffff
 *   --tbt-serif:     Cormorant Garamond
 *   --tbt-sans:      Inter
 *
 * Each variable ships with a hard-coded fallback so the portal still
 * looks coherent on a different theme (just in case).
 *
 * Layout: login view is a full-viewport split — beige decorative column
 * on the left, transparent (page-bg) column on the right holding the
 * form. The wrapper breaks out of the theme's content container with a
 * 100vw trick so the beige reaches the left edge of the browser window.
 */

/* =========================================================
   Outer wrapper — viewport-wide breakout
========================================================= */
.tbt-mb {
    --mb-card:        var(--tbt-card, #ffffff);
    --mb-bg:          var(--tbt-bg, #f7f4ef);
    --mb-beige:       var(--tbt-secondary, #e6ded2);
    --mb-border:      var(--tbt-border, #e0dbd3);
    --mb-muted:       var(--tbt-muted, #6b7a84);
    --mb-primary:     var(--tbt-primary, #1479b8);
    --mb-primary-ink: #0e5a8c;
    --mb-ink:         var(--tbt-ink, #111111);
    --mb-serif:       var(--tbt-serif, "Cormorant Garamond", Georgia, serif);
    --mb-sans:        var(--tbt-sans, "Inter", Arial, sans-serif);

    /* Break out of the theme's content container so the split-screen
       backgrounds reach each edge of the viewport. */
    position: relative;
    left: 50%;
    right: 50%;
    width: 100vw;
    margin-left: -50vw;
    margin-right: -50vw;
    margin-top: 0;
    margin-bottom: 0;
    max-width: none;
    padding: 0;

    font-family: var(--mb-sans);
    color: var(--mb-ink);
    background: var(--mb-bg);
}

/* =========================================================
   Flash messages — full-width strip above the split
========================================================= */
.tbt-mb__flash {
    padding: 14px 24px;
    margin: 0;
    font-size: 14px;
    line-height: 1.55;
    text-align: center;
    border-bottom: 1px solid var(--mb-border);
    background: var(--mb-card);
}
.tbt-mb__flash--error {
    background: #faf1ef;
    color: #8a2e1d;
    border-bottom-color: #e4c4bf;
}
.tbt-mb__flash--info {
    background: #eef5f8;
    color: var(--mb-primary-ink);
    border-bottom-color: #c9dbe4;
}

/* =========================================================
   Panel shell — no card chrome anymore. Login is a split-screen,
   detail view keeps its own layered header.
========================================================= */
.tbt-mb__panel {
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
}

/* =========================================================
   LOGIN view — two-column split, full viewport height
========================================================= */
.tbt-mb__panel--login {
    display: grid;
    grid-template-columns: 1fr;
    min-height: calc(100vh - 160px); /* leaves room for header + footer */
}
@media (min-width: 900px) {
    .tbt-mb__panel--login {
        grid-template-columns: 1fr 1fr;
    }
}

/* LEFT column — beige block, full-height, content aligns with 960px
   content rail so the copy doesn't drift too far off to the edge */
.tbt-mb__intro {
    background: var(--mb-beige);
    padding: 80px 48px;
    color: var(--mb-ink);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-end;      /* push content toward the centre seam */
    min-height: 420px;
}
.tbt-mb__intro > * {
    width: 100%;
    max-width: 440px;
}
.tbt-mb__intro-eyebrow {
    margin: 0 0 14px 0;
    font-family: var(--mb-sans);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--mb-primary);
}
.tbt-mb__intro-title {
    margin: 0 0 20px 0;
    font-family: var(--mb-serif);
    font-weight: 500;
    font-size: 48px;
    line-height: 1.05;
    letter-spacing: -0.6px;
    color: var(--mb-ink);
}
.tbt-mb__intro-lede {
    margin: 0 0 36px 0;
    font-family: var(--mb-serif);
    font-size: 20px;
    line-height: 1.5;
    font-style: italic;
    color: var(--mb-primary-ink);
    max-width: 32ch;
}
.tbt-mb__rule {
    width: 72px;
    height: 1px;
    background: var(--mb-primary);
    opacity: 0.6;
    margin: 32px 0 20px 0;
    border: 0;
}
.tbt-mb__intro-note {
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
    color: var(--mb-muted);
    max-width: 36ch;
}

/* RIGHT column — transparent so the page bg shows through. Form is
   max-width constrained and aligned to the centre seam. */
.tbt-mb__form-wrap {
    background: transparent;
    padding: 80px 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}
.tbt-mb__form-wrap > * {
    width: 100%;
    max-width: 440px;
}

.tbt-mb__form-head {
    margin: 0 0 32px 0;
}
.tbt-mb__form-head h3 {
    margin: 0 0 10px 0;
    font-family: var(--mb-serif);
    font-weight: 500;
    font-size: 32px;
    line-height: 1.15;
    color: var(--mb-ink);
}
.tbt-mb__form-head p {
    margin: 0;
    font-size: 14px;
    color: var(--mb-muted);
    line-height: 1.6;
    max-width: 42ch;
}

/* =========================================================
   Form fields
========================================================= */
.tbt-mb__form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.tbt-mb__field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.tbt-mb__field label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--mb-primary);
}
.tbt-mb__field input {
    padding: 14px 16px;
    font-size: 15px;
    font-family: var(--mb-sans);
    border: 1px solid var(--mb-border);
    border-radius: 2px;
    background: var(--mb-card);
    color: var(--mb-ink);
    transition: border-color .18s ease, box-shadow .18s ease;
}
.tbt-mb__field input::placeholder {
    color: #b6ada0;
}
.tbt-mb__field input:focus {
    outline: none;
    border-color: var(--mb-primary);
    box-shadow: 0 0 0 3px rgba(20, 121, 184, 0.15);
}
.tbt-mb__field--ref input {
    text-transform: uppercase;
    font-family: "JetBrains Mono", Menlo, Monaco, monospace;
    letter-spacing: 1.5px;
}

/* =========================================================
   Buttons
========================================================= */
.tbt-mb__btn {
    appearance: none;
    border: 1px solid transparent;
    border-radius: 2px;
    padding: 15px 26px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-family: var(--mb-sans);
    cursor: pointer;
    transition: background .18s ease, border-color .18s ease, color .18s ease, transform .1s ease;
}
.tbt-mb__btn:active:not(:disabled) {
    transform: translateY(1px);
}
.tbt-mb__btn--primary {
    background: var(--mb-primary);
    color: #ffffff;
    border-color: var(--mb-primary);
}
.tbt-mb__btn--primary:hover:not(:disabled) {
    background: var(--mb-primary-ink);
    border-color: var(--mb-primary-ink);
}
.tbt-mb__btn--secondary {
    background: transparent;
    color: var(--mb-primary);
    border-color: var(--mb-border);
}
.tbt-mb__btn--secondary:hover:not(:disabled) {
    border-color: var(--mb-primary);
    color: var(--mb-primary-ink);
}
.tbt-mb__btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.tbt-mb__btn--block {
    width: 100%;
    justify-content: center;
}

.tbt-mb__hint {
    margin: 14px 0 0 0;
    font-size: 13px;
    color: var(--mb-muted);
    line-height: 1.55;
}
.tbt-mb__hint a {
    color: var(--mb-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}
.tbt-mb__hint a:hover {
    color: var(--mb-primary-ink);
}

/* =========================================================
   DETAIL view — edge-to-edge layered sections
========================================================= */
.tbt-mb__panel--detail {
    padding: 0;
}

/* Hero band — beige strip with greeting + ticket card */
.tbt-mb__hero {
    padding: 64px 48px 52px;
    background:
        radial-gradient(ellipse at top left, rgba(20, 121, 184, 0.07), transparent 55%),
        var(--mb-beige);
    border-bottom: 1px solid var(--mb-border);
    position: relative;
}
.tbt-mb__hero-inner {
    max-width: 960px;
    margin: 0 auto;
}
.tbt-mb__hero-eyebrow {
    margin: 0 0 12px 0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--mb-primary);
}
.tbt-mb__greeting {
    margin: 0 0 8px 0;
    font-family: var(--mb-serif);
    font-weight: 500;
    font-size: 46px;
    line-height: 1.05;
    letter-spacing: -0.6px;
    color: var(--mb-ink);
}
.tbt-mb__greeting em {
    font-style: italic;
    color: var(--mb-primary);
}
.tbt-mb__greeting-sub {
    margin: 0 0 32px 0;
    font-family: var(--mb-serif);
    font-size: 20px;
    line-height: 1.5;
    font-style: italic;
    color: var(--mb-primary-ink);
    max-width: 60ch;
}

/* Ticket strip */
.tbt-mb__ticket {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    background: var(--mb-card);
    border: 1px solid var(--mb-border);
    border-radius: 2px;
    overflow: hidden;
    box-shadow: 0 6px 24px -14px rgba(17, 17, 17, 0.18);
    max-width: 520px;
}
.tbt-mb__ticket-ref {
    padding: 20px 26px;
    border-right: 1px dashed var(--mb-border);
    flex: 1 1 auto;
    min-width: 0;
}
.tbt-mb__ticket-label {
    display: block;
    margin: 0 0 6px 0;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--mb-muted);
}
.tbt-mb__ticket-code {
    margin: 0;
    font-family: "JetBrains Mono", Menlo, Monaco, monospace;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--mb-ink);
    word-break: break-all;
}
.tbt-mb__ticket-status {
    display: flex;
    align-items: center;
    padding: 18px 26px;
    background: rgba(255, 255, 255, 0.55);
}

/* Status pill */
.tbt-mb__pill {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    background: var(--mb-border);
    color: var(--mb-primary-ink);
    white-space: nowrap;
}
.tbt-mb__pill--pending       { background: #f3e5cc; color: #7a5818; }
.tbt-mb__pill--deposit_due   { background: #f4dccb; color: #7a3f18; }
.tbt-mb__pill--deposit_paid  { background: #d8e7f0; color: var(--mb-primary-ink); }
.tbt-mb__pill--paid_in_full  { background: #d6e7d8; color: #28583a; }
.tbt-mb__pill--cancelled     { background: #ecd4cf; color: #7a2b1d; }
.tbt-mb__pill--completed     { background: #d9d9e8; color: #3a3968; }

/* Body */
.tbt-mb__body {
    max-width: 960px;
    margin: 0 auto;
    padding: 48px 48px 24px;
}

/* Section */
.tbt-mb__section {
    padding: 6px 0 32px;
}
.tbt-mb__section + .tbt-mb__section {
    border-top: 1px solid var(--mb-border);
    padding-top: 32px;
}
.tbt-mb__section-head {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin: 0 0 20px 0;
}
.tbt-mb__section-head h3 {
    margin: 0;
    font-family: var(--mb-serif);
    font-weight: 500;
    font-size: 26px;
    line-height: 1.2;
    color: var(--mb-ink);
}
.tbt-mb__section-head::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--mb-border);
    align-self: center;
    margin-top: 2px;
}

/* Definition list */
.tbt-mb__dl {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 22px 32px;
    margin: 0;
}
.tbt-mb__dl > div { min-width: 0; }
.tbt-mb__dl dt {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--mb-muted);
    margin-bottom: 6px;
    text-transform: uppercase;
}
.tbt-mb__dl dd {
    margin: 0;
    font-family: var(--mb-serif);
    font-size: 22px;
    font-weight: 500;
    line-height: 1.25;
    color: var(--mb-ink);
    word-break: break-word;
}
.tbt-mb__dl dd a {
    color: var(--mb-primary);
    text-decoration: none;
    border-bottom: 1px solid rgba(20, 121, 184, 0.3);
    transition: border-color .18s ease, color .18s ease;
}
.tbt-mb__dl dd a:hover {
    color: var(--mb-primary-ink);
    border-bottom-color: var(--mb-primary-ink);
}

/* Payment summary */
.tbt-mb__money-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0;
    background: var(--mb-card);
    border: 1px solid var(--mb-border);
    border-radius: 2px;
    overflow: hidden;
}
.tbt-mb__money-grid > div {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 22px 24px;
    border-right: 1px solid var(--mb-border);
}
.tbt-mb__money-grid > div:last-child {
    border-right: none;
}
.tbt-mb__money-grid span {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--mb-muted);
}
.tbt-mb__money-grid strong {
    font-family: var(--mb-serif);
    font-size: 28px;
    font-weight: 500;
    color: var(--mb-ink);
    line-height: 1;
}
.tbt-mb__money-grid__balance {
    background: var(--mb-beige);
}
.tbt-mb__money-grid__balance strong {
    color: var(--mb-primary-ink);
}
.tbt-mb__money-note {
    margin: 18px 0 0 0;
    font-size: 13px;
    font-style: italic;
    color: #8a5418;
    line-height: 1.55;
}

/* Actions */
.tbt-mb__actions {
    padding: 26px 0 8px 0;
    border-top: 1px solid var(--mb-border);
    margin-top: 4px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.tbt-mb__actions-note {
    width: 100%;
    margin: 10px 0 0 0;
    font-size: 13px;
    font-style: italic;
    color: var(--mb-muted);
    line-height: 1.55;
}

/* Footer */
.tbt-mb__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 960px;
    margin: 0 auto;
    padding: 26px 48px;
    gap: 16px;
    flex-wrap: wrap;
    border-top: 1px solid var(--mb-border);
}
.tbt-mb__footer form { margin: 0; }
.tbt-mb__logout {
    appearance: none;
    background: none;
    border: 0;
    padding: 0;
    color: var(--mb-primary);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    cursor: pointer;
    font-family: var(--mb-sans);
    border-bottom: 1px solid rgba(20, 121, 184, 0.35);
    transition: color .18s ease, border-color .18s ease;
}
.tbt-mb__logout:hover {
    color: var(--mb-primary-ink);
    border-bottom-color: var(--mb-primary-ink);
}
.tbt-mb__footer-hint {
    margin: 0;
    font-size: 12px;
    font-style: italic;
    color: var(--mb-muted);
}

/* =========================================================
   Mobile
========================================================= */
@media (max-width: 900px) {
    .tbt-mb__panel--login {
        min-height: 0;
    }
    .tbt-mb__intro {
        padding: 48px 28px 40px;
        align-items: flex-start;
        min-height: 0;
    }
    .tbt-mb__intro > * { max-width: none; }
    .tbt-mb__intro-title { font-size: 36px; }

    .tbt-mb__form-wrap {
        padding: 48px 28px 56px;
    }
    .tbt-mb__form-wrap > * { max-width: none; }
    .tbt-mb__form-head h3 { font-size: 26px; }

    .tbt-mb__hero      { padding: 40px 28px 36px; }
    .tbt-mb__greeting  { font-size: 34px; }
    .tbt-mb__body      { padding: 32px 28px 12px; }
    .tbt-mb__footer    { padding: 22px 28px; }

    .tbt-mb__ticket-ref { border-right: none; border-bottom: 1px dashed var(--mb-border); }
    .tbt-mb__ticket-status { padding: 16px 26px; }

    .tbt-mb__actions .tbt-mb__btn { flex: 1 1 100%; }

    .tbt-mb__money-grid > div {
        border-right: none;
        border-bottom: 1px solid var(--mb-border);
    }
    .tbt-mb__money-grid > div:last-child { border-bottom: none; }
}