/*
 * Peekopals web app: the 1:1 chat screen drawn like the phone app's ChatScreen (floating header,
 * bubbles, long-press tray, input bar, plus chooser, photo and voice note sheets) and the dialogs
 * the chat opens. Colours are the phone's Material roles (--md-* in web-app.css). Phone-width
 * screens get the phone's layout (bottom sheets, full-screen forms); wide screens get the same
 * screen centred at a readable width, with sheets and forms as cards.
 * Loaded on every signed-in page after web-app.css.
 */

:root {
    /* derived from the shared --md-* roles in web-app.css (no new colours) */
    --wa-chat-error-container: color-mix(in srgb, var(--md-error) 16%, var(--md-background));
    --wa-chat-shadow-small: 0 1px 2px rgba(0, 0, 0, 0.12);
    --wa-chat-shadow-sheet: 0 -2px 18px rgba(0, 0, 0, 0.16);
    /* the phone's relationshipBadgeProgress (Color.kt): the header face's ring fill */
    --wa-relationship-badge-progress: #E3AE00;
    /* the phone's onSecondaryContainer: words and icons on the yellow limit banner and well */
    --wa-on-secondary-container: #201C00;
}
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --wa-relationship-badge-progress: #F1DE3D;
        --wa-on-secondary-container: #0C0C0C;
    }
}
:root[data-theme="dark"] {
    --wa-relationship-badge-progress: #F1DE3D;
    --wa-on-secondary-container: #0C0C0C;
}

/* panels and bars that web-app-chat.js shows and hides */
.wa-composer[hidden],
.wa-media-panel[hidden],
.wa-composer-context[hidden] { display: none !important; }

/* a photo or voice note already in the thread: the send screen steps aside while the upload finishes */
.wa-media-panel.is-left-for-send,
#wa-chat-voice-sheet.is-left-for-send { display: none !important; }

/* ==================== the chat screen ==================== */

.wa-thread-page {
    position: relative;
    background: var(--md-background);
    color: var(--md-on-surface);
}

/* floating header: the thread scrolls under it with no fade, like the phone (7 Nov 2026); only the
   strip under a phone's status bar (the safe area) is solid, so messages never show through it */
.wa-thread-page .wa-thread-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px;
    padding-top: max(8px, env(safe-area-inset-top));
    /* the strip goes clear while a picture fills the chat (--wa-chat-bar-background, web-app-chat-play.css) */
    background: linear-gradient(var(--wa-chat-bar-background, var(--md-background)), var(--wa-chat-bar-background, var(--md-background))) top / 100% env(safe-area-inset-top, 0px) no-repeat;
    border-bottom: 0;
    pointer-events: none;
}
.wa-thread-page .wa-thread-header > * { pointer-events: auto; }
/* the empty holder dialogs open into must not take a slot in the row (it pushed the actions inwards) */
.wa-thread-page .wa-thread-header > .wa-dialog-holder { position: absolute; width: 0; height: 0; }
.wa-thread-header-start { display: flex; align-items: center; gap: 8px; min-width: 0; }
.wa-thread-page .wa-thread-header-actions { display: flex; align-items: center; gap: 8px; flex: none; }

.wa-floating-icon-button {
    position: relative;
    width: 44px;
    height: 44px;
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid var(--md-outline-variant);
    background: var(--md-background);
    color: var(--md-on-surface);
    text-decoration: none;
    cursor: pointer;
}
.wa-floating-icon-button .wa-icon svg { width: 22px; height: 22px; }
.wa-floating-icon-button:hover { background: var(--md-surface-container-low); }
.wa-floating-icon-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--md-secondary);
    color: var(--md-on-secondary);
    font-size: calc(11px * var(--wa-text-scale, 1));
    font-weight: 700;
    line-height: calc(20px * var(--wa-text-scale, 1));
    text-align: center;
}
.wa-floating-title-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid var(--md-outline-variant);
    background: var(--md-background);
    color: var(--md-on-surface);
    text-decoration: none;
    font-size: calc(16px * var(--wa-text-scale, 1));
    font-weight: 600;
}
.wa-floating-title-pill-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wa-floating-title-pill-chevron svg { width: 16px; height: 16px; }
.wa-thread-header-avatar { position: relative; display: inline-flex; padding: 4px; border: 0; border-radius: 14px; background: transparent; cursor: pointer; }
.wa-avatar--header { width: 40px; height: 40px; border-radius: 12px; font-size: calc(16px * var(--wa-text-scale, 1)); }
.wa-avatar--header .wa-avatar-image { border-radius: 12px; }
.wa-thread-header-face { position: relative; display: inline-flex; }
/* the yellow ring toward the next relationship badge: 4 px round the photo (the button keeps its 48 px), no photo border */
.wa-header-face-ring { position: absolute; inset: 0; display: block; pointer-events: none; }
.wa-header-face-ring svg { display: block; width: 48px; height: 48px; }
.wa-header-face-ring-track { stroke: var(--wa-header-face-ring-track, var(--md-outline-variant)); }
.wa-header-face-ring-progress { stroke: var(--wa-relationship-badge-progress); }
/* while a magic runs, the ring's track takes the magic's colour (the phone's potion border) instead of a ring round the photo */
.wa-thread-page:has(#wa-chat-active-magic[data-active-magic]) .wa-thread-header-avatar[data-has-badge-ring] .wa-avatar { box-shadow: none; }
.wa-thread-page:has(#wa-chat-active-magic[data-active-magic="romantic"]) .wa-thread-header-avatar[data-has-badge-ring] { --wa-header-face-ring-track: var(--wa-magic-romantic); }
.wa-thread-page:has(#wa-chat-active-magic[data-active-magic="super-love"]) .wa-thread-header-avatar[data-has-badge-ring],
.wa-thread-page:has(#wa-chat-active-magic[data-active-magic="romantic-and-super-love"]) .wa-thread-header-avatar[data-has-badge-ring] { --wa-header-face-ring-track: var(--wa-magic-super-love); }

/* the floating header grows by the notch (viewport-fit=cover), so the thread's first messages start under it */
.wa-thread-page .wa-thread-scroller { padding: calc(max(8px, env(safe-area-inset-top)) + 60px) 0 8px; background: var(--wa-chat-bar-background, var(--md-background)); }
/* a scrollbar takes width on one side only; an equal gutter on both sides keeps the thread centred under the header */
.wa-thread-page .wa-thread-scroller { scrollbar-gutter: stable both-edges; }
.wa-thread-page .wa-thread { gap: 0; max-width: 760px; padding: 0 12px; }

/* day lines stick under the header while their day scrolls past (the phone's sticky date pill) */
.wa-thread-page .wa-day-separator { position: sticky; top: calc(max(8px, env(safe-area-inset-top)) + 56px); z-index: 3; margin: 10px 0 6px; pointer-events: none; }
.wa-thread-page .wa-day-separator span {
    background: var(--md-surface-container-high);
    border: 0;
    color: var(--md-on-surface-variant);
    font-size: calc(11px * var(--wa-text-scale, 1));
    font-weight: 600;
}

/* ==================== bubbles ==================== */

/* the phone's row pads: 3dp each side inside one person's run (6px), 8dp each side when the
   speaker changes (16px). The first bubble keeps the scroller's own top pad. */
.wa-thread-page .wa-message { position: relative; max-width: min(280px, 82%); margin-top: 6px; }
.wa-thread-page .wa-message:not(.wa-message--continues-cluster) { margin-top: 16px; }
.wa-thread-page .wa-thread > .wa-message:first-child,
.wa-thread-page .wa-load-older + .wa-message { margin-top: 0; }
.wa-thread-page .wa-bubble {
    padding: 8px 12px;
    border-radius: 16px;
    /* see-through over a background picture (--wa-chat-fill-strength, web-app-chat-play.css) */
    background: color-mix(in srgb, var(--wa-pal-bubble) var(--wa-chat-fill-strength, 100%), transparent);
    color: var(--md-on-surface);
    border: 1px solid var(--wa-hairline);
    box-shadow: var(--wa-chat-shadow-small);
    font-size: calc(15px * var(--wa-text-scale, 1));
    line-height: 1.4;
}
/* the tight corners of the phone's bubbles: the tail at the bottom, and the top of a run's later bubbles */
.wa-thread-page .wa-message--from-pal .wa-bubble { border-bottom-left-radius: 4px; }
.wa-thread-page .wa-message--from-user .wa-bubble {
    background: color-mix(in srgb, var(--wa-user-bubble) var(--wa-chat-fill-strength, 100%), transparent);
    color: var(--wa-on-user-bubble);
    border-bottom-right-radius: 4px;
}
.wa-thread-page .wa-message--from-pal.wa-message--continues-cluster .wa-bubble { border-top-left-radius: 4px; }
.wa-thread-page .wa-message--from-user.wa-message--continues-cluster .wa-bubble { border-top-right-radius: 4px; }
.wa-thread-page .wa-message--from-user .wa-bubble a { color: var(--md-primary); }
.wa-thread-page .wa-bubble-meta { color: var(--md-on-surface-variant); opacity: 1; font-size: calc(11px * var(--wa-text-scale, 1)); }
.wa-thread-page .wa-ticks { color: var(--md-on-surface-variant); }
.wa-thread-page .wa-ticks--read { color: var(--md-on-surface-variant); }
/* the phone shows no tick while sending; a failed send gets the "Tap to retry" pill instead */
.wa-thread-page .wa-ticks--sending,
.wa-thread-page .wa-ticks--failed { visibility: hidden; }

/* the phone's in-bubble button row (MessageBubbleListStyleActionCta): a thin line across, then icon + label centred */
.wa-bubble-action-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 48px;
    margin: 6px 0 0;
    padding: 12px;
    border: 0;
    border-top: 1px solid var(--md-on-surface);
    background: none;
    color: var(--md-on-surface);
    font: inherit;
    font-size: calc(14px * var(--wa-text-scale, 1));
    line-height: calc(20px * var(--wa-text-scale, 1));
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}
.wa-thread-page .wa-message--from-user .wa-bubble a.wa-bubble-action-strip { color: var(--md-on-surface); }
.wa-bubble-action-strip svg { width: 20px; height: 20px; }
.wa-bubble-action-strip:hover { background: color-mix(in srgb, var(--md-on-surface) 6%, transparent); }
.wa-bubble-action-strip:focus-visible, .wa-announcement-card-photo-link:focus-visible { outline: 2px solid var(--md-on-surface); outline-offset: -2px; }
.wa-bubble-action-strip:disabled { opacity: 0.6; cursor: default; }

/* the phone's image + button card (a new episode's Watch card): the bubble is exactly the still's width, the still
   sits edge to edge, whole (never cropped), at most 280px wide and about 55% of the screen tall */
.wa-thread-page .wa-bubble--announcement-card {
    display: flex;
    flex-direction: column;
    padding: 0;
    /* clip rounds the still into the bubble. hidden would make this box a scroll container, and a
       finger on the card (most of a phone screen) would never reach the thread scroller */
    overflow: clip;
}
.wa-announcement-card-photo-link {
    display: block;
    padding: 0;
    border: 0;
    background: var(--md-surface-container-highest);
    cursor: pointer;
}
.wa-announcement-card-photo {
    display: block;
    width: auto;
    height: auto;
    max-width: min(280px, 72vw);
    max-height: 55vh;
    min-width: 120px;
    min-height: 80px;
}
/* the words and the time wrap inside the still's width instead of widening the bubble */
.wa-bubble--announcement-card .wa-announcement-card-caption { width: 0; min-width: 100%; box-sizing: border-box; padding: 8px 12px; }
.wa-bubble--announcement-card .wa-bubble-meta { width: 0; min-width: 100%; box-sizing: border-box; margin: 0; padding: 4px 12px; }
.wa-bubble--announcement-card .wa-bubble-action-strip { width: 0; min-width: 100%; box-sizing: border-box; margin: 0; }

/* the phone's "Tap to retry" pill under a failed bubble */
.wa-thread-page .wa-retry {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 4px 0 0;
    padding: 4px 12px;
    border: 0;
    border-radius: 999px;
    background: var(--wa-chat-error-container);
    color: var(--md-on-surface);
    font-size: calc(12px * var(--wa-text-scale, 1));
    font-weight: 600;
    cursor: pointer;
}
.wa-thread-page .wa-retry::before { content: '⚠'; color: var(--md-error); }
.wa-thread-page .wa-retry::after { content: '↻'; }

/* quotes inside bubbles */
.wa-thread-page .wa-quote {
    background: color-mix(in srgb, var(--md-on-surface) 7%, transparent);
    border-left: 3px solid var(--md-primary);
    border-radius: 8px;
    color: var(--md-on-surface);
}
.wa-thread-page .wa-quote-author { color: var(--md-primary); }
button.wa-quote {
    width: 100%;
    border-top: 0;
    border-right: 0;
    border-bottom: 0;
    font: inherit;
    font-size: calc(13px * var(--wa-text-scale, 1));
    text-align: left;
    cursor: pointer;
}
button.wa-quote:hover { background: color-mix(in srgb, var(--md-on-surface) 12%, transparent); }

/* reaction pill hanging over the bubble's bottom edge (ChatMessageReactionBadge) */
.wa-thread-page .wa-reactions {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin: -8px 8px 0;
    padding: 1px 6px;
    min-height: 0;
    border-radius: 999px;
    background: var(--md-surface-container-highest);
    border: 1px solid var(--wa-hairline);
    box-shadow: 0 0 0 2px var(--md-background);
    font-size: calc(14px * var(--wa-text-scale, 1));
    line-height: 1.4;
    color: var(--md-on-surface);
}
.wa-thread-page .wa-reactions:empty { display: none; }
.wa-thread-page .wa-message--from-user .wa-reactions { align-self: flex-end; }
.wa-thread-page .wa-message--from-pal .wa-reactions { align-self: flex-start; }
button.wa-reactions { font: inherit; cursor: pointer; }
/* the total after the emoji once there is more than one reaction, like the phone's pill */
.wa-thread-page .wa-reaction-count {
    margin-left: 2px;
    font-size: calc(12px * var(--wa-text-scale, 1));
    font-weight: 600;
    color: var(--md-on-surface-variant);
}
.wa-thread-page button.wa-reactions:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--md-background), var(--wa-focus-ring); }

/* the "who reacted" sheet the pill opens (chatMessageReactionsSheet.kt) */
.wa-chat-reaction-chips {
    display: flex;
    gap: 8px;
    padding: 4px 0 12px;
    overflow-x: auto;
    scrollbar-width: none;
}
.wa-chat-reaction-chips::-webkit-scrollbar { display: none; }
.wa-chat-reaction-chip {
    position: relative;
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid var(--md-outline-variant);
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface);
    font: inherit;
    cursor: pointer;
}
/* a 48px tall tap area around the 40px chip */
.wa-chat-reaction-chip::after { content: ""; position: absolute; inset: -4px 0; }
.wa-chat-reaction-chip:hover { background: var(--md-surface-container-high); }
.wa-chat-reaction-chip--picked,
.wa-chat-reaction-chip--picked:hover {
    background: color-mix(in srgb, var(--md-primary) 12%, transparent);
    border-color: var(--md-primary);
}
.wa-chat-reaction-chip-emoji { font-size: calc(18px * var(--wa-text-scale, 1)); line-height: 1; }
.wa-chat-reaction-chip-count { font-size: calc(14px * var(--wa-text-scale, 1)); font-weight: 600; }
.wa-chat-reaction-rows { display: grid; gap: 2px; }
.wa-chat-reaction-row {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    min-height: 56px;
    padding: 8px 4px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--md-on-surface);
    font: inherit;
    text-align: left;
}
button.wa-chat-reaction-row { cursor: pointer; }
button.wa-chat-reaction-row:hover { background: var(--md-surface-container-high); }
button.wa-chat-reaction-row:disabled { opacity: 0.6; cursor: progress; }
.wa-chat-reaction-chip:focus-visible,
button.wa-chat-reaction-row:focus-visible { outline: none; box-shadow: var(--wa-focus-ring); }
.wa-chat-reaction-row-names { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.wa-chat-reaction-row-name {
    font-size: calc(16px * var(--wa-text-scale, 1));
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.wa-chat-reaction-row-hint { font-size: calc(13px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-chat-reaction-row-emoji { flex: none; font-size: calc(22px * var(--wa-text-scale, 1)); line-height: 1; }
/* touch screens: a long press opens the tray (no text selection callout), like the phone */
@media (hover: none) {
    .wa-thread-page .wa-bubble { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
}

/* the typing row: the next pal bubble, without the avatar (1:1 rows have none on the phone) */
.wa-thread-page .wa-typing-row { padding: 0 12px; max-width: 760px; }
.wa-thread-page .wa-typing-row .wa-avatar { display: none; }
.wa-thread-page .wa-typing-bubble {
    background: var(--wa-pal-bubble);
    border: 1px solid color-mix(in srgb, var(--md-outline-variant) 35%, transparent);
    border-radius: 16px;
    border-bottom-left-radius: 4px;
    box-shadow: var(--wa-chat-shadow-small);
    color: var(--md-on-surface-variant);
}

/* the message a quote or a link opened, flashed for a moment */
.wa-message--highlighted .wa-bubble { animation: wa-message-highlight 1.8s ease-out; }
@keyframes wa-message-highlight {
    0%, 35% { box-shadow: 0 0 0 3px var(--md-secondary); }
    100% { box-shadow: var(--wa-chat-shadow-small); }
}

/* "3 unread messages" (UnreadMessagesSeparator) */
.wa-unread-divider { display: flex; justify-content: center; margin: 16px 0; }
.wa-unread-divider span {
    font-size: calc(11px * var(--wa-text-scale, 1));
    font-weight: 600;
    color: var(--md-on-surface-variant);
    background: var(--md-surface-container-high);
    padding: 3px 12px;
    border-radius: 999px;
}

/* ==================== the long-press tray ==================== */

/* the "⋯" next to a bubble, for mice and keyboards (a long press or right click opens the tray too) */
.wa-message-menu-button {
    position: absolute;
    top: 2px;
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface-variant);
    cursor: pointer;
    opacity: 0;
    transition: opacity 120ms ease;
}
.wa-message--from-pal .wa-message-menu-button { left: calc(100% + 2px); }
.wa-message--from-user .wa-message-menu-button { right: calc(100% + 2px); }
.wa-message-menu-button:hover { background: var(--md-surface-container-low); color: var(--md-on-surface); }
.wa-message:hover .wa-message-menu-button,
.wa-message-menu-button:focus-visible,
.wa-message-menu-button[aria-expanded="true"] { opacity: 1; }
@media (hover: none) {
    /* touch screens use the long press, like the phone */
    .wa-message-menu-button { display: none; }
}

/* the tray floats just above the bubble (below it when there is no room above) */
.wa-message-menu {
    position: absolute;
    bottom: calc(100% + 6px);
    z-index: 30;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding: 4px;
    background: var(--md-surface-container);
    border: 1px solid var(--wa-hairline);
    border-radius: 999px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
    animation: wa-fade-in 120ms ease-out;
    white-space: nowrap;
}
.wa-message-menu--with-emoji-row { border-radius: 24px; }
.wa-message--from-pal .wa-message-menu { left: 0; }
.wa-message--from-user .wa-message-menu { right: 0; }
.wa-message-menu--below { bottom: auto; top: calc(100% + 6px); }
.wa-message-menu-emoji-row {
    display: flex;
    justify-content: center;
    padding: 0 4px 4px;
    margin-bottom: 4px;
    border-bottom: 1px solid color-mix(in srgb, var(--md-outline-variant) 50%, transparent);
}
.wa-message-menu-emoji {
    width: 44px;
    height: 44px;
    border: 1px solid transparent;
    border-radius: 999px;
    background: transparent;
    font-size: calc(22px * var(--wa-text-scale, 1));
    line-height: 1;
    cursor: pointer;
}
.wa-message-menu-emoji:hover { background: var(--md-surface-container-high); }
.wa-message-menu-emoji--chosen {
    background: color-mix(in srgb, var(--md-primary) 12%, transparent);
    border-color: var(--md-primary);
}
.wa-message-menu-actions { display: flex; justify-content: center; gap: 2px; padding: 0 4px; }
.wa-message-menu-item {
    min-width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface-variant);
    cursor: pointer;
}
.wa-message-menu-item .wa-icon svg { width: 22px; height: 22px; }
.wa-message-menu-item:hover,
.wa-message-menu-item:focus-visible { background: var(--md-surface-container-high); }
.wa-message-menu-item[data-web-already-chosen] { color: var(--md-primary); }
.wa-message-menu-item--danger { color: var(--md-error); }
.wa-message-menu-note { padding: 10px 14px; font-size: calc(13px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }

/* ==================== input bar (ChatInputBarCommon) ==================== */

.wa-composer-context {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 8px;
    padding: 6px 6px 6px 0;
    background: var(--md-surface-container-high);
    border-radius: 8px;
    box-shadow: var(--wa-chat-shadow-small);
    overflow: hidden;
}
.wa-composer-context-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    padding: 2px 10px;
    border-left: 4px solid var(--md-primary);
}
.wa-composer-context-title { font-size: calc(13px * var(--wa-text-scale, 1)); font-weight: 700; color: var(--md-primary); }
.wa-composer-context-preview {
    font-size: calc(13px * var(--wa-text-scale, 1));
    color: var(--md-on-surface-variant);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wa-icon-button--small { width: 32px; height: 32px; }

.wa-thread-page .wa-composer {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    padding: 8px 6px;
    padding-bottom: max(8px, var(--wa-bottom-inset));
    background: var(--wa-chat-bar-background, var(--md-background));
    border-top: 0;
}
/* the safe-area inset is the nav bar. the keyboard already covers that bar, so the inset
   would leave a gap under the microphone (web-app-chat.js adds this while the keyboard is open). */
.wa-thread-page .wa-composer.is-above-keyboard {
    padding-bottom: 8px;
}
/* the same, without asking the script: the composer holding the cursor means the keyboard is up.
   some browsers shrink the window for it, some cover the page with it, and the script's own test
   does not catch every one of them — this one always does. */
.wa-thread-page .wa-composer:focus-within {
    padding-bottom: 8px;
}
.wa-composer-field {
    position: relative;
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: flex-end;
    border-radius: 12px;
    border: 1px solid var(--md-outline-variant);
    background: color-mix(in srgb, var(--md-surface-container-high) var(--wa-chat-fill-strength, 100%), transparent);
}
.wa-composer-field:focus-within { border-color: var(--md-outline-variant); box-shadow: inset 0 0 0 1px var(--md-outline-variant); }
.wa-thread-page .wa-composer-text {
    flex: 1;
    min-width: 0;
    min-height: 54px;
    max-height: 160px;
    padding: 15px 8px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--md-on-surface);
    font: inherit;
    font-size: calc(16px * var(--wa-text-scale, 1));
    line-height: calc(24px * var(--wa-text-scale, 1));
    resize: none;
}
.wa-thread-page .wa-composer-text:focus { outline: none; box-shadow: none; }
.wa-thread-page .wa-composer-text::placeholder { color: var(--md-on-surface-variant); font-size: calc(14px * var(--wa-text-scale, 1)); }
.wa-composer--editing .wa-composer-text { padding-left: 16px; }
.wa-composer-plus {
    width: 48px;
    height: 48px;
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 3px 4px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface);
    cursor: pointer;
}
.wa-composer-plus-circle .wa-icon svg { width: 20px; height: 20px; }
.wa-composer-plus-circle {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: color-mix(in srgb, var(--md-surface-container-highest) var(--wa-chat-fill-strength, 100%), transparent);
    border: 1px solid var(--md-outline-variant);
}
.wa-composer-field-end { display: flex; flex: none; margin: 0 4px 3px 0; }
.wa-composer-tool .wa-icon svg { width: 20px; height: 20px; }
.wa-composer-tool {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: transparent;
    color: var(--md-on-surface-variant);
    cursor: pointer;
}
.wa-composer-fab {
    width: 48px;
    height: 48px;
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: var(--md-primary);
    color: var(--md-on-primary);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    cursor: pointer;
}
.wa-composer-fab:disabled { background: color-mix(in srgb, var(--md-on-surface) 12%, transparent); color: color-mix(in srgb, var(--md-on-surface) 38%, transparent); box-shadow: none; }
/* WhatsApp-style, like the phone: the microphone while the box is empty, send once something is typed */
.wa-composer:not(.wa-composer--has-text) .wa-composer-fab--send { display: none; }
.wa-composer--has-text .wa-composer-fab--microphone { display: none; }

/* wide screens: the input bar's content is centred at the thread's reading width */
@media (min-width: 900px) {
    /* the header's buttons and the input bar end where the bubbles end (the thread is 760px with 12px sides) */
    .wa-thread-page .wa-thread-header { padding-left: calc((100% - 760px) / 2 + 12px); padding-right: calc((100% - 760px) / 2 + 12px); }
    .wa-thread-page .wa-composer { padding-left: calc((100% - 760px) / 2 + 12px); padding-right: calc((100% - 760px) / 2 + 12px); }
    .wa-composer-context { margin-left: max(8px, calc((100% - 744px) / 2)); margin-right: max(8px, calc((100% - 744px) / 2)); }
}

/* ==================== sheets and dialogs the chat opens ==================== */

/* inside the shared bottom sheet (web-app-bottom-sheets.css): title spacing and buttons */
.wa-sheet .wa-dialog-title { margin: 4px 0 14px; font-size: calc(20px * var(--wa-text-scale, 1)); }
.wa-sheet .wa-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; }

@media (max-width: 899px) {
    /* the phone's own screens (report, feedback, ask for a photo): fill the screen */
    .wa-dialog-backdrop--full-screen-on-phones { padding: 0; }
    .wa-dialog-backdrop--full-screen-on-phones .wa-dialog {
        max-width: none;
        width: 100%;
        height: 100dvh;
        max-height: none;
        border-radius: 0;
        padding: max(16px, env(safe-area-inset-top)) 16px max(16px, var(--wa-bottom-inset));
        background: var(--md-background);
    }
}
.wa-dialog-subtitle { margin: -6px 0 14px; font-size: calc(14px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-report-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--md-surface-container-high);
    font-size: calc(14px * var(--wa-text-scale, 1));
}
.wa-report-preview-text {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: pre-line;
}
.wa-fine-print--with-icon { display: flex; align-items: center; gap: 6px; margin: 0; }
.wa-fine-print--with-icon .wa-icon svg { width: 16px; height: 16px; }
.wa-textarea { resize: vertical; min-height: 56px; font: inherit; line-height: 1.4; }

/* the plus chooser (ChatPlusChooserSheetContent): one card per thing to start */
.wa-plus-chooser { display: grid; gap: 8px; }
.wa-plus-chooser-card {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    padding: 16px;
    border: 0;
    border-radius: 12px;
    background: var(--md-surface-container-low);
    color: var(--md-on-surface);
    text-align: left;
    cursor: pointer;
}
.wa-plus-chooser-card:hover { background: var(--md-surface-container); }
.wa-plus-chooser-icon-well {
    width: 48px;
    height: 48px;
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--md-surface-container-highest);
}
.wa-plus-chooser-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wa-plus-chooser-title { font-size: calc(15px * var(--wa-text-scale, 1)); font-weight: 600; }
.wa-plus-chooser-description { font-size: calc(13px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-plus-chooser-card--destructive .wa-plus-chooser-title,
.wa-plus-chooser-card--destructive .wa-plus-chooser-icon-well { color: var(--md-error); }
/* End roleplay's info button: a 48px target floating over the card's right end, vertically centred */
.wa-plus-chooser-card-with-info { position: relative; }
.wa-plus-chooser-card-with-info .wa-plus-chooser-card { padding-right: 56px; }
.wa-plus-chooser-info {
    position: absolute;
    top: 50%;
    right: 4px;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface-variant);
    cursor: pointer;
}
.wa-plus-chooser-info .wa-icon svg { width: 20px; height: 20px; }
.wa-plus-chooser-info:hover { background: var(--md-surface-container-highest); }

/* the pal options (CharacterOptionsBottomSheet) */
.wa-option-list { display: grid; margin: 0 -8px 8px; }
.wa-option-row {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 8px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: var(--md-on-surface);
    text-align: left;
    cursor: pointer;
}
.wa-option-row:hover { background: var(--md-surface-container-low); }
.wa-option-row + .wa-option-row { border-top: 1px solid var(--md-outline-variant); border-radius: 0; }
.wa-option-row-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wa-option-row-title { font-size: calc(16px * var(--wa-text-scale, 1)); font-weight: 500; }
.wa-option-row-description { font-size: calc(13px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-option-row-chevron { color: var(--md-on-surface-variant); }
.wa-option-row-chevron svg { width: 16px; height: 16px; }
.wa-switch-visual {
    position: relative;
    width: 52px;
    height: 32px;
    flex: none;
    border-radius: 999px;
    background: var(--md-surface-container-highest);
    border: 2px solid var(--md-outline-variant);
    transition: background 140ms ease;
}
.wa-switch-visual::after {
    content: '';
    position: absolute;
    top: 6px;
    left: 6px;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: var(--md-outline-variant);
    transition: transform 140ms ease, width 140ms ease, height 140ms ease, top 140ms ease;
}
/* checked: the phone's secondary (yellow) track with a light thumb */
.wa-switch-visual--on { background: var(--md-secondary); border-color: var(--md-secondary); }
.wa-switch-visual--on::after { top: 2px; width: 24px; height: 24px; transform: translateX(20px); background: var(--md-on-secondary); }

/* ==================== photo and voice note ==================== */

/* "photo ready to send" fills the screen on black, like the phone */
.wa-media-panel--photo {
    position: fixed;
    inset: 0;
    z-index: 45;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: max(10px, env(safe-area-inset-top)) 10px max(10px, var(--wa-bottom-inset));
    background: #000;
    color: #fff;
}
.wa-media-panel-top-bar { display: flex; }
.wa-media-panel-close {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
}
.wa-media-panel-preview { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
.wa-media-panel-photo { display: block; max-width: 100%; max-height: 100%; object-fit: contain; }
.wa-media-panel-price {
    align-self: center;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 4px 12px;
    border-radius: 999px;
    background: var(--md-secondary-container);
    color: var(--md-on-surface);
    font-size: calc(13px * var(--wa-text-scale, 1));
}
.wa-media-panel--photo .wa-media-panel-price { background: var(--md-secondary-container); color: #000; }
.wa-media-panel-caption-row { display: flex; align-items: flex-end; gap: 6px; width: 100%; max-width: 760px; margin: 0 auto; }
.wa-media-panel-caption {
    flex: 1;
    min-width: 0;
    min-height: 48px;
    max-height: 140px;
    padding: 13px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font: inherit;
    font-size: calc(16px * var(--wa-text-scale, 1));
    resize: none;
}
.wa-media-panel-caption::placeholder { color: rgba(255, 255, 255, 0.7); }

/* the voice note recorder: the phone's full-height VoiceRecordingBottomSheet (chat/WebAppVoiceNoteRecorderSheet.kt):
   ✕ top right, the voice orb and "Recording…" in the middle, the coin price, then discard · time left · send */
.wa-media-panel .wa-dialog-actions { margin-top: 0; }
.wa-voice-recording-sheet {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 16px max(32px, var(--wa-bottom-inset));
    color: var(--md-on-surface);
}
.wa-voice-recording-close { position: absolute; top: 8px; right: 16px; z-index: 1; }
.wa-voice-recording-middle { flex: 1; min-height: 0; width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; padding: 56px 0 28px; }
/* the orb shows only while the microphone is live */
.wa-voice-orb { display: none; width: 200px; height: 200px; }
.wa-voice-recording-sheet.is-recording .wa-voice-orb { display: block; }
/* titleMedium in onSurfaceVariant */
.wa-voice-recording-title { margin: 0; font-size: calc(16px * var(--wa-text-scale, 1)); line-height: calc(24px * var(--wa-text-scale, 1)); font-weight: 500; color: var(--md-on-surface-variant); text-align: center; }
/* the coin price just above the controls: surfaceContainerHigh, 2 px outline, 12 px corners, bodySmall */
.wa-voice-recording-cost {
    margin: 0 0 20px;
    padding: 8px 16px;
    border-radius: 12px;
    border: 2px solid var(--md-outline-variant);
    background: var(--md-surface-container-high);
    color: var(--md-on-surface-variant);
    font-size: calc(12px * var(--wa-text-scale, 1));
    line-height: calc(16px * var(--wa-text-scale, 1));
    text-align: center;
}
/* one row: discard, the time left counting down, send (48 px circles, 12 px apart) */
.wa-voice-recording-controls { width: 100%; max-width: 560px; display: flex; align-items: center; gap: 12px; }
.wa-voice-recording-circle {
    width: 48px;
    height: 48px;
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
}
.wa-voice-recording-circle svg { width: 24px; height: 24px; }
.wa-voice-recording-discard { background: var(--md-error-container, color-mix(in srgb, var(--md-error) 20%, var(--md-background))); color: var(--md-error); }
.wa-voice-recording-send { background: var(--md-primary); color: var(--md-on-primary); }
.wa-voice-recording-send:disabled { background: color-mix(in srgb, var(--md-on-surface) 12%, transparent); color: color-mix(in srgb, var(--md-on-surface) 38%, transparent); cursor: default; }
/* titleLarge, semi-bold, on inverseOnSurface */
.wa-voice-recording-countdown {
    flex: 1;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--md-inverse-on-surface);
    color: var(--md-on-surface);
    font-size: calc(22px * var(--wa-text-scale, 1));
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

/* ==================== chat row and profile ==================== */

.wa-chat-row-muted { display: inline-flex; flex: none; color: var(--wa-text-muted); }
.wa-chat-row-muted svg { width: 16px; height: 16px; }
.wa-page-header .wa-page-title { flex: 1; min-width: 0; }

/* ==================== chat thread parity (w3): the empty chat, swipe to reply, the reply card's picture ==================== */

/* the phone's ChatEmptyConversationState: the face, "I'm Meera", "Ask Meera anything", "Try asking:" and three chips, centred */
.wa-thread-page .wa-thread:has(> .wa-chat-empty-state) { min-height: 100%; }
.wa-thread-page .wa-chat-empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    padding: 24px 16px;
    color: var(--md-on-surface);
    text-align: center;
}
.wa-chat-empty-state-face {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
    border-radius: 12px;
    border: 1px solid var(--md-outline-variant);
    object-fit: cover;
}
.wa-chat-empty-state-greeting { margin: 0; font-size: calc(24px * var(--wa-text-scale, 1)); line-height: calc(32px * var(--wa-text-scale, 1)); font-weight: 400; color: var(--md-on-surface); }
.wa-chat-empty-state-ask { margin: 8px 0 0; font-size: calc(14px * var(--wa-text-scale, 1)); line-height: calc(20px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-chat-empty-state-try-asking { margin: 20px 0 8px; font-size: calc(11px * var(--wa-text-scale, 1)); line-height: calc(16px * var(--wa-text-scale, 1)); font-weight: 500; color: var(--md-on-surface-variant); }
.wa-chat-suggestion-chip {
    width: 100%;
    min-height: 40px;
    margin: 2px 0;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--md-outline-variant) 50%, transparent);
    background: var(--md-surface-container-high);
    color: var(--md-on-surface);
    font: inherit;
    font-size: calc(14px * var(--wa-text-scale, 1));
    line-height: calc(20px * var(--wa-text-scale, 1));
    text-align: center;
    cursor: pointer;
}
.wa-chat-suggestion-chip:hover { background: var(--md-surface-container-highest); }
.wa-chat-suggestion-chip:focus-visible { outline: none; box-shadow: var(--wa-focus-ring); }

/* swipe a bubble to the right to reply (web-app-chat.js): sideways drags are the page's, up and down still scroll */
.wa-thread-page .wa-message[data-web-swipe-reply-message-id] { touch-action: pan-y pinch-zoom; }
.wa-thread-page .wa-message--swiping { z-index: 2; }
/* the reply arrow stays at the thread's start edge (the script cancels the bubble's slide on it) and grows in */
.wa-swipe-reply-arrow {
    position: absolute;
    top: 50%;
    left: 0;
    z-index: 1;
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--md-surface-container-highest);
    color: var(--md-primary);
    opacity: 0;
    pointer-events: none;
}

/* the reply card (ReplySnapshot): a tap on its words scrolls back to the quoted message */
button.wa-composer-context-text {
    margin: 0;
    border: 0;
    border-left: 4px solid var(--md-primary);
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}
button.wa-composer-context-text:disabled { cursor: default; color: inherit; }
.wa-composer-context-preview-line { display: flex; align-items: center; gap: 4px; min-width: 0; }
.wa-composer-context-kind-icon { flex: none; display: inline-flex; color: var(--md-on-surface-variant); }
.wa-composer-context-kind-icon[hidden] { display: none; }
.wa-composer-context-kind-icon svg { width: 14px; height: 14px; }
.wa-composer-context-preview { min-width: 0; }
/* the quoted photo (40 px) or story poster (48 x 80) on the right, like the phone */
.wa-composer-context-thumbnail { flex: none; width: 40px; height: 40px; border-radius: 8px; object-fit: cover; }
.wa-composer-context-thumbnail--story { width: 48px; height: 80px; }
.wa-composer-context-thumbnail[hidden] { display: none; }

/* like the phone, "jump to newest" steps aside while a reply is staged */
.wa-thread-page:has(#wa-composer-context[data-mode="reply"]:not([hidden])) .wa-scroll-to-newest,
.wa-thread-page:has(#wa-group-reply-chip:not([hidden])) .wa-scroll-to-newest { display: none; }

/* ==================== the message box at phone width (ChatInputBarCommon) ==================== */

/* the placeholder stays on one line, cut with "…", like the phone's maxLines = 1 */
.wa-thread-page .wa-composer-text::placeholder { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* once the typed text wraps, the gallery, camera (and gift) icons fold into one (web-app-chat.js) */
.wa-composer-attach-fold { display: none; }
.wa-composer--attach-folded .wa-composer-field-end > :not(.wa-composer-attach-fold) { display: none; }
.wa-composer--attach-folded .wa-composer-attach-fold { display: inline-flex; }
.wa-composer-attach-fold .wa-icon svg { width: 24px; height: 24px; }
/* measures how many lines the typed text takes with every icon showing (never on screen) */
.wa-composer-line-measurer {
    position: absolute;
    top: 0;
    left: -10000px;
    visibility: hidden;
    padding: 0;
    border: 0;
    white-space: pre-wrap;
    overflow-wrap: break-word;
    word-break: break-word;
    pointer-events: none;
}

/* the characters left, under the bar's right end, from 1950 of 2048 (red from 10 left) */
.wa-composer-counter {
    margin: -4px 0 0;
    padding: 0 16px 4px;
    text-align: end;
    font-size: calc(11px * var(--wa-text-scale, 1));
    line-height: calc(16px * var(--wa-text-scale, 1));
    font-weight: 500;
    color: var(--md-on-surface-variant);
    background: var(--md-background);
}
.wa-composer-counter[hidden],
.wa-composer[hidden] + .wa-composer-counter { display: none; }
.wa-composer-counter--almost-full { color: var(--md-error); }

/* switched off (today's limit, a Forget magic erasing): the field and its buttons read as disabled; the plus stays on */
.wa-composer--switched-off .wa-composer-text { color: color-mix(in srgb, var(--md-on-surface) 38%, transparent); cursor: not-allowed; }
.wa-composer--switched-off .wa-composer-tool:disabled { color: color-mix(in srgb, var(--md-on-surface) 38%, transparent); cursor: default; }

/* the folded icon's sheet (ChatPhotoSourcePickerBottomSheet): reuses the plus chooser cards; this only pads the sheet */
.wa-attach-source-picker { padding: 0 16px 48px; }

/* ==================== today's message limit (QuotaExceededBanner, DailyMessageLimitExceededBottomSheet) ==================== */

.wa-daily-limit-banner {
    width: calc(100% - 16px);
    max-width: 744px;
    margin: 8px auto;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid var(--md-secondary);
    background: var(--md-secondary-container);
    color: var(--wa-on-secondary-container);
}
.wa-daily-limit-banner[hidden] { display: none; }
.wa-daily-limit-banner-top { display: flex; align-items: flex-start; gap: 8px; }
.wa-daily-limit-banner-sign { flex: none; display: inline-flex; color: var(--wa-on-secondary-container); }
.wa-daily-limit-banner-text { flex: 1; min-width: 0; }
.wa-daily-limit-banner-title { margin: 0; font-size: calc(14px * var(--wa-text-scale, 1)); line-height: calc(20px * var(--wa-text-scale, 1)); font-weight: 500; }
.wa-daily-limit-banner-body { margin: 2px 0 0; font-size: calc(12px * var(--wa-text-scale, 1)); line-height: calc(16px * var(--wa-text-scale, 1)); }
.wa-daily-limit-banner-close {
    flex: none;
    width: 40px;
    height: 40px;
    margin: -8px -8px 0 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--wa-on-secondary-container);
    cursor: pointer;
}
.wa-daily-limit-banner-close .wa-icon svg { width: 16px; height: 16px; }
.wa-daily-limit-banner-invite { display: flex; width: 100%; margin-top: 12px; justify-content: center; text-decoration: none; }

.wa-daily-limit-sheet { position: relative; display: flex; flex-direction: column; align-items: center; padding: 12px 16px 24px; text-align: center; color: var(--md-on-surface); }
.wa-daily-limit-sheet-close {
    position: absolute;
    top: 0;
    right: 0;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--md-on-surface);
    cursor: pointer;
}
.wa-daily-limit-sheet-icon-well {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--md-secondary-container);
    color: var(--wa-on-secondary-container);
}
.wa-daily-limit-sheet-icon-well .wa-icon svg { width: 32px; height: 32px; }
.wa-daily-limit-sheet-title { margin: 16px 0 0; font-size: calc(24px * var(--wa-text-scale, 1)); line-height: calc(32px * var(--wa-text-scale, 1)); font-weight: 600; }
.wa-daily-limit-sheet-body { margin: 8px 0 0; font-size: calc(14px * var(--wa-text-scale, 1)); line-height: calc(20px * var(--wa-text-scale, 1)); color: var(--md-on-surface-variant); }
.wa-daily-limit-sheet-invite-hint {
    width: 100%;
    margin: 16px 0 0;
    padding: 12px 16px;
    border-radius: 12px;
    background: var(--md-inverse-on-surface);
    color: var(--md-on-surface);
    font-size: calc(14px * var(--wa-text-scale, 1));
    line-height: calc(20px * var(--wa-text-scale, 1));
    font-weight: 600;
}
.wa-daily-limit-sheet-invite { margin-top: 24px; gap: 8px; text-decoration: none; }
.wa-daily-limit-sheet-invite .wa-icon { display: inline-flex; }

@media (prefers-reduced-motion: reduce) {
    .wa-thread-page .wa-message--swiping { transition: none !important; }
}
