/* BBB-UX-001: everyday actions first, details on demand. */
:root { --box-surface: #141414; --box-muted: #aaa9a2; --box-line: #ffffff1c; --box-placeholder: #20211e; --box-accent: #b8ff5a; }
:root[data-theme="light"] { --box-surface: #fffefa; --box-muted: #69685f; --box-line: #25251d22; --box-placeholder: #e9e7df; --box-accent: #315f09; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.screen-heading { margin: 0; font-size: 22px; font-weight: 600; letter-spacing: -.5px; }
.app-header { padding-top: max(6px,env(safe-area-inset-top)); padding-bottom: 6px; }
.app-header .avatar-button { width: 44px; height: 44px; }
.topline { gap: 10px; }
.summary { margin-left: 0; flex: 1; }
.summary small,.summary span { display: none; }
.app-content { padding-top: 8px; }
.toolbar { margin-bottom: 8px; }
.planner-toolbar { display: flex; align-items: center; gap: 8px; margin: 0; }
.planner-toolbar .recipient-select { flex: 1; width: 0; min-width: 0; min-height: 44px; padding: 0 10px; border: 1px solid var(--box-line); border-radius: 10px; background: var(--box-surface); color: inherit; font-size: 16px; text-overflow: ellipsis; }
.planner-toolbar > button { flex: 0 0 auto; min-height: 44px; border-color: var(--box-line); font-size: 14px; font-weight: 500; }
.search-row { margin: 0; }
.search-field { height: 44px; }
.filter-toggle { min-width: 44px; min-height: 44px; }
.section-title { display: none; }
.collection-context { padding: 0 0 8px; }
.list-menu { position: relative; flex: 0 0 44px; }
.list-menu > summary,.card-menu > summary { display: grid; place-items: center; list-style: none; width: 44px; height: 44px; box-sizing: border-box; cursor: pointer; border-radius: 10px; color: var(--box-muted); font-size: 24px; }
summary::-webkit-details-marker { display: none; }
.list-menu > summary { border: 1px solid var(--box-line); }
.list-menu-body { position: absolute; top: 48px; right: 0; z-index: 30; width: min(240px,80vw); padding: 6px; border: 1px solid var(--box-line); border-radius: 12px; background: var(--box-surface); box-shadow: 0 8px 24px #0002; }
.list-menu:not([open]) > .list-menu-body { display: none; }
.list-menu-body button { width: 100%; min-height: 44px; padding: 10px; text-align: left; border: 0; background: transparent; color: inherit; font-size: 14px; }
.wishlist-grid { gap: 12px; }
.swipe-shell { border-radius: 14px; }
.wish-card { grid-template-columns: 104px minmax(0,1fr); min-height: 142px; border-radius: 14px; background: var(--box-surface); border-color: var(--box-line); }
.wish-image[class] { background: var(--box-placeholder); }
.wish-image .fallback-icon { color: var(--box-muted); font-size: 26px; opacity: .55; }
.wish-image img { object-fit: contain; }
.wish-copy { position: relative; padding: 12px; }
.wish-heading { display: block; margin: 0; padding-right: 30px; }
.wish-title { margin: 0; font-size: 15px; line-height: 1.4; font-weight: 550; }
.title-open { min-height: 44px; }
.wish-meta { margin: 3px 0 6px; color: var(--box-muted); font-size: 12px; text-transform: none; letter-spacing: 0; }
.wish-price { margin: 0; font-size: 17px; font-weight: 600; }
.wish-price.price-missing { font-size: 14px; font-weight: 400; color: var(--box-muted); }
.priority-badge { padding: 4px 6px; margin: 0; font-size: 10px; }
.card-menu > summary { position: absolute; top: 4px; right: 2px; }
.card-menu > .wish-actions { margin-top: 12px; padding-top: 8px; border-top: 1px solid var(--box-line); }
.card-menu:not([open]) > .wish-actions { display: none; }
.card-menu .wish-actions button,.card-menu .wish-actions select { background: var(--box-surface); color: inherit; border-color: var(--box-line); }
.card-processing { margin: 4px 0; padding: 0; background: transparent; border: 0; color: var(--box-muted); font-size: 12px; }
.processing-failed { color: #d36a79; }
.card-price-trend,.card-deal { font-size: 12px; font-weight: 400; }
.app-shell { padding-bottom: calc(156px + env(safe-area-inset-bottom)); }
.bottom-nav { bottom: 0; width: min(100%,760px); height: 56px; padding-bottom: env(safe-area-inset-bottom); border-radius: 0; border: 0; border-top: 1px solid var(--box-line); background: var(--box-surface); box-shadow: none; }
.bottom-nav button { min-height: 44px; font-weight: 500; font-size: 12px; }
.bottom-nav button[aria-current="page"] { color: var(--box-accent); }
.bottom-nav button span { font-size: 18px; }
.chat-composer { bottom: calc(56px + env(safe-area-inset-bottom)); width: min(100%,760px); box-sizing: border-box; padding: 5px 12px 8px; border: 0; border-radius: 0; background: var(--box-surface); box-shadow: 0 -6px 20px #00000008; }
.capture-destination { margin: 0 4px 3px; color: var(--box-muted); font-size: 12px; line-height: 16px; white-space: normal; overflow-wrap: anywhere; }
.add-input-row { min-height: 44px; padding: 2px; }
.composer-attachment,.send-link,.paste-link,.clear-link { min-width: 44px; min-height: 44px; }
.add-form input[name="url"] { min-width: 0; height: 44px; padding-left: 6px; }
.chat-composer:focus-within { bottom: max(0px,env(safe-area-inset-bottom)); }
.app-shell:has(.chat-composer:focus-within) .bottom-nav { visibility: hidden; }
.edit-preview { display: none; }
.edit-section { padding: 4px 2px; border: 0; background: transparent; gap: 12px; }
.edit-dialog .dialog-scroll { gap: 12px; padding: 4px 16px 16px; }
.edit-details-body { display: grid; gap: 12px; }
.edit-dialog .collection-option span { min-height: 44px; }
.edit-dialog .dialog-footer button { text-transform: none; }
.edit-dialog .price-history { margin: 0; }
.edit-dialog .deal-search { border: 0; padding: 0; }
.edit-dialog .dialog-actions { margin: 0; }
.notifications-panel { border: 0; background: transparent; padding: 8px 0; }
.notifications-panel h2 { margin: 0 0 8px; font-size: 18px; }
.settings-link { min-height: 44px; padding: 0; border: 0; background: none; color: var(--box-accent); font-size: 14px; }
.profile-shortcuts { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 20px 12px; }
.profile-shortcuts button,.profile-tools > button { min-height: 44px; padding: 8px 14px; border: 1px solid var(--box-line); border-radius: 10px; background: var(--box-surface); color: inherit; font-size: 14px; }
.profile-account { margin: 0 20px; }
.profile-tools { display: grid; gap: 10px; margin: 12px 0 0; padding: 0 20px 24px; }
.settings-group { min-width: 0; border: 1px solid var(--box-line); border-radius: 12px; padding: 0 12px; }
.settings-group > summary { display: flex; align-items: center; justify-content: space-between; min-height: 48px; list-style: none; font-size: 14px; font-weight: 500; cursor: pointer; }
.settings-group > summary::after { content: '＋'; color: var(--box-muted); }
.settings-group > button { width: 100%; min-height: 44px; margin-bottom: 8px; padding: 8px 12px; border: 1px solid var(--box-line); border-radius: 9px; background: var(--box-surface); color: var(--box-accent); font-size: 14px; }
.settings-group .notification-switches label { min-height: 44px; }
.settings-group[open] > summary::after { content: '−'; }
.settings-group > section,.settings-group > .stats-hero { margin: 0 0 12px; padding: 12px; }
.settings-group .stats-hero { background: transparent; border: 0; color: inherit; }
.settings-group .stats-hero strong { font-size: 26px; }
.settings-group .profile-form { padding: 0 0 12px; }
.welcome-shell { padding: 24px; }
.welcome-shell h2 { margin-top: 24px; font-size: 26px; }
.welcome-lead { font-size: 16px; line-height: 1.5; }
.welcome-start { margin-top: 20px; }
.welcome-note { margin-top: 14px; }
button:focus-visible,summary:focus-visible,select:focus-visible,input:focus-visible { outline: 2px solid var(--box-accent); outline-offset: 3px; }
@media (max-width: 680px) {
  .app-header { padding-left: 16px; padding-right: 16px; }
  .app-content { padding-left: 16px; padding-right: 16px; }
  .wish-card { grid-template-columns: 96px minmax(0,1fr); }
  .profile-shell { overflow-y: auto; }
}
@media (max-width: 360px) { .wish-card { grid-template-columns: 80px minmax(0,1fr); } .wish-copy { padding: 10px; } }

/* BBB-UX-002: two primary organization actions replace the composer. */
[data-selection-toolbar] { display: flex; justify-content: flex-end; }
[data-selection-start] { min-height: 44px; padding: 0 12px; background: transparent; color: var(--box-accent); border: 0; font: inherit; }
.list-bulk-actions { position: fixed; z-index: 24; left: 50%; transform: translateX(-50%); bottom: calc(56px + env(safe-area-inset-bottom)); width: min(100%,760px); box-sizing: border-box; margin: 0; padding: 12px 16px; display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; border: 0; border-top: 1px solid var(--box-line); border-radius: 0; background: var(--box-surface); box-shadow: 0 -6px 20px #0001; }
.list-bulk-actions strong { grid-column: 1; grid-row: 1; color: inherit; font-weight: 500; }
.list-bulk-actions button { min-height: 44px; background: var(--box-surface); color: inherit; border-color: var(--box-line); font-size: 15px; }
.list-bulk-actions [data-selection-all] { grid-column: 2; grid-row: 1; border: 0; color: var(--box-muted); }
.list-bulk-actions .bulk-cancel { grid-column: 3; grid-row: 1; width: 44px; }
.list-bulk-actions [data-organize-people] { grid-column: 1; grid-row: 2; }
.list-bulk-actions [data-organize-lists] { grid-column: 2/4; grid-row: 2; }
.organize-dialog { width: min(440px,calc(100% - 24px)); max-height: 85dvh; box-sizing: border-box; background: var(--box-surface); color: inherit; }
.organize-dialog form { display: grid; gap: 12px; min-width: 0; }
.organize-dialog header { display: flex; align-items: center; justify-content: space-between; }
.organize-dialog h2 { margin: 0; font-size: 22px; }
.organize-dialog p { color: var(--box-muted); margin: 0; font-size: 14px; }
.organize-dialog button { min-height: 44px; padding: 8px 16px; background: var(--box-surface); color: inherit; border: 1px solid var(--box-line); border-radius: 10px; }
.organize-options { display: grid; gap: 4px; }
.organize-options label { display: flex; gap: 12px; align-items: center; min-height: 48px; padding: 0 8px; border-bottom: 1px solid var(--box-line); overflow-wrap: anywhere; }
.organize-options input { width: 22px; height: 22px; flex: 0 0 22px; accent-color: var(--box-accent); }
[data-organize-new] { display: grid; gap: 8px; font-size: 14px; }
[data-organize-new] input { box-sizing: border-box; width: 100%; min-width: 0; min-height: 44px; font-size: 16px; padding: 8px; background: var(--box-surface); color: inherit; border: 1px solid var(--box-line); border-radius: 8px; }
.organize-dialog .organize-error { color: #c84959; }
.organize-dialog [data-organize-apply] { color: var(--box-accent); font-weight: 600; }
.collection-context { flex-wrap: wrap; }
.collection-context button { min-height: 44px; }
.collection-settings { max-width: 100%; min-width: 0; }
.collection-settings summary { min-width: 44px; min-height: 44px; display: grid; place-items: center; cursor: pointer; }
.collection-settings:not([open]) > :not(summary) { display: none; }
.collection-settings input { box-sizing: border-box; max-width: 100%; }
