
/* Harthwyn 26.01.346 — Mobile Family Action Completion
 * Action-first mobile surface: primary tasks appear before explanatory content, fields remain full-width, and primary controls stay reachable.
 */
@media (max-width: 782px), (pointer: coarse) {
  .harthwyn-mobile-primary-action-260346 {
    display: grid !important;
    gap: .75rem !important;
    margin: .75rem 0 1rem !important;
    padding: .9rem !important;
    border: 1px solid rgba(18,62,104,.16) !important;
    border-radius: 18px !important;
    background: linear-gradient(135deg, rgba(255,255,255,.96), rgba(248,244,234,.94)) !important;
    box-shadow: 0 14px 34px rgba(17, 31, 48, .08) !important;
  }
  .harthwyn-mobile-primary-action-260346__title {
    margin: 0 !important;
    font-size: 1.05rem !important;
    line-height: 1.18 !important;
    color: #123e68 !important;
  }
  .harthwyn-mobile-primary-action-260346__note {
    margin: 0 !important;
    font-size: .92rem !important;
    line-height: 1.35 !important;
    color: rgba(20, 38, 58, .78) !important;
  }
  .harthwyn-mobile-primary-action-260346 .harthwyn-button,
  .harthwyn-mobile-action-button-260346,
  .harthwyn-page-primary-action-260346 {
    width: 100% !important;
    min-height: 52px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 16px !important;
    font-size: 1rem !important;
    font-weight: 800 !important;
    text-align: center !important;
    white-space: normal !important;
  }
  .harthwyn-mobile-primary-action-260346 .harthwyn-actions,
  .harthwyn-mobile-primary-action-260346__actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: .55rem !important;
  }

  /* Reduce process-copy dominance on mobile. Keep context available, but put action first. */
  .harthwyn-page-hero--2026,
  .harthwyn-guide-hero,
  .harthwyn-front-command,
  .harthwyn-moments-intro,
  .harthwyn-album-command-hero--2026 {
    padding: 1rem !important;
    margin-top: .5rem !important;
  }
  .harthwyn-page-hero--2026 p,
  .harthwyn-guide-hero p,
  .harthwyn-front-command__copy p,
  .harthwyn-panel-header-inline .harthwyn-inline-note,
  .harthwyn-message-rail__privacy,
  .harthwyn-composer-details,
  .harthwyn-moment-upload-hints {
    font-size: .92rem !important;
    line-height: 1.38 !important;
  }
  .harthwyn-moments-intro .harthwyn-front-command__actions,
  .harthwyn-album-command-hero--2026 .harthwyn-actions {
    display: none !important;
  }

  /* Universal front-facing form hardening. */
  .harthwyn-content-system-shell input:not([type='hidden']):not([type='checkbox']):not([type='radio']),
  .harthwyn-content-system-shell select,
  .harthwyn-content-system-shell textarea,
  .harthwyn-form input:not([type='hidden']):not([type='checkbox']):not([type='radio']),
  .harthwyn-form select,
  .harthwyn-form textarea {
    width: 100% !important;
    max-width: 100% !important;
    min-height: 50px !important;
    font-size: 16px !important;
    line-height: 1.35 !important;
    box-sizing: border-box !important;
  }
  .harthwyn-content-system-shell textarea,
  .harthwyn-form textarea {
    min-height: 132px !important;
    resize: vertical !important;
  }
  .harthwyn-form-row,
  .harthwyn-form-row--two,
  .harthwyn-grid,
  .harthwyn-album-composer-grid--2026,
  .harthwyn-moment-composer-grid,
  .harthwyn-events-form-grid,
  .harthwyn-profile-workspace-grid,
  .harthwyn-i-am-layout,
  .harthwyn-messages-layout,
  .harthwyn-message-split-pane {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: .85rem !important;
    max-width: 100% !important;
    overflow: visible !important;
  }
  .harthwyn-panel,
  .harthwyn-card,
  .harthwyn-message-thread-view,
  .harthwyn-message-thread-list,
  .harthwyn-event-summary-card,
  .harthwyn-album-details-drawer--2026 {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Moments: action and composer first, shorter path to share. */
  .harthwyn-family-moments .harthwyn-moment-composer,
  .harthwyn-family-moments [data-harthwyn-moment-composer] {
    scroll-margin-top: 76px !important;
  }
  .harthwyn-moment-type-picker,
  .harthwyn-moment-kind-row-260140,
  .harthwyn-moment-upload-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: .55rem !important;
  }
  .harthwyn-moment-type-card,
  .harthwyn-moment-kind-card-260140 {
    min-height: 52px !important;
    justify-content: flex-start !important;
  }

  /* Albums/media: choose/add media first, details second. */
  .harthwyn-albums-browser #harthwyn-add-album,
  .harthwyn-album-editor--2026 {
    scroll-margin-top: 76px !important;
  }
  .harthwyn-albums-browser summary {
    min-height: 52px !important;
    display: flex !important;
    align-items: center !important;
    font-weight: 800 !important;
  }

  /* Messages: compose/send stays reachable. */
  .harthwyn-messages-center .harthwyn-message-home-cards-260199 {
    grid-template-columns: 1fr 1fr !important;
    gap: .55rem !important;
  }
  .harthwyn-messages-center .is-compose {
    grid-column: 1 / -1 !important;
  }
  .harthwyn-message-send-actions-260344,
  .harthwyn-message-composer-actions,
  .harthwyn-message-form-actions {
    position: sticky !important;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 72px) !important;
    z-index: 20 !important;
    padding: .7rem !important;
    border-radius: 18px !important;
    background: rgba(255,255,255,.96) !important;
    box-shadow: 0 -12px 30px rgba(17,31,48,.10) !important;
  }

  /* Save the Date: event actions before secondary overview content. */
  .harthwyn-events-hub .harthwyn-event-summary-cards {
    grid-template-columns: 1fr !important;
  }
  .harthwyn-events-hub .harthwyn-event-summary-card.is-create {
    order: -1 !important;
  }
  .harthwyn-event-summary-card__action,
  .harthwyn-event-communication-actions-260345 .harthwyn-button,
  .harthwyn-event-action-bar-260346 .harthwyn-button {
    min-height: 50px !important;
    width: 100% !important;
    justify-content: center !important;
  }

  /* Profile/I Am: keep edit/save route visible and prevent squeezed fields. */
  .harthwyn-member-profile .harthwyn-button,
  .harthwyn-i-am-page .harthwyn-button,
  .harthwyn-profile-save-actions-260346 .harthwyn-button {
    min-height: 50px !important;
  }
  .harthwyn-profile-save-actions-260346 {
    position: sticky !important;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 72px) !important;
    z-index: 18 !important;
    background: rgba(255,255,255,.96) !important;
    padding: .65rem !important;
    border-radius: 18px !important;
    box-shadow: 0 -12px 30px rgba(17,31,48,.10) !important;
  }

  /* Auth: inputs first, image remains support layer on small screens. */
  .harthwyn-auth-panel,
  .harthwyn-auth-card,
  .harthwyn-login-card {
    max-width: 100% !important;
  }
  .harthwyn-auth-legacy-panel,
  .harthwyn-auth-family-image,
  .harthwyn-auth-visual-panel {
    max-height: 32vh !important;
    overflow: hidden !important;
  }

  /* Prevent bottom app shell from hiding final actions. */
  .harthwyn-content-system-shell,
  .harthwyn-managed-page-shell,
  .harthwyn-family-app-shell {
    padding-bottom: calc(104px + env(safe-area-inset-bottom, 0px)) !important;
  }
}

@media (min-width: 783px) {
  .harthwyn-mobile-primary-action-260346 {
    display: none !important;
  }
}
