.qr-public-account-root {
    position: relative;
    z-index: 1020;
}

.qr-public-account-fab {
    position: fixed;
    right: 22px;
    bottom: 96px;
    min-height: 50px;
    padding: 0 14px;
    border: none;
    border-radius: 14px;
    background: #1f2937;
    color: #ffffff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .28);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    z-index: 1022;
    transition:
        transform .2s ease,
        opacity .2s ease,
        box-shadow .2s ease;
}

.qr-public-account-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 34px rgba(0, 0, 0, .34);
}

.qr-public-account-fab-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.qr-public-account-fab-text {
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.qr-public-account-fab-count {
    min-width: 23px;
    height: 23px;
    padding: 0 6px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
}

.qr-public-account-overlay {
    position: fixed;
    inset: 0;
    background: rgba(17, 24, 39, .64);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 1058;
    transition:
        opacity .25s ease,
        visibility .25s ease;
}

.qr-public-account-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.qr-public-account-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: min(430px, 100%);
    height: 100%;
    background: #ffffff;
    color: #1f2937;
    box-shadow: -12px 0 38px rgba(0, 0, 0, .28);
    transform: translateX(105%);
    visibility: hidden;
    z-index: 1059;
    display: flex;
    flex-direction: column;
    transition:
        transform .3s ease,
        visibility .3s ease;
}

.qr-public-account-drawer.show {
    transform: translateX(0);
    visibility: visible;
}

.qr-public-account-header {
    min-height: 76px;
    padding: 17px 18px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #ffffff;
}

.qr-public-account-title {
    font-size: 20px;
    line-height: 1.2;
    font-weight: 800;
    color: #111827;
}

.qr-public-account-subtitle {
    margin-top: 4px;
    font-size: 12px;
    color: #6b7280;
}

.qr-public-account-close {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border: none;
    border-radius: 10px;
    background: #f3f4f6;
    color: #111827;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
}

.qr-public-account-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 16px;
    background: #f8fafc;
}

.qr-public-account-loading,
.qr-public-account-empty,
.qr-public-account-error {
    padding: 32px 20px;
    border-radius: 14px;
    background: #ffffff;
    text-align: center;
    font-size: 14px;
    line-height: 1.6;
    color: #64748b;
    box-shadow: 0 3px 14px rgba(15, 23, 42, .06);
}

.qr-public-account-error {
    color: #b91c1c;
}

.qr-public-account-info-card {
    margin-bottom: 14px;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 3px 14px rgba(15, 23, 42, .06);
    overflow: hidden;
}

.qr-public-account-info-toggle {
    width: 100%;
    padding: 14px;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.qr-public-account-info-toggle:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .28);
    outline-offset: -3px;
}

.qr-public-account-info-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.qr-public-account-info-top > span:first-child {
    min-width: 0;
}

.qr-public-account-info-toggle-row {
    margin-top: 11px;
    padding-top: 10px;
    border-top: 1px solid #eef2f7;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: #475569;
}

.qr-public-account-info-toggle-label {
    font-size: 11px;
    line-height: 1.4;
    font-weight: 800;
}

.qr-public-account-info-chevron {
    flex: 0 0 auto;
    transition: transform .2s ease;
}

.qr-public-account-info-toggle[aria-expanded="true"]
    .qr-public-account-info-chevron {
    transform: rotate(180deg);
}

.qr-public-account-info-details {
    padding: 0 14px 14px;
}

.qr-public-account-info-details[hidden] {
    display: none;
}

.qr-public-account-order-no {
    display: block;
    font-size: 15px;
    font-weight: 800;
    color: #111827;
}

.qr-public-account-order-date {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #64748b;
}

.qr-public-account-order-status {
    padding: 6px 9px;
    border-radius: 999px;
    background: #fff7ed;
    color: #c2410c;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}

.qr-public-account-stat-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.qr-public-account-stat {
    padding: 9px 10px;
    border-radius: 10px;
    background: #f8fafc;
}

.qr-public-account-stat-label {
    display: block;
    font-size: 10px;
    color: #64748b;
}

.qr-public-account-stat-value {
    display: block;
    margin-top: 2px;
    font-size: 13px;
    font-weight: 800;
    color: #111827;
}

.qr-public-account-item {
    margin-bottom: 10px;
    padding: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, .04);
}

.qr-public-account-item.cancelled {
    opacity: .68;
}

.qr-public-account-item-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.qr-public-account-item-name {
    min-width: 0;
    font-size: 14px;
    line-height: 1.4;
    font-weight: 800;
    color: #111827;
}

.qr-public-account-item-price {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 800;
    color: #111827;
    white-space: nowrap;
}

.qr-public-account-item-meta {
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.55;
    color: #64748b;
}

.qr-public-account-item-status-row {
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.qr-public-account-item-status {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 9px;
    border-radius: 999px;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: 10px;
    font-weight: 800;
}

.qr-public-account-item-status.preparing {
    background: #fff7ed;
    color: #c2410c;
}

.qr-public-account-item-status.ready {
    background: #ecfdf5;
    color: #047857;
}

.qr-public-account-item-status.delivered {
    background: #f0fdf4;
    color: #15803d;
}

.qr-public-account-item-status.cancelled {
    background: #fef2f2;
    color: #b91c1c;
}

.qr-public-account-item-quantity {
    font-size: 11px;
    font-weight: 700;
    color: #475569;
}

.qr-public-account-item-note {
    margin-top: 9px;
    padding: 8px 9px;
    border-radius: 8px;
    background: #f8fafc;
    font-size: 11px;
    line-height: 1.5;
    color: #475569;
}

.qr-public-account-item-discount {
    margin-top: 7px;
    font-size: 11px;
    font-weight: 700;
    color: #059669;
}

.qr-public-account-footer {
    padding: 16px 18px;
    border-top: 1px solid #e5e7eb;
    background: #ffffff;
}

.qr-public-account-summary-row {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    color: #475569;
}

.qr-public-account-summary-row strong {
    color: #111827;
}

.qr-public-account-discount-row strong {
    color: #059669;
}

.qr-public-account-total-row {
    margin-top: 11px;
    padding-top: 12px;
    border-top: 1px dashed #cbd5e1;
    font-size: 17px;
    font-weight: 800;
    color: #111827;
}

.qr-public-account-refresh {
    width: 100%;
    min-height: 43px;
    margin-top: 13px;
    border: none;
    border-radius: 11px;
    background: #1f2937;
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.qr-public-account-refresh:disabled {
    opacity: .65;
    cursor: wait;
}

.qr-public-account-modifiers {
    margin-top: 10px;
    padding: 10px 11px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #f8fafc;
}

.qr-public-account-modifier-title {
    margin-bottom: 6px;
    color: #64748b;
    font-size: 10px;
    line-height: 1.3;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .4px;
}

.qr-public-account-modifier-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 4px 0;
    font-size: 11px;
    line-height: 1.4;
}

.qr-public-account-modifier-name {
    min-width: 0;
    color: #334155;
    font-weight: 700;
}

.qr-public-account-modifier-name::before {
    content: "+";
    margin-right: 6px;
    color: #059669;
    font-weight: 900;
}

.qr-public-account-modifier-price {
    flex: 0 0 auto;
    color: #475569;
    font-weight: 800;
    white-space: nowrap;
}

body.qr-public-account-open {
    overflow: hidden !important;
}

@media (max-width: 575px) {
    .qr-public-account-fab {
        left: 16px;
        right: auto;
        bottom: calc(77px + env(safe-area-inset-bottom));
        min-width: 52px;
        width: 52px;
        height: 52px;
        padding: 0;
        border-radius: 50%;
    }

    .qr-public-account-fab-text {
        display: none;
    }

    .qr-public-account-fab-count {
        position: absolute;
        top: -5px;
        right: -4px;
        border: 2px solid #ffffff;
    }

    .qr-public-account-drawer {
        width: 100%;
    }

    .qr-public-account-header {
        min-height: 70px;
        padding: 14px 15px;
    }

    .qr-public-account-body {
        padding: 12px;
    }

    .qr-public-account-footer {
        padding:
            14px
            15px
            calc(14px + env(safe-area-inset-bottom));
    }
}
