/* Shared styles for editable media and a concise, non-transcript incident register. */
.map-actions { display: flex; gap: 6px; }
.media-item { position: relative; }
.media-item .delete-media { position: absolute; top: 7px; right: 7px; width: 32px; height: 32px; border: 0; border-radius: 50%; background: #17231dcc; color: #fff; font-size: 21px; line-height: 1; }
.incident-record { padding: 13px 0; border-bottom: 1px solid #e7ebe5; }
.incident-record-heading { display: flex; justify-content: space-between; align-items: center; gap: 9px; }
.incident-record-heading strong { font-size: 13px; }
.incident-record time { display: block; margin-top: 5px; color: #77817a; font-size: 11px; }
.incident-record p { margin: 8px 0 0; font-size: 12px; line-height: 1.5; white-space: pre-wrap; }
.password-control { position: relative; display: block; }
.password-control input { padding-right: 50px !important; }
.password-visibility { position: absolute; top: 50%; right: 8px; display: grid; place-items: center; width: 36px; height: 36px; padding: 7px; transform: translateY(-50%); border: 0; border-radius: 8px; background: transparent; color: #526057; }
.password-visibility:hover { background: #eaf0e8; }
.password-visibility svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.auth-switch { display: block; width: 100%; margin: 8px 0 0; padding: 8px 0; text-align: left; color: #315b42; font-size: 13px; }
.login-help { margin: 5px 0 0; border-radius: 9px; background: #f1f4ef; padding: 10px 12px; color: #526057; font-size: 13px; line-height: 1.5; }
.join-code-controls { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.join-code-controls code { display: inline-block; min-width: 170px; border: 1px solid #dfe5de; border-radius: 8px; background: #f1f4ef; padding: 10px 12px; color: #173d31; font-size: 17px; font-weight: 700; letter-spacing: .12em; }
.login-brand { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 auto 9px; color: #173d31; }
.login-brand img { display: block; width: 56px; height: 56px; object-fit: contain; }
.login-brand span { font: 800 32px/1 Manrope, sans-serif; letter-spacing: -.045em; }
.login-subtitle { margin: 0 0 20px; color: #65736a; text-align: center; font-size: 14px; line-height: 1.45; }

/* Mobile-first legibility pass: keep controls comfortable for use in the field. */
@media (max-width: 700px) {
  .topbar {
    height: auto;
    min-height: 96px;
    flex-basis: auto;
    flex-wrap: wrap;
    gap: 7px;
    padding: 8px 15px;
  }
  .brand-button { gap: 8px; }
  .topbar-logo { width: 40px; height: 40px; object-fit: contain; }
  .brand-name { font: 700 22px/1 Manrope, sans-serif; letter-spacing: -.04em; }
  .top-actions { width: 100%; justify-content: space-between; gap: 7px; }
  .top-actions .quiet-button { flex: 1; padding: 9px 7px; font-size: 13px; }

  .page { font-size: 15px; }
  .eyebrow { font-size: 12px; }
  .muted, .home-page > .muted, .form-page > .muted, .manuals-page > .muted { font-size: 15px; }
  .choice-card { min-height: 88px; }
  .choice-card strong, .headwork-card strong { font-size: 15px; }
  .choice-card small, .headwork-card small { font-size: 13px; }
  .small-button, .quiet-button, .back-link { font-size: 13px; }
  .primary { font-size: 15px; }
  .form-card { gap: 18px; }
  .login-card label, .form-card > label, .two-fields label { font-size: 14px; }
  .login-brand img { width: 50px; height: 50px; }
  .login-brand span { font-size: 29px; }
  .login-subtitle { margin-bottom: 18px; font-size: 14px; }
  .login-card input, .form-card input:not([type=file]), .form-card textarea,
  .detail-page textarea, .form-card select, .detail-page input { font-size: 16px; }
  .media-picker strong { font-size: 14px; }
  .media-picker small, .privacy-note, .map-attribution { font-size: 12px; }
  .record-section h2 { font-size: 17px; }
  .record-section textarea { font-size: 16px; }
  .inline-status, .empty-state { font-size: 13px; }
  .media-gallery figcaption { font-size: 12px; }
  .headwork-map { height: 300px; }
  .map-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
  .map-actions .small-button { padding: 8px 9px; }
  .incident-toolbar label { font-size: 14px; font-weight: 600; }
  .incident-toolbar textarea { width: 100%; min-height: 88px; border: 1px solid #dfe5de; border-radius: 10px; padding: 12px; font: inherit; font-size: 16px; }
  .incident-actions { gap: 9px; }
  .incident-actions button { min-height: 42px; font-size: 13px; }
  .incident-record-heading strong { font-size: 15px; }
  .incident-record time { font-size: 13px; }
  .incident-record p { font-size: 14px; }
  .incident-badge { font-size: 12px; }
  .media-item .delete-media { width: 36px; height: 36px; font-size: 23px; }
  .chat-page { height: calc(100dvh - 96px); }
  .chat-page .message-text { font-size: 15px; }
  .chat-page .message-role, .chat-page .voice-controls > span { font-size: 13px; }
  .composer textarea { font-size: 16px; }
  .composer-wrap > p { font-size: 12px; }
  .mic-button { min-width: 56px; min-height: 56px; width: 56px; height: 56px; }
}

@media (max-width: 380px) {
  .topbar { min-height: 101px; }
  .top-actions .quiet-button { padding-inline: 5px; font-size: 12px; }
  .chat-page { height: calc(100dvh - 101px); }
  .map-actions { width: 100%; justify-content: flex-start; }
}
