.bf-lp,
.bf-lp-queue {
    --bf-lp-wine: #8f1730;
    --bf-lp-wine-dark: #681022;
    --bf-lp-gold: #dfb35b;
    --bf-lp-ink: #241f1c;
    --bf-lp-muted: #6f625b;
    --bf-lp-paper: #fffdf9;
    --bf-lp-line: #e2d7cc;
    box-sizing: border-box;
    color: var(--bf-lp-ink);
}

.bf-lp *,
.bf-lp-queue * {
    box-sizing: border-box;
}

.bf-lp [hidden],
.bf-lp-queue [hidden] {
    display: none !important;
}

.bf-lp {
    border-top: 1px solid var(--bf-lp-line);
    margin: 64px 0 0;
    padding: 58px 0 0;
}

.bf-lp__heading h2,
.bf-lp__crowd h3,
.bf-lp__panel h3,
.bf-lp-queue h2,
.bf-lp-queue h3 {
    color: var(--bf-lp-ink);
    font-family: Georgia, 'Times New Roman', serif;
    font-weight: 400;
    line-height: 1.08;
    margin: 0;
}

.bf-lp__heading h2,
.bf-lp-queue h2 {
    font-size: clamp(30px, 4vw, 48px);
}

.bf-lp__heading > p:last-child {
    color: var(--bf-lp-muted);
    font-size: 18px;
    line-height: 1.6;
}

.bf-lp__eyebrow {
    color: var(--bf-lp-wine);
    font-size: 12px;
    font-weight: 850;
    letter-spacing: .13em;
    margin: 0 0 10px;
    text-transform: uppercase;
}

.bf-lp__actions {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 28px;
}

.bf-lp__action {
    align-items: flex-start;
    background: #f7f1ea;
    border: 1px solid var(--bf-lp-line);
    border-radius: 10px;
    color: var(--bf-lp-ink);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    min-height: 190px;
    padding: 24px;
    text-align: left;
}

.bf-lp__action > span {
    color: var(--bf-lp-wine);
    font-size: 30px;
    line-height: 1;
}

.bf-lp__action strong {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 24px;
    font-weight: 400;
    margin: 22px 0 10px;
}

.bf-lp__action small {
    color: var(--bf-lp-muted);
    font-size: 14px;
    line-height: 1.45;
}

.bf-lp__action:not(.is-disabled):hover,
.bf-lp__action:not(.is-disabled):focus-visible {
    border-color: var(--bf-lp-wine);
    box-shadow: 0 12px 30px rgba(52, 38, 31, .1);
    transform: translateY(-2px);
}

.bf-lp__action.is-disabled {
    cursor: not-allowed;
    opacity: .58;
}

.bf-lp__notice,
.bf-lp-queue__status {
    border-radius: 8px;
    margin-top: 18px;
    padding: 12px 14px;
}

.bf-lp__notice.is-success,
.bf-lp-queue__status.is-success { background: #edf7ed; border: 1px solid #b8d8b8; }
.bf-lp__notice.is-error,
.bf-lp-queue__status.is-error { background: #fff0f0; border: 1px solid #e2b4b4; }
.bf-lp__notice.is-info,
.bf-lp-queue__status.is-info { background: #f4f0ea; border: 1px solid var(--bf-lp-line); }

.bf-lp__panel {
    background: #fff;
    border: 1px solid var(--bf-lp-line);
    border-left: 5px solid var(--bf-lp-wine);
    border-radius: 10px;
    box-shadow: 0 18px 55px rgba(52, 38, 31, .08);
    margin-top: 28px;
    padding: clamp(24px, 4vw, 42px);
}

.bf-lp__form-heading,
.bf-lp__crowd-heading,
.bf-lp-queue__header {
    align-items: flex-start;
    display: flex;
    gap: 20px;
    justify-content: space-between;
}

.bf-lp__form-heading button {
    background: none;
    border: 0;
    color: var(--bf-lp-wine);
    cursor: pointer;
    font-size: 32px;
    line-height: 1;
}

.bf-lp form {
    display: grid;
    gap: 18px;
}

.bf-lp label {
    color: var(--bf-lp-ink);
    display: grid;
    font-weight: 700;
    gap: 7px;
}

.bf-lp label small {
    color: var(--bf-lp-muted);
    font-weight: 400;
}

.bf-lp input[type="text"],
.bf-lp input[type="search"],
.bf-lp select,
.bf-lp textarea {
    background: #fff;
    border: 1px solid #b7aaa0;
    border-radius: 7px;
    color: var(--bf-lp-ink);
    font: inherit;
    min-height: 48px;
    padding: 11px 13px;
    width: 100%;
}

.bf-lp textarea { min-height: 100px; resize: vertical; }
.bf-lp__check { align-items: center; display: flex !important; grid-template-columns: auto 1fr; }
.bf-lp__check input { height: 20px; width: 20px; }

.bf-lp__submit,
.bf-lp__crowd-heading button,
.bf-lp-queue button {
    background: var(--bf-lp-wine);
    border: 0;
    border-radius: 999px;
    color: #fff;
    cursor: pointer;
    font-weight: 800;
    min-height: 42px;
    padding: 10px 18px;
}

.bf-lp__submit { justify-self: start; min-height: 48px; }
.bf-lp button:disabled { cursor: not-allowed; opacity: .55; }

.bf-lp__song-results {
    display: grid;
    gap: 6px;
    max-height: 300px;
    overflow: auto;
}

.bf-lp__song-result {
    background: #f8f5f1;
    border: 1px solid var(--bf-lp-line);
    border-radius: 6px;
    color: var(--bf-lp-ink);
    cursor: pointer;
    padding: 10px 12px;
    text-align: left;
}

.bf-lp__song-result.is-selected { background: var(--bf-lp-wine); color: #fff; }

.bf-lp__crowd {
    border-top: 1px solid var(--bf-lp-line);
    margin-top: 48px;
    padding-top: 44px;
}

.bf-lp__request {
    align-items: center;
    border-bottom: 1px solid var(--bf-lp-line);
    display: flex;
    gap: 18px;
    justify-content: space-between;
    padding: 16px 0;
}

.bf-lp__request > div { display: grid; gap: 4px; }
.bf-lp__request small { color: var(--bf-lp-muted); }
.bf-lp__request button { align-items: center; background: #f7f1ea; border: 1px solid var(--bf-lp-line); border-radius: 999px; color: var(--bf-lp-wine); cursor: pointer; display: flex; gap: 8px; padding: 8px 14px; }
.bf-lp__request button strong { background: var(--bf-lp-wine); border-radius: 999px; color: #fff; min-width: 27px; padding: 3px 7px; text-align: center; }
.bf-lp__request button.is-voted { border-color: var(--bf-lp-wine); }

.bf-lp-queue {
    background: var(--bf-lp-paper);
    border: 1px solid var(--bf-lp-line);
    border-radius: 12px;
    margin: 34px 0;
    padding: clamp(22px, 4vw, 36px);
}

.bf-lp-queue__controls {
    background: #f7f1ea;
    border-radius: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin-top: 22px;
    padding: 15px;
}

.bf-lp-queue__controls label { align-items: center; display: flex; gap: 8px; font-weight: 700; }
.bf-lp-queue__controls input { height: 20px; width: 20px; }
.bf-lp-queue__list { display: grid; gap: 16px; margin-top: 22px; }

.bf-lp-queue__item {
    background: #fff;
    border: 1px solid var(--bf-lp-line);
    border-left: 5px solid var(--bf-lp-gold);
    border-radius: 9px;
    padding: 22px;
}

.bf-lp-queue__item.is-played { border-left-color: #497b4a; opacity: .78; }
.bf-lp-queue__item.is-skipped { border-left-color: #777; opacity: .68; }
.bf-lp-queue__item h3 { font-size: clamp(24px, 3vw, 34px); }
.bf-lp-queue__requester {
    color: var(--bf-lp-muted);
    margin: 8px 0 0;
}

.bf-lp-queue__message {
    background: #f7f1ea;
    border-left: 3px solid var(--bf-lp-wine);
    font-family: inherit;
    font-size: 17px;
    font-style: normal;
    line-height: 1.5;
    margin: 14px 0;
    padding: 12px 16px;
}
.bf-lp-queue__meta { color: var(--bf-lp-muted); font-size: 13px; }
.bf-lp-queue__item-controls { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.bf-lp-queue__item-controls button { border-radius: 6px; font-size: 13px; min-height: 36px; padding: 8px 12px; }

@media (max-width: 900px) {
    .bf-lp__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
    .bf-lp { margin-top: 46px; padding-top: 42px; }
    .bf-lp__actions { grid-template-columns: 1fr; }
    .bf-lp__action { min-height: 0; }
    .bf-lp__request { align-items: flex-start; }
    .bf-lp__form-heading,
    .bf-lp__crowd-heading,
    .bf-lp-queue__header { align-items: stretch; flex-direction: column; }
}

/* Permanent homepage entry for the fixed piano-shell QR. */
.bf-lp-home-launcher {
    align-items: center;
    background: #8f1730;
    border: 0;
    border-radius: 999px;
    bottom: 22px;
    box-shadow: 0 12px 32px rgba(36,31,28,.26);
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    font: 800 15px/1.2 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    gap: 9px;
    left: 22px;
    min-height: 52px;
    padding: 13px 19px;
    position: fixed;
    text-align: left;
    z-index: 100000;
}

.bf-lp-home-launcher::before {
    content: "♫";
    font-size: 21px;
    line-height: 1;
}

.bf-lp-home-launcher:hover,
.bf-lp-home-launcher:focus-visible {
    background: #681022;
    box-shadow: 0 15px 36px rgba(36,31,28,.32);
    transform: translateY(-1px);
}

@media (max-width: 600px) {
    .bf-lp-home-launcher {
        bottom: 16px;
        left: 16px;
        max-width: calc(100vw - 32px);
    }
}

.bf-lp-home-dialog {
    box-sizing: border-box;
    width: min(520px, calc(100vw - 40px));
    max-width: none;
    margin: auto;
    padding: 48px 42px 38px;
    overflow: visible;
    color: #241f1c;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(223,179,91,.14), transparent 38%),
        #fffdf9;
    border: 1px solid #e2d7cc;
    border-top: 5px solid #8f1730;
    border-radius: 18px;
    box-shadow: 0 24px 80px rgba(20, 14, 12, .4);
}

.bf-lp-home-dialog::backdrop {
    background: rgba(20, 14, 12, .68);
    backdrop-filter: blur(2px);
}

.bf-lp-home-dialog__close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    width: 42px;
    height: 42px;
    padding: 0;
    color: #241f1c;
    font: 30px/38px Arial, sans-serif;
    cursor: pointer;
    background: #fffdf9;
    border: 1px solid #e2d7cc;
    border-radius: 999px;
    box-shadow: 0 4px 16px rgba(36, 31, 28, .18);
}

.bf-lp-home-dialog__close:hover,
.bf-lp-home-dialog__close:focus-visible {
    color: #fff;
    background: #8f1730;
}

.bf-lp-home-dialog__brand {
    color: #8f1730;
    font: 800 13px/1.2 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.bf-lp-home-dialog h2 {
    margin: 8px 0 10px;
    color: #241f1c;
    font-family: Georgia,"Times New Roman",serif;
    font-size: clamp(31px, 5vw, 42px);
    font-weight: 600;
    line-height: 1.08;
}

.bf-lp-home-dialog__lead {
    margin: 0 auto;
    max-width: 390px;
    color: #5f5149;
    font: 17px/1.55 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}

.bf-lp-home-dialog__notes {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    min-height: 42px;
    margin-top: 10px;
    color: #8f1730;
    font-size: 32px;
}

.bf-lp-home-dialog__notes span {
    display: inline-block;
    animation: bf-lp-note-bounce 1s ease-in-out infinite;
}

.bf-lp-home-dialog__notes span:nth-child(2) {
    color: #dfb35b;
    animation-delay: .15s;
}

.bf-lp-home-dialog__notes span:nth-child(3) {
    animation-delay: .3s;
}

.bf-lp-home-dialog__actions {
    display: grid;
    gap: 10px;
    margin: 26px 0 18px;
}

.bf-lp-home-dialog__actions button {
    min-height: 48px;
    padding: 12px 18px;
    border-radius: 999px;
    cursor: pointer;
    font: 800 15px/1.2 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}

.bf-lp-home-dialog__primary {
    color: #fff;
    background: #8f1730;
    border: 2px solid #8f1730;
}

.bf-lp-home-dialog__primary:hover,
.bf-lp-home-dialog__primary:focus-visible {
    background: #681022;
    border-color: #681022;
}

.bf-lp-home-dialog__secondary {
    color: #681022;
    background: #fffdf9;
    border: 2px solid #8f1730;
}

.bf-lp-home-dialog__secondary:hover,
.bf-lp-home-dialog__secondary:focus-visible {
    background: #f7eee7;
}

.bf-lp-home-dialog__quiet {
    min-height: 36px !important;
    padding: 6px 12px !important;
    color: #6f625b;
    background: transparent;
    border: 0;
}

.bf-lp-home-dialog__quiet:hover,
.bf-lp-home-dialog__quiet:focus-visible {
    color: #241f1c;
    text-decoration: underline;
}

.bf-lp-home-dialog__fineprint {
    margin: 0;
    color: #786b63;
    font: 13px/1.45 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}

@keyframes bf-lp-note-bounce {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .bf-lp-home-dialog__notes span {
        animation: none;
    }
}

@media (max-width: 600px) {
    .bf-lp-home-dialog {
        width: calc(100vw - 24px);
        max-height: calc(100dvh - 24px);
        padding: 42px 24px 28px;
        overflow-y: auto;
        border-radius: 15px;
    }

    .bf-lp-home-dialog__close {
        top: 8px;
        right: 8px;
    }
}
