:root {
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  /* Cute Pink Pastel Theme */
  --pink-900: #881337;
  --pink-800: #9f1239;
  --pink-700: #be123c;
  --pink-600: #e11d48;
  --pink-500: #f43f5e;
  --pink-400: #fb7185;
  --pink-300: #fda4af;
  --pink-200: #fecdd3;
  --pink-100: #ffe4e6;
  --pink-50:  #fff1f2;

  --sage-600: #059669;
  --sage-500: #10b981;
  --sage-100: #d1fae5;
  --sage-50:  #ecfdf5;

  --bg-page: #fff5f7;
  --card-bg: #ffffff;
  --text-primary: #372027;
  --text-secondary: #704d57;
  --text-muted: #9e7d86;
  --border-subtle: #fce7ec;
  --border-pink: #fbcfe8;

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 6px rgba(244, 63, 94, 0.05);
  --shadow-md: 0 8px 24px rgba(244, 63, 94, 0.07);
  --shadow-lg: 0 16px 36px rgba(244, 63, 94, 0.12);
  --shadow-modal: 0 20px 50px rgba(136, 19, 55, 0.18);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
  min-height: -webkit-fill-available;
  position: relative;
  overflow-x: hidden;
  padding-bottom: calc(95px + env(safe-area-inset-bottom));
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
}

/* Cute Floating Background Blurs */
.bg-ornament {
  position: fixed;
  border-radius: 50%;
  filter: blur(85px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
}
.bg-ornament-1 {
  width: 380px; height: 380px; top: -80px; left: -60px;
  background: radial-gradient(circle, #fecdd3, transparent 70%);
}
.bg-ornament-2 {
  width: 440px; height: 440px; top: 25%; right: -100px;
  background: radial-gradient(circle, #fed7aa, transparent 70%);
}

/* Flying Love Burst Animation */
.love-burst-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  overflow: hidden;
}

.flying-heart {
  position: absolute;
  bottom: 30px;
  user-select: none;
  pointer-events: none;
  animation: flyUpAndFade 1.6s forwards cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes flyUpAndFade {
  0% { transform: translateY(0) scale(0.6) rotate(0deg); opacity: 1; }
  60% { opacity: 1; }
  100% { transform: translateY(-550px) scale(1.3) rotate(20deg); opacity: 0; }
}

.app-container {
  max-width: 800px;
  margin: 0 auto;
  padding: calc(20px + env(safe-area-inset-top)) calc(18px + env(safe-area-inset-right)) 40px calc(18px + env(safe-area-inset-left));
  position: relative;
  z-index: 1;
}

/* Header */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-rings {
  width: 46px; height: 46px;
  background: #ffffff;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-subtle);
}

.heart-pulse-icon {
  display: inline-block;
  font-size: 1.55rem;
  animation: heartbeat 2.2s infinite ease-in-out;
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  14% { transform: scale(1.22); }
  28% { transform: scale(1); }
  42% { transform: scale(1.18); }
  70% { transform: scale(1); }
}

.brand-eyebrow {
  display: block;
  font-size: 0.73rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--pink-600);
  font-weight: 700;
}

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
}

.heart-inline {
  display: inline-block;
  animation: heartbeat 3s infinite ease-in-out;
  font-size: 1.15rem;
}

.header-actions { display: flex; align-items: center; gap: 8px; }

.sync-dot-only {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-sm);
}

.sync-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse-dot 2s infinite;
}

.sync-dot-only.offline .sync-dot {
  background: #f59e0b;
  animation: none;
}

@keyframes pulse-dot {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.btn-icon {
  background: #ffffff;
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-full);
  width: 40px; height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--pink-600);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}
.btn-icon:hover {
  background: var(--pink-50);
  border-color: var(--pink-300);
  color: var(--pink-700);
}

.card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border-subtle);
  box-shadow: var(--shadow-md);
  padding: 22px;
  margin-bottom: 18px;
}

/* Hero Card - Cute Sweet Berry Gradient */
.hero-card {
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 50%, #fecdd3 100%);
  color: var(--text-primary);
  border: 1.5px solid var(--pink-200);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-card::after {
  content: '✨';
  position: absolute;
  top: 10px; right: 14px;
  font-size: 1.4rem;
  opacity: 0.3;
  pointer-events: none;
}

.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 12px;
  flex-wrap: wrap;
}

.card-caption {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--pink-700);
  display: block;
  margin-bottom: 3px;
}

.hero-total {
  font-size: 2.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--pink-800);
  font-variant-numeric: tabular-nums;
}

.hero-countdown {
  background: rgba(255, 255, 255, 0.92);
  border: 1.5px solid var(--pink-300);
  border-radius: var(--radius-md);
  width: 170px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.08);
  text-align: center;
}

.countdown-sub {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--pink-800);
  white-space: nowrap;
}

.countdown-main {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
}

.countdown-days {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--pink-600);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.countdown-unit {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--pink-700);
  white-space: nowrap;
}

.progress-wrap { display: flex; flex-direction: column; gap: 8px; }

.progress-bar-track {
  height: 12px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-full);
  display: flex;
  overflow: hidden;
  border: 1.5px solid var(--pink-200);
}

.progress-bar-segment {
  height: 100%;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.segment-pria { background: linear-gradient(90deg, #34d399, #10b981); }
.segment-wanita { background: linear-gradient(90deg, #f43f5e, #fb7185); }

.progress-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  white-space: nowrap;
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-weight: 700;
}
.progress-info-row strong { color: var(--pink-800); }
.sisa-text strong { color: var(--pink-600); }

.progress-legend {
  display: flex;
  gap: 14px;
  font-size: 0.76rem;
  font-weight: 700;
}
.legend-item { display: flex; align-items: center; gap: 6px; color: var(--text-secondary); }
.legend-text { white-space: nowrap; }
.legend-text strong { color: var(--text-primary); font-weight: 800; }
.legend-dot { width: 8px; height: 8px; border-radius: 50%; }
.dot-pria { background: #10b981; }
.dot-wanita { background: #f43f5e; }

/* Couple Bento Grid (50:50 Side-by-Side) */
.couple-bento-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.bento-card {
  border-radius: var(--radius-md);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  user-select: none;
  box-shadow: var(--shadow-sm);
}
.bento-card:active {
  transform: scale(0.98);
}
.bento-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.bento-pria {
  background: linear-gradient(145deg, #f0fdf4 0%, #ffffff 100%);
  border: 1.5px solid #a7f3d0;
}
.bento-wanita {
  background: linear-gradient(145deg, #fff1f2 0%, #ffffff 100%);
  border: 1.5px solid #fecdd3;
}

.bento-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.bento-avatar {
  font-size: 1.4rem;
  line-height: 1;
}
.bento-role {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.bento-name {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.1;
}

.bento-nominal {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-variant-numeric: tabular-nums;
}

.bento-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: auto;
  background: var(--sage-50);
  border-radius: var(--radius-full);
  padding: 7px 8px;
}
.bento-pria .bento-footer { background: var(--sage-50); }
.bento-wanita .bento-footer { background: var(--pink-50); }
.bento-pill {
  background: var(--sage-100);
  color: var(--sage-600);
  padding: 2px 7px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 800;
}
.bento-pill-wanita {
  background: var(--pink-100);
  color: var(--pink-600);
}
.bento-hint {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--sage-600);
  white-space: nowrap;
}
.bento-hint-wanita {
  color: var(--pink-600);
}

/* Compact Summary Strip (Masuk vs Keluar) */
.compact-summary-strip {
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: #ffffff;
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}

.summary-strip-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
}
.summary-strip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}
.dot-in { background: #10b981; }
.dot-out { background: #e11d48; }
.summary-strip-label {
  color: var(--text-muted);
}
.summary-strip-divider {
  width: 1px;
  height: 16px;
  background: var(--border-subtle);
}
.text-success { color: #15803d; }
.text-danger { color: #e11d48; }

/* History Section */
.history-section { padding: 20px; }

.history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}

.history-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.history-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
}

.count-badge {
  background: var(--pink-50);
  color: var(--pink-700);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  border: 1px solid var(--pink-200);
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  width: 100%;
}

.filter-chip {
  background: #fff1f2;
  border: 1px solid var(--pink-200);
  border-radius: var(--radius-full);
  padding: 5px 14px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--pink-700);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.filter-chip.active {
  background: var(--pink-600);
  color: #ffffff;
  border-color: var(--pink-600);
  box-shadow: var(--shadow-sm);
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tx-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 15px;
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-subtle);
  transition: all 0.15s ease;
  box-shadow: var(--shadow-sm);
}
.tx-item:hover {
  border-color: var(--pink-300);
  transform: translateY(-1px);
}

.tx-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tx-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 800;
  flex-shrink: 0;
}

.tx-category {
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.tx-meta {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 1px;
}

.tx-right {
  text-align: right;
  display: flex;
  align-items: center;
  gap: 10px;
}

.tx-amount {
  font-weight: 800;
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
}
.tx-amount.masuk { color: #15803d; }
.tx-amount.keluar { color: #e11d48; }

.btn-del-tx {
  background: transparent;
  border: none;
  color: #fda4af;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  transition: color 0.15s;
}
.btn-del-tx:hover { color: #e11d48; }

.empty-state {
  text-align: center;
  padding: 38px 20px;
  color: var(--text-muted);
}
.empty-icon { font-size: 2.5rem; margin-bottom: 8px; }
.empty-state h3 { color: var(--text-primary); margin-bottom: 6px; font-weight: 800; }
.empty-state p { font-size: 0.85rem; margin-bottom: 16px; }

/* Bottom Action Bar */
.bottom-action-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 95;
  padding: 10px 18px calc(14px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(255, 245, 247, 0) 0%, rgba(255, 245, 247, 0.95) 20%, #fff5f7 100%);
  pointer-events: none;
  display: flex;
  justify-content: center;
}

.btn-main-action {
  pointer-events: auto;
  width: 100%;
  max-width: 460px;
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: #ffffff;
  border: 2px solid #ffffff;
  border-radius: var(--radius-full);
  padding: 14px 20px;
  font-size: 1.02rem;
  font-weight: 800;
  box-shadow: 0 8px 24px rgba(244, 63, 94, 0.45);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
}
.btn-main-action:active {
  transform: scale(0.98);
}

.btn-primary {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-full);
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.3);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(244, 63, 94, 0.4);
}

.btn-secondary {
  background: #fff1f2;
  color: var(--pink-700);
  border: 1px solid var(--pink-200);
  border-radius: var(--radius-full);
  padding: 12px 20px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-secondary:hover { background: #ffe4e6; }

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(136, 19, 55, 0.4);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.modal-overlay.show { opacity: 1; pointer-events: auto; }

.modal-card {
  background: #ffffff;
  width: 100%;
  max-width: 480px;
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--pink-200);
  box-shadow: var(--shadow-modal);
  padding: 24px;
  transform: translateY(20px) scale(0.97);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 90vh;
  overflow-y: auto;
}
.modal-overlay.show .modal-card { transform: translateY(0) scale(1); }

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}
.modal-tag {
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--pink-600);
}
.modal-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
}
.modal-close {
  background: none;
  border: none;
  font-size: 1.7rem;
  line-height: 1;
  color: var(--pink-300);
  cursor: pointer;
  transition: color 0.15s;
}
.modal-close:hover { color: var(--pink-600); }

.modal-form { display: flex; flex-direction: column; gap: 15px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 0.8rem; font-weight: 800; color: var(--text-secondary); }
.form-help { font-size: 0.72rem; color: var(--text-muted); }

.form-control {
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--text-primary);
  background: #fff8f9;
  outline: none;
  transition: all 0.2s;
}
.form-control:focus {
  border-color: var(--pink-400);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(251, 113, 133, 0.15);
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Type Segmented */
.type-segmented {
  display: flex;
  background: #ffe4e6;
  border-radius: var(--radius-full);
  padding: 4px;
  gap: 4px;
}
.type-btn {
  flex: 1;
  border: none;
  background: none;
  padding: 8px 12px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  color: var(--pink-800);
  transition: all 0.2s;
}
.type-btn.active[data-tipe="masuk"] { background: #ffffff; color: #15803d; box-shadow: var(--shadow-sm); }
.type-btn.active[data-tipe="keluar"] { background: #ffffff; color: #e11d48; box-shadow: var(--shadow-sm); }
/* Partner Radio Selector */
.partner-selector {
  display: flex;
  gap: 10px;
}
.partner-radio-label {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1.5px solid var(--border-subtle);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  background: #fff8f9;
}
.partner-radio-label input { display: none; }
.partner-radio-label.active {
  border-color: var(--pink-500);
  background: #ffe4e6;
  color: var(--pink-900);
}
.selector-dot { width: 10px; height: 10px; border-radius: 50%; }

/* Input Nominal */
.input-nominal-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.currency-prefix {
  position: absolute;
  left: 14px;
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--pink-600);
}
#input-nominal-display {
  width: 100%;
  padding: 12px 14px 12px 48px;
  font-size: 1.35rem;
  font-weight: 800;
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-md);
  outline: none;
  background: #fff8f9;
  font-variant-numeric: tabular-nums;
  color: var(--pink-900);
  transition: all 0.2s;
}
#input-nominal-display:focus {
  border-color: var(--pink-400);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(251, 113, 133, 0.15);
}

.nominal-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.chip-add {
  background: #fff1f2;
  border: 1px solid var(--pink-200);
  border-radius: var(--radius-full);
  padding: 5px 12px;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--pink-700);
  cursor: pointer;
  transition: all 0.15s;
}
.chip-add:hover {
  background: var(--pink-200);
  color: var(--pink-900);
  transform: translateY(-1px);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}

/* Toast Notification - Cute Pink */
.toast {
  position: fixed;
  bottom: calc(28px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%) translateY(60px);
  background: #881337;
  color: #ffffff;
  padding: 12px 24px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(136, 19, 55, 0.35);
  border: 1.5px solid var(--pink-300);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 150;
  white-space: nowrap;
}
.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* Responsive Mobile-First */
@media (max-width: 640px) {
  .hero-top { flex-direction: column; }
  .couple-grid { grid-template-columns: 1fr; }
  .mini-stats-grid { grid-template-columns: 1fr; }
  .form-row-2 { grid-template-columns: 1fr; }
  .modal-card {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    margin-top: auto;
    max-height: 90vh;
    padding-bottom: calc(28px + env(safe-area-inset-bottom));
  }
  .modal-overlay {
    align-items: flex-end;
    padding: 0;
  }
}
