:root {
  color-scheme: light;
  --page: #eef2f6;
  --phone: #f7f9fb;
  --surface: #ffffff;
  --soft: #edf1f4;
  --text: #17212b;
  --sub: #66727f;
  --line: #dbe1e6;
  --green: #76bb40;
  --green-ink: #17212b;
  --red: #d84455;
  --pink: #ed5f9b;
  --blue: #2d9aff;
  --yellow: #b77a00;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic UI", sans-serif;
  background: var(--page);
  color: var(--text);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--page); }
body { min-width: 320px; }
button, input, select, textarea { font: inherit; }
button { touch-action: manipulation; }

.app-shell {
  width: min(100%, 430px);
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--phone);
  display: flex;
  flex-direction: column;
  position: relative;
}

.app-header {
  min-height: 74px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 11px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  background: color-mix(in srgb, var(--phone) 94%, transparent);
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
}

.app-header h1 { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 21px; font-weight: 600; line-height: 1.15; margin: 0; }
.today-date-title { display: inline-block; min-width: 0; white-space: nowrap; font-size: 15px; line-height: 1.15; letter-spacing: -.02em; }
.today-relative-label { font-size: 18px; font-weight: 700; line-height: 1.1; }
.today-date-separator { line-height: 1; }
.today-date-detail { font-size: 15px; font-weight: 600; line-height: 1.15; }
.app-header.today-header { min-height: 0; padding: calc(8px + env(safe-area-inset-top, 0px)) 12px 6px; align-items: center; gap: 8px; }
.app-header.today-header h1 { display: flex; align-items: baseline; overflow: visible; text-overflow: clip; }
.today-header .header-title { display: flex; align-items: center; }
.today-header .header-actions { min-height: 44px; gap: 2px; }
.today-date-nav { display: inline-flex; flex: 0 0 auto; align-items: center; min-height: 44px; }
.today-header .date-nav-button,
.today-header .header-actions > .icon-button { width: 44px; min-width: 44px; height: 44px; min-height: 44px; padding: 0; display: inline-flex; align-items: center; justify-content: center; }
.today-header .today-jump-button { font-size: 13px; }
.app-header.has-notice { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "title actions" "notice notice"; }
.app-header.has-notice .header-title { grid-area: title; }
.app-header.has-notice .header-actions { grid-area: actions; }
.app-header.has-notice .today-event-notice { grid-area: notice; justify-self: start; }
.calendar-month-button { display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); color: inherit; min-height: 34px; padding: 5px 10px; font: inherit; font-weight: inherit; white-space: nowrap; }
.calendar-month-button::after { content: '▾'; color: var(--sub); font-size: 12px; }
.calendar-month-button:active { background: var(--soft); }
.month-nav-group { display: inline-flex; align-items: center; gap: 0; max-width: 100%; vertical-align: middle; }
.month-nav-group .date-nav-button { flex: 0 0 44px; }
.month-nav-group .calendar-month-button { min-width: 0; font-size: 15px; font-weight: 600; }
.header-title { min-width: 0; flex: 1 1 auto; }
.header-title p { margin: 3px 0 0; color: var(--sub); font-size: 12px; }
.header-actions { display: flex; align-items: center; gap: 2px; flex: 0 0 auto; }
.app-header.has-notice { gap: 4px 10px; }
.app-header.has-notice .header-title { flex: 1 1 auto; }
.today-event-notice { flex: 0 0 auto; align-self: center; height: 32px; min-height: 32px; border: 0; padding: 2px 0; background: transparent; color: var(--text); font-size: 12px; font-weight: 600; white-space: nowrap; }
.today-event-notice span { display: inline-flex; min-height: 28px; align-items: center; border: 1px solid var(--green); border-radius: 99px; padding: 3px 9px; background: color-mix(in srgb, var(--green) 13%, var(--surface)); }
.today-event-notice:active span { background: color-mix(in srgb, var(--green) 23%, var(--surface)); }

.app-main {
  flex: 1;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  padding: 0 16px calc(82px + var(--safe-bottom));
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 10px;
}
.app-main > * { min-width: 0; max-width: 100%; }
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 430px);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 95%, transparent);
  padding: 7px 4px calc(9px + var(--safe-bottom));
  z-index: 20;
  backdrop-filter: blur(14px);
}
.bottom-nav button { border: 0; background: transparent; color: var(--sub); display: grid; gap: 2px; justify-items: center; padding: 3px; font-size: 11px; min-height: 44px; min-width: 0; }
.bottom-nav[hidden] { display: none; }
.materials-toolbar { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; min-width: 0; }
.materials-subtitle { font-size: 15px; }
.materials-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.material-card { position: relative; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; padding: 10px 11px; }
.material-open { min-width: 0; display: grid; grid-template-columns: 72px minmax(0, 1fr); align-items: center; gap: 10px; padding: 0; background: none; border: none; color: inherit; text-align: left; }
.material-thumb { display: grid; place-items: center; width: 72px; height: 76px; color: var(--sub); font-size: 12px; background: var(--soft); border-radius: 6px; }
.material-thumb img { max-width: 100%; max-height: 76px; object-fit: contain; }
.material-title { min-width: 0; overflow-wrap: anywhere; font-size: 14px; }
.material-open .material-title { padding-bottom: 40px; }
.material-badges { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.material-badge { display: inline-block; font-size: 10px; padding: 2px 6px; background: var(--soft); border-radius: 9px; color: var(--sub); }
.material-updated { background: color-mix(in srgb, var(--green) 16%, white); color: var(--text); }
.material-actions { position: absolute; right: 8px; bottom: 6px; display: flex; justify-content: flex-end; gap: 4px; }
.material-actions button { min-width: 44px; min-height: 44px; }
.material-actions button:disabled { opacity: .35; }
.material-actions .material-pin-button { min-width: 38px; padding-inline: 6px; border: 1px solid transparent; border-radius: 8px; }
.material-actions .material-pin-button.material-pin-active { border-color: var(--green); background: color-mix(in srgb, var(--green) 18%, var(--surface)); color: color-mix(in srgb, var(--green) 78%, var(--text)); }
.material-add-preview { max-width: 100%; max-height: 220px; object-fit: contain; justify-self: center; }
.material-viewer { position: fixed; inset: 0; width: 100%; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: #15191e; color: white; }
.material-viewer[open] { display: flex; flex-direction: column; }
.material-viewer header { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: calc(8px + env(safe-area-inset-top, 0px)) 10px 8px; flex: 0 0 auto; }
.material-viewer header strong { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.material-viewer header button { flex: 0 0 auto; min-width: 44px; min-height: 44px; padding: 7px; font-size: 12px; white-space: nowrap; }
.material-viewport { position: relative; flex: 1; min-height: 0; min-width: 0; overflow: hidden; touch-action: none; user-select: none; margin-bottom: env(safe-area-inset-bottom, 0px); }
.material-viewport img { position: absolute; left: 50%; top: 50%; max-width: none; transform-origin: center; pointer-events: none; }
.material-loading { padding: 16px; font-size: 14px; }
.bottom-nav button span:first-child { font-size: 13px; }
.bottom-nav button.is-current { color: var(--green); font-weight: 600; }

.icon-button, .text-button {
  border: 0;
  background: transparent;
  color: var(--text);
  min-height: 40px;
  padding: 7px 8px;
  border-radius: 10px;
}
.icon-button:active, .text-button:active { background: var(--soft); }
.navigation-link { color: var(--sub); white-space: nowrap; }
.date-nav-button { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 4px; border: 0; background: transparent; color: var(--text); border-radius: 10px; font-size: 21px; font-weight: 600; line-height: 1; }
.date-nav-button:active { background: var(--soft); }
.date-nav-button:disabled { color: var(--sub); opacity: .42; }
.nav-chevron { --chevron-size: 16px; --chevron-box-size: 18px; --chevron-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 4l8 8-8 8' fill='none' stroke='black' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); display: inline-block; width: calc(var(--chevron-box-size) / 2); height: var(--chevron-box-size); vertical-align: middle; flex: 0 0 auto; margin-inline-start: 8px; background: currentColor; -webkit-mask: var(--chevron-mask) center / var(--chevron-size) var(--chevron-size) no-repeat; mask: var(--chevron-mask) center / var(--chevron-size) var(--chevron-size) no-repeat; }
.nav-chevron-left { transform: rotate(180deg); }
.date-nav-button > .nav-chevron { --chevron-size: 22px; --chevron-box-size: 24px; width: 24px; margin: 0; }
.month-nav-group:has(#detail-month) { gap: 0; }
.month-nav-group:has(#detail-month) > .date-nav-button { padding-inline: 1px; }
.month-nav-group:has(#detail-month) > .date-nav-button:first-child { justify-content: flex-end; }
.month-nav-group:has(#detail-month) > .date-nav-button:last-child { justify-content: flex-start; }
.text-button:has(> .nav-chevron) { display: inline-flex; align-items: center; column-gap: 8px; }
.text-button > .nav-chevron { margin-inline-start: 0; }
.app-header .text-button:has(.nav-chevron) { column-gap: 6px; min-height: 44px; min-width: 44px; }
.app-header .text-button .nav-chevron { --chevron-size: 18px; --chevron-box-size: 20px; }
.app-header .header-actions:has(.nav-chevron) { gap: 6px; }
.list-row:has(.nav-chevron) { padding-right: 16px; }
.list-row .nav-chevron, .data-management-entry .nav-chevron, .data-management-link .nav-chevron { --chevron-size: 17px; --chevron-box-size: 19px; margin: 0; }
.list-row > :last-child:has(.nav-chevron) { display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.list-row > :last-child:has(.nav-chevron) br { display: none; }
.timer-streamer-link-arrow, .timer-material-arrow { font-size: 0; }
.timer-streamer-link-arrow .nav-chevron { margin-inline-start: 6px; }
.timer-material-arrow .nav-chevron { margin-inline-start: 3px; }
.timer-help-link:has(> .nav-chevron) { column-gap: 6px; }
.today-jump-button { min-width: 38px; padding-inline: 2px; font-size: 13px; }
.primary-button, .secondary-button, .action-button, .danger-button {
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid var(--line);
  padding: 10px 13px;
  color: var(--text);
  background: var(--soft);
}
.primary-button { background: var(--green); border-color: var(--green); color: var(--green-ink); font-weight: 600; }
.action-button { background: color-mix(in srgb, var(--green) 17%, var(--surface)); border-color: color-mix(in srgb, var(--green) 58%, var(--line)); color: var(--text); font-weight: 600; }
.header-action-button { min-height: 36px; padding: 6px 9px; font-size: 13px; white-space: nowrap; }
.primary-button:disabled, .secondary-button:disabled, .action-button:disabled { opacity: .45; }
.danger-button { background: color-mix(in srgb, var(--red) 10%, var(--surface)); border-color: color-mix(in srgb, var(--red) 38%, var(--line)); color: var(--red); }
.block-button { width: 100%; }
.button-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.button-row.three { grid-template-columns: 1fr 1.35fr 1fr; }

.panel, .list {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.today-input-fields { min-width: 0; margin: 0; padding: 0; border: 0; display: grid; gap: 10px; }
.today-input-card.is-locked { background: color-mix(in srgb, var(--soft) 62%, var(--surface)); }
.today-input-card.is-locked .today-input-fields > :not(.button-row), .today-input-card.is-locked .today-input-fields .button-row > :not([data-action="start-timer"]) { opacity: .58; }
.today-input-lock-message { margin: 0; padding: 10px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--sub); font-size: 13px; line-height: 1.45; }
.panel { padding: 13px; }
.data-management-entry { width: 100%; display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; border: 1px solid var(--line); color: var(--text); text-align: left; font: inherit; cursor: pointer; }
.data-management-entry:active { background: var(--soft); }
.data-management-entry-title { font-size: 15px; font-weight: 600; }
.data-management-entry > .sub { grid-column: 1 / -1; }
.data-management-links { display: grid; gap: 4px; min-width: 0; }
.data-management-links > h2 { margin: 0; font-size: 15px; }
.data-management-link { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; min-width: 0; width: 100%; padding: 4px 0; border: 0; border-radius: 0; background: transparent; color: var(--text); text-align: left; font: inherit; font-size: 14px; cursor: pointer; }
.data-management-link + .data-management-link { border-top: 1px solid var(--line); }
.data-management-link > .sub { grid-column: 1 / -1; overflow-wrap: anywhere; }
.data-management-link:active { background: var(--soft); }
.data-management-action { display: grid; gap: 7px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.data-management-action:last-child { padding-bottom: 0; border-bottom: 0; }
.excel-io-actions { display: grid; gap: 7px; min-width: 0; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.excel-io-actions > button { min-width: 0; white-space: normal; overflow-wrap: anywhere; }
.excel-diff-summary p { margin: 3px 0; }
.excel-diff-details, .excel-diff-details li { min-width: 0; overflow-wrap: anywhere; }
.danger-section { border-color: color-mix(in srgb, var(--red) 30%, var(--line)); }
.panel.warning { background: color-mix(in srgb, #ffcc4d 14%, var(--surface)); border-color: #e0ad2f; }
.panel.timer { padding: 8px 12px 5px; background: color-mix(in srgb, var(--green) 11%, var(--surface)); border-color: var(--green); }
.panel.timer { position: relative; }
.timer-color-line { position: absolute; left: 7px; top: 11px; bottom: 13px; width: 6px; border-radius: 3px; pointer-events: none; }
.timer:has(.timer-color-line) .timer-layout { padding-left: 11px; }
.timer-layout { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2px 10px; min-width: 0; }
.timer-main { grid-column: 1; grid-row: 2; display: grid; gap: 2px; min-width: 0; }
.timer-streamer-label { grid-column: 1 / -1; grid-row: 1; display: flex; flex-wrap: wrap; align-items: center; min-width: 0; line-height: 1.35; }
.timer-streamer-name { display: flex; flex: 1 1 150px; align-items: center; min-width: 0; max-width: 100%; }
.timer-streamer-prefix, .timer-streamer-link-arrow { flex: 0 0 auto; white-space: nowrap; }
.timer-card-text-link { color: color-mix(in srgb, var(--text) 68%, var(--sub)); font-weight: 500; -webkit-tap-highlight-color: transparent; }
.timer-card-text-link:active { background: color-mix(in srgb, var(--text) 6%, transparent); opacity: .78; }
.timer-streamer-link { display: inline-flex; flex: 1 1 auto; align-items: center; min-width: 0; min-height: 28px; margin: -4px -2px; padding: 4px 2px; font: inherit; font-weight: 500; line-height: inherit; text-align: left; }
.timer-streamer-link-text { min-width: 0; overflow-wrap: anywhere; white-space: normal; }
.timer-streamer-name .member-badge { flex: 0 0 auto; margin-left: 3px; }
.timer-streamer-meta { display: inline-flex; flex: 0 0 auto; min-width: 0; max-width: 100%; align-items: center; white-space: nowrap; }
.timer-attendance-label { white-space: normal; overflow-wrap: anywhere; }
.timer-cutoff-label { flex: 0 0 auto; white-space: nowrap; }
.timer-material-shortcut { grid-column: 1; grid-row: 3; display: inline-flex; justify-self: start; align-items: center; gap: 3px; min-width: 0; max-width: 100%; min-height: 28px; margin: -2px -3px; padding: 4px 3px; border-radius: 7px; font-size: 11px; line-height: 1.25; text-align: left; }
.timer-material-pin, .timer-material-arrow { flex: 0 0 auto; white-space: nowrap; }
.timer-material-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.timer-start-note { margin: 0; line-height: 1.35; }
.timer-stop-button { grid-column: 2; grid-row: 2; align-self: center; min-height: 44px; white-space: nowrap; }
.timer-details { grid-column: 1 / -1; grid-row: 4; display: grid; gap: 2px; min-width: 0; }
.timer-layout:not(.has-material-shortcut) .timer-details { grid-row: 3; }
.timer-help-link { display: inline-flex; min-height: 26px; max-width: 100%; margin: 0; padding: 2px 0; color: var(--green); font-size: 12px; font-weight: 500; line-height: 1.25; white-space: nowrap; -webkit-tap-highlight-color: transparent; }
.timer-help-link:active { background: color-mix(in srgb, var(--green) 8%, transparent); opacity: .78; }
.timer-help-content { min-width: 0; color: var(--text); font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; }
.timer-help-content p { margin: 0; }
.timer-help-content h3 { margin: 3px 0 -2px; font-size: 15px; }
.timer-help-content ul { display: grid; gap: 8px; margin: 0; padding-left: 1.35em; }
.help-entry-list { display: grid; gap: 8px; min-width: 0; }
.help-guide { display: grid; gap: 20px; min-width: 0; padding-bottom: calc(18px + var(--safe-bottom)); color: var(--text); font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; }
.help-guide-section { display: grid; gap: 8px; min-width: 0; }
.help-guide h2, .help-guide h3 { margin: 0; color: var(--text); }
.help-guide h2 { font-size: 16px; }
.help-guide h3 { font-size: 15px; }
.help-guide p, .help-guide ul { margin: 0; }
.help-guide ul { display: grid; gap: 5px; padding-left: 1.35em; }
.help-guide strong { font-weight: 700; }
.help-guide-primary-action { color: var(--text); font-size: 15px; }
.panel h2, .panel h3 { margin: 0; font-size: 15px; }

.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.row.start { align-items: flex-start; }
.row.wrap { flex-wrap: wrap; }
.stack { display: grid; gap: 10px; }
.sub { color: var(--sub); font-size: 12px; }
.note { color: var(--sub); font-size: 11px; margin: 5px 0 0; }
.section-heading { margin: 5px 0 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.section-heading h2 { margin: 0; font-size: 15px; }
.compact-actions { display: flex; align-items: center; gap: 6px; }
.song-section-heading { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "title manage" "count add"; align-items: center; column-gap: 12px; row-gap: 4px; min-width: 0; max-width: 100%; }
.song-request-section { display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; gap: 14px; margin-top: 27px; min-width: 0; max-width: 100%; }
.song-request-section > * { min-width: 0; max-width: 100%; }
.song-section-heading { margin: 0; }
.song-section-heading > h2 { grid-area: title; min-width: 0; }
.song-section-heading > #song-result-count { grid-area: count; min-width: 0; }
.song-heading-manage { grid-area: manage; min-width: 0; justify-self: end; }
.song-heading-add { grid-area: add; justify-self: end; }
.closing-change-panel, .closing-history, .closing-history-list { display: grid; gap: 8px; }
.streamer-closing-settings { min-width: 0; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); }
.streamer-closing-settings h3 { margin: 0; font-size: 14px; }
.streamer-closing-settings .closing-history { padding: 0; border: 0; background: transparent; }
.streamer-closing-settings [data-closing-effective][hidden] { display: none; }
.streamer-birthday-inputs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.streamer-birthday-inputs .field { min-width: 0; padding-inline: 4px; }
.streamer-birthday-status { display: flex; align-items: center; justify-content: space-between; gap: 4px; min-width: 0; }
.streamer-birthday-status[hidden] { display: none; }
.streamer-birthday-status .text-button { min-height: 28px; padding: 2px 4px; font-size: 11px; }
.closing-history { padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); }
.closing-history-current, .closing-history-heading { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 8px; }
.closing-history-current strong { white-space: nowrap; }
.closing-history-toggle { width: 100%; min-height: 44px; }
.closing-history-heading .text-button { min-height: 44px; padding: 4px 0 4px 8px; white-space: nowrap; }
.closing-history h3, .closing-history p { margin: 0; }
.closing-history-list[hidden] { display: none; }
.closing-history ul { margin: 0; padding-left: 1.25em; font-size: .82rem; color: var(--muted); }
.warning-text { color: #a65900; }
.annual-event-month { display: grid; gap: 5px; margin-top: 14px; }

.progress-value { font-size: 28px; font-weight: 600; }
.progress-track { margin-top: 9px; height: 9px; background: var(--soft); border-radius: 99px; overflow: hidden; }
.progress-bar { height: 100%; background: var(--green); border-radius: inherit; }
.progress-bar.over { background: var(--red); }
.today-heart-summary-card { padding: 11px 13px 10px; }
.today-heart-summary-row { align-items: center; }
.today-heart-status { display: grid; align-content: center; justify-items: end; min-width: 0; line-height: 1.25; text-align: right; }
.today-heart-status > strong { line-height: 1.25; }
.today-heart-status .sub { margin: 2px 0 0; line-height: 1.25; }
.today-heart-summary-card .progress-track { margin-top: 7px; }
.today-heart-summary-card .note { margin-top: 4px; }
.zone { color: var(--red); font-weight: 600; }
.timer-value { font-size: 25px; font-weight: 600; font-variant-numeric: tabular-nums; }
.timer-entered-hearts { margin: 0; padding: 9px 11px; border-radius: 11px; background: color-mix(in srgb, var(--green) 12%, var(--surface)); font-size: 13px; }
.timer-entered-hearts strong { color: var(--green); }
.timer-heart-allocation-summary { display: grid; gap: 3px; margin: 0; font-size: 13px; }
.timer-heart-allocation-summary p { margin: 0; }
.timer-heart-difference-value { font-weight: 700; }
.timer-heart-difference-value.is-different { color: var(--red); }
.quick-detail-summary { display: flex; align-items: center; gap: 7px; min-width: 0; padding: 9px 10px; border-radius: 10px; background: color-mix(in srgb, var(--green) 11%, var(--surface)); font-size: 11px; }
.quick-detail-summary strong { flex: 0 0 auto; color: var(--green); }
.quick-detail-summary span { min-width: 0; overflow-wrap: anywhere; }
.quick-detail-close-note { margin: 2px 0 0; color: var(--sub); font-size: 11px; line-height: 1.45; text-align: left; }
.quick-diary-save-control { display: grid; min-width: 0; }
.quick-diary-save-control > * { grid-area: 1 / 1; }
.quick-diary-save-control.is-recorded > button { visibility: hidden; }
.quick-diary-saved { align-self: center; text-align: center; color: var(--sub); font-size: 14px; }
.quick-diary-saved[hidden] { display: none; }
.quick-diary-save-error { margin: 0; min-width: 0; white-space: pre-line; overflow-wrap: anywhere; }
.quick-detail-date-field { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 8px; }
.quick-detail-date-field input { min-width: 0; width: 100%; }
.manual-viewing-date-preview { overflow-wrap: anywhere; }
.viewing-diary-comparison { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 3px 8px; margin: 8px 0 0; }
.viewing-diary-comparison dd { min-width: 0; margin: 0; }
[data-viewing-diary-warning] { white-space: pre-line; overflow-wrap: anywhere; }
.viewing-date-choice { min-width: 0; padding: 9px; border: 1px solid var(--line); border-radius: 8px; overflow-wrap: anywhere; }
.viewing-date-choice-actions { display: flex; flex-wrap: wrap; gap: 6px; }

.field-group { display: grid; gap: 6px; min-width: 0; }
.field-group label, .field-label { color: var(--sub); font-size: 12px; }
.super-like-input-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 8px; min-width: 0; }
.super-like-wait-group { display: flex; flex-direction: column; align-items: flex-end; align-self: center; justify-items: end; min-width: 0; max-width: 100%; margin-left: auto; color: var(--sub); font-size: 11px; line-height: 1.35; text-align: right; }
.super-like-wait, .super-like-attendance-wait { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.super-like-attendance-wait { font-size: 10px; }
.super-like-attendance-wait { grid-row: 1; }
.tentative-plans { min-width: 0; margin-bottom: 12px; }
.tentative-plans > .section-heading { margin: 0; gap: 8px; }
.tentative-plans h2 { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.tentative-plans [data-add-tentative-plan] { flex: 0 0 auto; margin-left: auto; }
.tentative-plan-month-nav { justify-content: center; gap: 8px; }
.tentative-plan-month-field { row-gap: 0; }
.tentative-plan-list { border-top: 1px solid var(--line); margin-top: 6px; }
.tentative-plan-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 4px 2px; text-align: left; background: transparent; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
.tentative-plan-title { min-width: 0; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; white-space: normal; line-height: 1.25; color: var(--blue); }
.tentative-plan-status { white-space: nowrap; font-size: 11px; }
.super-like-wait { grid-row: 2; }
.super-like-wait-group > [hidden] { display: none; }
.inline-field-note { margin: 0; line-height: 1.45; }
.streamer-archive-option { display: grid; gap: 4px; }
.field-label-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-width: 0; }
.memo-timestamp-button { flex: 0 0 auto; min-height: 32px; border: 1px solid var(--line); border-radius: 9px; padding: 5px 9px; background: var(--soft); color: var(--text); font-size: 11px; white-space: nowrap; }
.field, select.field, textarea.field {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--phone);
  color: var(--text);
  padding: 11px;
  min-height: 44px;
}
textarea.field { min-height: 82px; resize: vertical; }
textarea.field.expanded-memo { min-height: 122px; }
#quick-memo { height: 82px; min-height: 82px; resize: none; }
#quick-memo.is-input-focused:not(:disabled) { height: 158px; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: start; gap: 8px; }
.field-grid > * { min-width: 0; align-self: start; }
.streamer-preference-grid { align-items: start; }
.streamer-preference-grid select.field { height: 44px; }
.quick-streamer-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 8px; }
.quick-streamer-row > * { min-width: 0; }
.quick-streamer-row > .secondary-button { min-width: 66px; }
.quick-streamer-select { position: relative; }
.quick-streamer-select > #quick-streamer { height: 50px; padding: 8px 36px 14px 11px; line-height: 20px; text-overflow: ellipsis; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='18' viewBox='0 0 12 18'%3E%3Cpath d='M2 6l4-4 4 4M2 12l4 4 4-4' fill='none' stroke='%2317212b' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-size: 12px 18px; background-position: right 11px top 12px; }
.quick-streamer-select > .quick-closing-hour { position: absolute; left: 12px; right: 34px; bottom: 2px; height: 15px; color: var(--sub); font-size: 11px; line-height: 15px; text-align: right; white-space: nowrap; pointer-events: none; }
.today-input-card .super-like-input-heading { min-height: 31px; }
.archive-streamer-row { align-items: center; }
.event-import-mapping-row { border: 1px solid transparent; border-radius: 12px; padding: 6px; transition: background-color .15s, border-color .15s; }
.event-import-mapping-row.is-unresolved { background: color-mix(in srgb, var(--red) 8%, var(--surface)); border-color: color-mix(in srgb, var(--red) 48%, var(--line)); }
.event-import-warning { display: grid; gap: 7px; padding: 10px; border: 1px solid color-mix(in srgb, var(--red) 52%, var(--line)); border-radius: 12px; background: color-mix(in srgb, var(--red) 10%, var(--surface)); color: #9d3036; font-size: 13px; line-height: 1.45; }
.event-import-warning[hidden] { display: none; }
.event-import-warning strong { color: var(--red); }
.event-import-warning .secondary-button { justify-self: start; min-height: 36px; padding-inline: 10px; color: #9d3036; border-color: color-mix(in srgb, var(--red) 45%, var(--line)); background: var(--surface); }
.event-import-info { display: grid; gap: 5px; padding: 10px; border: 1px solid color-mix(in srgb, #4c83b4 38%, var(--line)); border-radius: 12px; background: color-mix(in srgb, #4c83b4 9%, var(--surface)); color: #315d84; font-size: 13px; line-height: 1.45; }
.event-import-info[hidden] { display: none; }
.excel-import-error { display: grid; gap: 10px; padding: 12px; border: 1px solid color-mix(in srgb, var(--red) 52%, var(--line)); border-radius: 12px; background: color-mix(in srgb, var(--red) 9%, var(--surface)); color: #9d3036; line-height: 1.5; text-align: left; }
.excel-import-error > strong { color: var(--red); }
.excel-import-error-detail { margin: 3px 0 0; color: var(--text); font: inherit; white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-word; text-overflow: clip; }
.excel-import-error .secondary-button { justify-self: start; }
.time-input-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; }
.dialog-body, .dialog-body > *, .dialog-body .field-group { min-width: 0; max-width: 100%; }
.app-dialog .ios-date-time-field { display: block; inline-size: 100%; width: 100%; min-width: 0; max-width: 100%; overflow: hidden; -webkit-appearance: none; appearance: none; }
.app-dialog .ios-date-time-field::-webkit-date-and-time-value { min-width: 0; text-align: left; }
.color-field { height: 44px; padding: 4px; }
.streamer-color-group, .streamer-birthday { gap: 2px; }
.color-preset-label { min-height: 36px; }
.color-preset-controls { display: grid; grid-template-columns: minmax(0, 1fr) 44px; align-items: center; gap: 4px; min-width: 0; }
.color-preset-controls .color-field { width: 100%; min-width: 0; }
.color-preset-trigger { width: 44px; height: 44px; min-width: 44px; min-height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 8px; background: var(--soft); font-size: 18px; }
.streamer-birthday > label { min-height: 36px; display: flex; align-items: center; }
.color-preset-dialog { overflow-y: auto; overscroll-behavior: contain; }
.color-preset-dialog .dialog-header { grid-template-columns: minmax(0, 1fr); }
.color-preset-dialog .dialog-header > span { display: none; }
.color-preset-dialog .dialog-header h2 { white-space: nowrap; font-size: clamp(15px, 5vw, 19px); }
.color-preset-dialog .dialog-header h2:focus { outline: none; }
.color-preset-body { padding: 0 14px 8px; }
.color-preset-group + .color-preset-group { border-top: 1px solid var(--line); margin-top: 7px; padding-top: 7px; }
.color-preset-group h3 { margin: 0 0 4px; font-size: 13px; color: var(--sub); }
.color-preset-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2px 4px; }
.color-preset-option { min-width: 0; min-height: 60px; padding: 3px 0; display: grid; justify-items: center; align-content: center; gap: 3px; border: 0; background: transparent; color: var(--text); }
.color-preset-swatch { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid #c6c6c6; border-radius: 50%; }
.color-preset-option[aria-pressed="true"] { border-radius: 8px; box-shadow: inset 0 0 0 2px var(--text); }
.color-preset-option:focus:not(:focus-visible) { outline: none; }
.color-preset-option:focus-visible { outline: 3px solid #2673cb; outline-offset: -3px; border-radius: 8px; }
.color-preset-name { font-size: 11px; line-height: 1.2; text-align: center; overflow-wrap: anywhere; }
.event-appearance-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(136px, .9fr); align-items: end; gap: 8px; min-width: 0; }
.event-color-group, .event-display-group { min-width: 0; }
.event-display-group { margin: 0; padding: 0; border: 0; }
.event-display-group legend { margin: 0 0 6px; padding: 0; color: var(--sub); font-size: 12px; }
.event-display-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; min-width: 0; height: 44px; padding: 4px; border-radius: 11px; background: var(--soft); }
.event-display-options label { position: relative; min-width: 0; }
.event-display-options input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.event-display-options span { height: 100%; display: flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 8px; color: var(--sub); font-size: 12px; white-space: nowrap; }
.event-display-options input:checked + span { border-color: var(--line); background: var(--surface); color: var(--text); font-weight: 600; box-shadow: 0 1px 4px rgba(20,35,48,.1); }
.event-display-options input:focus-visible + span { outline: 2px solid var(--green); outline-offset: 1px; }
.duration-picker { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 5px; min-width: 0; }
.duration-picker select { min-width: 0; padding-inline: 7px; text-align: center; font-variant-numeric: tabular-nums; }
.duration-picker > span { color: var(--sub); font-weight: 600; }
.duration-sync-status { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 7px; min-height: 16px; margin-top: 4px; font-size: 11px; line-height: 1.35; }
.duration-sync-status .sub { margin: 0; }
.duration-auto-use-link { min-height: 28px; padding: 2px 0; color: var(--sub); font-size: 11px; line-height: 1.35; white-space: nowrap; text-decoration: underline; text-underline-offset: 2px; }

.heart-control { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: 8px; }
.heart-control button { min-height: 48px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); color: var(--text); font-size: 18px; }
.heart-control .attend { background: var(--green); border-color: var(--green); color: var(--green-ink); font-size: 15px; font-weight: 600; }
.heart-number { text-align: center; font-size: 22px; font-weight: 600; }

.list { overflow: hidden; }
.list-row {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  padding: 11px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
}
.song-drag-handle { flex: 0 0 32px; width: 32px; min-height: 40px; border: 0; border-radius: 8px; background: transparent; color: var(--sub); font-size: 21px; touch-action: none; }
.song-drag-handle:active { background: var(--soft); }
.list-row.is-dragging-song { opacity: .65; background: color-mix(in srgb, var(--green) 12%, var(--surface)); box-shadow: inset 0 2px 0 var(--green); }
.list-row:last-child { border-bottom: 0; }
.list-row:active { background: var(--soft); }
.list-row.is-selected-event-date { background: color-mix(in srgb, var(--green) 10%, var(--surface)); box-shadow: inset 3px 0 0 var(--green); }
.list-row.is-selected-event-date .event-date { color: var(--text); font-weight: 700; }
.list-copy { min-width: 0; flex: 1; }
.diary-date-time-meta { display: block; min-width: 0; white-space: nowrap; }
.diary-list-time-meta { display: block; min-width: 0; }
.diary-list-duration, .diary-list-frame-count, .diary-heart-count { white-space: nowrap; }
.diary-heart-count { flex: 0 0 auto; }
.name { font-weight: 600; }
.check { color: var(--green); }
.diary-attendance-progress { display: inline-block; flex: 0 0 auto; white-space: nowrap; overflow-wrap: normal; }
.favorite { color: var(--yellow); }
.memo-preview { margin: 5px 0 0; font-size: 11px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.song-request-row { position: relative; align-items: center; gap: 5px; padding: 6px 8px 6px 6px; }
.song-tag-bar { align-self: stretch; flex: 0 0 4px; min-height: 52px; border-radius: 99px; background: transparent; }
.song-request-title { min-width: 0; line-height: 1.3; }
.song-request-title .name { display: -webkit-box; min-width: 0; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow-wrap: anywhere; }
.song-request-tags { display: flex; flex-wrap: wrap; align-content: flex-start; width: 100%; min-width: 0; max-width: 100%; max-height: 35px; column-gap: 5px; row-gap: 3px; margin-top: 2px; overflow: hidden; }
.song-request-tag { display: inline-flex; flex: 0 0 auto; width: fit-content; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border: 1px solid color-mix(in srgb, var(--tag-color) 54%, var(--line)); border-radius: 99px; padding: 1px 7px; color: var(--text); background: color-mix(in srgb, var(--tag-color) 13%, var(--surface)); font-size: 9px; line-height: 1.25; }
.song-request-tag-more { flex: 0 0 auto; min-width: 3ch; max-width: none; justify-content: center; overflow: visible; text-overflow: clip; --tag-color: var(--sub); }
.song-request-artist { display: block; margin-top: 1px; color: var(--sub); font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-request-memo { margin: 2px 0 0; color: var(--sub); font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-request-actions { flex: 0 0 70px; width: 70px; display: grid; grid-template-columns: 34px 34px; grid-template-rows: 25px 25px; gap: 1px 2px; align-items: center; }
.song-request-actions:not(.is-reorderable) { flex-basis: 38px; width: 38px; grid-template-columns: 38px; grid-template-rows: 28px; }
.song-request-actions .icon-button, .song-request-actions .text-button { min-width: 0; min-height: 25px; padding: 2px 3px; font-size: 11px; line-height: 1; white-space: nowrap; }
.song-favorite-button { flex: 0 0 40px; width: 40px; min-width: 40px; min-height: 40px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--sub); font-size: 20px; line-height: 1; }
.song-favorite-button.is-favorite { color: var(--yellow); }
.song-tag-manage-link { min-height: 32px; padding: 3px 0 3px 8px; color: var(--sub); font-size: 14px; line-height: 1.2; white-space: nowrap; }
.song-dialog-favorite { display: inline-flex; flex: 0 0 auto; width: auto; min-width: 0; min-height: 40px; align-items: center; justify-content: center; gap: 5px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 99px; background: transparent; color: var(--text); font-size: 14px; line-height: 1; white-space: nowrap; }
.song-dialog-favorite-mark { color: var(--sub); font-size: 18px; line-height: 1; }
.song-dialog-favorite.is-favorite { border-color: color-mix(in srgb, var(--yellow) 72%, #8b6100); background: color-mix(in srgb, var(--yellow) 18%, var(--surface)); }
.song-dialog-favorite.is-favorite .song-dialog-favorite-mark { color: var(--yellow); }
#song-request-specific { display: grid; gap: 12px; margin-top: 12px; }
#song-request-specific .song-dialog-favorite { justify-self: start; margin-bottom: 4px; }
.song-tag-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; max-width: 100%; }
.song-favorite-filter { flex: 0 0 auto; border-color: var(--line); background: transparent; color: var(--text); }
.song-favorite-filter > span:first-child { color: var(--yellow); }
button.song-favorite-filter.is-on { border-color: color-mix(in srgb, var(--yellow) 72%, #8b6100); background: color-mix(in srgb, var(--yellow) 18%, var(--surface)); color: var(--text); }
.song-tag-filter-chip { display: inline-flex; align-items: center; gap: 4px; min-width: 0; max-width: 100%; min-height: 29px; padding: 4px 8px; border: 1px solid color-mix(in srgb, var(--tag-color) 43%, var(--line)); border-radius: 99px; background: transparent; color: var(--text); font-size: 11px; }
.song-tag-filter-chip.is-on, .song-tag-filter-chip:has(input:checked) { border-color: var(--tag-color); background: color-mix(in srgb, var(--tag-color) 26%, var(--surface)); font-weight: 700; }
.song-tag-filter-chip input { position: absolute; opacity: 0; pointer-events: none; }
.song-tag-filter-chip > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-tag-dot { width: 8px; height: 8px; flex: 0 0 8px; border: 1px solid color-mix(in srgb, var(--tag-color) 68%, #65717d); border-radius: 50%; background: var(--tag-color); }
.song-tag-editor-list { display: grid; gap: 7px; }
.song-tag-editor-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 6px; padding: 7px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.song-tag-editor-fields { display: grid; gap: 6px; min-width: 0; }
.song-tag-editor-fields .field { min-height: 38px; padding: 7px 9px; }
.song-tag-editor-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; min-width: 0; }
.song-tag-delete-button { min-height: 30px; width: auto; padding: 4px 8px; font-size: 12px; white-space: nowrap; }
.song-tag-drag-handle { min-width: 28px; min-height: 36px; border: 0; border-radius: 8px; background: transparent; color: var(--sub); font-size: 20px; touch-action: none; }
.song-tag-color-picker { display: grid; gap: 4px; min-width: 0; }
.song-tag-color-label { color: var(--sub); font-size: 12px; }
.song-tag-custom-color-control { position: relative; display: flex; min-width: 0; min-height: 42px; align-items: center; gap: 7px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); font-size: 13px; line-height: 1; cursor: pointer; }
.song-tag-custom-color-control:focus-within { border-color: var(--green); box-shadow: 0 0 0 2px color-mix(in srgb, var(--green) 18%, transparent); }
.song-tag-custom-color-dot { width: 13px; height: 13px; flex: 0 0 13px; border: 1px solid color-mix(in srgb, var(--tag-color) 62%, #59646f); border-radius: 50%; background: var(--tag-color); }
.song-tag-custom-color-control code { min-width: 0; margin-left: auto; color: var(--sub); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; white-space: nowrap; }
.song-tag-native-color-input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; border: 0; opacity: 0; cursor: pointer; }
.song-tag-initial-color-link { justify-self: start; min-height: 28px; padding: 2px 0; border: 0; background: transparent; color: var(--sub); font-size: 12px; white-space: nowrap; }
.song-tag-initial-colors { display: flex; flex-wrap: wrap; gap: 4px; min-width: 0; }
.song-tag-initial-color-option { display: inline-flex; min-width: 0; min-height: 28px; align-items: center; gap: 4px; padding: 3px 7px; border: 1px solid color-mix(in srgb, var(--tag-color) 52%, var(--line)); border-radius: 99px; background: transparent; color: var(--text); font-size: 11px; line-height: 1; white-space: nowrap; }
.song-tag-initial-color-option.is-selected-color { border-color: var(--tag-color); background: color-mix(in srgb, var(--tag-color) 20%, var(--surface)); font-weight: 700; }
.song-tag-order-actions { display: grid; gap: 3px; }
.song-tag-order-actions .icon-button { min-width: 30px; min-height: 29px; padding: 3px; }
.song-master-results { display: grid; gap: 6px; max-height: 280px; overflow: auto; }
.song-master-result-list { display: grid; gap: 5px; }
.song-master-result { display: grid; gap: 2px; width: 100%; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); text-align: left; }
.song-master-result.is-selected { border-color: var(--green); background: color-mix(in srgb, var(--green) 12%, var(--surface)); }
.song-master-result.is-registered { opacity: .7; }
.song-master-result span, .song-master-result em { color: var(--sub); font-size: 11px; font-style: normal; }
.song-master-result small { display: flex; flex-wrap: wrap; gap: 3px; }
.song-master-result small i { border: 1px solid color-mix(in srgb, var(--tag-color) 50%, var(--line)); border-radius: 99px; padding: 1px 4px; background: color-mix(in srgb, var(--tag-color) 13%, var(--surface)); color: var(--text); font-size: 9px; font-style: normal; }
.artist-selection-summary { display: grid; gap: 2px; min-width: 0; padding: 8px 10px; border: 1px solid var(--line); border-radius: 11px; background: var(--soft); }
.artist-selection-summary[hidden] { display: none; }
.artist-selection-summary strong, .artist-selection-summary span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.artist-selection-button { grid-template-columns: minmax(0, 1fr) auto; width: 100%; align-items: center; color: var(--text); text-align: left; font: inherit; cursor: pointer; }
.artist-selection-button > span:first-child { display: grid; gap: 2px; min-width: 0; }
.artist-selection-button .artist-selection-arrow { min-width: auto; overflow: visible; color: var(--sub); font-size: 20px; line-height: 1; }
.artist-selection-button:active { background: color-mix(in srgb, var(--green) 9%, var(--soft)); }
.artist-master-toolbar { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 8px; }
.artist-master-toolbar .header-action-button { flex: 0 0 auto; }
.artist-master-row { min-height: 58px; padding-top: 8px; padding-bottom: 8px; }
.artist-master-edit { flex: 0 0 auto; white-space: nowrap; }
.artist-new-link { justify-self: start; min-height: 32px; padding: 3px 0; color: var(--sub); font-size: 14px; white-space: nowrap; }
.empty-state { text-align: center; padding: 26px 16px; color: var(--sub); }
.empty-state strong { display: block; color: var(--text); margin-bottom: 5px; }
.today-onboarding { display: grid; gap: 12px; min-width: 0; padding: 4px 2px; }
.today-onboarding > strong { color: var(--text); font-size: 15px; }
.today-onboarding-title { text-align: center; }
.today-onboarding-guide { display: grid; gap: 7px; min-width: 0; padding-top: 2px; }
.today-onboarding-guide h2 { margin: 0; font-size: 14px; }
.today-onboarding-steps { display: grid; gap: 5px; color: var(--text); font-size: 13px; line-height: 1.4; }
.today-onboarding-note { margin: 0; color: var(--sub); font-size: 12px; line-height: 1.55; overflow-wrap: anywhere; }
.today-onboarding-help { justify-self: start; min-height: 36px; padding: 4px 0; white-space: nowrap; }

.member-badge { display: inline-flex; width: 45px; height: 18px; align-items: center; justify-content: center; padding: 0; border-radius: 99px; background: linear-gradient(100deg, var(--red), var(--pink), var(--blue)); color: white; font-size: 10px; line-height: 1; font-weight: 600; vertical-align: middle; }
.chip { display: inline-flex; align-items: center; gap: 4px; min-height: 32px; border: 1px solid var(--line); border-radius: 99px; padding: 5px 9px; background: var(--surface); color: var(--sub); font-size: 12px; }
button.chip { color: var(--text); }
.chip.is-on { border-color: var(--green); color: var(--text); }
.toolbar { display: flex; gap: 7px; flex-wrap: wrap; }
.diary-toolbar { --diary-filter-control-height: 34px; flex-wrap: wrap; align-items: center; }
.diary-toolbar #diary-streamer { width: 112px; min-width: 0; height: var(--diary-filter-control-height); min-height: var(--diary-filter-control-height); padding-block: 0; overflow: hidden; text-overflow: ellipsis; }
.diary-month-control { display: inline-flex; min-width: 0; align-items: center; gap: 0; }
.diary-month-picker { width: 94px; min-width: 0; height: var(--diary-filter-control-height); min-height: var(--diary-filter-control-height); justify-content: center; padding-block: 0; padding-inline: 4px; }
.diary-month-nav { flex: 0 0 44px; }
.diary-sort-control { display: inline-flex; gap: 4px; }
.diary-sort-button { width: 28px; min-width: 28px; justify-content: center; padding-inline: 0; font-size: 13px; }
.diary-sort-button.is-on { border-color: var(--green); background: color-mix(in srgb, var(--green) 13%, var(--surface)); color: var(--text); font-weight: 700; }

@media (max-width: 370px) {
  .song-section-heading .compact-actions { width: 100%; justify-content: space-between; }
}
.filter-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.filter-grid .chip { width: 100%; min-width: 0; justify-content: center; padding-inline: 4px; font-size: 11px; white-space: nowrap; overflow: hidden; }
.filter-grid .chip span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.filter-grid .filter-toggle { gap: 2px; }
.filter-toggle.is-on { border-color: var(--green); background: color-mix(in srgb, var(--green) 13%, var(--surface)); color: var(--text); font-weight: 700; }
.filter-toggle-mark { flex: 0 0 auto; color: var(--sub); }
.filter-toggle.is-on .filter-toggle-mark { color: var(--green); }
.filter-grid label.chip { gap: 2px; padding-inline: 2px; font-size: 10px; }
.filter-grid label.chip input[type="checkbox"] { width: 14px; height: 14px; margin: 0; flex: 0 0 14px; }
.record-search-row { padding-block: 9px; }
.record-search-meta { display: flex; align-items: baseline; flex-wrap: wrap; gap: 5px; min-width: 0; }
.record-search-type { color: var(--sub); font-size: 11px; }
.record-search-title { margin-top: 3px; font-size: 13px; font-weight: 600; }
.diary-custom-filter-panel { display: grid; gap: 8px; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.diary-custom-filter-panel h3 { margin: 0; font-size: 15px; }
.diary-custom-filter-panel p { margin: 3px 0 0; }
.coin-allocation-panel { display: grid; gap: 8px; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.coin-allocation-panel[hidden] { display: none; }
.coin-allocation-panel h3 { margin: 0; font-size: 15px; }
.coin-allocation-panel p { margin: 3px 0 0; }
.manual-heart-allocation { display: grid; gap: 8px; margin-top: 10px; padding: 10px; border-radius: 10px; background: var(--bg); }
.manual-heart-allocation p { margin: 0; }
.search-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; min-width: 0; max-width: 100%; }
.search-row > .field { min-width: 0; max-width: 100%; }
#song-title-search { font-size: 16px; }
.hidden-filter { border-color: color-mix(in srgb, var(--red) 42%, var(--line)); color: var(--red); }
.privacy-panel { background: color-mix(in srgb, var(--green) 10%, var(--surface)); border-color: var(--green); }
.version-panel { text-align: center; }
.version-panel p { margin: 5px 0 0; }
.version-panel a { display: inline-block; margin-top: 5px; color: var(--green); font-size: 12px; }
.update-actions { display: grid; gap: 8px; }
.app-update-status { min-height: 18px; margin: 0 !important; }
.app-update-status.is-available { color: var(--text); font-weight: 600; }
.app-update-status.is-success { color: var(--green); font-weight: 600; }
.app-update-status.is-error { color: var(--red); font-weight: 600; }
.version-credits { padding-top: 2px; }
.license-summary-text { font-size: 12px; line-height: 1.5; }
.mini-actions { display: grid; grid-template-columns: 38px 38px auto; align-items: center; gap: 1px; flex: 0 0 auto; }
.mini-actions button:disabled { opacity: .28; }
.filter-editor-list { display: grid; gap: 8px; }
.filter-editor-row { display: grid; grid-template-columns: minmax(0, 1fr) 82px 76px; align-items: center; gap: 6px; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.filter-editor-row > .field, .filter-enabled-control, .filter-order-actions button { height: 44px; min-height: 44px; }
.filter-enabled-control { display: inline-flex; width: 82px; align-items: center; justify-content: center; gap: 3px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); color: var(--sub); font-size: 11px; white-space: nowrap; }
.filter-enabled-control input { width: 15px; height: 15px; margin: 0; flex: 0 0 15px; }
.filter-order-actions { display: grid; grid-template-columns: 37px 37px; gap: 2px; }
.filter-order-actions button { border: 1px solid var(--line); border-radius: 10px; padding: 0; background: var(--soft); color: var(--text); font-size: 12px; }
.filter-order-actions button:disabled { opacity: .28; }

.streamer-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  justify-content: stretch;
  gap: 8px;
}
.streamer-card > * { width: 100%; min-width: 0; }
.streamer-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.streamer-name-row { min-width: 0; overflow-wrap: anywhere; }
.streamer-cutoff-label { flex: 0 0 auto; white-space: nowrap; }
.streamer-active-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 18px; padding: 0 6px; border: 1px solid color-mix(in srgb, var(--green) 45%, var(--line)); border-radius: 99px; background: color-mix(in srgb, var(--green) 13%, var(--surface)); color: var(--green); font-size: 10px; font-weight: 600; line-height: 1; vertical-align: middle; white-space: nowrap; }
.k-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.k-tile { background: var(--soft); border-radius: 9px; text-align: center; padding: 7px 2px; font-size: 11px; line-height: 1.2; }
.k-tile-label { display: block; min-width: 0; white-space: nowrap; }
.k-tile strong { display: block; color: var(--green); margin-top: 3px; font-size: 16px; line-height: 1.15; }
.k-tile-button { border: 0; color: var(--text); font-family: inherit; cursor: pointer; touch-action: manipulation; }
.k-tile-button:active { outline: 2px solid var(--green); background: color-mix(in srgb, var(--green) 13%, var(--soft)); }
.k-tile-edit-mark { display: inline-block; margin-left: 1px; color: var(--sub); font-size: 10px; vertical-align: 1px; }
.pt-card-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 4px 8px; flex-wrap: wrap; margin-bottom: 8px; }
.pt-card-title-group { display: flex; align-items: baseline; gap: 5px; min-width: 0; }
.pt-card-title-group h2 { margin: 0; white-space: nowrap; }
.pt-edit-hint { font-size: 11px; white-space: nowrap; }
.pt-card-priority { flex: 0 0 auto; white-space: nowrap; }

.calendar { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
.weekday { text-align: center; color: var(--sub); font-size: 11px; padding: 4px 0; }
.day { 
  min-width: 0;
  min-height: 64px;
  border: 0;
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  padding: 4px 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
}
.day.empty { background: transparent; }
.day.selected { outline: 2px solid var(--green); background: color-mix(in srgb, var(--green) 11%, var(--surface)); }
.day-number { text-align: center; font-size: 12px; }
.day-data { text-align: center; font-size: 9px; color: var(--sub); line-height: 1.15; white-space: nowrap; overflow: hidden; }
.day-birthdays { display: grid; gap: 2px; min-width: 0; margin-top: auto; }
.day-birthday, .calendar-birthday-detail { box-sizing: border-box; border-left: 3px solid #DAA050; border-radius: 2px; background: rgba(230, 165, 80, 0.10); color: var(--text); }
.day-birthday { display: block; min-width: 0; padding: 1px 1px 1px 2px; font-size: 8.8px; font-weight: inherit; line-height: 1.3; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: clip; }
.calendar-birthday-details { display: grid; gap: 6px; min-width: 0; }
.calendar-birthday-detail { display: flex; align-items: flex-start; gap: 6px; min-width: 0; padding: 7px 9px; font-size: 14px; line-height: 1.5; }
.calendar-birthday-detail > [aria-hidden] { flex: 0 0 auto; }
.calendar-birthday-name { min-width: 0; white-space: normal; overflow-wrap: anywhere; }
.day-event { width: 100%; max-width: 5.5em; margin-inline: auto; box-sizing: border-box; display: block; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; border: 1px solid; border-radius: 4px; padding: 1px 0; font-size: 8.8px; line-height: 1.2; letter-spacing: 0; text-align: left; overflow-wrap: anywhere; word-break: normal; text-wrap: wrap; }
.day-event-unbroken-latin { word-break: break-all; text-wrap: balance; }
.day-event-single { max-height: calc(2.4em + 4px); }
.day-events { width: 100%; min-width: 0; display: grid; justify-items: center; gap: 2px; }
.day-event-compact { display: block; -webkit-line-clamp: unset; line-clamp: unset; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.more-events { font-size: 9px; text-align: center; color: var(--sub); }
.event-dot { width: 10px; height: 10px; box-sizing: border-box; border: 1px solid transparent; border-radius: 50%; flex: 0 0 10px; }
.event-date { flex: 0 0 64px; color: var(--sub); font-size: 11px; font-variant-numeric: tabular-nums; }
.event-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.event-list-memo { display: block; white-space: pre-wrap; overflow-wrap: anywhere; }

.segment { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; border-radius: 11px; background: var(--soft); }
.segment button { border: 0; border-radius: 8px; padding: 8px 4px; background: transparent; color: var(--text); }
.segment button.is-current { background: var(--surface); box-shadow: 0 1px 4px rgba(20,35,48,.1); }
.compact-segment { grid-template-columns: repeat(2, auto); }
.compact-segment button { white-space: nowrap; }
#song-filter-form { gap: 8px; min-width: 0; max-width: 100%; }
.song-filter-subheading { margin-top: 2px; color: var(--sub); font-size: 12px; font-weight: 600; }
.song-clear-filters { min-height: 40px; padding: 7px 12px; background: transparent; color: var(--sub); font-size: 12px; font-weight: 400; }
#song-filter-form > .row.wrap {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
}
#song-filter-form > .row.wrap > .song-favorite-filter { flex: 0 0 100%; }
#song-filter-form > .row.wrap > .sub { flex: 1 1 0; min-width: 0; white-space: normal; }
#song-filter-form > .row.wrap > .compact-segment { flex: 0 0 auto; min-width: 0; }
#song-filter-form > .row.wrap > .text-button { flex: 0 0 auto; min-width: 0; white-space: nowrap; }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.metric { background: var(--soft); border-radius: 11px; padding: 9px; min-width: 0; text-align: center; }
.metric strong { display: block; margin-top: 3px; font-size: 15px; }
.diary-coin-total .coin-value-number, .diary-coin-total .coin-value-unit { white-space: nowrap; }
.route { border-left: 4px solid var(--green); padding-left: 10px; }
.coin-opportunity-detail { display: grid; gap: 5px; padding-top: 9px; border-top: 1px solid var(--line); }
.coin-opportunity-heading { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 8px; font-size: 12px; }
.coin-opportunity-heading span { min-width: 0; color: var(--sub); font-size: 10px; line-height: 1.35; text-align: right; }
.coin-opportunity-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) minmax(0, 1fr); align-items: baseline; gap: 5px; font-size: 11px; line-height: 1.35; }
.coin-opportunity-row span:last-child { color: var(--sub); text-align: right; }
.coin-opportunity-detail > .sub { margin: 0; }
.coin-opportunity-note, .recording-input-note { margin: 0; color: var(--sub); font-size: 10px; line-height: 1.45; }
.coin-opportunity-alerts { display: grid; gap: 3px; padding: 7px 9px; border-radius: 10px; background: color-mix(in srgb, #ffcc4d 15%, var(--surface)); color: var(--text); font-size: 11px; line-height: 1.35; }
.monthly-song-target-row { display: grid; grid-template-columns: auto minmax(0, 100px) auto auto; align-items: center; justify-content: start; gap: 6px; min-width: 0; margin: 0; }
.monthly-song-target-row > label, .monthly-song-target-row > span { white-space: nowrap; font-size: 13px; }
.monthly-song-target-row .field { min-width: 0; height: 44px; padding: 5px 7px; text-align: center; }
.monthly-song-target-row > button { min-height: 44px; padding: 5px 10px; font-size: 13px; white-space: nowrap; }
.pt-update-warning { display: inline-flex; align-items: center; margin-left: 3px; color: #bd8a17; font-size: 12px; vertical-align: middle; }
.pt-update-notice { width: 100%; border: 1px solid #e0ad2f; border-radius: 10px; padding: 8px 10px; color: var(--text); background: color-mix(in srgb, #ffcc4d 15%, var(--surface)); font: inherit; font-size: 12px; line-height: 1.4; text-align: left; cursor: pointer; }
.song-badge { display: inline-flex; align-items: center; border-radius: 99px; padding: 5px 10px; color: white; font-size: 12px; font-weight: 600; }
.streamer-card .song-badge, [data-diary-id] .song-badge { height: 18px; padding: 0 7px; font-size: 10px; line-height: 1; vertical-align: middle; }
.app-settings-group { gap: 0; }
.app-settings-group > div:first-child { padding-bottom: 12px; }
.settings-subsection { min-width: 0; display: grid; gap: 10px; padding: 14px 0; border-top: 1px solid var(--line); }
.settings-subsection > div > .sub { margin: 4px 0 0; line-height: 1.45; }
.accent-control { display: grid; grid-template-columns: 48px minmax(92px, 1fr) auto; align-items: center; gap: 7px; min-width: 0; }
.accent-control .color-field { width: 48px; }
.accent-reset { min-height: 44px; padding-inline: 10px; font-size: 12px; white-space: nowrap; }
.setting-choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.setting-choice { min-width: 0; min-height: 48px; display: flex; align-items: center; gap: 7px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-size: 13px; }
.setting-choice:has(input:checked) { border-color: var(--green); background: color-mix(in srgb, var(--green) 11%, var(--surface)); }
.setting-choice input { flex: 0 0 auto; margin: 0; accent-color: var(--green); }
.setting-choice span { min-width: 0; }
.setting-choice.tentative-title-inline { padding-block: 4px; }
.tentative-title-toggle { display: flex; align-items: center; gap: 7px; flex: 0 0 auto; min-height: 44px; white-space: nowrap; }
.tentative-title-inline > .field { flex: 1 1 0; width: 0; min-width: 0; font-size: 16px; }
.coin-opportunity-setting { width: 100%; }
.coin-opportunity-settings { display: grid; gap: 0; padding: 4px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); }
.coin-opportunity-settings .setting-choice { min-height: 38px; padding: 4px 0; border: 0; background: transparent; }
.coin-opportunity-settings .setting-choice:has(input:checked) { background: transparent; }
.coin-notice-setting-group { display: grid; gap: 0; }
.coin-notice-thresholds { display: grid; gap: 3px; min-width: 0; margin: -1px 0 3px 24px; padding: 3px 0 1px 10px; border: 0; border-left: 2px solid var(--line); }
.coin-notice-thresholds:disabled { opacity: .48; }
.coin-notice-thresholds label { display: grid; grid-template-columns: minmax(5.5em, 1fr) 8ch auto; align-items: center; gap: 8px; min-width: 0; font-size: 13px; }
.coin-threshold-input { width: 8ch; min-width: 0; min-height: 34px; padding: 5px 7px; text-align: right; }
.settings-save-action { display: grid; gap: 7px; padding-top: 14px; border-top: 1px solid var(--line); }
.settings-unsaved-status { margin: 0; color: var(--yellow); font-size: 12px; font-weight: 600; text-align: center; }
.backup-export-option { display: grid; gap: 8px; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); }
.backup-export-option h3 { margin: 0; font-size: 14px; }
.backup-export-option p { margin: 4px 0 0; line-height: 1.5; }

.viewing-times-panel { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.viewing-time-panel-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; padding: 12px 12px 8px; }
.viewing-time-panel-header h3 { margin: 0; font-size: 15px; }
.viewing-time-panel-header p { margin: 3px 0 0; }
.viewing-time-add { min-height: 36px; padding: 7px 10px; white-space: nowrap; }
.viewing-time-row { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px; padding: 11px 12px; border: 0; border-top: 1px solid var(--line); background: transparent; color: var(--text); text-align: left; }
.viewing-time-row:disabled { opacity: .45; }
.viewing-time-range { min-width: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.viewing-time-total { color: var(--sub); font-size: 12px; font-variant-numeric: tabular-nums; }
.viewing-time-arrow { color: var(--sub); font-size: 20px; }
.viewing-time-empty { margin: 0; padding: 11px 12px; border-top: 1px solid var(--line); color: var(--sub); font-size: 12px; }
.viewing-time-summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-top: 1px solid var(--line); background: var(--soft); }
.viewing-time-summary strong { font-variant-numeric: tabular-nums; }
.viewing-time-editor { display: grid; gap: 9px; padding: 11px 12px; border-top: 1px solid var(--line); background: color-mix(in srgb, var(--green) 5%, var(--surface)); }
.viewing-time-editor p { margin: 0; }
.viewing-time-editor-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; min-width: 0; }
.viewing-time-editor-grid > * { min-width: 0; }
.viewing-time-editor-actions { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.35fr) minmax(0, 1.1fr) minmax(0, 1fr); align-items: center; gap: 7px; }
.viewing-time-editor-actions button { min-width: 0; height: 44px; min-height: 44px; padding: 6px 4px; font-size: 12px; line-height: 1; white-space: nowrap; }
[data-zero-input].is-zero-value { color: var(--sub); }
[data-zero-input]::placeholder { color: var(--sub); opacity: 1; }

.app-dialog { width: min(calc(100% - 24px), 410px); max-height: calc(100dvh - 24px); border: 0; border-radius: 22px; padding: 0; color: var(--text); background: var(--phone); box-shadow: 0 20px 50px rgba(20,35,48,.25); }
.app-dialog::backdrop { background: rgba(17, 24, 31, .42); backdrop-filter: blur(2px); }
.confirm-dialog { width: min(calc(100% - 48px), 360px); }
.confirm-dialog-body { padding-top: 22px; padding-bottom: 22px; }
.confirm-dialog-body p { margin: 0; text-align: center; font-weight: 700; }
.confirm-dialog-body p.is-left-aligned { text-align: left; white-space: pre-line; }
.dialog-header { position: sticky; top: 0; z-index: 1; background: var(--phone); display: grid; grid-template-columns: minmax(72px, 1fr) minmax(0, auto) minmax(72px, 1fr); align-items: center; gap: 8px; padding: 14px 14px 9px; }
.dialog-header h2 { min-width: 0; margin: 0; font-size: 19px; text-align: center; }
.dialog-header > :first-child { justify-self: start; }
.dialog-body { padding: 0 14px 14px; display: grid; gap: 10px; }
.dialog-footer { position: sticky; bottom: 0; background: var(--phone); padding: 9px 14px calc(14px + var(--safe-bottom)); display: grid; grid-template-columns: 1fr 1.7fr; gap: 8px; }
.dialog-footer-single { grid-template-columns: 1fr; }
.dialog-save-error { grid-column: 1 / -1; min-width: 0; margin: 0; color: var(--red); font-size: 14px; line-height: 1.5; white-space: normal; overflow-wrap: anywhere; }
.dialog-save-error[hidden] { display: none; }
.song-master-delete-area { display: grid; justify-items: start; gap: 6px; padding-top: 4px; }
.song-master-delete-area .sub { margin: 0; }
.duplicate-streamer-review { display: grid; min-width: 0; }
.duplicate-streamer-review .dialog-header { grid-template-columns: minmax(0, 1fr); }
.duplicate-streamer-review .dialog-header > span { display: none; }
.duplicate-streamer-review .dialog-header h2 { overflow-wrap: anywhere; }
.duplicate-streamer-list { gap: 9px; }
.duplicate-streamer-card { display: grid; gap: 8px; min-width: 0; padding: 11px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); }
.duplicate-streamer-heading { display: grid; gap: 2px; min-width: 0; }
.duplicate-streamer-heading strong { overflow-wrap: anywhere; }
.duplicate-streamer-flags { display: flex; flex-wrap: wrap; gap: 5px; color: var(--sub); font-size: 11px; }
.duplicate-streamer-flags span { padding: 2px 6px; border-radius: 99px; background: var(--soft); }
.duplicate-streamer-card dl { display: grid; gap: 3px; margin: 0; font-size: 12px; }
.duplicate-streamer-card dl div { display: grid; grid-template-columns: 5em minmax(0, 1fr); gap: 7px; }
.duplicate-streamer-card dt { color: var(--sub); }
.duplicate-streamer-card dd { min-width: 0; margin: 0; }
.duplicate-streamer-actions { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 7px; }
.duplicate-streamer-actions button { min-width: 0; }
.duplicate-review-footer { grid-template-columns: minmax(0, .8fr) minmax(0, 1.7fr); }

.toast { position: fixed; left: 50%; bottom: calc(76px + var(--safe-bottom)); transform: translate(-50%, 16px); background: var(--text); color: var(--surface); padding: 9px 13px; border-radius: 10px; opacity: 0; pointer-events: none; transition: .2s; z-index: 100; white-space: nowrap; max-width: calc(100% - 28px); overflow: hidden; text-overflow: ellipsis; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.live-heart-status { position: fixed; z-index: 30; left: 50%; bottom: calc(120px + var(--safe-bottom)); transform: translateX(-50%); width: max-content; max-width: min(406px, calc(100vw - 24px)); padding: 7px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--sub); font-size: 12px; line-height: 1.5; pointer-events: none; overflow-wrap: anywhere; }
.live-heart-status.is-warning { z-index: 101; width: min(406px, calc(100vw - 24px)); overflow-y: auto; overscroll-behavior: contain; color: #a65900; border-color: #d4a771; font-size: 13px; pointer-events: auto; }
.live-heart-status.is-warning > span { display: block; }
.live-heart-status .text-button { color: inherit; min-height: 44px; }

@media (min-width: 431px) {
  .app-shell { box-shadow: 0 0 0 1px var(--line), 0 18px 50px rgba(20,35,48,.12); }
}

@media (max-width: 430px) {
  .event-date-time-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 389px) {
  .app-header.today-header,
  .app-header.today-header.has-notice {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 44px;
    grid-template-areas: "title settings" "nav nav";
    align-items: center;
    gap: 0 8px;
    padding-top: calc(6px + env(safe-area-inset-top, 0px));
    padding-bottom: 4px;
  }
  .app-header.today-header.has-notice { grid-template-areas: "title settings" "nav nav" "notice notice"; }
  .today-header .header-title { grid-area: title; }
  .today-header .header-actions { display: contents; }
  .today-header .today-date-nav { grid-area: nav; justify-self: center; margin-block: -5px -3px; }
  .app-header.today-header.has-notice .today-date-nav { margin-bottom: 0; }
  .app-header.today-header.has-notice .today-event-notice { margin-top: 2px; }
  .today-header .header-actions > .icon-button { grid-area: settings; justify-self: end; }
  .today-header .today-event-notice { grid-area: notice; justify-self: start; }
}

@media (max-width: 350px) {
  .app-main { padding-inline: 12px; }
  .app-header { padding-inline: 12px; }
  .field-grid { gap: 6px; }
  .filter-grid label.chip { gap: 1px; padding-inline: 1px; font-size: 9px; }
  .filter-grid label.chip input[type="checkbox"] { width: 12px; height: 12px; flex-basis: 12px; }
  .calendar { gap: 2px; }
  .day { min-height: 55px; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
.membership-details { padding: 12px; border: 1px solid #d9e3dc; border-radius: 14px; background: #f5f8f6; gap: 10px; }
.membership-details h3 { margin: 0 0 2px; }
.membership-pass-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(90px, 1fr); align-items: center; gap: 12px; }
.membership-details[hidden] { display: none; }
.membership-details, .membership-pass-row > *, .membership-note { min-width: 0; }
.membership-note { overflow-wrap: anywhere; margin: 6px 0; line-height: 1.5; }
.coin-conversion-panel { padding-bottom: 9px; }
.coin-conversion-panel > p.sub:not(.membership-note) { margin: 0; }
.coin-conversion-panel .membership-note { margin: -6px 0 -5px; line-height: 1.35; }
.membership-selection { margin: 2px 0 0; padding-top: 9px; border-top: 1px solid #d9e3dc; line-height: 1.4; }
.membership-reference-note { margin: 2px 0 0; font-size: 11px; line-height: 1.35; font-weight: 400; opacity: .82; }

/* Supplementary text links retain their existing layout boxes and hit areas. */
.today-onboarding-help .nav-chevron, .timer-card-text-link .nav-chevron, .timer-help-link .nav-chevron, [data-action="edit-period"] .nav-chevron, [data-action="edit-filter-definitions"] .nav-chevron, [data-action="edit-filters"] .nav-chevron, [data-action="manage-song-masters"] .nav-chevron, .song-tag-manage-link .nav-chevron, [data-material-manage] .nav-chevron, [data-action="annual-events"] .nav-chevron, [data-action="artist-masters"] .nav-chevron, [data-duplicate-detail] .nav-chevron { --chevron-size: 14px; --chevron-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 4l8 8-8 8' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }

[data-action="favorite-filter"].is-on { border-color: var(--green); background: color-mix(in srgb, var(--green) 13%, var(--surface)); color: var(--text); }
[data-action="favorite-filter"].is-on .streamer-favorite-mark { color: var(--green); }

.streamer-filter-group { display: grid; gap: 6px; min-width: 0; }
.streamer-filter-group > [data-action="edit-filters"] { justify-self: start; }
.streamer-card { gap: 6px; padding-block: 10px; }
.streamer-card .k-tile { padding-block: 5px; }

#dialog-form:has(#filter-editor-list) .dialog-header { grid-template-columns: minmax(44px, 1fr) minmax(0, auto) minmax(44px, 1fr); }
#dialog-form:has(#filter-editor-list) .dialog-header h2 { white-space: nowrap; font-size: 17px; }

.streamer-display-toolbar { column-gap: 0; }
.streamer-display-toolbar > .chip { padding-inline: 1px; }

.streamer-display-toolbar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.streamer-display-toolbar > .chip { box-sizing: border-box; width: 100%; min-width: 0; height: 38px; min-height: 38px; padding-inline: 2px; justify-content: center; font-size: 10px; }
.streamer-month-compact { position: relative; overflow: hidden; }
.streamer-month-compact input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.001; cursor: pointer; }
.streamer-month-compact:focus-within { outline: 2px solid var(--green); outline-offset: 2px; }

@media (min-width: 410px) { .streamer-display-toolbar > .chip { font-size: 11px; } }
@media (min-width: 430px) { .streamer-display-toolbar > .chip { font-size: 12px; } }

.streamer-display-toolbar > select.chip { -webkit-appearance: none; appearance: none; padding-left: 5px; padding-right: 15px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 12'%3E%3Cpath d='M1 5L4 2l3 3M1 7l3 3 3-3' fill='none' stroke='%23646f69' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 5px center; background-size: 8px 12px; }

/* Ratios derive from the measured widest labels plus group/padding allowances. */
.streamer-display-toolbar { grid-template-columns: minmax(0, 61fr) minmax(0, 71fr) minmax(0, 43fr) minmax(0, 68fr); }
.streamer-select-compact { position: relative; }
.streamer-select-group { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; pointer-events: none; }
.streamer-choice-arrows { flex: 0 0 8px; width: 8px; height: 12px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 12'%3E%3Cpath d='M1 5L4 2l3 3M1 7l3 3 3-3' fill='none' stroke='%23646f69' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 8px 12px no-repeat; }
.streamer-select-compact > select.chip { position: absolute; inset: 0; box-sizing: border-box; width: 100%; min-width: 0; height: 100%; margin: 0; padding: 0; opacity: 0.001; -webkit-appearance: none; appearance: none; background-image: none; cursor: pointer; }
.streamer-select-compact:focus-within { outline: 2px solid var(--green); outline-offset: 2px; }

/* v149: these rules apply only to the three requested screens. */
.app-settings-group .settings-subsection { gap: 7px; padding-block: 8px; }
.app-settings-group .settings-subsection > div > .sub { margin-top: 3px; }
.app-settings-group .settings-subsection > h3 + .sub { margin: -4px 0 1px; }
#app-dialog:has(.quick-detail-close-note) .dialog-header h2:focus { outline: none; }
#record-search-form { gap: 0; }
#record-search-form > .note { margin: 6px 0 16px; }
#record-search-form > .field-group { gap: 7px; margin-bottom: 12px; }

.super-like-wait-notice { font-size: 10px; overflow-wrap: anywhere; max-width: 100%; }

.timer-start-notice { margin: 10px 0; padding: 10px 12px; border: 1px solid #e1ce88; border-radius: 10px; background: #fff8df; color: #654f19; white-space: pre-line; overflow-wrap: anywhere; line-height: 1.6; text-align: left; }
.timer-start-notice[hidden] { display: none; }

.version-panel .app-build { font-size: 11px; margin-top: 4px; overflow-wrap: anywhere; }

/* Isolated stage-1 diagnostic UI. */
.unsaved-diagnostics { min-width:0; }
.unsaved-diagnostics summary { cursor:pointer; min-height:44px; display:list-item; padding-block:10px; }
.unsaved-diagnostic-item { margin-top:12px; padding-top:10px; border-top:1px solid var(--line); overflow-wrap:anywhere; }
.unsaved-diagnostic-item p { text-align:left; margin-block:6px; }
.draft-protection-status { overflow-wrap:anywhere; white-space:normal; margin-block:6px 0; }

#quick-detail-coins[readonly] { background: var(--soft); color: var(--sub); cursor: text; }
.quick-coin-allocation-note { margin: 6px 0 0; line-height: 1.6; overflow-wrap: anywhere; text-align: left; }
