/* RCS PWA – Complete Dark Theme */

/* ============================================================
   CSS Variables
   ============================================================ */
:root {
    --pwa-theme-color:     #e91e8c;
    --pwa-bg-color:        #0d0d0d;
    --pwa-surface-1:       #1a1a1a;
    --pwa-surface-2:       #242424;
    --pwa-surface-3:       #2e2e2e;
    --pwa-border:          rgba(255,255,255,0.08);
    --pwa-text-primary:    #f0f0f0;
    --pwa-text-secondary:  #9a9a9a;
    --pwa-text-muted:      #5a5a5a;
    --pwa-accent:          #e91e8c;
    --pwa-accent-rgb:      233, 30, 140;
    --pwa-accent-hover:    #c4176f;
    --pwa-accent-dim:      rgba(var(--pwa-accent-rgb), 0.12);
    --pwa-gold:            #f5c842;
    --pwa-success:         #22c55e;
    --pwa-error:           #f43f5e;
    --pwa-warning:         #f59e0b;
    --pwa-blue:            #3b82f6;
    --pwa-radius:          16px;
    --pwa-radius-sm:       8px;
    --pwa-shadow:          0 4px 24px rgba(0,0,0,0.4);
    --pwa-header-h:        56px;
    --pwa-nav-h:           64px;
    --pwa-safe-bottom:     env(safe-area-inset-bottom, 0px);
    --pwa-safe-top:        env(safe-area-inset-top, 0px);
}

/* ============================================================
   Reset + Base
   ============================================================ */

/* box-sizing is safe to set globally */
*, *::before, *::after { box-sizing: border-box; }

/* margin/padding reset scoped to PWA containers.
   :where() has zero specificity so class-level rules always win. */
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner, .pwa-toast-container) *,
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner, .pwa-toast-container) *::before,
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner, .pwa-toast-container) *::after { margin: 0; padding: 0; }

/* html/body rules only apply when the full PWA is running (not install-only mode) */
body:not(.rcs-pwa-install-only) {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--pwa-bg-color);
    color: var(--pwa-text-primary);
    line-height: 1.5;
    height: 100%;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}

html:not(:has(body.rcs-pwa-install-only)) {
    -webkit-text-size-adjust: 100%;
    font-size: 16px;
    height: 100%;
}

/* Install-only mode (banner/modal on external pages): full layout passthrough */
body.rcs-pwa-install-only {
    height: auto !important;
    overflow-y: visible !important;
    overflow-x: hidden !important;
    background-color: transparent !important;
    color: inherit !important;
    font-family: inherit !important;
    line-height: inherit !important;
    -webkit-tap-highlight-color: unset;
}

/* element resets scoped to PWA containers.
   :where() keeps specificity at 0 so component classes always override. */
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner) a { color: var(--pwa-accent); text-decoration: none; }
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner) a:hover { color: var(--pwa-accent-hover); }
:where(#pwa-root, .pwa-modal-overlay, .pwa-install-banner) button { cursor: pointer; border: none; background: none; font: inherit; color: inherit; }
:where(#pwa-root) input, :where(#pwa-root) textarea, :where(#pwa-root) select { font: inherit; }

/* ============================================================
   Layout
   ============================================================ */
#pwa-root {
    position: fixed;
    inset: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.pwa-splash {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 0;
    background:
        radial-gradient(circle at top, rgba(var(--pwa-accent-rgb), 0.18), transparent 52%),
        var(--pwa-bg-color);
    transition: opacity 0.28s ease, visibility 0.28s ease, transform 0.28s ease;
}

.pwa-splash.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.pwa-splash__media {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pwa-splash__image,
.pwa-splash__logo {
    display: block;
    width: 100%;
    height: 100%;
    max-height: none;
    box-shadow: none;
}

.pwa-splash__image {
    object-fit: cover;
    border-radius: 0;
}

.pwa-splash__logo {
    width: min(58vw, 220px);
    height: auto;
    max-height: min(62vh, 760px);
    object-fit: contain;
    border-radius: 24px;
    padding: 18px;
    background: rgba(255,255,255,0.04);
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

.pwa-splash__fallback {
    width: 96px;
    height: 96px;
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--pwa-accent), var(--pwa-accent-hover));
    color: #fff;
    font-size: 40px;
    font-weight: 800;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
}

.pwa-splash__text {
    position: absolute;
    left: 0;
    right: 0;
    bottom: max(28px, calc(20px + var(--pwa-safe-bottom)));
    z-index: 2;
    max-width: min(90vw, 520px);
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
    pointer-events: none;
}

.pwa-splash__title {
    display: block;
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0;
    text-shadow: 0 4px 22px rgba(0, 0, 0, 0.48);
}

.pwa-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: calc(var(--pwa-header-h) + var(--pwa-safe-top));
    padding-top: var(--pwa-safe-top);
    background: rgba(13,13,13,0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--pwa-border);
    display: flex;
    align-items: center;
    padding-left: 20px;
    padding-right: 20px;
    z-index: 100;
}

.pwa-header__title {
    font-size: 17px;
    font-weight: 700;
    color: var(--pwa-text-primary);
    flex: 1;
}

.pwa-header__action {
    font-size: 13px;
    color: var(--pwa-accent);
    padding: 6px 10px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-accent-dim);
}

.pwa-view {
    position: fixed;
    top: calc(var(--pwa-header-h) + var(--pwa-safe-top));
    bottom: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom));
    left: 0;
    right: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
    padding: 16px;
}

.pwa-view--no-header {
    top: var(--pwa-safe-top);
}

.pwa-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom));
    padding-bottom: var(--pwa-safe-bottom);
    background: rgba(13,13,13,0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--pwa-border);
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    z-index: 100;
}

.pwa-nav__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 4px;
    color: var(--pwa-text-muted);
    font-size: 12px;
    font-weight: 500;
    transition: color 0.15s;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.pwa-nav__item svg { width: 22px; height: 22px; }
.pwa-nav__item.is-active { color: var(--pwa-accent); }
.pwa-nav__item:active { opacity: 0.7; }

/* ============================================================
   Login
   ============================================================ */
.pwa-login {
    min-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 24px;
    padding-top: calc(32px + var(--pwa-safe-top));
    background: var(--pwa-bg-color);
}

.pwa-login__logo {
    margin-bottom: 32px;
    text-align: center;
}

.pwa-login__logo-icon {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    background: linear-gradient(135deg, var(--pwa-accent), var(--pwa-accent-hover));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.pwa-login__logo-icon svg { width: 32px; height: 32px; fill: #fff; }

.pwa-login__title {
    font-size: 20px;
    font-weight: 800;
    color: var(--pwa-text-primary);
    letter-spacing: -0.5px;
}

.pwa-login__subtitle {
    font-size: 14px;
    color: var(--pwa-text-secondary);
    margin-top: 6px;
}

.pwa-login__form {
    width: 100%;
    max-width: 380px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.pwa-login__footer {
    margin-top: 24px;
    text-align: center;
    font-size: 13px;
    color: var(--pwa-text-secondary);
}

.pwa-login__footer-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pwa-login__footer-row + .pwa-login__footer-row {
    margin-top: 10px;
}

.pwa-login__notice-card {
    width: 100%;
    max-width: 380px;
    padding: 18px 20px;
    text-align: center;
    color: var(--pwa-text-primary);
}

/* ============================================================
   Form Elements
   ============================================================ */
.pwa-input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pwa-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--pwa-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pwa-input {
    width: 100%;
    padding: 14px 16px;
    background: var(--pwa-surface-1);
    border: 1.5px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    color: var(--pwa-text-primary);
    font-size: 16px;
    outline: none;
    transition: border-color 0.15s;
    -webkit-appearance: none;
}

.pwa-input:focus {
    border-color: var(--pwa-accent);
}

/* Kill autofill yellow flash */
.pwa-input:-webkit-autofill,
.pwa-input:-webkit-autofill:hover,
.pwa-input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--pwa-text-primary);
    -webkit-box-shadow: 0 0 0 1000px var(--pwa-surface-1) inset;
    transition: background-color 5000s ease-in-out 0s;
}

.pwa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 15px 24px;
    border-radius: var(--pwa-radius-sm);
    font-size: 15px;
    font-weight: 600;
    transition: background-color 0.15s, opacity 0.15s;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.pwa-btn--primary {
    background: var(--pwa-accent);
    color: #fff;
    width: 100%;
}

.pwa-btn--primary:hover, .pwa-btn--primary:active { background: var(--pwa-accent-hover); }
.pwa-btn--primary:disabled { opacity: 0.6; cursor: not-allowed; }

.pwa-btn--ghost {
    background: transparent;
    color: var(--pwa-accent);
    border: 1.5px solid var(--pwa-accent);
    width: 100%;
}

.pwa-btn--danger {
    background: var(--pwa-error);
    color: #fff;
}

.pwa-error-msg {
    background: rgba(244,63,94,0.12);
    border: 1px solid rgba(244,63,94,0.3);
    color: #fca5a5;
    padding: 10px 14px;
    border-radius: var(--pwa-radius-sm);
    font-size: 13px;
    display: none;
}

.pwa-error-msg.is-visible { display: block; }

/* ============================================================
   Cards
   ============================================================ */
.pwa-card {
    background: var(--pwa-surface-1);
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius);
    overflow: hidden;
    margin-bottom: 16px;
    padding: 15px;
}
/* Structured cards (with __header / __body children) own their own inner spacing;
   removing the card-level padding avoids triple-stacking with body + form padding. */
.pwa-card:has(.pwa-card__body) {
    padding: 0;
}

/* Appointment cards: horizontal scroll on small screens.
   Tooltip panels use position:fixed (set by JS) so they escape this container. */
.pwa-card:has(.pwa-appt) { overflow-x: auto; }

.pwa-stack:has(.pwa-card) { padding: 20px; padding-top: 0;}

.pwa-card__header {
    padding: 16px 20px 12px;
    border-bottom: 1px solid var(--pwa-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.pwa-card__header--toggle {
    gap: 12px;
}

.pwa-card__title {
    font-size: 14px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.pwa-card__body { padding: 20px; }

/* A .pwa-form directly inside a card body already benefits from the body's 20 px
   horizontal padding — suppress the form's own left/right padding to avoid doubling. */
.pwa-card__body > .pwa-form {
    padding-left: 0;
    padding-right: 0;
}

.pwa-card__body--collapsible {
    overflow: hidden;
}

.pwa-card__toggle {
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: var(--pwa-text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color 0.18s ease;
    cursor: pointer;
}
.pwa-card__toggle:active { opacity: 0.6; }

.pwa-card__toggle svg {
    width: 18px;
    height: 18px;
    transition: transform 0.2s ease;
}

.pwa-card--collapsible.is-collapsed .pwa-card__body--collapsible {
    display: none;
}

/* When collapsed: remove header bottom border (nothing below the header to divide from) */
.pwa-card--collapsible.is-collapsed .pwa-card__header {
    border-bottom: none;
}

/* When collapsed: also remove toggle-row bottom border if it's still visible */
.pwa-card--collapsible.is-collapsed .pwa-toggle-row {
    border-bottom: none;
}

.pwa-card--collapsible.is-collapsed .pwa-card__toggle {
    color: var(--pwa-text-secondary);
}

.pwa-card--collapsible.is-collapsed .pwa-card__toggle svg {
    transform: rotate(-90deg);
}

.pwa-stack {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 24px;
}

.pwa-grid {
    display: grid;
    gap: 14px;
}

.pwa-grid--admin-quick {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pwa-card--button {
    width: 100%;
    min-width: 0;
    padding: 16px 18px;
    margin: 0;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: space-between;
    transition: border-color 0.16s ease, transform 0.16s ease, background-color 0.16s ease;
}

.pwa-card--button:hover,
.pwa-card--button:focus-visible {
    border-color: rgba(var(--pwa-accent-rgb), 0.34);
    background: linear-gradient(180deg, rgba(var(--pwa-accent-rgb), 0.08), rgba(255,255,255,0.02)), var(--pwa-surface-1);
    transform: translateY(-1px);
    outline: none;
}

.pwa-update-notice {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
    padding: 16px 18px;
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(245, 158, 11, 0.14), rgba(245, 158, 11, 0.08));
}

.pwa-update-notice__content {
    min-width: 0;
    flex: 1 1 auto;
}

.pwa-update-notice__eyebrow {
    margin-bottom: 4px;
    color: #fbbf24;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-update-notice__title {
    margin: 0;
    color: #fff8eb;
    font-size: 18px;
    font-weight: 700;
}

.pwa-update-notice__text {
    margin-top: 6px;
    color: rgba(255, 248, 235, 0.84);
    font-size: 14px;
    line-height: 1.5;
}

.pwa-update-notice__actions {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    flex: 0 0 auto;
}

.pwa-update-notice__btn {
    white-space: nowrap;
}

.pwa-update-notice__dismiss {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.92);
    font-size: 22px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.pwa-update-notice__dismiss:hover,
.pwa-update-notice__dismiss:focus-visible {
    background: rgba(255,255,255,0.14);
}

.pwa-card__title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.pwa-card__title-row strong {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--pwa-text-primary);
}

.pwa-card__title-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--pwa-accent);
    background: rgba(var(--pwa-accent-rgb), 0.10);
    border: 1px solid rgba(var(--pwa-accent-rgb), 0.18);
}

.pwa-card__title-icon svg {
    width: 22px;
    height: 22px;
}

.pwa-card__text {
    font-size: 13px;
    line-height: 1.5;
    color: var(--pwa-text-secondary);
}

.pwa-card__hint {
    font-size: 12px;
    line-height: 1.4;
    color: var(--pwa-text-muted);
}

.pwa-card__hint--blocked {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(225, 186, 119, 0.12);
    border: 1px solid rgba(225, 186, 119, 0.24);
    color: #f3d5a0;
    font-weight: 600;
}

.pwa-card--admin-blocked {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at top, rgba(225, 186, 119, 0.14), transparent 46%),
        linear-gradient(180deg, rgba(18, 18, 18, 0.96), rgba(10, 10, 10, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    min-height: min(72vh, 620px);
    display: flex;
    flex-direction: column;
    gap: 18px;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.pwa-card--admin-blocked__hero {
    width: min(100%, 580px);
    padding: 36px 28px;
    display: grid;
    gap: 16px;
    text-align: center;
    justify-items: center;
}

.pwa-card--admin-blocked__logo {
    width: 84px;
    height: 84px;
    border-radius: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.24);
    overflow: hidden;
}

.pwa-card--admin-blocked__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pwa-card--admin-blocked__logo--fallback {
    color: #e1ba77;
}

.pwa-card--admin-blocked__logo--fallback svg {
    width: 34px;
    height: 34px;
}

.pwa-card--admin-blocked__kicker {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #cbb99a;
}

.pwa-card--admin-blocked__title {
    margin: 0;
    font-size: clamp(28px, 6vw, 42px);
    line-height: 1.05;
    color: #ffffff;
}

.pwa-card--admin-blocked__text {
    margin: 0;
    max-width: 42ch;
    font-size: 15px;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.74);
}

.pwa-card--admin-blocked__meta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.09);
    color: #f1e7d4;
    font-size: 13px;
    font-weight: 600;
}

.pwa-card--admin-blocked__meta-label {
    color: rgba(255, 255, 255, 0.68);
}

.pwa-card--admin-blocked__meta-value {
    color: #ffffff;
    font-weight: 700;
}

.pwa-card--admin-blocked__actions {
    display: flex;
    justify-content: center;
}

.pwa-card--admin-blocked__actions .pwa-btn {
    min-width: 220px;
}

@media (max-width: 640px) {
    .pwa-card--admin-blocked {
        min-height: min(68vh, 560px);
        padding: 18px;
    }

    .pwa-card--admin-blocked__hero {
        padding: 26px 10px 8px;
    }

    .pwa-card--admin-blocked__logo {
        width: 72px;
        height: 72px;
        border-radius: 20px;
    }

    .pwa-card--admin-blocked__title {
        font-size: clamp(24px, 8vw, 34px);
    }

    .pwa-card--admin-blocked__actions .pwa-btn {
        min-width: 0;
        width: 100%;
    }
}

.pwa-section__eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--pwa-accent);
    margin-bottom: 4px;
}

.pwa-section__title {
    font-size: 28px;
    line-height: 1.12;
    font-weight: 800;
    color: var(--pwa-text-primary);
    margin: 0 0 10px;
}

.pwa-section__copy {
    font-size: 14px;
    line-height: 1.6;
    color: var(--pwa-text-secondary);
}

/* ============================================================
   Loyalty Gauge
   ============================================================ */
.pwa-gauge-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 20px;
}

.pwa-dashboard-warning {
    margin: 0 0 16px;
    border: 1px solid rgba(244, 159, 66, 0.28);
    background:
        radial-gradient(circle at top right, rgba(245, 200, 66, 0.14), transparent 34%),
        linear-gradient(180deg, rgba(33, 24, 10, 0.98), rgba(24, 18, 8, 0.98));
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.28);
    position: relative;
    overflow: visible;
    z-index: 2;
}

.pwa-dashboard-birthday-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
    padding: 18px 20px;
    border: 1px solid rgba(228, 195, 120, 0.22);
    background:
        linear-gradient(180deg, rgba(228, 195, 120, 0.08), rgba(228, 195, 120, 0.03)),
        var(--pwa-surface-1);
}

.pwa-dashboard-birthday-card__eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #e4c378;
}

.pwa-dashboard-birthday-card__title {
    font-size: 18px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-dashboard-birthday-card__message {
    font-size: 14px;
    line-height: 1.6;
    color: var(--pwa-text-secondary);
}

.pwa-dashboard-birthday-card__action {
    width: 100%;
    margin-top: 4px;
}

.pwa-dashboard-warning--blocked {
    border-color: rgba(220, 38, 38, 0.30);
    background:
        radial-gradient(circle at top right, rgba(220, 38, 38, 0.16), transparent 34%),
        linear-gradient(180deg, rgba(42, 11, 16, 0.98), rgba(28, 9, 12, 0.98));
}

.pwa-dashboard-warning__shell {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 16px;
    padding: 18px;
    overflow: visible;
}

.pwa-dashboard-warning__icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #2a1c08;
    background: linear-gradient(180deg, #f5c842, #d9a81f);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.46);
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__icon {
    color: #ffffff;
    background: linear-gradient(180deg, #ef4444, #b91c1c);
}

.pwa-dashboard-warning__icon svg {
    width: 24px;
    height: 24px;
}

.pwa-dashboard-warning__content {
    min-width: 0;
    overflow: visible;
}

.pwa-dashboard-warning__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}

.pwa-dashboard-warning__header-main {
    min-width: 0;
}

.pwa-dashboard-warning__header-side {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.pwa-dashboard-warning__eyebrow {
    font-size: 11px;
    font-weight: 700;
    color: #f6bf6b;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    margin-bottom: 6px;
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__eyebrow {
    color: #fca5a5;
}

.pwa-dashboard-warning__title {
    font-size: 15px;
    font-weight: 800;
    color: var(--pwa-text-primary);
    line-height: 1.25;
}

.pwa-dashboard-warning__badge {
    flex-shrink: 0;
    min-width: 76px;
    padding: 9px 13px;
    border-radius: 999px;
    background: rgba(245, 200, 66, 0.14);
    border: 1px solid rgba(245, 200, 66, 0.24);
    color: #f6d783;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__badge {
    display: none;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__header {
    align-items: center;
    margin-bottom: 0;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__header-main {
    display: block;
    flex: 1;
    min-width: 0;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__header-side {
    width: auto;
    margin-left: auto;
    gap: 0;
    justify-content: flex-end;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__eyebrow {
    margin-bottom: 4px;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__title {
    font-size: 14px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__shell {
    align-items: center;
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__badge {
    background: rgba(239, 68, 68, 0.14);
    border-color: rgba(239, 68, 68, 0.24);
    color: #fecaca;
}

.pwa-dashboard-warning__section {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(245, 200, 66, 0.12);
}

.pwa-dashboard-warning__details {
    overflow: visible;
    max-height: 420px;
    opacity: 1;
    transition: max-height .24s ease, opacity .18s ease;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__details {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__section {
    border-top-color: rgba(239, 68, 68, 0.14);
}

.pwa-dashboard-warning__section-label {
    margin-bottom: 6px;
    color: #caa65a;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__section-label {
    color: #fca5a5;
}

.pwa-dashboard-warning__summary,
.pwa-dashboard-warning__consequence {
    font-size: 14px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
}

.pwa-dashboard-warning__toggle {
    width: 34px;
    height: 34px;
    border: 1px solid rgba(245, 200, 66, 0.20);
    border-radius: 12px;
    background: rgba(245, 200, 66, 0.08);
    color: #f6d783;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    transition: transform .18s ease, background-color .18s ease, border-color .18s ease;
}

.pwa-dashboard-warning__toggle svg {
    width: 16px;
    height: 16px;
}

.pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__toggle svg {
    transform: rotate(180deg);
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__toggle {
    border-color: rgba(239, 68, 68, 0.22);
    background: rgba(239, 68, 68, 0.08);
    color: #fecaca;
}

.pwa-inline-tooltip {
    position: relative;
    display: inline-flex;
    vertical-align: middle;
    margin: 0 6px 0 4px;
}

.pwa-inline-tooltip__trigger {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(245, 200, 66, 0.16);
    border: 1px solid rgba(245, 200, 66, 0.28);
    color: #f5c842;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    cursor: help;
}

.pwa-inline-tooltip__bubble {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 10px);
    transform: translateX(-50%);
    min-width: 220px;
    max-width: min(280px, calc(100vw - 48px));
    padding: 10px 12px;
    border-radius: 12px;
    background: #151825;
    color: #f8fbff;
    font-size: 12px;
    line-height: 1.5;
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.32);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .16s ease, visibility .16s ease, transform .16s ease;
    z-index: 10020;
}

.pwa-inline-tooltip:hover .pwa-inline-tooltip__bubble,
.pwa-inline-tooltip:focus-within .pwa-inline-tooltip__bubble {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-2px);
}

.pwa-dashboard-warning__consequence {
    color: var(--pwa-text-primary);
    font-weight: 600;
}

.pwa-dashboard-warning__unlock {
    padding: 14px 15px;
    border-radius: 14px;
    border: 1px solid rgba(245, 200, 66, 0.18);
    background: rgba(245, 200, 66, 0.08);
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__unlock {
    border-color: rgba(239, 68, 68, 0.18);
    background: rgba(239, 68, 68, 0.08);
}

.pwa-dashboard-warning__unlock-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.pwa-dashboard-warning__unlock-fee-label {
    color: var(--pwa-text-primary);
    font-size: 13px;
    font-weight: 700;
}

.pwa-dashboard-warning__unlock-fee-amount {
    color: #f6d783;
    font-size: 14px;
    font-weight: 800;
}

.pwa-dashboard-warning--blocked .pwa-dashboard-warning__unlock-fee-amount {
    color: #fecaca;
}

.pwa-dashboard-warning__unlock-text {
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.6;
}

.pwa-dashboard-warning--blocked .pwa-inline-tooltip__trigger {
    background: rgba(239, 68, 68, 0.14);
    border-color: rgba(239, 68, 68, 0.24);
    color: #fca5a5;
}

@media (max-width: 560px) {
    .pwa-dashboard-warning__shell {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .pwa-dashboard-warning__icon {
        width: 44px;
        height: 44px;
    }

    .pwa-dashboard-warning__header {
        flex-direction: column;
        gap: 10px;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__header {
        flex-direction: row;
        gap: 8px;
        align-items: flex-start;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__shell {
        align-items: stretch;
        gap: 0;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__icon {
        display: none;
    }

    .pwa-dashboard-warning__header-side {
        width: 100%;
        justify-content: space-between;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__header-side {
        width: auto;
        justify-content: flex-end;
    }

    .pwa-dashboard-warning__badge {
        min-width: 0;
        align-self: flex-start;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__eyebrow {
        font-size: 10px;
        letter-spacing: 0.05em;
        margin-bottom: 3px;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__title {
        font-size: 13px;
    }

    .pwa-dashboard-warning.is-collapsed .pwa-dashboard-warning__toggle {
        width: 30px;
        height: 30px;
        border-radius: 10px;
    }

    .pwa-inline-tooltip__bubble {
        position: fixed;
        left: 12px;
        right: 12px;
        bottom: 5rem;
        top: auto;
        transform: none;
        min-width: 0;
        max-width: none;
        width: auto;
        padding: 12px 14px;
        z-index: 10020;
    }

    .pwa-inline-tooltip:hover .pwa-inline-tooltip__bubble,
    .pwa-inline-tooltip:focus-within .pwa-inline-tooltip__bubble {
        transform: none;
    }
}

.pwa-gauge {
    width: 220px;
    height: 220px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pwa-gauge svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.pwa-gauge__track {
    fill: none;
    stroke: var(--pwa-surface-3);
    stroke-width: 12;
    stroke-linecap: round;
}

.pwa-gauge__fill {
    fill: none;
    stroke: var(--pwa-accent);
    stroke-width: 12;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s cubic-bezier(.4,0,.2,1);
    filter: drop-shadow(0 0 8px rgba(var(--pwa-accent-rgb), 0.5));
}

.pwa-gauge__center {
    position: relative;
    text-align: center;
    z-index: 1;
}

.pwa-gauge__points {
    font-size: 42px;
    font-weight: 900;
    color: var(--pwa-text-primary);
    line-height: 1;
    letter-spacing: -2px;
}

.pwa-gauge__label {
    font-size: 12px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 4px;
}

.pwa-gauge__next {
    margin-top: 20px;
    text-align: center;
}

.pwa-gauge__next-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--pwa-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.pwa-gauge__next-plan {
    font-size: 18px;
    font-weight: 800;
    color: var(--pwa-gold);
    margin-top: 4px;
}

.pwa-gauge__next-pts {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    margin-top: 2px;
}

/* ============================================================
   Appointment Cards — 2-column grid
   Col 1: Date / time / status  (130 px fixed)
   Col 2: Staff photo + service / staff / category / price row
   ============================================================ */
.pwa-appt {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 10px 14px;
    align-items: start;
    padding: 14px 16px;
    border-bottom: 1px solid var(--pwa-border);
    min-width: 370px; /* triggers horizontal scroll below the 2-column minimum */
}

.pwa-appt:last-child { border-bottom: none; }

/* ── Col 1 ── */
.pwa-appt__col-date {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 130px;
}

.pwa-appt__date-compact {
    font-size: 12px;
    font-weight: 700;
    color: var(--pwa-text-primary);
    line-height: 1.3;
}

/* Time slot: bold from-time */
.pwa-appt__slot {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    line-height: 1.4;
}

.pwa-appt__slot strong {
    color: var(--pwa-text-primary);
    font-weight: 700;
}

.pwa-appt__duration {
    color: var(--pwa-text-muted);
    font-size: 12px;
}

.pwa-appt__status-wrap { margin-top: 4px; }

/* Status pill */
.pwa-appt__status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 15px;
    min-width: 125px;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.3px;
    white-space: nowrap;
    text-align: center;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.03);
}

.pwa-appt__status-pill-icon {
    display: inline-flex;
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
}

.pwa-appt__status-pill-icon svg {
    width: 16px;
    height: 16px;
    display: block;
}

.pwa-appt__status-pill-label {
    display: inline-block;
}

/* ── Col 2: service + price row ── */
.pwa-appt__col-svc {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    min-width: 0;
}

.pwa-header__title--logo {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pwa-header__logo {
    display: block;
    width: auto;
    max-width: min(132px, 42vw);
    max-height: 35px;
    object-fit: contain;
}

.pwa-appt__avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--pwa-surface-2);
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
}

.pwa-appt__avatar img { width: 100%; height: 100%; object-fit: cover; }

.pwa-appt__svc-info { flex: 1; min-width: 0; }

.pwa-appt__service {
    font-size: 15px;
    font-weight: 700;
    color: var(--pwa-text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.pwa-appt__staff {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pwa-appt__category {
    font-size: 12px;
    color: var(--pwa-text-muted);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Price row (col 2, below category) ── */
.pwa-appt__price-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 5px;
}

.pwa-section-label--appointments {
    padding-top: 24px;
}

.pwa-appt-next {
    display: flex;
    justify-content: center;
    margin-bottom: 10px;
    padding-top: 22px;
    padding-bottom: 22px;
    text-align: center;
}

.pwa-appt-next__staff {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-align: center;
    justify-content: center;
}

.pwa-appt-next__staff--inline {
    flex-direction: column;
    margin-bottom: 14px;
}

.pwa-appt-next__avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--pwa-surface-2);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
    flex-shrink: 0;
}

.pwa-appt-next__avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pwa-appt-next__staff-name {
    font-size: 12px;
    line-height: 1.35;
    font-weight: 700;
    color: var(--pwa-text-secondary);
}

.pwa-appt-next__content {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.pwa-appt-next__eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.9px;
    color: var(--pwa-text-muted);
}

.pwa-appt-next__date {
    margin-top: 6px;
    font-size: 20px;
    line-height: 1.25;
    font-weight: 800;
    color: var(--pwa-text-primary);
}

.pwa-appt-next__time {
    margin-top: 4px;
    font-size: 15px;
    line-height: 1.45;
    font-weight: 700;
    color: var(--pwa-accent);
}

.pwa-appt-next__meta,
.pwa-appt-next__service {
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.45;
    color: var(--pwa-text-secondary);
}

.pwa-appt-next__service {
    font-size: 15px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-appt-next__btn {
    margin-top: 20px;
    width: 100%;
    min-width: 0;
}

.pwa-floating-widgets {
    --pwa-floating-handle-size: 36px;
    position: fixed;
    z-index: 120;
    display: flex;
    flex-direction: column;
    gap: 6px;
    pointer-events: none;
}

.pwa-floating-widgets--right-bottom {
    right: 0;
    bottom: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom) + 18px);
    align-items: flex-end;
}

.pwa-floating-widgets--right-center {
    right: 0;
    top: calc(50vh - 44px);
    align-items: flex-end;
}

.pwa-floating-widgets--left-bottom {
    left: 0;
    bottom: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom) + 18px);
    align-items: flex-start;
}

.pwa-floating-widgets--left-center {
    left: 0;
    top: calc(50vh - 44px);
    align-items: flex-start;
}

.pwa-floating-widget {
    position: relative;
    display: flex;
    width: var(--pwa-floating-handle-size);
    min-height: var(--pwa-floating-handle-size);
    pointer-events: auto;
    z-index: 1;
    overflow: visible;
}

.pwa-floating-widget.is-open {
    z-index: 6;
}

.pwa-floating-widget__shell {
    position: absolute;
    inset: 0;
    display: block;
    filter: drop-shadow(0 12px 24px rgba(0,0,0,0.28));
    overflow: visible;
}

.pwa-floating-widget__tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    width: var(--pwa-floating-handle-size);
    min-height: var(--pwa-floating-handle-size);
    padding: 0;
    border-radius: 12px 0 0 12px;
    background: rgba(13,13,13,0.96);
    border: 1px solid var(--pwa-border);
    border-right: 0;
    color: var(--pwa-text-primary);
    transition: background 0.15s ease, color 0.15s ease, transform 0.18s ease;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.pwa-floating-widgets--left-bottom .pwa-floating-widget__tab,
.pwa-floating-widgets--left-center .pwa-floating-widget__tab {
    order: 1;
    left: 0;
    right: auto;
    border-radius: 0 12px 12px 0;
    border-right: 1px solid var(--pwa-border);
    border-left: 0;
}

.pwa-floating-widget__tab:active {
    background: rgba(255,255,255,0.08);
}

.pwa-floating-widget.is-open .pwa-floating-widget__tab {
    background: rgba(255,255,255,0.08);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.pwa-floating-widget__tab-icon {
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pwa-floating-widget__tab-icon svg {
    width: 18px;
    height: 18px;
}

.pwa-floating-widget__tab-text {
    display: none;
}

.pwa-floating-widget__panel {
    position: absolute;
    right: 100%;
    margin-right: -1px;
    top: 0;
    width: 214px;
    min-width: 214px;
    max-width: min(214px, calc(100vw - 68px));
    padding: 12px 12px 12px 14px;
    border-radius: 16px 0 0 16px;
    background: rgba(13,13,13,0.96);
    border: 1px solid var(--pwa-border);
    border-right: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    visibility: hidden;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    max-height: calc(100dvh - var(--pwa-header-h) - var(--pwa-nav-h) - var(--pwa-safe-top) - var(--pwa-safe-bottom) - 24px);
    pointer-events: none;
    transform: translateX(8px) scaleX(0.92);
    transform-origin: right center;
    transition: opacity 0.16s ease, transform 0.2s ease, visibility 0s linear 0.2s;
}

.pwa-floating-widgets--left-bottom .pwa-floating-widget__panel,
.pwa-floating-widgets--left-center .pwa-floating-widget__panel {
    right: auto;
    left: 100%;
    margin-right: 0;
    margin-left: -1px;
    border-radius: 0 16px 16px 0;
    border-left: 0;
    border-right: 1px solid var(--pwa-border);
    transform: translateX(-8px) scaleX(0.92);
    transform-origin: left center;
}

.pwa-floating-widgets--right-bottom .pwa-floating-widget__panel,
.pwa-floating-widgets--left-bottom .pwa-floating-widget__panel {
    top: auto;
    bottom: 0;
}

.pwa-floating-widget.is-open .pwa-floating-widget__panel {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    right: calc(100% - var(--pwa-floating-handle-size));
    transform: translateX(0) scaleX(1);
    transition-delay: 0s;
}

.pwa-floating-widgets--left-bottom .pwa-floating-widget.is-open .pwa-floating-widget__panel,
.pwa-floating-widgets--left-center .pwa-floating-widget.is-open .pwa-floating-widget__panel {
    left: calc(100% - var(--pwa-floating-handle-size));
    transform: translateX(0) scaleX(1);
}

.pwa-floating-widget__panel-title {
    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;
    color: var(--pwa-text-primary);
}

.pwa-floating-widget__panel-meta {
    font-size: 12px;
    line-height: 1.4;
    color: var(--pwa-text-secondary);
}

.pwa-floating-widget__panel-meta svg {
    display: block;
    max-width: 100%;
}

.pwa-floating-widget__consent {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 11px;
    line-height: 1.45;
    color: var(--pwa-text-secondary);
}

.pwa-floating-widget__consent-input {
    margin-top: 2px;
    accent-color: var(--pwa-accent);
}

.pwa-floating-widget__privacy-link {
    display: none;
}

.pwa-floating-widget__privacy-link-inline {
    display: inline;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--pwa-accent);
    font-size: inherit;
    font-weight: 600;
    line-height: inherit;
    text-decoration: none;
    text-align: left;
}

.pwa-floating-widget__privacy-link-inline:active,
.pwa-floating-widget__privacy-link-inline:hover {
    color: var(--pwa-accent-hover);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.pwa-floating-widget__action {
    width: 100%;
    min-height: 36px;
    padding-top: 8px;
    padding-bottom: 8px;
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
    white-space: normal;
    line-height: 1.35;
    text-align: center;
}

.pwa-floating-widget__action[disabled] {
    opacity: 0.55;
    pointer-events: none;
}

.pwa-floating-widget__panel .pwa-btn + .pwa-floating-widget__consent {
    margin-top: 2px;
}

.pwa-appt-list-shell {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pwa-appt-list__summary {
    font-size: 12px;
    font-weight: 600;
    color: var(--pwa-text-secondary);
    padding: 0 2px;
}

.pwa-booking-shell {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-height: 100%;
    height: 100%;
}

.pwa-booking-shell__hero {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px 18px 0;
}

.pwa-booking-shell__eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--pwa-text-muted);
}

.pwa-booking-shell__title {
    font-size: 22px;
    line-height: 1.15;
    font-weight: 800;
    color: var(--pwa-text-primary);
}

.pwa-booking-shell__text {
    font-size: 13px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
    max-width: 62ch;
}

.pwa-booking-shell__external {
    align-self: flex-start;
    font-size: 13px;
    font-weight: 600;
    color: var(--pwa-accent);
}

.pwa-booking-frame-wrap {
    position: relative;
    flex: 1 1 auto;
    min-height: 0;
    border-top: 1px solid var(--pwa-border);
    background: rgba(255,255,255,0.02);
    overflow: hidden;
}

.pwa-booking-frame-loading {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 24px;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(13,13,13,0.94), rgba(13,13,13,0.84)),
        radial-gradient(circle at top, rgba(255,255,255,0.06), transparent 42%);
}

.pwa-booking-frame-loading[hidden] {
    display: none;
}

.pwa-booking-frame-loading__spinner {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.12);
    border-top-color: var(--pwa-accent);
    animation: pwa-spin 0.8s linear infinite;
}

.pwa-booking-frame-loading__title {
    font-size: 14px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-booking-frame-loading__text {
    max-width: 42ch;
    font-size: 12px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
}

.pwa-booking-frame-loading--skeleton {
    gap: 16px;
    background:
        linear-gradient(180deg, rgba(13,13,13,0.78), rgba(13,13,13,0.9));
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.pwa-booking-frame-loading__blur-card {
    width: min(320px, calc(100% - 36px));
    padding: 18px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 18px;
    background: rgba(255,255,255,0.03);
    box-shadow: 0 18px 40px rgba(0,0,0,0.28);
}

.pwa-booking-frame-loading__skeleton-line {
    height: 12px;
    border-radius: 999px;
}

.pwa-booking-frame-loading__skeleton-line + .pwa-booking-frame-loading__skeleton-line {
    margin-top: 12px;
}

.pwa-booking-frame-loading__skeleton-line--lg { width: 82%; }
.pwa-booking-frame-loading__skeleton-line--md { width: 64%; }
.pwa-booking-frame-loading__skeleton-line--sm { width: 48%; }

.pwa-booking-frame {
    width: 100%;
    height: 100%;
    min-height: 100%;
    border: 0;
    background: #0d0d0d;
    opacity: 0;
    visibility: hidden;
    display: block;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

.pwa-booking-frame.is-ready {
    opacity: 1;
    visibility: visible;
}

/* ── Iframe views: full-width / no outer padding ─────────────────────────────
   Any .pwa-view that hosts a booking or sidebar-webview iframe gets padding:0
   so the frame fills edge-to-edge (mirrors the admin-webview-route treatment). */
.pwa-view:has(.pwa-booking-frame-wrap) {
    padding: 0;
}

/* The shell still needs to fill the full view height so the frame can stretch */
.pwa-view:has(.pwa-booking-frame-wrap) .pwa-booking-shell {
    min-height: 100%;
    height: 100%;
}

body.pwa-admin-webview-route .pwa-card__title-row strong,
body.pwa-admin-webview-route .pwa-booking-shell__title,
body.pwa-admin-webview-route .pwa-booking-shell__eyebrow,
body.pwa-admin-webview-route .pwa-booking-shell__text {
    color: #111827;
}

body.pwa-admin-webview-route .pwa-view {
    padding: 0;
    background: #ffffff;
}

body.pwa-admin-webview-route .pwa-stack:has(.pwa-card) {
    padding: 0;
}

body.pwa-admin-webview-route .pwa-card,
body.pwa-admin-webview-route .pwa-booking-shell {
    background: #ffffff;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

body.pwa-admin-webview-route .pwa-booking-frame-wrap {
    border-top: 0;
    background: #ffffff;
}

body.pwa-admin-webview-route .pwa-booking-frame,
body.pwa-admin-webview-route .pwa-floating-privacy-modal__frame {
    display: block;
    border: 0;
    background: #ffffff;
}

body.pwa-admin-webview-route .pwa-booking-frame-loading,
body.pwa-admin-webview-route .pwa-booking-frame-loading--skeleton {
    background: #ffffff;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

body.pwa-admin-webview-route .pwa-booking-frame-loading__blur-card {
    background: #ffffff;
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: none;
}

body.pwa-admin-webview-route .pwa-booking-frame-loading__title {
    color: #111827;
}

body.pwa-admin-webview-route .pwa-booking-frame-loading__text {
    color: #4b5563;
}

body.pwa-admin-webview-route .pwa-booking-frame-loading__spinner {
    border-color: rgba(17, 24, 39, 0.14);
    border-top-color: var(--pwa-accent);
}

@keyframes pwa-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.pwa-appt-list {
    padding: 0;
    overflow: hidden;
}

.pwa-appt-list__empty {
    margin-top: 4px;
}

.pwa-appt-list-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border: 0;
    border-bottom: 1px solid var(--pwa-border);
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.pwa-appt-list-item:last-child {
    border-bottom: 0;
}

.pwa-appt-list-item:active,
.pwa-appt-list-item:hover {
    background: rgba(255,255,255,0.02);
}

.pwa-appt-list-item__main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pwa-appt-list-item__note-col {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
}

.pwa-appt-list-item__note-tip {
    font-size: 15px;
    opacity: 0.7;
    transition: opacity .15s;
}

.pwa-appt-list-item__note-tip:hover,
.pwa-appt-list-item__note-tip:focus {
    opacity: 1;
}

.pwa-appt-list-item__date {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--pwa-text-primary);
}

.pwa-appt-list-item__time {
    font-size: 13px;
    line-height: 1.45;
    color: var(--pwa-text-secondary);
}

.pwa-appt-list-item__aside {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-shrink: 0;
    white-space: nowrap;
}

.pwa-appt-list-item__chevron {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 28px;
    min-width: 14px;
    font-size: 24px;
    line-height: 1;
    color: var(--pwa-text-muted);
}

.pwa-appt-detail-modal {
    width: min(100%, 760px);
    overflow: auto;
}

.pwa-appt-detail {
    padding: 22px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: visible;
}

.pwa-appt-detail__header {
    display: flex;
    gap: 14px;
    align-items: center;
    padding-right: 40px;
}

.pwa-appt-detail__header-copy {
    min-width: 0;
}

.pwa-appt-detail__eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.9px;
    color: var(--pwa-text-muted);
}

.pwa-appt-detail__title {
    margin: 6px 0 0;
    font-size: 22px;
    line-height: 1.2;
    color: var(--pwa-text-primary);
}

.pwa-appt-detail__staff {
    margin-top: 6px;
    font-size: 14px;
    color: var(--pwa-text-secondary);
}

.pwa-appt-detail__meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px;
    border-radius: 16px;
    background: var(--pwa-surface-2);
    border: 1px solid var(--pwa-border);
}

.pwa-appt-detail__meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.pwa-appt-detail__date {
    font-size: 15px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-appt-detail__time {
    font-size: 15px;
    font-weight: 700;
    color: var(--pwa-accent);
}

.pwa-appt-detail__duration {
    font-size: 13px;
    color: var(--pwa-text-secondary);
}

.pwa-appt-detail__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.pwa-appt-detail__actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.pwa-appt-detail__action-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--pwa-border);
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00)), var(--pwa-surface-2);
    color: var(--pwa-text-primary);
    text-align: left;
}

.pwa-appt-detail__action-btn:active,
.pwa-appt-detail__action-btn:hover {
    border-color: rgba(233, 30, 140, 0.35);
    background: linear-gradient(180deg, rgba(233,30,140,0.12), rgba(233,30,140,0.04)), var(--pwa-surface-2);
}

.pwa-appt-detail__action-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    background: rgba(233,30,140,0.12);
    color: var(--pwa-accent);
}

.pwa-appt-detail__action-icon svg {
    width: 20px;
    height: 20px;
}

.pwa-appt-detail__action-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.pwa-appt-detail__action-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-appt-detail__action-desc {
    font-size: 12px;
    line-height: 1.45;
    color: var(--pwa-text-secondary);
}

.pwa-appt-detail__section {
    padding: 14px 16px;
    border-radius: 16px;
    background: var(--pwa-surface-2);
    border: 1px solid var(--pwa-border);
    min-width: 0;
}

.pwa-appt-detail__section--shared-note {
    background: linear-gradient(180deg, rgba(83, 213, 108, 0.12), rgba(83, 213, 108, 0.05));
    border-color: rgba(83, 213, 108, 0.42);
    box-shadow: inset 0 0 0 1px rgba(83, 213, 108, 0.08);
}

.pwa-appt-detail__section--price {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pwa-appt-detail__label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--pwa-text-muted);
}

.pwa-appt-detail__value {
    margin-top: 6px;
    font-size: 14px;
    line-height: 1.45;
    color: var(--pwa-text-primary);
    word-break: break-word;
}

.pwa-appt-detail__price .pwa-appt__price-row {
    margin-top: 0;
}

.pwa-appt-detail__note {
    margin-top: 8px;
    font-size: 14px;
    line-height: 1.55;
    color: var(--pwa-text-primary);
    white-space: pre-wrap;
}

.pwa-appt-detail__avatar {
    width: 64px;
    height: 64px;
}

.pwa-appt-action-modal {
    width: min(100%, 620px);
    overflow: auto;
}

.pwa-appt-action {
    padding: 22px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.pwa-appt-action__header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-right: 40px;
}

.pwa-appt-action__icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(233,30,140,0.12);
    color: var(--pwa-accent);
}

.pwa-appt-action__icon svg {
    width: 24px;
    height: 24px;
}

.pwa-appt-action__copy {
    min-width: 0;
}

.pwa-appt-action__eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--pwa-text-muted);
}

.pwa-appt-action__title {
    margin: 6px 0 0;
    font-size: 20px;
    line-height: 1.2;
    color: var(--pwa-text-primary);
}

.pwa-appt-action__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.pwa-skeleton {
    position: relative;
    overflow: hidden;
    background: rgba(255,255,255,0.08);
    border-radius: 10px;
}

.pwa-skeleton::after {
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.1) 45%, transparent 100%);
    animation: pwaSkeletonShimmer 1.25s ease-in-out infinite;
}

.pwa-skeleton--avatar {
    border-radius: 999px;
}

.pwa-skeleton--line {
    height: 14px;
}

.pwa-skeleton--line-xs {
    width: 110px;
    height: 12px;
}

.pwa-skeleton--line-sm {
    width: 140px;
}

.pwa-skeleton--line-md {
    width: 220px;
}

.pwa-skeleton--line-lg {
    width: min(320px, 80%);
    height: 22px;
}

.pwa-skeleton--button {
    height: 46px;
    width: 100%;
    margin-top: 20px;
    border-radius: var(--pwa-radius-sm);
}

.pwa-skeleton--pill {
    width: 92px;
    height: 28px;
    border-radius: 999px;
}

.pwa-skeleton--chevron {
    width: 14px;
    height: 24px;
    border-radius: 6px;
}

.pwa-appt-list-item--loading {
    cursor: default;
}

.pwa-appt-list-item--loading:hover,
.pwa-appt-list-item--loading:active {
    background: transparent;
}

@keyframes pwaSkeletonShimmer {
    100% {
        transform: translateX(100%);
    }
}

@media (max-width: 640px) {
    .pwa-appt-next {
        gap: 16px;
        text-align: center;
    }

    .pwa-appt-next__staff {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .pwa-appt-next__btn {
        width: 100%;
        min-width: 0;
    }

    .pwa-appt-next__content {
        align-items: center;
        text-align: center;
    }

    .pwa-appt-list-item {
        align-items: center;
        gap: 12px;
    }

    .pwa-appt-list-item__aside {
        flex-direction: row;
        align-items: center;
        gap: 8px;
        white-space: nowrap;
    }

    .pwa-appt-detail__actions {
        grid-template-columns: 1fr;
    }

    .pwa-form-row--two {
        grid-template-columns: 1fr;
    }

    .pwa-appt-detail__grid {
        grid-template-columns: 1fr;
    }

    .pwa-appt-detail__meta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .pwa-floating-widgets--right-bottom,
    .pwa-floating-widgets--left-bottom {
        bottom: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom) + 14px);
    }

    .pwa-floating-widgets--right-center,
    .pwa-floating-widgets--left-center {
        top: calc(50vh - 40px);
    }

    .pwa-floating-widget__tab {
        width: 34px;
        min-height: 34px;
    }

    .pwa-floating-widgets {
        --pwa-floating-handle-size: 34px;
    }

    .pwa-floating-widget__panel {
        width: 186px;
        min-width: 186px;
        max-width: min(186px, calc(100vw - 60px));
        padding-top: 11px;
        padding-bottom: 11px;
    }
}

.pwa-floating-privacy-modal {
    width: min(100%, 760px);
    /* Explicit height so flex children can fill remaining space correctly.
       max-height alone is insufficient for flex: 1 1 0 to work on the body. */
    height: min(88vh, 820px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.pwa-floating-privacy-modal__header {
    flex-shrink: 0;
    padding: 20px 22px 12px;
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-floating-privacy-modal__eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--pwa-text-muted);
}

.pwa-floating-privacy-modal__title {
    margin: 6px 0 0;
    font-size: 20px;
    line-height: 1.2;
    color: var(--pwa-text-primary);
}

.pwa-floating-privacy-modal__body {
    flex: 1 1 0;
    min-height: 0;
    padding: 0;
    border-bottom: 1px solid var(--pwa-border);
    overflow: hidden;
}

.pwa-floating-privacy-modal__frame {
    width: 100%;
    height: 100%; /* fills flex body — no fixed vh height that overflows */
    border: 0;
    background: #fff;
}

.pwa-floating-privacy-modal__footer {
    flex-shrink: 0;
    padding: 14px 22px calc(20px + env(safe-area-inset-bottom, 0px));
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.pwa-floating-privacy-modal__footer .pwa-btn {
    flex: 0 1 auto;
}

@media (max-width: 480px) {
    .pwa-floating-privacy-modal__footer .pwa-btn {
        flex: 1 1 100%;
        justify-content: center;
    }
}

/* Price value: same weight/scale as status pill */
.pwa-appt__price-val {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.2px;
    white-space: nowrap;
    background: rgba(156, 163, 175, 0.10);
    color: var(--pwa-text-secondary);
}

/* ── Tooltip system (mirrors .rcs-loyalty-inline-tooltip-wrap) ── */

/* Wrapper: position:relative so the panel is anchored here */
.pwa-tooltip-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
}

/* Trigger icon (mirrors .rcs-tooltip) */
.pwa-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    border: 1px solid currentColor;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
    transition: opacity 0.15s;
}

.pwa-tooltip:focus { outline: none; }
.pwa-tooltip:hover { opacity: 0.8; }

.pwa-tooltip--price-warning {
    color: #f59e0b;
    border-color: rgba(245, 158, 11, 0.45);
    background: rgba(245, 158, 11, 0.12);
}

.pwa-tooltip--discount {
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.38);
    background: rgba(74, 222, 128, 0.10);
}

.pwa-tooltip--note {
    color: var(--pwa-text-muted);
    border-color: rgba(156, 163, 175, 0.30);
    background: rgba(156, 163, 175, 0.08);
}

/* Green when the shared/"Kunde benachrichtigen" note is active */
.pwa-tooltip--note--shared {
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.38);
    background: rgba(74, 222, 128, 0.10);
}

/* Panel: hidden by default; JS sets position:fixed + adds .is-visible */
.pwa-tooltip-panel {
    position: absolute; /* overridden to fixed by JS when shown */
    z-index: 9500;
    min-width: 210px;
    max-width: 280px;
    border-radius: 10px;
    padding: 12px 14px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    pointer-events: none;
    white-space: nowrap;
}

.pwa-tooltip-panel.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* price-warning panel: amber (dark variant) */
.pwa-tooltip-panel--price-warning {
    --tt-fg:    #fbbf24;
    --tt-muted: rgba(251, 191, 36, 0.68);
    background: linear-gradient(160deg, rgba(40, 28, 4, 0.97), rgba(55, 38, 5, 0.97));
    border: 1px solid rgba(245, 158, 11, 0.30);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.65);
}

/* discount panel: green (dark variant) */
.pwa-tooltip-panel--discount {
    --tt-fg:    #4ade80;
    --tt-muted: rgba(74, 222, 128, 0.65);
    background: linear-gradient(160deg, rgba(6, 30, 14, 0.97), rgba(8, 40, 18, 0.97));
    border: 1px solid rgba(74, 222, 128, 0.25);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.65);
}

.pwa-tooltip-panel--unlock {
    --tt-fg:    #f0c96c;
    --tt-muted: rgba(240, 201, 108, 0.72);
    background: linear-gradient(160deg, rgba(41, 30, 7, 0.97), rgba(58, 42, 9, 0.97));
    border: 1px solid rgba(240, 201, 108, 0.28);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.65);
}

/* note panel: neutral dark */
.pwa-tooltip-panel--note {
    --tt-fg:    var(--pwa-text-primary);
    --tt-muted: var(--pwa-text-secondary);
    background: linear-gradient(160deg, rgba(24, 24, 38, 0.98), rgba(32, 32, 50, 0.98));
    border: 1px solid var(--pwa-border);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.65);
}

.pwa-tooltip-note-text {
    font-size: 12px;
    line-height: 1.6;
    color: var(--tt-fg);
    white-space: pre-line;
}

/* ── Price table inside panels (mirrors rcs-loyalty-tooltip-price-table) ── */
.pwa-price-table {
    display: grid;
    gap: 7px;
    min-width: min(220px, calc(100vw - 40px));
}

.pwa-price-table__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: baseline;
}

.pwa-price-table__label {
    font-size: 12px;
    line-height: 1.35;
    color: var(--tt-muted);
    min-width: 0;
}

.pwa-price-table__value {
    font-size: 12px;
    font-weight: 600;
    color: var(--tt-muted);
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.pwa-price-table__row.is-total .pwa-price-table__label,
.pwa-price-table__row.is-total .pwa-price-table__value {
    color: var(--tt-fg);
    font-weight: 700;
}

.pwa-price-table__row.is-negative .pwa-price-table__value { color: #4ade80; }

.pwa-price-table__children {
    display: grid;
    gap: 5px;
    margin: -1px 0 2px;
    padding: 7px 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.pwa-price-table__child-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: baseline;
}

.pwa-price-table__child-label {
    font-size: 12px;
    line-height: 1.35;
    color: var(--tt-fg);
    min-width: 0;
}

.pwa-price-table__child-value {
    font-size: 12px;
    font-weight: 600;
    color: var(--tt-fg);
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip {
    display: grid;
    gap: 7px;
    min-width: min(220px, calc(100vw - 40px));
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__row,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__head,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__meta > div {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: baseline;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__label,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__refs-label {
    font-size: 12px;
    line-height: 1.35;
    color: var(--tt-muted);
    min-width: 0;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__value,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__amount {
    font-size: 12px;
    font-weight: 600;
    color: var(--tt-muted);
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__row.is-total .rcs-loyalty-tooltip-price-table__label,
.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__row.is-total .rcs-loyalty-tooltip-price-table__value,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__copy,
.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__child-label,
.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__child-value {
    color: var(--tt-fg);
    font-size: 12px;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__row.is-negative .rcs-loyalty-tooltip-price-table__value {
    color: #4ade80;
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__children {
    display: grid;
    gap: 5px;
    margin: -1px 0 2px;
    padding: 7px 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.pwa-tooltip-panel .rcs-loyalty-tooltip-price-table__child-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: baseline;
}

.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__copy,
.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__copy--muted {
    margin: 0;
    font-size: 12px;
    line-height: 1.45;
}

.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__copy--muted {
    color: var(--tt-muted);
}

.pwa-tooltip-panel .rcs-loyalty-unlock-tooltip__refs {
    display: grid;
    gap: 7px;
}

/* Badges */
.pwa-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    flex-shrink: 0;
}

.pwa-badge--pending    { background: rgba(245,158,11,0.15); color: #fbbf24; }
.pwa-badge--approved   { background: rgba(59,130,246,0.15); color: #60a5fa; }
.pwa-badge--upcoming   { background: rgba(59,130,246,0.15); color: #60a5fa; }
.pwa-badge--completed  { background: rgba(156,163,175,0.15); color: #9ca3af; }
.pwa-badge--cancelled  { background: rgba(244,63,94,0.15); color: #f87171; }
.pwa-badge--rejected   { background: rgba(244,63,94,0.15); color: #f87171; }

/* ============================================================
   Filter Tabs
   ============================================================ */
.pwa-tabs {
    display: flex;
    gap: 4px;
    background: var(--pwa-surface-1);
    border-radius: var(--pwa-radius-sm);
    padding: 4px;
    margin-bottom: 16px;
}

.pwa-tab {
    flex: 1;
    padding: 8px;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--pwa-text-secondary);
    border-radius: calc(var(--pwa-radius-sm) - 2px);
    cursor: pointer;
    transition: all 0.15s;
}

.pwa-tab.is-active {
    background: var(--pwa-surface-3);
    color: var(--pwa-text-primary);
}

/* ============================================================
   Profile / Toggle
   ============================================================ */
.pwa-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-toggle-row:last-child { border-bottom: none; }
/* Hide the divider when the status picker directly below is collapsed */
.pwa-toggle-row:has(+ .pwa-appt-status-picker--hidden) { border-bottom: none; }

.pwa-toggle-row__label { font-size: 15px; font-weight: 500; color: var(--pwa-text-primary); }
.pwa-toggle-row__desc  { font-size: 12px; color: var(--pwa-text-secondary); margin-top: 2px; }

/* ── Appointment status chip picker (Profile → Terminanzeige) ── */
.pwa-appt-status-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 20px 16px;
    /* No border-top: the toggle-row above already has border-bottom as divider */
}
.pwa-appt-status-picker--hidden {
    display: none;
}
.pwa-status-chip {
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid var(--pwa-border);
    background: transparent;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    user-select: none;
    -webkit-user-select: none;
}
.pwa-status-chip.is-active {
    background: var(--pwa-accent);
    border-color: var(--pwa-accent);
    color: #fff;
}
.pwa-status-chip:active { opacity: 0.8; }

.pwa-appt-status-info {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    margin: 0 20px 16px;
    padding: 14px 14px 14px 12px;
    border: 1px solid rgba(255, 184, 77, 0.22);
    border-radius: 16px;
    background: rgba(255, 184, 77, 0.08);
}
.pwa-appt-status-info__icon {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 184, 77, 0.16);
    color: #ffb84d;
    font-size: 14px;
    font-weight: 700;
}
.pwa-appt-status-info__copy {
    min-width: 0;
}
.pwa-appt-status-info__title {
    font-size: 13px;
    font-weight: 600;
    color: var(--pwa-text-primary);
}
.pwa-appt-status-info__text {
    margin-top: 3px;
    font-size: 12px;
    line-height: 1.45;
    color: var(--pwa-text-secondary);
}
.pwa-appt-status-info__action {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--pwa-accent);
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.pwa-no-show-modal {
    /* layout handled by .pwa-modal.pwa-no-show-modal */
}
.pwa-no-show-modal__header {
    padding: 24px 24px 14px;
    border-bottom: 1px solid var(--pwa-border);
    flex-shrink: 0;
}
.pwa-no-show-modal__eyebrow {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--pwa-text-secondary);
}
.pwa-no-show-modal__title {
    margin: 6px 0 0;
    font-size: 22px;
    line-height: 1.15;
    color: var(--pwa-text-primary);
}
.pwa-no-show-modal__intro {
    margin-top: 10px;
    font-size: 14px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
}
.pwa-no-show-modal__body {
    padding: 18px 24px 24px;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
    min-height: 0;
}
.pwa-no-show-modal__panel {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--pwa-border);
}
.pwa-no-show-modal__panel-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--pwa-text-primary);
}
.pwa-no-show-modal__panel-text {
    margin-top: 6px;
    font-size: 13px;
    line-height: 1.5;
    color: var(--pwa-text-secondary);
}
.pwa-no-show-modal__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}
.pwa-no-show-modal__fact {
    padding: 12px 14px;
    border: 1px solid var(--pwa-border);
    border-radius: 14px;
    background: rgba(255,255,255,0.02);
}
.pwa-no-show-modal__fact span {
    display: block;
    font-size: 11px;
    color: var(--pwa-text-secondary);
}
.pwa-no-show-modal__fact strong {
    display: block;
    margin-top: 5px;
    font-size: 14px;
    line-height: 1.4;
    color: var(--pwa-text-primary);
}

@media (max-width: 640px) {
    .pwa-appt-status-info {
        grid-template-columns: auto 1fr;
    }
    .pwa-appt-status-info__action {
        grid-column: 1 / -1;
        justify-self: flex-start;
    }
    .pwa-no-show-modal__grid {
        grid-template-columns: 1fr;
    }
}

.pwa-toggle {
    position: relative;
    width: 48px;
    height: 28px;
    flex-shrink: 0;
}

.pwa-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.pwa-toggle__track {
    position: absolute;
    inset: 0;
    background: var(--pwa-surface-3);
    border-radius: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.pwa-toggle input:checked + .pwa-toggle__track { background: var(--pwa-accent); }

.pwa-toggle__track::after {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.pwa-toggle input:checked + .pwa-toggle__track::after { transform: translateX(20px); }

/* ============================================================
   Benefits List
   ============================================================ */
.pwa-benefit {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 20px;
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-benefit:last-child { border-bottom: none; }

.pwa-benefit__icon {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(34,197,94,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
}

.pwa-benefit__icon svg { width: 12px; height: 12px; stroke: #22c55e; }
.pwa-benefit__text { font-size: 14px; color: var(--pwa-text-primary); line-height: 1.4; }

/* ============================================================
   Plan Header
   ============================================================ */
.pwa-plan-header {
    padding: 24px 20px;
    background: linear-gradient(135deg, rgba(var(--pwa-accent-rgb), 0.15), rgba(var(--pwa-accent-rgb), 0.08));
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-plan-name {
    font-size: 22px;
    font-weight: 900;
    letter-spacing: -0.5px;
}

.pwa-plan-pts {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    margin-top: 4px;
}

/* ============================================================
   Loading / Skeletons
   ============================================================ */
.pwa-skeleton {
    background: linear-gradient(90deg, var(--pwa-surface-2) 25%, var(--pwa-surface-3) 50%, var(--pwa-surface-2) 75%);
    background-size: 200% 100%;
    animation: pwa-shimmer 1.5s infinite;
    border-radius: 6px;
}

@keyframes pwa-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.pwa-skeleton--text  { height: 14px; margin-bottom: 8px; border-radius: 4px; }
.pwa-skeleton--title { height: 22px; width: 60%; margin-bottom: 12px; }
.pwa-skeleton--avatar { width: 44px; height: 44px; border-radius: 50%; flex-shrink: 0; }

.pwa-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--pwa-surface-2);
    border-top-color: var(--pwa-accent);
    border-radius: 50%;
    animation: pwa-spin 0.7s linear infinite;
    margin: 0 auto;
}

@keyframes pwa-spin { to { transform: rotate(360deg); } }

/* ============================================================
   Toast
   ============================================================ */
.pwa-toast-container {
    position: fixed;
    bottom: calc(var(--pwa-nav-h) + var(--pwa-safe-bottom) + 12px);
    left: 16px;
    right: 16px;
    z-index: 300;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.pwa-toast {
    background: var(--pwa-surface-2);
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    padding: 12px 16px;
    font-size: 14px;
    color: var(--pwa-text-primary);
    box-shadow: var(--pwa-shadow);
    animation: pwa-slide-up 0.25s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pwa-toast--success { border-left: 3px solid var(--pwa-success); }
.pwa-toast--error   { border-left: 3px solid var(--pwa-error); }
.pwa-toast--info    { border-left: 3px solid var(--pwa-blue); }

@keyframes pwa-slide-up {
    from { transform: translateY(20px); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

/* ============================================================
   Install Banner
   ============================================================ */
.pwa-install-banner {
    position: fixed;
    bottom: calc(var(--pwa-nav-h, 64px) + var(--pwa-safe-bottom, 0px) + 8px);
    left: max(12px, calc(50vw - 280px));
    right: max(12px, calc(50vw - 280px));
    z-index: 200;
    background: linear-gradient(135deg, var(--pwa-accent), var(--pwa-accent-hover));
    border-radius: var(--pwa-radius);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--pwa-shadow);
    animation: pwa-slide-up 0.3s ease;
}

/* When there's no nav (install-only mode) */
.pwa-install-banner--standalone {
    bottom: calc(var(--pwa-safe-bottom, 0px) + 12px);
}

/* Attractive color override — deep electric purple */
.pwa-install-banner--attractive {
    background: linear-gradient(135deg, #1e0050 0%, #5c00b8 45%, #aa00ff 100%);
    box-shadow: 0 8px 32px rgba(140, 0, 220, 0.45);
}

.pwa-install-banner__icon { font-size: 22px; flex-shrink: 0; }
.pwa-install-banner__text { flex: 1; font-size: 14px; font-weight: 600; color: #fff; }
.pwa-install-banner__desc { font-size: 12px; color: rgba(255,255,255,0.75); margin-top: 2px; }

.pwa-install-banner__btn {
    background: rgba(255,255,255,0.2);
    color: #fff;
    padding: 7px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
    border: 1.5px solid rgba(255,255,255,0.4);
}

.pwa-install-banner__close {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.7);
    padding: 4px;
    font-size: 18px;
    cursor: pointer;
    flex-shrink: 0;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    -webkit-appearance: none;
    appearance: none;
}
.pwa-install-banner__close:hover,
.pwa-install-banner__close:focus,
.pwa-install-banner__close:active {
    background: transparent;
    color: #fff;
    outline: none;
}

/* ── Install Prompt Modal ────────────────────────────────── */
.pwa-install-prompt-modal {
    width: min(calc(100vw - 32px), 480px);
    max-height: min(90vh, 780px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.pwa-install-prompt-modal__header {
    padding: 28px 28px 20px;
    border-bottom: 1px solid var(--pwa-border);
    flex-shrink: 0;
}
.pwa-install-prompt-modal__eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--pwa-accent);
}
.pwa-install-prompt-modal__title {
    margin: 8px 0 0;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--pwa-text-primary);
}
.pwa-install-prompt-modal__sub {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
}
.pwa-install-prompt-modal__body {
    padding: 20px 28px 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;   /* inner scroll managed by benefits list */
    flex: 1 1 auto;
    min-height: 0;
}
/* static items inside body: don't shrink */
.pwa-install-prompt-modal__app-row,
.pwa-install-prompt-modal__promo { flex-shrink: 0; margin-bottom: 4px; }

/* when there are no benefits the body collapses — let footer sit naturally */
.pwa-install-prompt-modal__body:not(:has(.pwa-install-prompt-modal__benefits)) {
    flex: 0 0 auto;
    overflow: visible;
}

/* footer: install button + dismiss — always pinned at the bottom */
.pwa-install-prompt-modal__footer {
    flex-shrink: 0;
    padding: 16px 28px 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pwa-install-prompt-modal__app-row {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--pwa-border);
    border-radius: 16px;
    padding: 14px 16px;
}
.pwa-install-prompt-modal__app-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    flex-shrink: 0;
    object-fit: cover;
    background: var(--pwa-accent-dim, rgba(233,30,140,0.12));
}
.pwa-install-prompt-modal__app-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--pwa-text-primary);
}
.pwa-install-prompt-modal__app-sub {
    font-size: 12px;
    color: var(--pwa-text-secondary);
    margin-top: 3px;
}
.pwa-install-prompt-modal__install-btn {
    width: 100%;
    padding: 14px;
    background: var(--pwa-accent);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .18s ease;
    flex-shrink: 0;
}
.pwa-install-prompt-modal__install-btn:active { background: var(--pwa-accent-hover); }
.pwa-install-prompt-modal__dismiss-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    color: var(--pwa-text-secondary);
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
}
.pwa-install-prompt-modal__dismiss-row input[type=checkbox] {
    width: 15px;
    height: 15px;
    cursor: pointer;
    accent-color: var(--pwa-accent);
}
.pwa-install-prompt-modal__promo {
    border-radius: 14px;
    overflow: hidden;
    line-height: 0;
}
.pwa-install-prompt-modal__promo-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}
.pwa-install-prompt-modal__benefits {
    list-style: none;
    margin: 0;
    padding: 4px 0 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}
.pwa-install-prompt-modal__benefit {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.45;
    color: var(--pwa-text-primary);
}
.pwa-install-prompt-modal__benefit-icon {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin-top: 1px;
    color: var(--pwa-accent);
}

/* ── Install Prompt Modal: Attractive Colors ─────────────── */
.pwa-install-prompt-modal--attractive {
    border: none;
    overflow: hidden;
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__header {
    background: linear-gradient(145deg, #0d0022 0%, #3a006f 40%, #7700cc 75%, #aa00ff 100%);
    border-bottom: none;
    border-radius: 22px 22px 0 0;
    padding-bottom: 28px;
}
.pwa-install-prompt-modal--attractive .pwa-modal__close {
    color: rgba(255,255,255,0.65);
}
.pwa-install-prompt-modal--attractive .pwa-modal__close:hover {
    color: #fff;
    background: rgba(255,255,255,0.12);
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__eyebrow {
    color: rgba(220, 160, 255, 0.85);
    letter-spacing: .1em;
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__title {
    color: #fff;
    text-shadow: 0 2px 12px rgba(170, 0, 255, 0.4);
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__sub {
    color: rgba(255,255,255,0.75);
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__benefit-icon {
    color: #cc66ff;
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__install-btn {
    background: linear-gradient(135deg, #5500bb 0%, #9900ee 50%, #cc00ff 100%);
    box-shadow: 0 6px 24px rgba(153, 0, 238, 0.55);
    letter-spacing: .02em;
}
.pwa-install-prompt-modal--attractive .pwa-install-prompt-modal__install-btn:active {
    background: linear-gradient(135deg, #3d0088, #7700bb);
    box-shadow: 0 3px 12px rgba(153, 0, 238, 0.4);
}

/* ============================================================
   Maintenance Screen
   ============================================================ */
.pwa-maintenance {
    position: fixed;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px;
    background: var(--pwa-bg-color);
    text-align: center;
    z-index: 1000;
}

.pwa-maintenance__icon {
    font-size: 56px;
    margin-bottom: 24px;
}

.pwa-maintenance__title {
    font-size: 24px;
    font-weight: 800;
    color: var(--pwa-text-primary);
    margin-bottom: 12px;
}

.pwa-maintenance__msg {
    font-size: 15px;
    color: var(--pwa-text-secondary);
    max-width: 300px;
    line-height: 1.6;
}

.pwa-maintenance__retry {
    margin-top: 28px;
}

/* ============================================================
   Page Transitions
   ============================================================ */
.pwa-page-enter {
    animation: pwa-page-in 0.2s ease;
}

@keyframes pwa-page-in {
    from { opacity: 0; transform: translateX(10px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* ============================================================
   Empty State
   ============================================================ */
.pwa-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 20px;
    text-align: center;
}

.pwa-empty__icon {
    font-size: 40px;
    margin-bottom: 16px;
    opacity: 0.5;
    display: flex;
    justify-content: center;
}
.pwa-empty__icon svg { width: 44px; height: 44px; }
.pwa-empty__icon--svg {
    font-size: 0;
    color: var(--pwa-text-secondary);
}
.pwa-empty__icon--svg svg {
    width: 52px;
    height: 52px;
    stroke: currentColor;
}

.pwa-empty__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
}

.pwa-empty__desc {
    font-size: 13px;
    color: var(--pwa-text-muted);
    margin-top: 6px;
}

/* ============================================================
   Section Label
   ============================================================ */
.pwa-section-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--pwa-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 20px 4px 8px;
}

/* ============================================================
   Utility
   ============================================================ */
.pwa-divider {
    height: 1px;
    background: var(--pwa-border);
    margin: 16px 0;
}

.pwa-info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 20px;
    border-bottom: 1px solid var(--pwa-border);
    font-size: 14px;
}

.pwa-info-row:last-child { border-bottom: none; }
.pwa-info-row__label { color: var(--pwa-text-secondary); }
.pwa-info-row__value { color: var(--pwa-text-primary); font-weight: 500; text-align: right; }
.pwa-info-row__value--app-info { display: inline-flex; align-items: center; gap: 8px; }
.pwa-info-row__action {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--pwa-border);
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    font-size: 12px;
    font-weight: 700;
}
.pwa-info-row__action:active,
.pwa-info-row__action:hover { color: var(--pwa-text-primary); border-color: rgba(255,255,255,0.18); }

.pwa-link-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 20px;
    border-radius: var(--pwa-radius-sm);
    font-size: 14px;
    font-weight: 600;
    color: var(--pwa-accent);
    background: var(--pwa-accent-dim);
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.15s;
}

.pwa-link-btn:hover { opacity: 0.85; color: var(--pwa-accent); }

/* ============================================================
   Pagination
   ============================================================ */
.pwa-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 16px;
}

.pwa-pagination__btn {
    padding: 8px 16px;
    background: var(--pwa-surface-2);
    border: 1px solid var(--pwa-border);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pwa-text-primary);
    cursor: pointer;
}

.pwa-pagination__btn:disabled { opacity: 0.4; cursor: not-allowed; }
.pwa-pagination__info { font-size: 13px; color: var(--pwa-text-secondary); }

/* ============================================================
   Header – Hamburger + Bell layout
   ============================================================ */
.pwa-header__title { text-align: center; }

.pwa-header__btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
    background: transparent;
    color: var(--pwa-text-secondary);
    transition: background 0.15s, color 0.15s;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

.pwa-header__btn:active { background: var(--pwa-surface-2); }

.pwa-header__btn svg { width: 22px; height: 22px; }

/* Bell badge */
.pwa-bell__badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    background: var(--pwa-accent);
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    pointer-events: none;
}

.pwa-bell__badge[hidden] { display: none !important; }

/* ============================================================
   Hamburger Drawer
   ============================================================ */
.pwa-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 500;
    opacity: 0;
    transition: opacity 0.25s ease;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.pwa-drawer-overlay.is-open { opacity: 1; }

.pwa-drawer {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(300px, 85vw);
    background: var(--pwa-surface-1);
    border-right: 1px solid var(--pwa-border);
    z-index: 501;
    transform: translateX(-100%);
    transition: transform 0.25s cubic-bezier(.4,0,.2,1);
    display: flex;
    flex-direction: column;
    padding-top: var(--pwa-safe-top);
    box-shadow: 4px 0 32px rgba(0,0,0,0.5);
}

.pwa-drawer.is-open { transform: translateX(0); }

.pwa-drawer__header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    padding: 20px 20px 16px;
    border-bottom: 1px solid var(--pwa-border);
    padding-right: 64px;
}

.pwa-drawer__brand {
    flex: 1 1 auto;
    display: flex;
    min-width: 0;
    width: 100%;
}

.pwa-drawer--logo-left .pwa-drawer__brand { justify-content: flex-start; }
.pwa-drawer--logo-center .pwa-drawer__brand { justify-content: center; }
.pwa-drawer--logo-right .pwa-drawer__brand { justify-content: flex-end; }

.pwa-drawer__logo {
    display: block;
    height: auto;
    width: var(--pwa-drawer-logo-width, 120px);
    max-width: 100%;
    max-height: 56px;
    object-fit: contain;
    border-radius: 4px;
}

.pwa-drawer__app-name {
    display: block;
    font-size: 17px;
    font-weight: 800;
    color: var(--pwa-accent);
    letter-spacing: -0.3px;
    width: var(--pwa-drawer-logo-width, 120px);
    max-width: 100%;
}

.pwa-drawer__close {
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--pwa-text-secondary);
    font-size: 18px;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s;
}

.pwa-drawer__close:active { background: var(--pwa-surface-2); }

.pwa-drawer__user {
    padding: 16px 20px;
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-drawer__user-greeting {
    font-size: 12px;
    color: var(--pwa-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.pwa-drawer__user-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--pwa-text-primary);
}

.pwa-drawer__nav { flex: 1; padding: 8px 0; overflow-y: auto; }

.pwa-drawer__item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    cursor: pointer;
    color: var(--pwa-text-secondary);
    font-size: 15px;
    font-weight: 500;
    transition: background 0.1s, color 0.1s;
    -webkit-tap-highlight-color: transparent;
    border-radius: 0;
}

.pwa-drawer__item:active { background: var(--pwa-surface-2); }

.pwa-drawer__item.is-active {
    color: var(--pwa-accent);
    background: var(--pwa-accent-dim);
}

.pwa-drawer__item-icon {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pwa-text-secondary);
}
.pwa-drawer__item-icon svg { width: 20px; height: 20px; display: block; }
.pwa-drawer__item-label { flex: 1; }

.pwa-drawer__footer {
    padding: 16px 20px;
    border-top: 1px solid var(--pwa-border);
}

.pwa-drawer__logout {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 15px;
    font-weight: 500;
    color: var(--pwa-text-secondary);
    cursor: pointer;
    padding: 10px 0;
    -webkit-tap-highlight-color: transparent;
    transition: color 0.15s;
}
.pwa-drawer__logout:active { color: var(--pwa-error); }

/* ============================================================
   Notification Dropdown
   ============================================================ */
.pwa-notif-dropdown {
    position: fixed;
    top: calc(var(--pwa-header-h) + var(--pwa-safe-top) + 8px);
    right: 12px;
    width: min(320px, calc(100vw - 24px));
    max-height: min(400px, 60vh);
    background: var(--pwa-surface-1);
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius);
    box-shadow: var(--pwa-shadow);
    z-index: 300;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    animation: pwa-slide-down 0.2s ease;
}

@keyframes pwa-slide-down {
    from { opacity: 0; transform: translateY(-8px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.pwa-notif-dropdown__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid var(--pwa-border);
    font-size: 13px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    position: sticky;
    top: 0;
    background: var(--pwa-surface-1);
    z-index: 1;
}

.pwa-notif-clear {
    font-size: 12px;
    color: var(--pwa-accent);
    cursor: pointer;
    text-transform: none;
    font-weight: 600;
    letter-spacing: 0;
}

.pwa-notif-empty {
    padding: 32px 20px;
    text-align: center;
    font-size: 14px;
    color: var(--pwa-text-muted);
}

.pwa-notif-item {
    padding: 14px 16px;
    border-bottom: 1px solid var(--pwa-border);
    transition: background 0.1s;
}

.pwa-notif-item:last-child { border-bottom: none; }
.pwa-notif-item:active { background: var(--pwa-surface-2); }

.pwa-notif-item--unread { border-left: 3px solid var(--pwa-accent); }

.pwa-notif-item__title {
    font-size: 14px;
    font-weight: 600;
    color: var(--pwa-text-primary);
    margin-bottom: 3px;
}

.pwa-notif-item__body {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    line-height: 1.4;
}

.pwa-notif-item__time {
    font-size: 12px;
    color: var(--pwa-text-muted);
    margin-top: 6px;
}

/* Login logo image */
.pwa-login__logo-img {
    height: 60px;
    max-width: 180px;
    object-fit: contain;
    margin: 0 auto 16px;
    display: block;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (min-width: 768px) {
    .pwa-view { padding: 0px; max-width: 600px; margin: 0 auto; }
    .pwa-nav  { max-width: 600px; left: 50%; transform: translateX(-50%); }
    .pwa-header { max-width: 600px; left: 50%; transform: translateX(-50%); }
    .pwa-notif-dropdown { right: calc(50% - 300px + 12px); }
}

@media (min-width: 768px) {
    body.pwa-admin-route .pwa-view,
    body.pwa-admin-route .pwa-nav,
    body.pwa-admin-route .pwa-header {
        max-width: none;
        left: 0;
        right: 0;
        margin: 0;
        transform: none;
    }
}

/* =========================================================
   Profile edit form
   ========================================================= */
/* =========================================================
   Profile avatar
   ========================================================= */
.pwa-avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 28px 20px 8px;
    gap: 8px;
}

.pwa-avatar-wrap {
    position: relative;
    width: 90px;
    height: 90px;
}

.pwa-avatar-img {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    border: 2px solid var(--pwa-border);
    background: var(--pwa-surface-2);
}

.pwa-avatar-img--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 700;
    color: var(--pwa-text-secondary);
    letter-spacing: 0.02em;
    border-radius: 50%;
}

.pwa-avatar-edit-btn {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--pwa-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    -webkit-tap-highlight-color: transparent;
    transition: opacity 0.15s;
}
.pwa-avatar-edit-btn svg { width: 14px; height: 14px; }
.pwa-avatar-edit-btn:active { opacity: 0.75; }
.pwa-avatar-edit-btn:disabled { opacity: 0.4; pointer-events: none; }

.pwa-avatar-hint {
    font-size: 12px;
    color: var(--pwa-text-muted);
    letter-spacing: 0.02em;
}

.pwa-form {
    padding: 16px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.pwa-form-row--two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
/* ── Password field with inline eye-toggle ───────────────────────────────── */
.pwa-input-wrap--pw {
    position: relative;
    display: flex;
    align-items: stretch;
}
.pwa-input-wrap--pw .pwa-input {
    padding-right: calc(44px + 16px); /* 44px eye-btn + 16px breathing room (= left padding) */
    flex: 1 1 auto;
    min-width: 0;
}
.pwa-pw-eye {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: none;
    border: none;
    color: var(--pwa-text-muted);
    cursor: pointer;
    transition: color 0.15s ease;
    border-radius: 0 var(--pwa-radius-sm, 8px) var(--pwa-radius-sm, 8px) 0;
}
.pwa-pw-eye:hover,
.pwa-pw-eye:focus-visible {
    color: var(--pwa-text-primary);
    outline: none;
}
.pwa-pw-eye svg {
    width: 18px;
    height: 18px;
    pointer-events: none;
}
/* Ensure only one eye icon is shown at a time — [hidden] can be overridden by global svg resets */
.pwa-pw-eye svg[hidden] {
    display: none !important;
}

/* ── Gift cards table ─────────────────────────────────────────────────────── */
.pwa-gc-card {
    padding: 0;
    overflow: hidden; /* clip border-radius around inner scroll */
}
.pwa-gc-loading {
    padding: 32px 0;
    display: flex;
    justify-content: center;
}
.pwa-gc-empty {
    padding: 32px 0 16px;
}
.pwa-gc-toolbar {
    position: relative;
    display: flex;
    justify-content: flex-end;
    padding: 12px 16px 8px;
}
.pwa-gc-col-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    background: var(--pwa-surface-2, rgba(255,255,255,0.07));
    border: 1px solid var(--pwa-border, rgba(255,255,255,0.1));
    border-radius: 8px;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.pwa-gc-col-btn:hover { background: var(--pwa-surface-3, rgba(255,255,255,0.12)); color: var(--pwa-text-primary); }
.pwa-gc-col-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.pwa-gc-col-panel {
    position: absolute;
    top: calc(100% - 2px);
    right: 0;
    z-index: 200;
    background: var(--pwa-surface-2, #232334);
    border: 1px solid var(--pwa-border, rgba(255,255,255,0.12));
    border-radius: 10px;
    padding: 8px 6px;
    min-width: 160px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}
.pwa-gc-col-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    color: var(--pwa-text-secondary);
    transition: background 0.12s, color 0.12s;
    user-select: none;
}
.pwa-gc-col-option:hover { background: rgba(255,255,255,0.06); color: var(--pwa-text-primary); }
.pwa-gc-col-option input[type="checkbox"] { accent-color: var(--pwa-accent); cursor: pointer; }
/* Scroll wrapper — horizontal scroll on small screens */
.pwa-gc-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-top: 1px solid var(--pwa-border, rgba(255,255,255,0.08));
}
.pwa-gc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    white-space: nowrap;
}
.pwa-gc-th {
    padding: 10px 16px;
    text-align: left;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pwa-text-muted);
    background: var(--pwa-surface-2, rgba(255,255,255,0.04));
    border-bottom: 1px solid var(--pwa-border, rgba(255,255,255,0.08));
}
.pwa-gc-th--chevron { width: 36px; padding: 10px 8px; }
.pwa-gc-row {
    cursor: pointer;
    transition: background 0.12s;
    border-bottom: 1px solid var(--pwa-border, rgba(255,255,255,0.06));
}
.pwa-gc-row:hover { background: rgba(255,255,255,0.04); }
.pwa-gc-row.is-expanded { background: rgba(255,255,255,0.04); }
.pwa-gc-td {
    padding: 13px 16px;
    color: var(--pwa-text-primary);
    vertical-align: middle;
}
.pwa-gc-td--chevron { padding: 13px 8px; text-align: center; }
.pwa-gc-chevron {
    width: 18px;
    height: 18px;
    color: var(--pwa-text-muted);
    transition: transform 0.2s ease;
    display: block;
    margin: 0 auto;
}
.pwa-gc-row.is-expanded .pwa-gc-chevron { transform: rotate(180deg); }
.pwa-gc-code {
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 13px;
    background: rgba(255,255,255,0.07);
    padding: 3px 8px;
    border-radius: 5px;
    letter-spacing: 0.04em;
}
/* Detail row (appointment history per card) */
.pwa-gc-detail-row {
    display: none;
}
.pwa-gc-detail-row.is-expanded {
    display: table-row;
}
.pwa-gc-detail-td {
    padding: 0 0 4px;
    background: var(--pwa-surface-1, rgba(0,0,0,0.18));
    border-bottom: 1px solid var(--pwa-border, rgba(255,255,255,0.08));
}
.pwa-gc-detail-wrap {
    padding: 8px 12px 12px;
}
.pwa-gc-detail-empty {
    padding: 14px 16px;
    color: var(--pwa-text-muted);
    font-size: 13px;
}
.pwa-gc-detail-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 6px;
    border: 1px solid var(--pwa-border, rgba(255,255,255,0.07));
}
.pwa-gc-detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    white-space: nowrap;
}
.pwa-gc-detail-table th {
    padding: 8px 12px;
    text-align: left;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pwa-text-muted);
    background: rgba(255,255,255,0.03);
    border-bottom: 1px solid var(--pwa-border, rgba(255,255,255,0.06));
}
.pwa-gc-detail-appt-row {
    cursor: pointer;
    transition: background 0.1s;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.pwa-gc-detail-appt-row:last-child { border-bottom: none; }
.pwa-gc-detail-appt-row:hover { background: rgba(255,255,255,0.05); }
.pwa-gc-detail-appt-row td {
    padding: 10px 12px;
    color: var(--pwa-text-primary);
    vertical-align: middle;
}
.pwa-gc-th--price, .pwa-gc-detail-td--price { text-align: right; }
.pwa-gc-th--details, .pwa-gc-detail-td--details { text-align: right; white-space: nowrap; width: 1%; }
.pwa-gc-anzeigen-btn {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: transparent;
    border: 1px solid var(--pwa-border, rgba(255,255,255,0.15));
    border-radius: 6px;
    color: var(--pwa-accent, #e91e8c);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.12s, border-color 0.12s;
    white-space: nowrap;
}
.pwa-gc-anzeigen-btn:hover {
    background: rgba(255,255,255,0.06);
    border-color: var(--pwa-accent, #e91e8c);
}

/* ── Gift cards empty state ───────────────────────────────────────────────── */
.pwa-gc-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 24px 32px;
    gap: 12px;
}
.pwa-gc-empty-icon {
    color: var(--pwa-text-muted, rgba(255,255,255,0.25));
    opacity: 0.55;
}
.pwa-gc-empty-icon svg {
    width: 56px;
    height: 56px;
    display: block;
}
.pwa-gc-empty-msg {
    font-size: 14px;
    color: var(--pwa-text-muted, rgba(255,255,255,0.45));
    text-align: center;
    line-height: 1.55;
}
/* HTML content inside msg (links, bold, emoji) inherits but stays safe */
.pwa-gc-empty-msg a { color: var(--pwa-accent); text-decoration: underline; }
.pwa-gc-empty-msg strong, .pwa-gc-empty-msg b { color: var(--pwa-text-primary); }
/* When the promo block is the last child the card's own 15px padding-bottom is
   enough — suppress the empty-state's extra 32px to avoid a doubled gap. */
.pwa-gc-empty-state:has(.pwa-gc-promo) {
    padding-bottom: 0;
}

/* ── Gift cards promo block ───────────────────────────────────────────────── */

/* Wrapper used when the promo is rendered below the table ("always" mode).
   Provides separation from the table and consistent inner spacing. */
.pwa-gc-promo-inline-wrap {
    padding: 20px 16px 20px;
    border-top: 1px solid var(--pwa-border, rgba(255,255,255,0.08));
}
.pwa-gc-promo-inline-wrap .pwa-gc-promo {
    margin-top: 0;
}

.pwa-gc-promo {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-top: 8px;
}

/* Single image */
.pwa-gc-promo-img-wrap {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    line-height: 0;
    aspect-ratio: 16 / 9;
    background: rgba(0,0,0,0.04);
}
.pwa-gc-promo-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover; /* default — overridden by inline style from imageFit setting */
}

/* Slideshow */
.pwa-gc-slideshow {
    position: relative;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    line-height: 0;
    /* Reserve height proportionally until images load */
    aspect-ratio: 16 / 9;
    background: rgba(255,255,255,0.04);
}
.pwa-gc-slides {
    position: relative;
    width: 100%;
    height: 100%;
}
.pwa-gc-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}
.pwa-gc-slide.is-active {
    opacity: 1;
    pointer-events: auto;
}
.pwa-gc-slide img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover; /* default — overridden by inline style from imageFit setting */
}

/* Arrow buttons */
.pwa-gc-slide-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,0.45);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
    padding: 0;
}
.pwa-gc-slide-btn:hover { background: rgba(0,0,0,0.7); }
.pwa-gc-slide-btn--prev { left: 10px; }
.pwa-gc-slide-btn--next { right: 10px; }
.pwa-gc-slide-btn svg { width: 18px; height: 18px; flex-shrink: 0; }

/* Dot indicators */
.pwa-gc-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 6px;
}
.pwa-gc-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: none;
    padding: 0;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}
.pwa-gc-dot.is-active {
    background: #fff;
    transform: scale(1.25);
}

/* Promo CTA button */
.pwa-gc-promo-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 28px;
    border-radius: 10px;
    background: var(--pwa-accent, #e91e8c);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    letter-spacing: 0.01em;
    transition: opacity 0.15s, transform 0.12s;
    width: 100%;
    max-width: 320px;
    text-align: center;
}
.pwa-gc-promo-btn:hover { opacity: 0.88; }
.pwa-gc-promo-btn:active { transform: scale(0.97); }

.pwa-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%239ca3af' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
    cursor: pointer;
}
.pwa-phone-wrap {
    width: 100%;
}
.pwa-phone-wrap .iti {
    --iti-border-color: rgba(255,255,255,0.12);
    --iti-dropdown-bg: var(--pwa-bg-color);
    --iti-hover-color: rgba(255,255,255,0.08);
    --iti-dialcode-color: var(--pwa-text-secondary);
    --iti-arrow-color: var(--pwa-text-secondary);
    width: 100%;
    display: block;
}
.iti--fullscreen-popup.iti--container {
    --iti-border-color: rgba(255,255,255,0.12);
    --iti-dropdown-bg: var(--pwa-bg-color);
    --iti-hover-color: rgba(255,255,255,0.08);
    --iti-dialcode-color: var(--pwa-text-secondary);
    --iti-arrow-color: var(--pwa-text-secondary);
    background: rgba(0,0,0,0.58);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
.pwa-phone-wrap .iti__tel-input,
.pwa-phone-wrap .iti input.iti__tel-input,
.pwa-phone-wrap .iti input.iti__tel-input[type="tel"] {
    width: 100%;
    min-height: 44px;
    padding: 0 14px 0 98px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.06);
    color: var(--pwa-text-primary);
    box-sizing: border-box;
}
.pwa-phone-wrap .iti__country-container {
    left: 0;
}
.pwa-phone-wrap .iti__selected-country {
    height: 44px;
    padding: 0 10px 0 12px;
    border-radius: 10px 0 0 10px;
    background: rgba(255,255,255,0.04);
    border-right: 1px solid rgba(255,255,255,0.10);
}
.pwa-phone-wrap .iti__selected-country-primary {
    gap: 6px;
}
.pwa-phone-wrap .iti__selected-dial-code,
.pwa-phone-wrap .iti__arrow,
.pwa-phone-wrap .iti__country-name,
.pwa-phone-wrap .iti__dial-code {
    color: var(--pwa-text-primary);
}
.pwa-phone-wrap .iti__dropdown-content,
.iti--fullscreen-popup .iti__dropdown-content {
    background: var(--pwa-bg-color);
    border: 1px solid rgba(255,255,255,0.12) !important;
    border-radius: 12px;
    box-shadow: 0 18px 42px rgba(0,0,0,0.42);
    color: var(--pwa-text-primary);
    overflow: hidden;
}
.iti--fullscreen-popup .iti__dropdown-content {
    width: min(100%, 420px);
    margin: 0 auto;
}
.pwa-phone-wrap .iti__search-input,
.iti--fullscreen-popup .iti__search-input {
    width: calc(100% - 16px) !important;
    margin: 8px;
    min-height: 42px;
    padding: 11px 14px;
    background: var(--pwa-surface-1);
    color: var(--pwa-text-primary) !important;
    border: 1px solid rgba(255,255,255,0.14) !important;
    border-radius: 10px !important;
    box-sizing: border-box;
    outline: none;
    box-shadow: none !important;
    appearance: none;
    -webkit-appearance: none;
    font-size: 14px;
    line-height: 1.2;
}
.pwa-phone-wrap .iti__search-input::placeholder,
.iti--fullscreen-popup .iti__search-input::placeholder {
    color: var(--pwa-text-secondary);
    opacity: 1;
}
.pwa-phone-wrap .iti__search-input:focus,
.pwa-phone-wrap .iti__search-input:focus-visible,
.iti--fullscreen-popup .iti__search-input:focus,
.iti--fullscreen-popup .iti__search-input:focus-visible {
    border-color: var(--pwa-accent) !important;
    background: var(--pwa-surface-2);
    box-shadow: 0 0 0 3px rgba(var(--pwa-accent-rgb), 0.16) !important;
}
.pwa-phone-wrap .iti__search-input + .iti__country-list,
.iti--fullscreen-popup .iti__search-input + .iti__country-list {
    border-top: 1px solid rgba(255,255,255,0.10);
}

.pwa-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(0, 0, 0, 0.72);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 16px 16px calc(16px + env(safe-area-inset-bottom, 0px));
}
.pwa-modal-overlay--centered {
    align-items: center;
    padding: 16px;
}
.pwa-modal {
    width: min(100%, 760px);
    max-height: min(88vh, 820px);
    background: var(--pwa-surface-1);
    border: 1px solid var(--pwa-border);
    border-radius: 22px;
    box-shadow: 0 24px 56px rgba(0,0,0,0.55);
    overflow: hidden;
    position: relative;
}
/* Privacy modal overrides: needs explicit height (not just max-height)
   so flex children can calculate remaining space correctly. */
.pwa-modal.pwa-floating-privacy-modal {
    max-height: none;
}
.pwa-modal.pwa-appt-detail-modal {
    overflow-y: auto;
    overflow-x: hidden;
}
/* No-show info modal: flex-column so header stays fixed, only body scrolls */
.pwa-modal.pwa-no-show-modal {
    width: min(100%, 560px);
    max-height: min(88vh, 820px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.pwa-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    color: var(--pwa-text-primary);
    font-size: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.pwa-app-info-modal__header {
    padding: 22px 24px 12px;
    border-bottom: 1px solid var(--pwa-border);
}
.pwa-app-info-modal__eyebrow {
    font-size: 12px;
    color: var(--pwa-text-secondary);
    margin-bottom: 6px;
}
.pwa-app-info-modal__title {
    font-size: 20px;
    line-height: 1.2;
    margin: 0;
}
.pwa-app-info-modal__build {
    margin-top: 6px;
    font-size: 12px;
    color: var(--pwa-text-secondary);
}
.pwa-app-info-modal__tabs {
    display: flex;
    gap: 8px;
    padding: 16px 24px 0;
}
.pwa-app-info-modal__tab {
    padding: 10px 14px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
}
.pwa-app-info-modal__tab.is-active {
    background: var(--pwa-accent-dim);
    color: var(--pwa-accent);
}
.pwa-app-info-modal__panel {
    display: none;
    padding: 18px 24px 24px;
    overflow-y: auto;
    max-height: calc(88vh - 150px);
}
.pwa-app-info-modal__panel.is-active { display: block; }
.pwa-app-info-modal__image {
    display: block;
    width: 100%;
    border-radius: 18px;
    object-fit: cover;
    border: 1px solid var(--pwa-border);
    background: var(--pwa-surface-2);
}
.pwa-app-info-modal__empty {
    padding: 24px;
    border-radius: 16px;
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    text-align: center;
}
.pwa-app-info-entry {
    padding: 0 0 18px;
    margin-bottom: 18px;
    border-bottom: 1px solid var(--pwa-border);
}
.pwa-app-info-entry:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: 0;
}
.pwa-app-info-entry__meta {
    font-size: 12px;
    color: var(--pwa-text-secondary);
    margin-bottom: 6px;
}
.pwa-app-info-entry__title {
    font-size: 16px;
    margin: 0 0 8px;
}
.pwa-app-info-entry__body {
    font-size: 14px;
    color: var(--pwa-text-primary);
    line-height: 1.6;
}
.pwa-phone-wrap .iti__country-list,
.iti--fullscreen-popup .iti__country-list {
    background: var(--pwa-bg-color);
    padding: 6px 0 8px;
}
.pwa-phone-wrap .iti__country,
.iti--fullscreen-popup .iti__country {
    color: var(--pwa-text-primary);
    padding: 10px 12px !important;
    gap: 10px;
}
.pwa-phone-wrap .iti__country-name,
.iti--fullscreen-popup .iti__country-name {
    color: var(--pwa-text-primary) !important;
    font-weight: 500;
}
.pwa-phone-wrap .iti__dial-code,
.iti--fullscreen-popup .iti__dial-code {
    color: var(--pwa-text-secondary) !important;
    margin-left: auto;
}
.pwa-phone-wrap .iti__country.iti__highlight,
.pwa-phone-wrap .iti__country:hover,
.iti--fullscreen-popup .iti__country.iti__highlight,
.iti--fullscreen-popup .iti__country:hover {
    background: rgba(255,255,255,0.08);
}
.pwa-input--phone {
    flex: 1;
    min-width: 0;
}
.pwa-input[type="date"] {
    color-scheme: dark;
}
.pwa-form-msg {
    font-size: 13px;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid transparent;
}
.pwa-form-msg--error {
    background: rgba(244,63,94,0.12);
    border-color: rgba(244,63,94,0.3);
    color: #fda4af;
}
.pwa-form-msg--success {
    background: rgba(34,197,94,0.12);
    border-color: rgba(34,197,94,0.3);
    color: #86efac;
}
.pwa-form-msg--warning {
    background: rgba(245,158,11,0.12);
    border-color: rgba(245,158,11,0.35);
    color: #fcd34d;
}

/* =========================================================
   Email settings
   ========================================================= */
.pwa-ep-notice {
    padding: 12px 20px 8px;
    font-size: 13px;
    color: var(--pwa-text-secondary, #9ca3af);
    line-height: 1.5;
}

/* =========================================================
   Packages page
   ========================================================= */
.pwa-pkg__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}
.pwa-pkg__name {
    font-weight: 600;
    font-size: 15px;
    line-height: 1.3;
}
/* status badge */
.pwa-pkg__badge {
    display: inline-block;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 3px 8px;
    border-radius: 20px;
    white-space: nowrap;
}
.pwa-pkg__badge--active  { color: #86efac; background: rgba(34,197,94,0.15); }
.pwa-pkg__badge--unpaid  { color: #fcd34d; background: rgba(245,158,11,0.15); }
.pwa-pkg__badge--expired { color: #fca5a5; background: rgba(244,63,94,0.15); }

/* meta row: price, ID, date */
.pwa-pkg__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin-bottom: 12px;
}
.pwa-pkg__meta-item {
    font-size: 13px;
    color: var(--pwa-text-secondary);
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.pwa-pkg__meta-item--full { flex-basis: 100%; }
.pwa-pkg__meta-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--pwa-text-muted);
}

.pwa-pkg__slots {
    font-size: 12px;
    color: var(--pwa-text-secondary);
    margin-bottom: 6px;
}
.pwa-pkg__progress-bar {
    height: 6px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    overflow: hidden;
}
.pwa-pkg__progress-fill {
    height: 100%;
    background: var(--pwa-theme-color, #e91e8c);
    border-radius: 3px;
    transition: width 0.4s ease;
}

@media (max-width: 640px) {
    .pwa-grid--admin-quick {
        grid-template-columns: 1fr;
    }

    .pwa-card--button {
        padding: 14px 16px;
    }

    .pwa-section__title {
        font-size: 24px;
    }
}

/* ── Push Opt-in Prompt Modal ────────────────────────────── */
.pwa-push-prompt-overlay {
    z-index: 1400; /* above install modal / app-info modals */
}
.pwa-push-prompt-modal {
    width: min(calc(100vw - 32px), 440px);
    max-height: min(90vh, 720px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.pwa-push-prompt-modal__header {
    padding: 30px 28px 20px;
    border-bottom: 1px solid var(--pwa-border);
    flex-shrink: 0;
    text-align: center;
}
.pwa-push-prompt-modal__icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 16px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--pwa-accent-rgb, 233, 30, 140), 0.14);
    color: var(--pwa-accent);
}
.pwa-push-prompt-modal__icon svg {
    width: 28px;
    height: 28px;
}
.pwa-push-prompt-modal--blocked .pwa-push-prompt-modal__icon {
    background: rgba(255, 176, 32, 0.14);
    color: #ffb020;
}
.pwa-push-prompt-modal__title {
    margin: 0;
    font-size: 21px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--pwa-text-primary);
}
.pwa-push-prompt-modal__sub {
    margin: 10px 0 0;
    font-size: 14px;
    line-height: 1.55;
    color: var(--pwa-text-secondary);
}
.pwa-push-prompt-modal__body {
    padding: 18px 28px 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    flex: 1 1 auto;
    min-height: 0;
}
.pwa-push-prompt-modal__benefits {
    list-style: none;
    margin: 0;
    padding: 0 0 4px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
}
.pwa-push-prompt-modal__benefit {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.45;
    color: var(--pwa-text-primary);
}
.pwa-push-prompt-modal__benefit-icon {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin-top: 1px;
    color: var(--pwa-accent);
}
.pwa-push-prompt-modal__footer {
    flex-shrink: 0;
    padding: 20px 28px calc(24px + env(safe-area-inset-bottom, 0px));
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.pwa-push-prompt-modal__accept-btn {
    width: 100%;
    padding: 14px;
    background: var(--pwa-accent);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .18s ease, opacity .18s ease;
    flex-shrink: 0;
}
.pwa-push-prompt-modal__accept-btn:active { background: var(--pwa-accent-hover); }
.pwa-push-prompt-modal__accept-btn[disabled] {
    opacity: .6;
    cursor: default;
}
.pwa-push-prompt-modal__decline-btn {
    width: 100%;
    padding: 12px;
    background: transparent;
    color: var(--pwa-text-secondary);
    border: 1px solid var(--pwa-border);
    border-radius: 14px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    flex-shrink: 0;
}
.pwa-push-prompt-modal__decline-btn:active { background: rgba(255, 255, 255, 0.05); }
.pwa-push-prompt-modal__dismiss-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    color: var(--pwa-text-secondary);
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
    padding-top: 2px;
}
.pwa-push-prompt-modal__dismiss-row input[type=checkbox] {
    width: 15px;
    height: 15px;
    cursor: pointer;
    accent-color: var(--pwa-accent);
}

/* ============================================================
   Loyalty: Punktekonto + Historie
   ============================================================ */

.pwa-loyalty-points__rows {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 4px;
}

.pwa-loyalty-points__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.pwa-loyalty-points__row-label {
    color: var(--pwa-text-secondary);
    font-size: 14px;
}

.pwa-loyalty-points__row-value {
    color: var(--pwa-text-primary);
    font-size: 15px;
    font-variant-numeric: tabular-nums;
}

.pwa-loyalty-points__row:first-child .pwa-loyalty-points__row-value {
    color: var(--pwa-gold);
    font-size: 20px;
    font-weight: 700;
}

.pwa-loyalty-points__hint {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.45;
}

.pwa-loyalty-points__hint--warn {
    background: rgba(245, 158, 11, 0.12);
    color: var(--pwa-warning);
}

.pwa-loyalty-points__history {
    margin-top: 16px;
    width: 100%;
}

/* --- Historien-Dialog --- */

.pwa-loyalty-history-modal {
    width: min(720px, 100%);
    max-height: min(86vh, 900px);
    display: flex;
    flex-direction: column;
}

.pwa-loyalty-history {
    display: flex;
    flex-direction: column;
    min-height: 0;
    gap: 16px;
}

.pwa-loyalty-history__eyebrow {
    color: var(--pwa-accent);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-loyalty-history__title {
    margin: 4px 0 0;
    font-size: 22px;
    font-weight: 700;
}

.pwa-loyalty-history__balances {
    display: flex;
    gap: 10px;
}

.pwa-loyalty-history__balance {
    flex: 1 1 0;
    padding: 12px 14px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
}

.pwa-loyalty-history__balance-label {
    display: block;
    margin-bottom: 2px;
    color: var(--pwa-text-secondary);
    font-size: 12px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.pwa-loyalty-history__balance strong {
    font-size: 20px;
    font-variant-numeric: tabular-nums;
}

.pwa-loyalty-history__filter {
    display: flex;
    gap: 6px;
    padding: 4px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
}

.pwa-loyalty-history__filter-btn {
    flex: 1 1 0;
    padding: 8px 10px;
    border: 0;
    border-radius: calc(var(--pwa-radius-sm) - 2px);
    background: transparent;
    color: var(--pwa-text-secondary);
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

.pwa-loyalty-history__filter-btn.is-active {
    background: var(--pwa-surface-3);
    color: var(--pwa-text-primary);
    font-weight: 600;
}

.pwa-loyalty-history__body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.pwa-loyalty-history__table-wrap {
    overflow-x: auto;
}

.pwa-loyalty-history__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.pwa-loyalty-history__table th {
    position: sticky;
    top: 0;
    z-index: 1;
    padding: 8px 10px;
    border-bottom: 1px solid var(--pwa-border);
    background: var(--pwa-surface-1);
    color: var(--pwa-text-secondary);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-align: left;
    text-transform: uppercase;
}

.pwa-loyalty-history__th--amount,
.pwa-loyalty-history__th--balance {
    text-align: right;
}

.pwa-loyalty-history__cell {
    padding: 12px 10px;
    border-bottom: 1px solid var(--pwa-border);
    vertical-align: top;
}

.pwa-loyalty-history__cell--date {
    color: var(--pwa-text-secondary);
    font-size: 13px;
    white-space: nowrap;
}

.pwa-loyalty-history__label {
    display: block;
    color: var(--pwa-text-primary);
    font-weight: 600;
}

.pwa-loyalty-history__detail {
    display: block;
    margin-top: 2px;
    color: var(--pwa-text-secondary);
    font-size: 12px;
}

.pwa-loyalty-history__cell--amount,
.pwa-loyalty-history__cell--balance {
    font-variant-numeric: tabular-nums;
    text-align: right;
    white-space: nowrap;
}

.pwa-loyalty-history__amount {
    display: block;
    font-size: 15px;
    font-weight: 700;
}

.pwa-loyalty-history__row.is-credit .pwa-loyalty-history__amount { color: var(--pwa-success); }
.pwa-loyalty-history__row.is-debit  .pwa-loyalty-history__amount { color: var(--pwa-error); }

.pwa-loyalty-history__row.is-reversed .pwa-loyalty-history__label {
    text-decoration: line-through;
    color: var(--pwa-text-muted);
}

.pwa-loyalty-history__currency {
    display: block;
    color: var(--pwa-text-muted);
    font-size: 11px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.pwa-loyalty-history__cell--balance {
    color: var(--pwa-text-secondary);
}

.pwa-loyalty-history__more {
    width: 100%;
    margin-top: 14px;
}

.pwa-loyalty-history__loading,
.pwa-loyalty-history__empty {
    padding: 32px 16px;
    color: var(--pwa-text-secondary);
    text-align: center;
}

.pwa-loyalty-history__empty-icon { font-size: 30px; }

.pwa-loyalty-history__empty-title {
    margin-top: 8px;
    color: var(--pwa-text-primary);
    font-weight: 600;
}

.pwa-loyalty-history__empty-text {
    margin-top: 4px;
    font-size: 13px;
    line-height: 1.5;
}

/* Auf schmalen Geräten weicht die Saldo-Spalte, damit Vorgang und Betrag
   ohne horizontales Scrollen lesbar bleiben. */
@media (max-width: 520px) {
    .pwa-loyalty-history__th--balance,
    .pwa-loyalty-history__cell--balance { display: none; }

    .pwa-loyalty-history__cell { padding: 10px 6px; }
    .pwa-loyalty-history__cell--date { font-size: 12px; white-space: normal; }
}

.pwa-benefits-card .pwa-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.pwa-benefit-plan {
    padding: 3px 10px;
    border: 1px solid var(--pwa-benefit-plan-color, var(--pwa-accent));
    border-radius: 999px;
    color: var(--pwa-benefit-plan-color, var(--pwa-accent));
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

/* Vorgemerkte Punkte */

.pwa-loyalty-points__row--pending .pwa-loyalty-points__row-value { color: var(--pwa-blue); }

.pwa-loyalty-points__row--projected {
    padding-top: 10px;
    border-top: 1px dashed var(--pwa-border);
}

.pwa-loyalty-points__row--projected .pwa-loyalty-points__row-value { font-weight: 600; }

.pwa-loyalty-points__hint--pending {
    background: rgba(59, 130, 246, .12);
    color: var(--pwa-blue);
}

.pwa-loyalty-points__pending-list {
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
}

.pwa-loyalty-points__pending-list li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    padding: 7px 2px;
    border-bottom: 1px solid var(--pwa-border);
    font-size: 13px;
}

.pwa-loyalty-points__pending-list li:last-child { border-bottom: 0; }
.pwa-loyalty-points__pending-list span { color: var(--pwa-text-secondary); }
.pwa-loyalty-points__pending-list strong { color: var(--pwa-blue); white-space: nowrap; }

/* Claim der Stufe unter dem Ring */

.pwa-gauge__tagline {
    margin-top: 10px;
    padding: 0 8px;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
}

/* Diagnose (nur im Debug-Modus sichtbar) */

.pwa-loyalty-debug {
    border: 1px dashed var(--pwa-warning);
}

.pwa-loyalty-debug p,
.pwa-loyalty-debug li {
    margin: 4px 0;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.pwa-loyalty-debug ul { margin: 6px 0 0; padding-left: 18px; }

/* ============================================================
   Stufenübersicht
   ============================================================ */

.pwa-gauge__plans-link {
    display: block;
    width: 100%;
    margin-top: 14px;
    padding: 10px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    background: transparent;
    color: var(--pwa-text-secondary);
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

.pwa-gauge__plans-link:hover {
    border-color: var(--pwa-accent);
    color: var(--pwa-text-primary);
}

.pwa-plans-modal {
    width: min(760px, 100%);
    max-height: min(88vh, 940px);
    display: flex;
    flex-direction: column;
}

.pwa-plans {
    display: flex;
    flex-direction: column;
    min-height: 0;
    gap: 16px;
}

.pwa-plans__eyebrow {
    color: var(--pwa-accent);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.pwa-plans__title {
    margin: 4px 0 0;
    font-size: 22px;
    font-weight: 700;
}

.pwa-plans__body {
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.pwa-plans__loading,
.pwa-plans__empty {
    padding: 32px 16px;
    color: var(--pwa-text-secondary);
    text-align: center;
}

/* --- Einzelne Stufe --- */

.pwa-plan-card {
    padding: 16px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius);
    background: var(--pwa-surface-2);
}

.pwa-plan-card.is-current {
    border-color: var(--pwa-gold);
    box-shadow: 0 0 0 1px var(--pwa-gold) inset;
}

.pwa-plan-card.is-qualified { border-color: var(--pwa-success); }

.pwa-plan-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.pwa-plan-card__badge {
    padding: 5px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.pwa-plan-card__pill {
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--pwa-surface-3);
    color: var(--pwa-text-secondary);
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.pwa-plan-card__pill.is-current { background: rgba(245, 200, 66, .18); color: var(--pwa-gold); }
.pwa-plan-card__pill.is-ready   { background: rgba(34, 197, 94, .18); color: var(--pwa-success); }

.pwa-plan-card__name {
    font-size: 17px;
    font-weight: 700;
}

.pwa-plan-card__tagline {
    margin: 4px 0 0;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.pwa-plan-card__section { margin-top: 14px; }

.pwa-plan-card__section-label {
    margin-bottom: 6px;
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.pwa-plan-card__conditions,
.pwa-plan-card__benefits {
    margin: 0;
    padding: 0;
    list-style: none;
}

.pwa-plan-card__conditions li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding: 6px 0;
    border-bottom: 1px solid var(--pwa-border);
    font-size: 13px;
}

.pwa-plan-card__conditions li:last-child { border-bottom: 0; }
.pwa-plan-card__conditions span { color: var(--pwa-text-secondary); }
.pwa-plan-card__conditions strong { font-variant-numeric: tabular-nums; white-space: nowrap; }
.pwa-plan-card__conditions li.is-met strong  { color: var(--pwa-success); }
.pwa-plan-card__conditions li.is-open strong { color: var(--pwa-text-secondary); }

.pwa-plan-card__benefits li {
    position: relative;
    padding: 4px 0 4px 20px;
    color: var(--pwa-text-primary);
    font-size: 13px;
    line-height: 1.5;
}

.pwa-plan-card__benefits li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--pwa-success);
    font-weight: 700;
}

/* Kostenpflichtiger Aufstieg */

.pwa-plan-card__price {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-3);
}

.pwa-plan-card__price-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.pwa-plan-card__price-row span { color: var(--pwa-text-secondary); font-size: 13px; }
.pwa-plan-card__price-row strong { color: var(--pwa-gold); font-size: 19px; }

.pwa-plan-card__price-note {
    margin-top: 4px;
    color: var(--pwa-text-secondary);
    font-size: 12px;
}

.pwa-plan-card__price-hint {
    margin-top: 8px;
    color: var(--pwa-text-muted);
    font-size: 12px;
    line-height: 1.5;
}

/* Aufstiegsanfrage */

.pwa-plan-card__request-btn { width: 100%; margin-top: 10px; }

.pwa-plan-card__request {
    margin-top: 10px;
    padding: 9px 12px;
    border-radius: var(--pwa-radius-sm);
    background: rgba(59, 130, 246, .14);
    color: var(--pwa-blue);
    font-size: 12px;
    line-height: 1.5;
}

/* ============================================================
   Abstände: Punktekonto, Historie, Mitgliedschaft
   ============================================================ */

/* Karten ohne __body tragen ihr Innenmaß selbst (.pwa-card padding).
   Der Kopf darf dann seitlich nichts draufrechnen, sonst steht die
   Überschrift eingerückter als die Zeilen darunter. */
.pwa-card:not(:has(.pwa-card__body)) > .pwa-card__header {
    padding-left: 0;
    padding-right: 0;
    padding-top: 0;
}

/* Dialoge bekommen dasselbe Innenmaß wie die Termin-Detailansicht. */
.pwa-loyalty-history,
.pwa-plans {
    padding: 22px 20px 20px;
}

/* Der Kopfbereich lässt rechts Platz für den Schließen-Knopf. */
.pwa-loyalty-history__head,
.pwa-plans__head {
    padding-right: 44px;
}

/* ============================================================
   Vorteile-Seite
   ============================================================ */

.pwa-benefit-hero {
    position: relative;
    padding: 20px;
    overflow: hidden;
}

/* Farbiger Schimmer der Stufe, dezent im Hintergrund. */
.pwa-benefit-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    /* Über opacity statt color-mix: läuft auch auf älteren iOS-Versionen. */
    background: radial-gradient(circle at top right, var(--pwa-hero-color, #e91e8c), transparent 62%);
    opacity: .22;
    pointer-events: none;
}

.pwa-benefit-hero > * { position: relative; }

.pwa-benefit-hero__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.pwa-benefit-hero__badge {
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.pwa-benefit-hero__pill {
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(245, 200, 66, .18);
    color: var(--pwa-gold);
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.pwa-benefit-hero__name {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
}

.pwa-benefit-hero__tagline {
    margin: 6px 0 0;
    color: var(--pwa-text-secondary);
    font-size: 14px;
    line-height: 1.55;
}

.pwa-benefit-hero__list {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--pwa-border);
}

/* Stufenliste auf der Seite: kein eigener Scrollbereich, die Seite scrollt. */
.pwa-plans__body--inline {
    overflow: visible;
    margin-bottom: 16px;
}

/* ============================================================
   Fortschritt zur nächsten Stufe
   ============================================================ */

.pwa-progress-card {
    display: block;
    width: 100%;
    /* Ohne Klick-Funktion soll die Karte auch nicht danach aussehen. */
    padding: 18px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius);
    background: var(--pwa-surface-1);
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: border-color .2s ease, transform .2s ease;
}

.pwa-progress-card:not(.is-clickable) { cursor: default; }
.pwa-progress-card.is-clickable:hover { border-color: var(--pwa-progress-color, var(--pwa-accent)); }
.pwa-progress-card.is-clickable:active { transform: scale(.995); }

/* Farbschimmer der Zielstufe im Hintergrund. */
.pwa-progress-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, var(--pwa-progress-color, var(--pwa-accent)), transparent 65%);
    opacity: .12;
    pointer-events: none;
}

.pwa-progress-card > * { position: relative; }

.pwa-progress-card__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.pwa-progress-card__eyebrow {
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.pwa-progress-card__percent {
    color: var(--pwa-progress-color, var(--pwa-accent));
    font-size: 26px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.pwa-progress-card__name {
    margin: 6px 0 14px;
    font-size: 17px;
    font-weight: 700;
}

.pwa-progress-card__track {
    height: 10px;
    border-radius: 999px;
    background: var(--pwa-surface-3);
    overflow: hidden;
}

.pwa-progress-card__fill {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg,
        color-mix(in srgb, var(--pwa-progress-color, #e91e8c) 55%, #ffffff),
        var(--pwa-progress-color, #e91e8c));
    transition: width .9s cubic-bezier(.22, .61, .36, 1);
}

/* Ältere Browser ohne color-mix bekommen den vollen Farbton. */
@supports not (background: color-mix(in srgb, red 50%, blue)) {
    .pwa-progress-card__fill { background: var(--pwa-progress-color, #e91e8c); }
}

.pwa-progress-card__detail {
    margin-top: 12px;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    line-height: 1.5;
}

.pwa-progress-card__detail strong { color: var(--pwa-text-primary); }

/* Wer Bewegung reduziert haben möchte, sieht den Balken sofort gefüllt. */
@media (prefers-reduced-motion: reduce) {
    .pwa-progress-card__fill { transition: none; }
    .pwa-progress-card.is-clickable:active { transform: none; }
}

/* Offene Bedingungen in der Fortschrittskarte */

.pwa-progress-card__open {
    margin: 12px 0 0;
    padding: 10px 12px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    list-style: none;
}

.pwa-progress-card__open li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 0;
    font-size: 12px;
}

.pwa-progress-card__open li + li { border-top: 1px solid var(--pwa-border); }
.pwa-progress-card__open span { color: var(--pwa-text-secondary); }

.pwa-progress-card__open strong {
    color: var(--pwa-warning);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* ============================================================
   Programmstart: Hinweiskarte + Terminübersicht
   Ansicht für Kunden, für die das Punkteprogramm noch nicht
   läuft. Ersetzt Ring, Stufen und Fortschritt.
   ============================================================ */
/* Ab 768px setzt die Responsive-Regel .pwa-view auf padding:0 – der Block
   klebte dort am Header. Darunter pflegt der Container den Abstand selbst. */
@media (min-width: 768px) {
    .pwa-locked {
        padding-top: 16px;
    }
}

.pwa-teaser {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(var(--pwa-accent-rgb), 0.28);
    background:
        linear-gradient(150deg, rgba(var(--pwa-accent-rgb), 0.16), transparent 62%),
        var(--pwa-surface-1);
}

/* Farbschleier oben rechts, damit die Karte nicht flach wirkt. */
.pwa-teaser__glow {
    position: absolute;
    top: -70px;
    right: -60px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--pwa-accent-rgb), 0.38), transparent 68%);
    pointer-events: none;
}

.pwa-teaser__body {
    position: relative;
    padding: 20px;
}

.pwa-teaser__eyebrow {
    display: inline-block;
    margin-bottom: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(var(--pwa-accent-rgb), 0.18);
    color: var(--pwa-accent);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-teaser__title {
    margin: 0 0 8px;
    color: var(--pwa-text-primary);
    font-size: 20px;
    font-weight: 700;
    line-height: 1.25;
}

.pwa-teaser__text {
    margin: 0;
    color: var(--pwa-text-secondary);
    font-size: 14px;
    line-height: 1.6;
}

/* --- Terminübersicht ------------------------------------- */
.pwa-activity__teaser-line {
    margin-top: 4px;
    color: var(--pwa-text-secondary);
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

.pwa-activity__hero {
    padding: 4px 0 18px;
    text-align: center;
}

.pwa-activity__hero-value {
    color: var(--pwa-gold);
    font-size: 34px;
    font-weight: 800;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.pwa-activity__hero-label {
    margin-top: 6px;
    color: var(--pwa-text-secondary);
    font-size: 13px;
}

.pwa-activity__kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 20px;
}

.pwa-activity__kpi {
    padding: 12px 8px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    text-align: center;
}

.pwa-activity__kpi-value {
    color: var(--pwa-text-primary);
    font-size: 15px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.pwa-activity__kpi-label {
    margin-top: 4px;
    color: var(--pwa-text-muted);
    font-size: 11px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* --- Monatsdiagramm --------------------------------------- */
.pwa-activity__chart {
    margin-bottom: 20px;
}

.pwa-activity__chart-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.pwa-activity__chart-title {
    color: var(--pwa-text-primary);
    font-size: 13px;
    font-weight: 600;
}

.pwa-activity__chart-max {
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}

/* --- Jahresnavigation --------------------------------------- */
.pwa-year-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    padding: 10px 6px;
    border: 1px solid var(--pwa-border);
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
}

.pwa-year-nav__arrow {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: none;
    color: var(--pwa-text-secondary);
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
    -webkit-tap-highlight-color: transparent;
}

.pwa-year-nav__arrow svg {
    width: 20px;
    height: 20px;
}

.pwa-year-nav__arrow:not(:disabled):hover {
    background: var(--pwa-surface-3);
    color: var(--pwa-text-primary);
}

/* Am Rand der Historie: sichtbar, aber erkennbar ohne Funktion. */
.pwa-year-nav__arrow:disabled {
    color: var(--pwa-text-muted);
    opacity: 0.35;
    cursor: default;
}

.pwa-year-nav__arrow:focus-visible {
    outline: 2px solid var(--pwa-accent);
    outline-offset: 2px;
}

.pwa-year-nav__body {
    flex: 1;
    min-width: 0;
    text-align: center;
}

.pwa-year-nav__year {
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.pwa-year-nav__amount {
    margin-top: 2px;
    color: var(--pwa-gold);
    font-size: 20px;
    font-weight: 800;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}

.pwa-year-nav__meta {
    margin-top: 2px;
    color: var(--pwa-text-secondary);
    font-size: 12px;
}

/* --- Vergleichslinien --------------------------------------- */
.pwa-line__compare {
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.75;
    stroke-dasharray: 5 4;
}

/* Legende: klein, antippbar, ohne der Hauptkurve die Schau zu stehlen. */
.pwa-series-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.pwa-series-legend__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border: 1px solid var(--pwa-border);
    border-radius: 999px;
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    font: inherit;
    font-size: 11px;
    cursor: pointer;
    transition: opacity 0.18s ease, color 0.18s ease;
    -webkit-tap-highlight-color: transparent;
}

/* Abgeschaltet bleibt sichtbar - sonst waere nicht erkennbar, dass es
   die Linie ueberhaupt gibt. */
.pwa-series-legend__item.is-off {
    opacity: 0.4;
}

.pwa-series-legend__item.is-off .pwa-series-legend__label {
    text-decoration: line-through;
}

.pwa-series-legend__item:focus-visible {
    outline: 2px solid var(--pwa-accent);
    outline-offset: 2px;
}

/* In der Balkenansicht bleibt die Legende stehen, aber ohne Funktion. */
.pwa-series-legend.is-locked .pwa-series-legend__item {
    cursor: default;
}

.pwa-series-legend__note {
    margin-top: 6px;
    color: var(--pwa-text-muted);
    font-size: 11px;
}

.pwa-series-legend__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex: 0 0 auto;
}

/* --- Wahl der Darstellung (nur wenn beides freigegeben) ----- */
.pwa-chart-switch {
    display: flex;
    gap: 2px;
    margin-bottom: 12px;
    padding: 3px;
    border-radius: 999px;
    background: var(--pwa-surface-2);
}

.pwa-chart-switch__btn {
    flex: 1;
    min-width: 0;
    padding: 7px 4px;
    border: 0;
    border-radius: 999px;
    background: none;
    color: var(--pwa-text-secondary);
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
    -webkit-tap-highlight-color: transparent;
}

.pwa-chart-switch__btn.is-active {
    background: var(--pwa-surface-3);
    color: var(--pwa-text-primary);
}

.pwa-chart-switch__btn:focus-visible {
    outline: 2px solid var(--pwa-accent);
    outline-offset: -2px;
}

/* --- Monatsverlauf als Kurve ------------------------------- */
.pwa-line {
    position: relative;
    margin-bottom: 8px;
}

/* Gleichmaessige Skalierung: kein preserveAspectRatio="none", sonst
   verzerren Linienstaerke und Punkte mit der Fensterbreite. */
.pwa-line__svg {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.pwa-line__stop--top {
    stop-color: var(--pwa-accent);
    stop-opacity: 0.32;
}

.pwa-line__stop--bottom {
    stop-color: var(--pwa-accent);
    stop-opacity: 0;
}

.pwa-line__stroke {
    stroke: var(--pwa-accent);
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.pwa-line__dot {
    fill: var(--pwa-surface-1);
    stroke: var(--pwa-accent);
    stroke-width: 2;
}

/* Trefferflaechen liegen als Raster ueber der Kurve. */
.pwa-line__hits {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: repeat(var(--pwa-chart-cols, 12), minmax(0, 1fr));
}

.pwa-line--labelled {
    padding-bottom: 20px;
}

.pwa-line__hit {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    min-width: 0;
    padding: 0;
    border: 0;
    background: none;
    font: inherit;
    color: inherit;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.pwa-line__hit:focus-visible {
    outline: 2px solid var(--pwa-accent);
    outline-offset: -2px;
    border-radius: 4px;
}

/* Senkrechte Hilfslinie am ausgewaehlten Monat. */
.pwa-line__hit.is-active::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1px;
    background: var(--pwa-gold);
    opacity: 0.7;
}

/* Hilfslinie endet ueber den Monatsnamen, nicht darueber hinweg. */
.pwa-line--labelled .pwa-line__hit.is-active::before {
    bottom: 20px;
}

.pwa-line__hit.is-active .pwa-chart__label {
    color: var(--pwa-text-primary);
    font-weight: 700;
}

.pwa-line--labelled .pwa-line__hit .pwa-chart__label {
    pointer-events: none;
}

.pwa-chart {
    display: grid;
    grid-template-columns: repeat(var(--pwa-chart-cols, 12), minmax(0, 1fr));
    align-items: end;
    gap: 4px;
    height: 116px;
}

.pwa-chart__col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    height: 100%;
    min-width: 0;
    /* Schaltflaeche: Browserstile zuruecksetzen, Trefferflaeche behalten. */
    padding: 0;
    border: 0;
    background: none;
    font: inherit;
    color: inherit;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.pwa-chart__col:focus-visible {
    outline: 2px solid var(--pwa-accent);
    outline-offset: 2px;
    border-radius: 4px;
}

.pwa-chart__col.is-active .pwa-chart__fill {
    background: linear-gradient(180deg, var(--pwa-gold), #d9a92e);
}

.pwa-chart__col.is-active .pwa-chart__label {
    color: var(--pwa-text-primary);
    font-weight: 700;
}

/* Die Spur bleibt immer sichtbar, damit leere Monate als Lücke
   lesbar sind statt einfach zu fehlen. */
.pwa-chart__bar {
    display: block;
    position: relative;
    flex: 1;
    width: 100%;
    border-radius: 4px;
    background: var(--pwa-surface-3);
    overflow: hidden;
}

.pwa-chart__fill {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 4px;
    background: linear-gradient(180deg, var(--pwa-accent), var(--pwa-accent-hover));
    transition: height 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.pwa-chart__col.is-filled .pwa-chart__bar {
    box-shadow: 0 0 12px rgba(var(--pwa-accent-rgb), 0.22);
}

/* Jahresanker etwas kraeftiger - er ordnet die uebrigen Kuerzel ein. */
.pwa-chart__label.is-year {
    color: var(--pwa-text-secondary);
    font-weight: 700;
}

.pwa-chart__readout {
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

.pwa-chart__label {
    color: var(--pwa-text-muted);
    font-size: 10px;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

/* --- Aufschlüsselung nach Kategorie und Leistung ---------- */
.pwa-activity__group + .pwa-activity__group {
    margin-top: 18px;
}

.pwa-activity__group-title {
    margin-bottom: 8px;
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-activity__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.pwa-activity__row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 2px 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--pwa-border);
}

.pwa-activity__row:last-child {
    border-bottom: 0;
}

.pwa-activity__row-label {
    color: var(--pwa-text-primary);
    font-size: 14px;
    font-weight: 600;
    min-width: 0;
    overflow-wrap: anywhere;
}

.pwa-activity__row-amount {
    color: var(--pwa-gold);
    font-size: 14px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    text-align: right;
    white-space: nowrap;
}

.pwa-activity__row-meta {
    grid-column: 1;
    color: var(--pwa-text-muted);
    font-size: 12px;
}

/* --- Wartefrist als Countdown ------------------------------ */
.pwa-activity__waiting {
    margin-top: 16px;
    padding: 14px 12px;
    border: 1px solid rgba(var(--pwa-accent-rgb), 0.22);
    border-radius: var(--pwa-radius-sm);
    background: rgba(var(--pwa-accent-rgb), 0.07);
    text-align: center;
}

.pwa-activity__waiting-label {
    color: var(--pwa-text-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pwa-activity__waiting-clock {
    margin-top: 6px;
    color: var(--pwa-accent);
    font-size: 26px;
    font-weight: 800;
    line-height: 1.1;
    /* Feste Ziffernbreite: sonst zappelt die Anzeige im Sekundentakt. */
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.pwa-activity__waiting-clock.is-due {
    color: var(--pwa-success);
}

.pwa-activity__waiting-hint {
    margin-top: 8px;
    color: var(--pwa-text-secondary);
    font-size: 12px;
    line-height: 1.5;
}

.pwa-activity__waiting-due {
    margin-top: 4px;
    color: var(--pwa-text-muted);
    font-size: 11px;
}

/* Spaetere Gutschriften: sichtbar, aber deutlich nachgeordnet. */
.pwa-activity__waiting-more {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--pwa-border);
    color: var(--pwa-text-muted);
    font-size: 11px;
}

.pwa-activity__note {
    margin: 16px 0 0;
    padding: 10px 12px;
    border-radius: var(--pwa-radius-sm);
    background: var(--pwa-surface-2);
    color: var(--pwa-text-secondary);
    font-size: 12px;
    line-height: 1.5;
}
