/* ==========================================================================
   RENTAL BUDDY — DESIGN SYSTEM & MASTER STYLES
   Based on AGENTS.md Baseline
   ========================================================================== */

:root {
  /* Color Tokens */
  --bg-canvas: #EFF0FA;
  --bg-surface: #FFFFFF;
  --bg-accent-subtle: #E8E7FB;
  --bg-secondary-btn: #E2E3F3;
  --bg-secondary-btn-hover: #D5D7EE;

  --color-primary: #5452EC;
  --color-primary-active: #413FD6;
  --color-primary-light: rgba(84, 82, 236, 0.06);
  --color-primary-glow: rgba(84, 82, 236, 0.28);
  --text-on-primary: #FFFFFF;

  --text-heading: #0E1326;
  --text-body: #52586E;
  --text-muted: #7E869E;
  --text-subtle: #A3AABF;

  --border-subtle: #E2E4F2;
  --border-active: #5452EC;

  /* Typography */
  --font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Geometry & Radius */
  --radius-pill: 9999px;
  --radius-card: 20px;
  --radius-input: 16px;
  --radius-circle: 50%;

  /* Transitions */
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-default: 260ms;
}

/* ==========================================================================
   Base & Reset
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  height: 100%;
  font-family: var(--font-family);
  background-color: #DCE0F0;
  color: var(--text-heading);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   Layout & Mobile Frame Simulation
   ========================================================================== */
.app-viewport {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.mobile-frame {
  position: relative;
  width: 100%;
  max-width: 412px;
  height: 100%;
  max-height: 875px;
  background-color: var(--bg-canvas);
  border-radius: 44px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px -12px rgba(22, 28, 68, 0.25),
              0 0 0 1px rgba(255, 255, 255, 0.6) inset,
              0 0 0 8px #1E2235;
  transition: max-width 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-frame.width-360 {
  max-width: 360px;
}

/* Fullscreen on real mobile viewports */
@media (max-width: 480px), (max-height: 800px) {
  .app-viewport {
    padding: 0;
  }
  .mobile-frame {
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
    box-shadow: none;
  }
  .mobile-frame.width-360 {
    max-width: 100%;
  }
}

/* ==========================================================================
   Status Bar Simulation
   ========================================================================== */
.status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px 8px;
  z-index: 50;
  user-select: none;
  flex-shrink: 0;
}

.status-time {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -0.01em;
}

.camera-punchhole {
  width: 14px;
  height: 14px;
  background-color: #12141F;
  border-radius: 50%;
  margin-top: 1px;
}

.status-icons {
  display: flex;
  align-items: center;
  gap: 7px;
}

.status-icon {
  width: 16px;
  height: 16px;
  color: var(--text-heading);
}

.status-icon.battery {
  width: 17px;
  height: 17px;
  transform: rotate(90deg);
}



/* ==========================================================================
   Screens Slider & Motion
   ========================================================================== */
.screens-slider {
  flex: 1 1 auto;
  position: relative;
  overflow: hidden;
  display: flex;
  min-height: 0;
}

.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  opacity: 0;
  pointer-events: none;
  transform: translateX(40px);
  transition: transform var(--duration-default) var(--ease-spring),
              opacity var(--duration-default) ease;
  overflow: hidden;
  min-height: 0;
}

.screen.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.screen.exit-left {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-40px);
}

.screen-content {
  flex: 1 1 auto;
  padding: 24px 24px 16px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.screen-content::-webkit-scrollbar {
  display: none;
}

/* ==========================================================================
   Brand & Navigation Headers
   ========================================================================== */
.brand-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
}

.brand-logo-icon {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
}

.brand-logo-icon svg {
  width: 32px;
  height: 32px;
}

.brand-title {
  font-size: 26px;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: -0.02em;
}

.nav-header {
  display: flex;
  align-items: center;
  height: 44px;
  margin-bottom: 12px;
}

.nav-back-btn {
  background: transparent;
  border: none;
  outline: none;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: -8px;
  border-radius: 50%;
  color: var(--text-heading);
  transition: background-color 0.15s ease, transform 0.15s ease;
}

.nav-back-btn:hover {
  background-color: rgba(14, 19, 38, 0.05);
}

.nav-back-btn:active {
  transform: scale(0.92);
}

.nav-back-btn svg {
  width: 24px;
  height: 24px;
}

/* ==========================================================================
   Hero Headings
   ========================================================================== */
.hero-block {
  margin-bottom: 24px;
}

.hero-title {
  font-size: 30px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  margin-bottom: 10px;
}

.hero-subtitle {
  font-size: 15px;
  line-height: 1.45;
  color: var(--text-body);
  font-weight: 400;
  text-wrap: balance;
  text-wrap: pretty;
}

/* ==========================================================================
   Screen 1: Feature Cards List
   ========================================================================== */
.features-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.feature-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.03);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  box-shadow: 0 6px 20px rgba(28, 33, 66, 0.06);
}

.feature-icon-wrapper {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: var(--radius-circle);
  background-color: var(--bg-accent-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
}

.feature-icon-wrapper svg {
  width: 24px;
  height: 24px;
}

.feature-text {
  flex: 1;
}

.feature-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 4px;
}

.feature-desc {
  font-size: 13.5px;
  line-height: 1.4;
  color: var(--text-body);
}

/* ==========================================================================
   Screen 2: Currency Preferences
   ========================================================================== */
.section-group {
  margin-top: 4px;
}

.section-label {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 14px;
}

.radio-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.radio-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-input);
  padding: 16px 20px;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.radio-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.radio-label {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-heading);
}

.custom-radio {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #C4C8D8;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.radio-card:hover {
  border-color: #BAC0D8;
}

.radio-card.selected {
  border-color: var(--color-primary);
  background-color: rgba(84, 82, 236, 0.03);
}

.radio-card.selected .radio-label {
  font-weight: 600;
}

.radio-card.selected .custom-radio {
  border-color: var(--color-primary);
  background-color: var(--color-primary);
  box-shadow: inset 0 0 0 3px #FFFFFF;
}

/* Custom Currency Box */
.custom-currency-box {
  margin-top: 14px;
  background-color: #FFFFFF;
  border-radius: 14px;
  padding: 14px 16px;
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.04);
  animation: fadeInDown 0.2s ease;
}

.custom-currency-box.hidden {
  display: none;
}

.custom-currency-field span {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-body);
  margin-bottom: 6px;
}

.currency-dropdown {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border-subtle);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-heading);
  background-color: #F8F9FD;
  outline: none;
}

.currency-dropdown:focus {
  border-color: var(--color-primary);
}

/* ==========================================================================
   Screen 3: Setup Choice Cards
   ========================================================================== */
.action-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 8px;
}

.action-card {
  width: 100%;
  background-color: var(--bg-surface);
  border: none;
  border-radius: var(--radius-card);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.03);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.action-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(28, 33, 66, 0.07);
}

.action-card:active {
  transform: scale(0.98);
}

.action-icon-circle {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: var(--radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
}

.action-icon-circle.primary {
  background-color: var(--color-primary);
  color: #FFFFFF;
}

.action-icon-circle.lavender {
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
}

.action-icon-circle svg {
  width: 24px;
  height: 24px;
}

.action-details {
  flex: 1;
}

.action-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 3px;
}

.action-subtitle {
  font-size: 13.5px;
  color: var(--text-body);
}

.action-chevron {
  color: var(--text-subtle);
  display: flex;
  align-items: center;
}

.action-chevron svg {
  width: 20px;
  height: 20px;
}

/* ==========================================================================
   Screen 4: Notifications (Centered Bell)
   ========================================================================== */
.notification-screen-content {
  display: flex;
  flex-direction: column;
}

.bell-illustration-container {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  min-height: 140px;
  max-height: 240px;
  margin: 10px 0;
}

.bell-glow {
  position: absolute;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(84, 82, 236, 0.18) 0%, rgba(84, 82, 236, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
}

.bell-svg-wrapper {
  position: relative;
  width: 160px;
  height: 192px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: bellFloat 4s ease-in-out infinite;
}

.bell-icon-svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 16px 30px rgba(84, 82, 236, 0.28));
}

@keyframes bellFloat {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  25% {
    transform: translateY(-6px) rotate(-2deg);
  }
  75% {
    transform: translateY(4px) rotate(2deg);
  }
}

/* ==========================================================================
   Screen 5: Success Summary
   ========================================================================== */
.success-screen-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  justify-content: center;
  padding: 30px 20px;
}

.success-icon-badge {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background-color: var(--color-primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  box-shadow: 0 12px 30px var(--color-primary-glow);
  animation: popIn 0.35s var(--ease-spring);
}

.success-icon-badge svg {
  width: 34px;
  height: 34px;
}

.badge-pill {
  background: var(--bg-accent-subtle);
  color: var(--color-primary);
  padding: 2px 10px;
  border-radius: 12px;
  font-weight: 700;
  display: inline-block;
}

.summary-card {
  width: 100%;
  background: #FFFFFF;
  border-radius: 18px;
  padding: 18px;
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
  box-shadow: 0 4px 16px rgba(28, 33, 66, 0.04);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  color: var(--text-body);
}

.summary-row strong {
  color: var(--text-heading);
}

/* ==========================================================================
   Buttons & Bottom Action Bars (Strict Anti-Collapse)
   ========================================================================== */
.bottom-bar {
  padding: 14px 24px 20px;
  background-color: var(--bg-canvas);
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0 !important;
  z-index: 20;
}

.bottom-bar.two-buttons {
  flex-direction: row;
  align-items: center;
  gap: 12px;
}

.btn {
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  height: 54px !important;
  min-height: 54px !important;
  max-height: 54px !important;
  flex-shrink: 0 !important;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
  user-select: none;
  transition: transform 0.15s var(--ease-spring), box-shadow 0.15s ease, background-color 0.15s ease;
}

.btn:active {
  transform: scale(0.97) translateY(1px);
}

.btn-primary {
  background: linear-gradient(180deg, #5D5BF5 0%, #4D4AE6 100%);
  color: var(--text-on-primary);
  box-shadow: 0 8px 24px var(--color-primary-glow), 0 2px 4px rgba(84, 82, 236, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.18);
  flex: 1;
}

.btn-primary:hover {
  background: linear-gradient(180deg, #5452EC 0%, #4340D8 100%);
  box-shadow: 0 10px 28px rgba(84, 82, 236, 0.42), 0 3px 6px rgba(84, 82, 236, 0.25);
}

.btn-secondary {
  background-color: var(--bg-secondary-btn);
  color: var(--text-heading);
  box-shadow: 0 4px 14px rgba(14, 19, 38, 0.08), 0 1px 2px rgba(14, 19, 38, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.6);
  flex: 1;
}

.btn-secondary:hover {
  background-color: var(--bg-secondary-btn-hover);
  box-shadow: 0 6px 18px rgba(14, 19, 38, 0.12);
}

.bottom-bar.two-buttons .btn-secondary {
  flex: 1;
  min-width: 100px;
  padding: 0 14px;
}

.bottom-bar.two-buttons .btn-primary {
  flex: 1.5;
  min-width: 160px;
  padding: 0 16px;
}

.btn-whatsapp {
  background: linear-gradient(180deg, #25D366 0%, #1EBE5D 100%);
  color: #FFFFFF !important;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.38), 0 2px 4px rgba(30, 190, 93, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.25);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s var(--ease-spring), box-shadow 0.15s ease, background-color 0.15s ease;
}

.btn-whatsapp:hover {
  background: linear-gradient(180deg, #28E06D 0%, #1BAB53 100%);
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.48), 0 3px 6px rgba(30, 190, 93, 0.3);
}

.btn-whatsapp:active {
  transform: scale(0.97) translateY(1px);
}

.btn-whatsapp svg {
  color: #FFFFFF !important;
  stroke: #FFFFFF !important;
}

.bottom-bar.two-buttons .btn-whatsapp {
  flex: 1.1;
  min-width: 115px;
  padding: 0 14px;
}

/* ==========================================================================
   Toast Notification
   ========================================================================== */
.toast-popup {
  position: absolute;
  top: 56px;
  left: 20px;
  right: 20px;
  background-color: #121422;
  color: #FFFFFF;
  padding: 12px 18px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-12px);
  transition: opacity 0.25s ease, transform 0.25s var(--ease-spring);
  z-index: 100;
}

.toast-popup.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* ==========================================================================
   Floating Screen Picker Widget (Desktop Review Tool)
   ========================================================================== */
.screen-picker-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #FFFFFF;
  padding: 12px 16px;
  border-radius: 20px;
  box-shadow: 0 12px 36px rgba(18, 22, 50, 0.16), 0 0 0 1px #E8EAFA;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
}

@media (max-width: 768px) {
  .screen-picker-widget {
    display: none;
  }
}

.widget-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.widget-dot {
  width: 8px;
  height: 8px;
  background: #10B981;
  border-radius: 50%;
}

.widget-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.widget-buttons {
  display: flex;
  gap: 6px;
}

.widget-btn {
  background: #F1F3FA;
  border: none;
  border-radius: 10px;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
}

.widget-btn:hover {
  background: #E5E8F5;
  color: var(--text-heading);
}

.widget-btn.active {
  background: var(--color-primary);
  color: #FFFFFF;
}

.widget-tools {
  border-top: 1px solid #ECEEF8;
  padding-top: 8px;
  margin-top: 2px;
}

.widget-viewport-btn {
  width: 100%;
  background: #F1F3FA;
  border: 1px solid #E2E4F2;
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.widget-viewport-btn:hover {
  background: #E4E8F8;
  color: var(--color-primary);
}

.widget-nav-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.widget-group-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 4px;
}

/* ==========================================================================
   Stepper Header
   ========================================================================== */
.stepper-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 48px;
  margin-bottom: 12px;
}

.stepper-titles {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stepper-main-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -0.02em;
}

.stepper-sub-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 1px;
}

.stepper-spacer {
  width: 40px;
  height: 40px;
}

/* ==========================================================================
   Form Controls
   ========================================================================== */
.form-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-label {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 8px;
  display: block;
}

.form-label.mini {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  height: 52px;
  background-color: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-input);
  padding: 0 16px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-heading);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input::placeholder {
  color: var(--text-subtle);
  font-weight: 400;
}

.form-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-glow);
}

.form-input.mini {
  height: 46px;
  font-size: 14px;
}

.form-caption {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 5px;
  line-height: 1.3;
}

.form-row-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.input-with-action {
  display: flex;
  align-items: center;
  gap: 10px;
}

.input-with-action .form-input {
  flex: 1;
}

.input-action-btn {
  width: 52px;
  height: 52px;
  min-width: 52px;
  background-color: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
}

.input-action-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.input-action-btn svg {
  width: 22px;
  height: 22px;
}

.split-radio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.radio-card.mini-radio {
  padding: 13px 16px;
  height: 52px;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-with-icon .form-input {
  padding-right: 44px;
}

.input-trailing-icon {
  position: absolute;
  right: 14px;
  pointer-events: none;
  color: var(--text-muted);
  display: flex;
  align-items: center;
}

.input-trailing-icon svg {
  width: 20px;
  height: 20px;
}

/* Interactive Date Picker Overlay */
.date-picker-box {
  cursor: pointer;
}

.date-picker-box .date-text {
  cursor: pointer;
  background-color: var(--bg-surface);
}

.native-date-field {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
  border: none;
  background: transparent;
}

.native-date-field::-webkit-calendar-picker-indicator {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.util-subfields {
  display: flex;
  flex-direction: column;
  animation: fadeInDown 0.2s ease;
}

.util-subfields.hidden {
  display: none !important;
}

/* ==========================================================================
   Toggle Switch & Utility Cards
   ========================================================================== */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 28px;
  flex-shrink: 0;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background-color: #6F7488;
  border-radius: 34px;
  transition: background-color 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.toggle-slider::before {
  content: "";
  position: absolute;
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 3px;
  background-color: #FFFFFF;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.toggle-switch input:checked + .toggle-slider {
  background-color: #10B981;
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(22px);
}

.utilities-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.utility-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 16px 18px;
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.03);
  transition: box-shadow 0.2s ease;
}

.utility-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.utility-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading);
}

.utility-details {
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
  transition: max-height 0.25s ease, opacity 0.2s ease, margin-top 0.2s ease;
}

.utility-details.hidden {
  display: none;
}

.utility-divider {
  height: 1px;
  background-color: #EEF0F8;
  margin: 12px 0 2px;
}

.inline-radios {
  display: flex;
  align-items: center;
  gap: 20px;
}

.radio-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-heading);
  cursor: pointer;
  user-select: none;
}

.radio-inline input {
  display: none;
}

.custom-radio.mini {
  width: 18px;
  height: 18px;
  border: 1.5px solid #C4C8D8;
}

.radio-inline.selected .custom-radio.mini {
  border-color: var(--color-primary);
  background-color: var(--color-primary);
  box-shadow: inset 0 0 0 2.5px #FFFFFF;
}

/* ==========================================================================
   Confirm Screen Cards
   ========================================================================== */
.confirm-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 18px 20px;
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.03);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.confirm-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.confirm-label {
  color: var(--text-muted);
  font-weight: 400;
}

.confirm-value {
  color: var(--text-heading);
  font-weight: 700;
}

.confirm-utility-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.confirm-utility-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 2px;
}

.confirm-divider {
  height: 1px;
  background-color: #EEF0F8;
  margin: 4px 0;
}

/* ==========================================================================
   Dashboard & Home Screen Styles
   ========================================================================== */
.dashboard-content {
  padding-bottom: 30px;
}

.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.icon-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--text-heading);
  transition: background-color 0.15s ease, transform 0.12s ease;
}

.icon-btn:hover {
  background-color: rgba(14, 19, 38, 0.06);
}

.icon-btn:active {
  transform: scale(0.92);
}

.icon-btn svg {
  width: 24px;
  height: 24px;
}

.dashboard-title {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  margin-bottom: 20px;
}

/* Tenancies Stack */
.tenancies-list-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tenancy-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 18px 20px;
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
  border: 1px solid rgba(226, 228, 242, 0.7);
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tenancy-card:hover {
  box-shadow: 0 8px 24px rgba(28, 33, 66, 0.08);
}

.tenancy-card-header {
  display: flex;
  align-items: center;
  margin-bottom: 12px;
}

/* Status Badges */
.status-pill {
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  padding: 5px 12px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.status-pill.status-overdue {
  background-color: #FEE2E2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.status-pill.status-due-today {
  background-color: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.status-pill.status-upcoming {
  background-color: #E0F2FE;
  color: #0284C7;
  border: 1px solid #BAE6FD;
}

.status-pill.status-paid {
  background-color: #DCFCE7;
  color: #16A34A;
  border: 1px solid #BBF7D0;
}


/* Tenancy Card Main Header Row */
.tenancy-card-main-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.tenancy-info {
  display: flex;
  flex-direction: column;
}

.tenancy-name {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.01em;
  margin-bottom: 2px;
}

.tenancy-meta-sub {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-body);
}

.tenancy-row-chevron {
  color: var(--text-subtle);
  display: flex;
  align-items: center;
  padding-left: 8px;
}

.tenancy-row-chevron svg {
  width: 20px;
  height: 20px;
}

.tenancy-card-divider {
  height: 1px;
  background-color: #EEF0F8;
  margin: 14px 0 12px;
}

/* 2-Column Metrics Grid */
.tenancy-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: flex-start;
  gap: 12px;
}

.metric-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.metric-col.right-align {
  text-align: right;
  align-items: flex-end;
}

.metric-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.metric-label {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
}

.metric-tag {
  font-size: 12.5px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.metric-tag.success {
  color: #16A34A;
  font-weight: 600;
}

.metric-tag.success svg {
  width: 14px;
  height: 14px;
}

.metric-tag.danger {
  color: #DC2626;
  font-weight: 700;
}

/* History Metadata */
.tenancy-history-meta {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
  margin-bottom: 14px;
}

/* Action Buttons inside Card */
.tenancy-action-row {
  display: flex;
  width: 100%;
}

.btn-card-action {
  font-family: inherit;
  height: 48px;
  min-height: 48px;
  max-height: 48px;
  flex-shrink: 0;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 600;
  white-space: nowrap;
  user-select: none;
  transition: transform 0.15s var(--ease-spring), background-color 0.15s ease, box-shadow 0.15s ease;
}

.btn-card-action:active {
  transform: scale(0.97);
}

.btn-card-action svg {
  width: 19px;
  height: 19px;
}

.lavender-action {
  width: 100%;
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
  border: 1px solid rgba(84, 82, 236, 0.15);
}

.lavender-action:hover {
  background-color: #DDE0F8;
  color: var(--color-primary-active);
}

.peach-action {
  background-color: #FFE4E6;
  color: #E11D48;
  border: 1px solid rgba(225, 29, 72, 0.18);
}

.peach-action:hover {
  background-color: #FED1D6;
  color: #BE123C;
}

/* Dual Action Row (Apartment 11 style) */
.dual-action-row {
  display: flex;
  gap: 10px;
  width: 100%;
}

.dual-action-row .peach-action {
  flex: 1.45;
  padding: 0 12px;
  font-size: 13.5px;
}

.dual-action-row .lavender-action {
  flex: 1;
  padding: 0 12px;
  font-size: 13.5px;
}

/* ==========================================================================
   Recent Activity Section (Payments & Bills)
   ========================================================================== */
.recent-section {
  margin-top: 28px;
}

.recent-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.recent-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
}

.segmented-control {
  background-color: #E2E4F2;
  border-radius: 9999px;
  padding: 3px;
  display: flex;
  gap: 2px;
}

.segment-btn {
  border: none;
  background: transparent;
  padding: 4px 12px;
  border-radius: 9999px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
}

.segment-btn.active {
  background-color: #FFFFFF;
  color: var(--text-heading);
  box-shadow: 0 1px 4px rgba(14, 19, 38, 0.1);
}

.recent-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.recent-item-card {
  background-color: var(--bg-surface);
  border-radius: 16px;
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 8px rgba(28, 33, 66, 0.03);
  border: 1px solid rgba(226, 228, 242, 0.5);
  cursor: pointer;
  user-select: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.recent-item-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(28, 33, 66, 0.07);
}

.recent-item-card:active {
  transform: scale(0.98);
}

.recent-item-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.recent-prop-name {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
}

.recent-item-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.recent-item-timestamp {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--text-subtle);
}

.recent-item-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.recent-item-amount {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.recent-chevron {
  width: 16px;
  height: 16px;
  color: var(--text-subtle);
}

/* Empty State for Recent Activity */
.empty-recent-card {
  background-color: var(--bg-surface);
  border: 1.5px dashed #D6D9EE;
  border-radius: 20px;
  padding: 36px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.empty-recent-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.empty-recent-icon svg {
  width: 28px;
  height: 28px;
}

.empty-recent-heading {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 6px;
}

.empty-recent-copy {
  font-size: 13px;
  line-height: 1.45;
  color: var(--text-body);
  max-width: 280px;
  text-wrap: balance;
}

/* Empty Tenancies View */
.empty-state-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  margin-top: 10px;
}

.empty-state-card {
  background-color: rgba(255, 255, 255, 0.6);
  border: 1.5px solid #D6D9EE;
  border-radius: 24px;
  padding: 40px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.empty-state-icon {
  width: 68px;
  height: 68px;
  border-radius: 18px;
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.empty-state-icon svg {
  width: 34px;
  height: 34px;
}

.empty-state-heading {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 8px;
}

.empty-state-copy {
  font-size: 14px;
  line-height: 1.45;
  color: var(--text-body);
  max-width: 260px;
  margin-bottom: 24px;
  text-wrap: balance;
}

.btn-empty-cta {
  height: 46px !important;
  min-height: 46px !important;
  max-height: 46px !important;
  padding: 0 28px;
  font-size: 14.5px;
  flex: 0 0 auto !important;
}

/* Universal Visibility Utility */
.hidden {
  display: none !important;
}

/* ==========================================================================
   Modals & Bottom Sheets
   ========================================================================== */
.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(14, 19, 38, 0.45);
  backdrop-filter: blur(4px);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.modal-overlay.hidden {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

.modal-sheet {
  width: 100%;
  background-color: #FFFFFF;
  border-radius: 24px 24px 0 0;
  padding: 16px 20px 24px;
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.15);
  animation: slideUpSheet 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 85%;
  overflow-y: auto;
}

.modal-handle {
  width: 38px;
  height: 4px;
  border-radius: 2px;
  background-color: #D6D9EE;
  margin: 0 auto 14px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.modal-handle:hover {
  background-color: #A3AABF;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.modal-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-heading);
}

.modal-close-btn {
  background: transparent;
  border: none;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  line-height: 1;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.modal-close-btn:hover {
  background-color: #F4F5FC;
  color: var(--text-heading);
}

.modal-close-btn:active {
  transform: scale(0.9);
}

.payment-methods-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.payment-methods-grid .radio-card.mini-radio {
  height: 42px;
  padding: 8px 10px;
  font-size: 13px;
  justify-content: center;
}

.payment-methods-grid .radio-card.mini-radio span {
  font-size: 13px;
}

/* Bill Preview Box */
.bill-preview-box {
  background-color: #F8F9FE;
  border: 1px solid #E2E4F2;
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 16px;
}

.bill-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-size: 14.5px;
  color: var(--text-heading);
}

.bill-preview-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bill-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-body);
}

.bill-row strong {
  color: var(--text-heading);
}

.bill-row.total {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-heading);
  margin-top: 4px;
}

.bill-row.total strong {
  color: var(--color-primary);
  font-size: 16px;
}

.bill-divider {
  height: 1px;
  background-color: #E2E4F2;
  margin: 6px 0;
}

.bill-actions-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

@keyframes slideUpSheet {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

/* Keyframes */
@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(0.6);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ==========================================================================
   Narrow Mobile Viewport (360px) Optimization
   Ensures zero wrapping and zero congestion
   ========================================================================== */
@media (max-width: 380px), (max-width: 480px) and (max-height: 700px) {
  .status-bar {
    padding: 10px 18px 6px;
  }

  .screen-content {
    padding: 10px 18px 14px;
  }

  .bottom-bar {
    padding: 10px 18px 16px;
    gap: 10px;
  }

  .bottom-bar.two-buttons {
    gap: 8px;
  }

  .bottom-bar.two-buttons .btn {
    font-size: 13.5px;
  }

  .bottom-bar.two-buttons .btn-secondary {
    flex: 1;
    min-width: 95px;
    padding: 0 10px;
  }

  .bottom-bar.two-buttons .btn-primary {
    flex: 1.5;
    min-width: 155px;
    padding: 0 12px;
  }

  .hero-title {
    font-size: 26px;
    line-height: 1.18;
    margin-bottom: 8px;
  }

  .hero-subtitle {
    font-size: 13.5px;
    line-height: 1.4;
  }

  .feature-card {
    padding: 13px 14px;
    gap: 12px;
    border-radius: 16px;
  }

  .feature-icon-wrapper {
    width: 42px;
    height: 42px;
    min-width: 42px;
  }

  .feature-title {
    font-size: 15px;
  }

  .feature-desc {
    font-size: 12.5px;
  }

  .action-card {
    padding: 14px 16px;
    gap: 12px;
    border-radius: 16px;
  }

  .action-icon-circle {
    width: 42px;
    height: 42px;
    min-width: 42px;
  }

  .action-title {
    font-size: 15px;
  }

  .action-subtitle {
    font-size: 12.5px;
  }

  .radio-card {
    padding: 14px 16px;
    border-radius: 14px;
  }

  .radio-label {
    font-size: 15px;
  }

  .bell-illustration-container {
    min-height: 120px;
    max-height: 180px;
  }

  .bell-svg-wrapper {
    width: 135px;
    height: 162px;
  }

  .bell-glow {
    width: 150px;
    height: 150px;
  }
}

/* Also apply 360px layout when .width-360 is toggled in desktop preview */
.mobile-frame.width-360 .status-bar {
  padding: 10px 18px 6px;
}

.mobile-frame.width-360 .screen-content {
  padding: 10px 18px 14px;
}

.mobile-frame.width-360 .bottom-bar {
  padding: 10px 18px 16px;
  gap: 10px;
}

.mobile-frame.width-360 .bottom-bar.two-buttons {
  gap: 8px;
}

.mobile-frame.width-360 .bottom-bar.two-buttons .btn {
  font-size: 13.5px;
}

.mobile-frame.width-360 .bottom-bar.two-buttons .btn-secondary {
  flex: 1;
  min-width: 95px;
  padding: 0 10px;
}

.mobile-frame.width-360 .bottom-bar.two-buttons .btn-whatsapp {
  flex: 1;
  min-width: 100px;
  padding: 0 10px;
}

.mobile-frame.width-360 .bottom-bar.two-buttons .btn-primary {
  flex: 1.5;
  min-width: 155px;
  padding: 0 12px;
}

.mobile-frame.width-360 .hero-title {
  font-size: 26px;
  line-height: 1.18;
  margin-bottom: 8px;
}

.mobile-frame.width-360 .hero-subtitle {
  font-size: 13.5px;
  line-height: 1.4;
}

.mobile-frame.width-360 .feature-card {
  padding: 13px 14px;
  gap: 12px;
  border-radius: 16px;
}

.mobile-frame.width-360 .feature-icon-wrapper {
  width: 42px;
  height: 42px;
  min-width: 42px;
}

.mobile-frame.width-360 .feature-title {
  font-size: 15px;
}

.mobile-frame.width-360 .feature-desc {
  font-size: 12.5px;
}

.mobile-frame.width-360 .action-card {
  padding: 14px 16px;
  gap: 12px;
  border-radius: 16px;
}

.mobile-frame.width-360 .action-icon-circle {
  width: 42px;
  height: 42px;
  min-width: 42px;
}

.mobile-frame.width-360 .action-title {
  font-size: 15px;
}

.mobile-frame.width-360 .action-subtitle {
  font-size: 12.5px;
}

.mobile-frame.width-360 .radio-card {
  padding: 14px 16px;
  border-radius: 14px;
}

.mobile-frame.width-360 .radio-label {
  font-size: 15px;
}

.mobile-frame.width-360 .bell-illustration-container {
  min-height: 120px;
  max-height: 180px;
}

.mobile-frame.width-360 .bell-svg-wrapper {
  width: 135px;
  height: 162px;
}

/* 360px adjustments for Dashboard */
@media (max-width: 380px) {
  .dashboard-title {
    font-size: 25px;
    margin-bottom: 16px;
  }

  .tenancy-card {
    padding: 14px 16px;
    border-radius: 18px;
  }

  .tenancy-name {
    font-size: 16.5px;
  }

  .tenancy-meta-sub {
    font-size: 12.5px;
  }

  .dual-action-row {
    gap: 8px;
  }

  .dual-action-row .peach-action {
    font-size: 12px;
    padding: 0 10px;
    flex: 1.4;
  }

  .dual-action-row .lavender-action {
    font-size: 12.5px;
    padding: 0 10px;
    flex: 1;
  }

  .recent-item-card {
    padding: 12px 14px;
    border-radius: 14px;
  }

  .recent-item-title {
    font-size: 12.5px;
  }

  .recent-item-amount {
    font-size: 13.5px;
  }
}

.mobile-frame.width-360 .dashboard-title {
  font-size: 25px;
  margin-bottom: 16px;
}

.mobile-frame.width-360 .tenancy-card {
  padding: 14px 16px;
  border-radius: 18px;
}

.mobile-frame.width-360 .tenancy-name {
  font-size: 16.5px;
}

.mobile-frame.width-360 .tenancy-meta-sub {
  font-size: 12.5px;
}

.mobile-frame.width-360 .dual-action-row {
  gap: 8px;
}

.mobile-frame.width-360 .dual-action-row .peach-action {
  font-size: 12px;
  padding: 0 10px;
  flex: 1.4;
}

.mobile-frame.width-360 .dual-action-row .lavender-action {
  font-size: 12.5px;
  padding: 0 10px;
  flex: 1;
}

.mobile-frame.width-360 .recent-item-card {
  padding: 12px 14px;
  border-radius: 14px;
}

.mobile-frame.width-360 .recent-item-title {
  font-size: 12.5px;
}

.mobile-frame.width-360 .recent-item-amount {
  font-size: 13.5px;
}

/* Floating screen picker mini buttons */
.widget-btn.mini-btn {
  font-size: 11px;
  padding: 4px 8px;
}

/* ==========================================================================
   Screen 10: Tenancy Details & Month-wise / Year-wise Status Ledger
   ========================================================================== */
.details-screen-content {
  padding-bottom: 28px;
}

.details-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  position: relative;
}

.details-page-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
  text-align: center;
  flex: 1;
  margin: 0 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu-trigger-wrapper {
  position: relative;
}

/* 3-Dots Floating Menu */
.floating-action-menu {
  position: absolute;
  top: 44px;
  right: 0;
  z-index: 60;
  background-color: #FFFFFF;
  border-radius: 16px;
  padding: 6px;
  box-shadow: 0 10px 30px rgba(14, 19, 38, 0.12), 0 2px 6px rgba(14, 19, 38, 0.04);
  border: 1px solid #E2E4F2;
  min-width: 155px;
  animation: popIn 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-action-menu.hidden {
  display: none;
}

.menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 14px;
  background: transparent;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-heading);
  cursor: pointer;
  text-align: left;
  transition: background-color 0.12s ease;
}

.menu-item:hover {
  background-color: #F4F5FC;
}

.menu-item svg {
  width: 17px;
  height: 17px;
  color: var(--text-body);
}

.menu-item.danger {
  color: #DC2626;
}

.menu-item.danger svg {
  color: #DC2626;
}

.menu-divider {
  height: 1px;
  background-color: #EEF0F8;
  margin: 4px 6px;
}

/* Summary Card */
.details-summary-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 20px 22px;
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
  border: 1px solid rgba(226, 228, 242, 0.7);
  margin-bottom: 24px;
}

.summary-card-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.summary-card-sublabel {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-body);
}

.bills-count-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 9999px;
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
}

.summary-card-big-amount {
  font-size: 28px;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.summary-card-meta-line {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-body);
}

/* History / Month Section */
.details-history-section {
  margin-bottom: 20px;
}

.details-section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
}

.header-titles {
  display: flex;
  flex-direction: column;
}

.details-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 2px;
}

.details-section-subtitle {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}

/* Month-wise Year Filter Bar */
.year-filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  gap: 8px;
  flex-wrap: wrap;
}

.year-dropdown {
  background-color: #FFFFFF;
  border: 1.5px solid #E2E4F2;
  border-radius: 9999px;
  padding: 4px 12px;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-heading);
  outline: none;
  cursor: pointer;
}

.status-summary-chips {
  display: flex;
  gap: 6px;
}

.status-chip {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
  white-space: nowrap;
}

.chip-paid {
  background-color: #DCFCE7;
  color: #16A34A;
  border: 1px solid #BBF7D0;
}

.chip-due {
  background-color: #FEE2E2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.chip-upcoming {
  background-color: #E0F2FE;
  color: #0284C7;
  border: 1px solid #BAE6FD;
}

/* Month Cards Stack */
.month-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.month-card {
  background-color: var(--bg-surface);
  border-radius: 14px;
  padding: 11px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 2px 6px rgba(28, 33, 66, 0.02);
  transition: transform 0.12s ease;
}

.month-card:hover {
  transform: translateY(-1px);
}

.month-card.month-overdue {
  border-left: 4px solid #DC2626;
  background: linear-gradient(90deg, rgba(254, 226, 226, 0.28) 0%, #FFFFFF 35%);
}

.month-card.month-paid {
  border-left: 4px solid #16A34A;
}

.month-card.month-upcoming {
  border-left: 4px solid #0284C7;
  opacity: 0.9;
}

.month-card-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.month-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 8px;
  text-align: center;
  min-width: 54px;
  line-height: 1.2;
}

.month-badge.paid {
  background-color: #E8F8EE;
  color: #16A34A;
}

.month-badge.overdue {
  background-color: #FEE2E2;
  color: #DC2626;
}

.month-badge.upcoming {
  background-color: #E0F2FE;
  color: #0284C7;
}

.month-details-col {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.month-name {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.month-subtext {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--text-muted);
}

.month-card-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.month-amount {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.month-amount.danger {
  color: #DC2626;
}

.month-amount.muted {
  color: var(--text-subtle);
}

.month-status-pill {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 9999px;
  line-height: 1;
}

.month-status-pill.paid {
  background-color: #DCFCE7;
  color: #16A34A;
}

.month-status-pill.overdue {
  background-color: #FEE2E2;
  color: #DC2626;
}

.month-status-pill.upcoming {
  background-color: #E0F2FE;
  color: #0284C7;
}

/* 360px adjustments for Details */
@media (max-width: 380px) {
  .details-summary-card {
    padding: 16px 16px;
  }
  .summary-card-big-amount {
    font-size: 24px;
  }
  .month-card {
    padding: 10px 10px;
  }
  .month-name {
    font-size: 12.5px;
  }
  .month-subtext {
    font-size: 10.5px;
  }
  .month-amount {
    font-size: 12.5px;
  }
}

.mobile-frame.width-360 .details-summary-card {
  padding: 16px 16px;
}

.mobile-frame.width-360 .summary-card-big-amount {
  font-size: 24px;
}

.mobile-frame.width-360 .month-card {
  padding: 10px 10px;
}

.mobile-frame.width-360 .month-name {
  font-size: 12.5px;
}

.mobile-frame.width-360 .month-subtext {
  font-size: 10.5px;
}

.mobile-frame.width-360 .month-amount {
  font-size: 12.5px;
}

/* ==========================================================================
   Screen 11: Edit Tenancy & Rent Revision Feature
   ========================================================================== */
.field-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  gap: 8px;
}

.btn-text-action {
  background: transparent;
  border: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 8px;
  white-space: nowrap;
  transition: background-color 0.15s ease, transform 0.12s ease;
}

.btn-text-action:hover {
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary-active);
}

.btn-text-action:active {
  transform: scale(0.96);
}

.btn-text-action svg {
  width: 14px;
  height: 14px;
  stroke-width: 2.2;
}

/* Scheduled Revision Banner */
.scheduled-revision-banner {
  background-color: #EFF6FF;
  border: 1.5px solid #BFDBFE;
  border-radius: 14px;
  padding: 12px 14px;
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: popIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.scheduled-revision-banner.hidden {
  display: none;
}

.banner-icon {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  background-color: #DBEAFE;
  color: #1D4ED8;
  display: flex;
  align-items: center;
  justify-content: center;
}

.banner-icon svg {
  width: 17px;
  height: 17px;
}

.banner-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 2px;
}

.banner-content strong {
  font-size: 13px;
  color: #1E3A8A;
  font-weight: 700;
  line-height: 1.3;
}

.banner-content .banner-sub {
  font-size: 11.5px;
  color: #3B82F6;
  line-height: 1.3;
}

.btn-banner-remove {
  background: transparent;
  border: none;
  font-size: 14px;
  color: #60A5FA;
  cursor: pointer;
  padding: 4px;
  border-radius: 50%;
  line-height: 1;
  transition: color 0.15s ease;
}

.btn-banner-remove:hover {
  color: #DC2626;
}

/* 360px adjustments for Edit Screen */
@media (max-width: 380px) {
  .field-label-row {
    flex-wrap: wrap;
    gap: 4px;
  }
  .btn-text-action {
    font-size: 11.5px;
    padding: 2px 4px;
  }
  .scheduled-revision-banner {
    padding: 10px 10px;
  }
  .banner-content strong {
    font-size: 12px;
  }
}

.mobile-frame.width-360 .field-label-row {
  flex-wrap: wrap;
  gap: 4px;
}

.mobile-frame.width-360 .btn-text-action {
  font-size: 11.5px;
  padding: 2px 4px;
}

.mobile-frame.width-360 .scheduled-revision-banner {
  padding: 10px 10px;
}

.mobile-frame.width-360 .banner-content strong {
  font-size: 12px;
}

/* ==========================================================================
   Screen 12: Dedicated Record Payment Page & Month-Wise Settlement
   ========================================================================== */
.amount-shortcut-chips {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.shortcut-chip {
  background-color: #FFFFFF;
  border: 1.5px solid #E2E4F2;
  border-radius: 9999px;
  padding: 5px 12px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
}

.shortcut-chip:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.shortcut-chip.active {
  background-color: var(--bg-accent-subtle);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.mode-pill-content {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--text-heading);
}

.online-channel-subfields {
  background-color: #F8F9FE;
  border: 1px solid #E2E4F2;
  border-radius: 14px;
  padding: 12px;
  margin-top: 10px;
  animation: fadeIn 0.15s ease;
}

.online-channel-subfields.hidden {
  display: none;
}

.channel-chips-row {
  display: flex;
  gap: 8px;
}

.channel-chip {
  flex: 1;
  text-align: center;
  background-color: #FFFFFF;
  border: 1.5px solid #E2E4F2;
  border-radius: 10px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.channel-chip input {
  display: none;
}

.channel-chip.selected {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background-color: rgba(84, 82, 236, 0.05);
}

/* Month Settle Card */
.month-settle-card {
  background-color: var(--bg-surface);
  border: 1.5px solid #E2E4F2;
  border-radius: 16px;
  padding: 14px 16px;
  margin-top: 6px;
}

.settle-card-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 600;
  margin-bottom: 12px;
  padding: 8px 10px;
  border-radius: 10px;
}

.settle-card-alert.warning {
  background-color: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.settle-card-alert.success {
  background-color: #DCFCE7;
  color: #16A34A;
  border: 1px solid #BBF7D0;
}

.months-select-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.month-select-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border: 1.5px solid #E2E4F2;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.month-select-option input {
  display: none;
}

.month-select-option.selected {
  border-color: var(--color-primary);
  background-color: rgba(84, 82, 236, 0.04);
}

.month-opt-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.month-opt-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.month-opt-sub {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-muted);
}

.custom-checkbox {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border-radius: 6px;
  border: 1.5px solid #C4C8D8;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.month-select-option.selected .custom-checkbox {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
  background-size: 13px;
  background-position: center;
  background-repeat: no-repeat;
}

/* No Pending Months View */
.current-month-settled-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background-color: #F8F9FE;
  border-radius: 12px;
  border: 1px solid #E2E4F2;
}

.current-month-icon {
  font-size: 20px;
  margin-right: 10px;
}

.current-month-text {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.current-month-text strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-heading);
}

.current-month-text span {
  font-size: 12px;
  color: var(--text-body);
}

select.form-input {
  cursor: pointer;
  background-color: var(--bg-surface);
  color: var(--text-heading);
}

select.form-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Waterfall Ledger & Auto-Allocation */
.waterfall-header-clean {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid #EAEBF6;
}

.waterfall-clean-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-heading);
}

.badge-pill.auto-badge {
  background-color: #EDE9FE;
  color: #6D28D9;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
  flex-shrink: 0;
}

.waterfall-items-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.waterfall-item-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1.5px solid #E2E4F2;
  background-color: #FFFFFF;
  transition: all 0.15s ease;
}

.waterfall-item-card.settled {
  border-color: #BBF7D0;
  background-color: #F0FDF4;
}

.waterfall-item-card.partial {
  border-color: #FDE68A;
  background-color: #FFFBEB;
}

.waterfall-item-card.advance {
  border-color: #BAE6FD;
  background-color: #F0F9FF;
}

.waterfall-item-card.past-due {
  border-color: #FECACA;
  background-color: #FEF2F2;
}

/* 2-Row Layout inside each card for 100% Alignment Guarantee */
.waterfall-card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.waterfall-card-month-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.waterfall-status-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.waterfall-item-card.settled .waterfall-status-icon {
  background-color: #DCFCE7;
  color: #16A34A;
}

.waterfall-item-card.partial .waterfall-status-icon {
  background-color: #FEF3C7;
  color: #B45309;
}

.waterfall-item-card.advance .waterfall-status-icon {
  background-color: #E0F2FE;
  color: #0284C7;
}

.waterfall-item-card.past-due .waterfall-status-icon {
  background-color: #FEE2E2;
  color: #DC2626;
}

.waterfall-month-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-heading);
}

.waterfall-amount-applied {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
}

.waterfall-card-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-left: 30px; /* Aligns precisely under month title, clearing 22px icon + 8px gap */
}

.waterfall-month-note {
  font-size: 12px;
  color: var(--text-body);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Concise Status Badges */
.badge-pill.badge-settled {
  background-color: #DCFCE7;
  color: #16A34A;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  white-space: nowrap;
}

.badge-pill.badge-partial {
  background-color: #FEF3C7;
  color: #B45309;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  white-space: nowrap;
}

.badge-pill.badge-advance {
  background-color: #E0F2FE;
  color: #0284C7;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  white-space: nowrap;
}

.badge-pill.badge-overdue {
  background-color: #FEE2E2;
  color: #DC2626;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  white-space: nowrap;
}

.waterfall-settled-notice {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: #F0FDF4;
  border: 1.5px solid #BBF7D0;
  border-radius: 12px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 500;
  color: #15803D;
  margin-bottom: 8px;
  line-height: 1.35;
}

.waterfall-settled-notice strong {
  font-weight: 700;
  color: #166534;
}

.waterfall-settled-notice .notice-check {
  font-size: 12px;
  font-weight: 700;
  background-color: #DCFCE7;
  color: #16A34A;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.waterfall-footer {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid #EAEBF6;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.waterfall-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
}

.waterfall-footer-row .footer-label {
  color: var(--text-body);
  font-weight: 500;
}

.waterfall-footer-row .footer-val {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

/* 360px adjustments for Record Payment Page */
@media (max-width: 380px) {
  .shortcut-chip {
    font-size: 11px;
    padding: 4px 8px;
  }
  .channel-chip {
    font-size: 11px;
    padding: 6px 4px;
  }
  .month-opt-title {
    font-size: 12.5px;
  }
  .month-opt-sub {
    font-size: 10.5px;
  }
}

.mobile-frame.width-360 .shortcut-chip {
  font-size: 11px;
  padding: 4px 8px;
}

.mobile-frame.width-360 .channel-chip {
  font-size: 11px;
  padding: 6px 4px;
}

.mobile-frame.width-360 .month-opt-title {
  font-size: 12.5px;
}

.mobile-frame.width-360 .month-opt-sub {
  font-size: 10.5px;
}

/* ==========================================================================
   Screens 13, 14, 15: Bill Generation, Review & Invoice Details
   ========================================================================== */
.form-textarea {
  min-height: 80px;
  resize: none;
  font-family: inherit;
  font-size: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-input);
  line-height: 1.45;
}

.review-tenancy-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 18px 20px;
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
}

.review-prop-title {
  font-size: 19px;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.01em;
  margin-top: 2px;
}

.breakdown-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 18px 20px;
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
}

.breakdown-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 11px;
}

.breakdown-row.complex {
  align-items: flex-start;
}

.breakdown-label-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.breakdown-label {
  font-size: 14px;
  color: var(--text-body);
  font-weight: 500;
}

.breakdown-subcalc {
  font-size: 11.5px;
  color: var(--text-muted);
}

.breakdown-value {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-heading);
}

.breakdown-row.subtotal .breakdown-label,
.breakdown-row.subtotal .breakdown-value {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-heading);
}

.breakdown-row.deduction .breakdown-label,
.breakdown-row.deduction .breakdown-value {
  color: #DC2626;
  font-weight: 700;
}

.breakdown-row.net-payable .breakdown-label {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-heading);
}

.breakdown-row.net-payable .breakdown-value {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-heading);
}

/* ==========================================================================
   Screen 16: Settings & System Preferences
   ========================================================================== */
.settings-group-card {
  flex-shrink: 0;
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
  overflow: hidden;
}

.settings-list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  cursor: pointer;
  transition: background-color 0.15s ease;
  user-select: none;
}

.settings-list-item:hover {
  background-color: #FAFAFD;
}

.settings-list-item:active {
  background-color: #F0F2FA;
}

.settings-item-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.settings-item-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-heading);
}

.settings-item-icon svg {
  width: 20px;
  height: 20px;
}

.settings-item-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-heading);
}

.settings-chevron {
  width: 18px;
  height: 18px;
  color: var(--text-subtle);
}

.settings-divider {
  height: 1px;
  background-color: #F0F2FA;
  margin: 0 20px;
}

/* ==========================================================================
   Screen 17 & 18: Archived Tenancies & Archived Details
   ========================================================================== */
.archived-tenancy-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 18px 20px;
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.archived-tenancy-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(28, 33, 66, 0.08);
}

.archived-tenancy-card:active {
  transform: scale(0.98);
}

.archived-card-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* 360px viewport overrides for Screens 13-18 */
@media (max-width: 380px) {
  .review-prop-title {
    font-size: 17px;
  }
  .breakdown-label {
    font-size: 13px;
  }
  .breakdown-value {
    font-size: 13.5px;
  }
  .settings-list-item {
    padding: 14px 16px;
  }
  .settings-item-label {
    font-size: 14px;
  }
  .backup-action-card {
    padding: 18px 16px;
    gap: 14px;
  }
  .backup-card-desc {
    font-size: 13.5px;
  }
  .backup-btn {
    font-size: 14.5px;
  }
}

.mobile-frame.width-360 .review-prop-title {
  font-size: 17px;
}

.mobile-frame.width-360 .breakdown-label {
  font-size: 13px;
}

.mobile-frame.width-360 .breakdown-value {
  font-size: 13.5px;
}

.mobile-frame.width-360 .settings-list-item {
  padding: 14px 16px;
}

.mobile-frame.width-360 .settings-item-label {
  font-size: 14px;
}

.mobile-frame.width-360 .backup-action-card {
  padding: 18px 16px;
  gap: 14px;
}

.mobile-frame.width-360 .backup-card-desc {
  font-size: 13.5px;
}

.mobile-frame.width-360 .backup-btn {
  font-size: 14.5px;
}

/* ==========================================================================
   Screen 19: Backup & Restore
   ========================================================================== */
.backup-action-card {
  background-color: var(--bg-surface);
  border-radius: 24px;
  padding: 24px 20px;
  border: 1px solid rgba(226, 228, 242, 0.7);
  box-shadow: 0 4px 18px rgba(28, 33, 66, 0.04);
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 20px;
}

.backup-card-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 8px;
}

.backup-card-desc {
  font-size: 14.5px;
  line-height: 1.48;
  color: var(--text-body);
  text-wrap: balance;
  text-wrap: pretty;
}

.backup-btn {
  width: 100%;
  height: 54px;
  min-height: 54px;
  font-size: 15.5px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-restore {
  background-color: #D4D5F8;
  color: var(--color-primary);
  border: none;
  box-shadow: 0 4px 14px rgba(84, 82, 236, 0.12);
}

.btn-restore:hover {
  background-color: #C6C8F5;
  color: var(--color-primary-active);
}

.btn-restore:active {
  transform: scale(0.98);
}

/* ==========================================================================
   Screen 20: Supabase Cloud Authentication & Family Sharing
   ========================================================================== */
.auth-brand-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.brand-icon-wrapper.auth-icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  background-color: var(--color-primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px var(--color-primary-focus);
}

.brand-icon-wrapper.auth-icon svg {
  width: 30px;
  height: 30px;
}

.auth-badge-cloud {
  display: inline-block;
  background-color: #E8E7FB;
  color: var(--color-primary);
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 9999px;
  margin-top: 6px;
  letter-spacing: 0.3px;
}

.auth-quick-roles {
  background-color: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(226, 228, 242, 0.8);
  border-radius: 18px;
  padding: 12px 14px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quick-role-chips {
  display: flex;
  gap: 8px;
}

.role-chip {
  flex: 1;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1.5px solid #E2E4F2;
  background-color: #FFFFFF;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-heading);
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.role-chip:hover {
  background-color: #F8F9FE;
  border-color: #D6D9EE;
}

.role-chip.active {
  background-color: var(--color-primary);
  color: #FFFFFF;
  border-color: var(--color-primary);
  box-shadow: 0 4px 12px rgba(84, 82, 236, 0.3);
}

.auth-card-surface {
  background-color: var(--bg-surface);
  border-radius: var(--radius-card);
  padding: 22px 20px;
  border: 1px solid rgba(226, 228, 242, 0.8);
  box-shadow: 0 6px 20px rgba(28, 33, 66, 0.05);
}

.auth-toggle-row {
  margin-top: 20px;
  text-align: center;
  font-size: 13.5px;
  color: var(--text-body);
}

.input-trailing-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
}

.input-trailing-btn:hover {
  color: var(--text-heading);
}

/* Family Members Stack in Modal */
.family-members-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.family-member-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background-color: #F8F9FE;
  border: 1px solid #E2E4F2;
  border-radius: 14px;
}

.member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: #E8E7FB;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.member-avatar.owner {
  background-color: #FEF3C7;
}

.member-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.member-email {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.member-role-tag {
  font-size: 11.5px;
  color: var(--text-muted);
}

.member-role-tag.owner-tag {
  color: #16A34A;
  font-weight: 600;
}

.btn-remove-member {
  background: transparent;
  border: none;
  color: #DC2626;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background-color 0.15s ease;
}

.btn-remove-member:hover {
  background-color: #FEE2E2;
}

/* Live Supabase Cloud Indicator (Hidden per User Request) */
.cloud-status-badge {
  display: none !important;
}

.cloud-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2E7D32;
  box-shadow: 0 0 0 0 rgba(46, 125, 50, 0.7);
  animation: cloudPulse 2s infinite;
}

@keyframes cloudPulse {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(46, 125, 50, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(46, 125, 50, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(46, 125, 50, 0);
  }
}

.cloud-user-email {
  color: #2E7D32;
  opacity: 0.85;
  font-weight: 500;
}

/* App Splash Screen — Zero flicker on boot */
.app-splash-screen {
  position: absolute;
  inset: 0;
  background-color: var(--bg-canvas);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.25s ease-out, visibility 0.25s ease-out;
}

.app-splash-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.splash-brand-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.splash-spinner {
  width: 26px;
  height: 26px;
  border: 3px solid rgba(84, 82, 236, 0.2);
  border-top-color: #5452EC;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-top: 10px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Month Card Future Cycle Styling */
.month-card.month-future {
  border-left: 4px solid #CBD5E1;
  opacity: 0.85;
}

.month-badge.future {
  background-color: #F1F5F9;
  color: #64748B;
}

.month-status-pill.future {
  background-color: #F1F5F9;
  color: #64748B;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 9999px;
}

/* Floating Action Menu Elevation & Safety */
.floating-action-menu {
  z-index: 1000 !important;
}

/* Danger Zone Cards */
.settings-group-card.danger-zone {
  border-color: #FECACA !important;
  background: #FFFBFB;
}


.settings-footer {
  flex-shrink: 0;
  padding-bottom: 24px;
}

/* ==========================================================================
   SCREEN 21: MOVIE-TICKET INSPIRED PAYMENT VOUCHER & RECEIPT
   ========================================================================== */

.receipt-screen-content {
  padding: 16px 20px 14px;
  display: flex;
  flex-direction: column;
}

.receipt-ticket-card {
  position: relative;
  background-color: var(--bg-surface);
  border-radius: 20px;
  border: 1px solid rgba(226, 228, 242, 0.95);
  box-shadow: 0 10px 30px rgba(28, 33, 66, 0.08), 0 2px 6px rgba(28, 33, 66, 0.03);
  margin-top: 6px;
  margin-bottom: 12px;
  overflow: hidden;
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Upper Ticket Section (Spacious Financial & Tenant Breakdown) */
.receipt-card-upper {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
}

.receipt-ticket-header {
  display: flex;
  flex-direction: column;
  padding: 24px 22px 16px;
}

.receipt-header-left {
  width: 100%;
  display: flex;
  flex-direction: column;
}

.receipt-brand-tag {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.09em;
  color: var(--color-primary);
  text-transform: uppercase;
  margin-bottom: 8px;
  line-height: 1.3;
}

.receipt-prop-title {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.01em;
  margin: 0 0 12px 0;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.receipt-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 2px;
}

.receipt-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-body);
  background: #F1F3FA;
  padding: 6px 13px;
  border-radius: 9999px;
  line-height: 1.4;
}

.receipt-meta-pill svg {
  width: 15px;
  height: 15px;
  color: var(--color-primary);
  flex-shrink: 0;
}

/* 2-Column Key Highlights Grid (Clean Direct Surface - No Truncation) */
.receipt-key-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  padding: 10px 22px 14px;
  margin: 0;
  background: transparent;
  border: none;
}

.receipt-grid-col {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.receipt-col-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #E8E7FB;
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.receipt-col-icon svg {
  width: 20px;
  height: 20px;
}

.receipt-col-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.receipt-col-val {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
  line-height: 1.4;
}

.receipt-col-sub {
  font-size: 12.5px;
  color: var(--text-muted);
  white-space: nowrap;
  line-height: 1.4;
}

.receipt-solid-divider {
  height: 1px;
  background: #ECEEF8;
  margin: 16px 22px;
}

/* Amount Hero Block (Clean, high contrast, strict NO-WRAP - No Stamp) */
.receipt-amount-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 22px 8px;
}

.receipt-amount-left {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  white-space: nowrap;
  flex-shrink: 0;
}

.receipt-amount-caption {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1.35;
}

.receipt-amount-number {
  font-size: clamp(26px, 7vw, 30px);
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.02em;
  line-height: 1.25;
  white-space: nowrap !important;
}

/* Details Section */
.receipt-body-details {
  padding: 0 22px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.receipt-detail-block {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.receipt-detail-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 1.35;
}

.receipt-detail-header svg {
  width: 15px;
  height: 15px;
  color: var(--color-primary);
  flex-shrink: 0;
}

.receipt-detail-body {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-heading);
  margin: 0;
  line-height: 1.55;
}

/* Settlement Allocation Rows (Short month names and clean currency) */
.receipt-allocations-table {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 6px;
}

.receipt-alloc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #F8F9FE;
  border: 1px solid #ECEEF8;
  border-radius: 14px;
  gap: 12px;
}

.receipt-alloc-row-left {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  flex: 1;
}

.receipt-alloc-row-icon {
  font-size: 13.5px;
  line-height: 1;
  flex-shrink: 0;
}

.receipt-alloc-row-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
  line-height: 1.4;
}

.receipt-alloc-row-right {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
}

.receipt-alloc-tag {
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 7px;
  white-space: nowrap;
  line-height: 1.25;
}

.receipt-alloc-tag.cleared {
  background: #DCFCE7;
  color: #16A34A;
}

.receipt-alloc-tag.advance {
  background: #E0F2FE;
  color: #0284C7;
}

.receipt-alloc-tag.partial {
  background: #FEF3C7;
  color: #B45309;
}

.receipt-alloc-row-amount {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--text-heading);
  white-space: nowrap;
  line-height: 1.3;
}

/* Lower Ticket Section (Pinned Authentic Perforation & Barcode Stub) */
.receipt-card-lower {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  margin-top: auto;
}

/* Perforation Zone with Authentic Inward Ticket Cutouts */
.receipt-perforation-zone {
  position: relative;
  display: flex;
  align-items: center;
  height: 32px;
  margin: 20px 0 12px;
}

.receipt-notch {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--bg-canvas);
  z-index: 2;
}

.receipt-notch.notch-left {
  left: -16px;
  box-shadow: inset -1.5px 0 0 rgba(226, 228, 242, 0.95);
}

.receipt-notch.notch-right {
  right: -16px;
  box-shadow: inset 1.5px 0 0 rgba(226, 228, 242, 0.95);
}

.receipt-cutline {
  width: 100%;
  margin: 0 22px;
  border-top: 2px dashed #CBD5E1;
}

/* Ticket Stub */
.receipt-stub-section {
  padding: 12px 22px 26px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
}

.receipt-barcode-wrap {
  width: 82%;
  max-width: 270px;
  height: 52px;
  margin: 8px auto 14px;
  color: #0E1326;
  flex-shrink: 0;
}

.barcode-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.receipt-order-id {
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  color: #334155;
  letter-spacing: 0.08em;
  line-height: 1.4;
  margin-bottom: 8px;
}

.receipt-verify-text {
  font-size: 12.5px;
  color: #64748B;
  max-width: 290px;
  line-height: 1.6;
  margin: 0 auto;
}

@media (max-width: 380px) {
  .receipt-screen-content {
    padding: 12px 14px 10px;
  }
  .receipt-ticket-header {
    padding: 18px 16px 12px;
  }
  .receipt-prop-title {
    font-size: 20px;
  }
  .receipt-key-grid {
    padding: 8px 16px 12px;
    gap: 12px;
  }
  .receipt-col-val {
    font-size: 13.5px;
  }
  .receipt-amount-hero {
    padding: 4px 16px 6px;
  }
  .receipt-amount-number {
    font-size: 24px;
  }
  .receipt-body-details {
    padding: 0 16px;
    gap: 14px;
  }
  .receipt-alloc-row {
    padding: 10px 12px;
  }
  .receipt-solid-divider {
    margin: 12px 16px;
  }
  .receipt-cutline {
    margin: 0 16px;
  }
  .receipt-stub-section {
    padding: 10px 16px 20px;
  }
}

/* ==========================================================================
   Share Receipt Modal Options (Send as Text vs Send as Image)
   ========================================================================== */
.share-choice-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 4px 0 12px;
}

.share-choice-subtitle {
  font-size: 14px;
  color: var(--text-body);
  line-height: 1.5;
  margin: 0;
}

.share-choice-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.share-choice-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background-color: #F8F9FE;
  border: 1.5px solid #E2E4F2;
  border-radius: 18px;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: transform 0.15s var(--ease-spring), border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  width: 100%;
}

.share-choice-card:hover {
  background-color: #FFFFFF;
  border-color: var(--color-primary);
  box-shadow: 0 6px 20px rgba(84, 82, 236, 0.12);
  transform: translateY(-1px);
}

.share-choice-card:active {
  transform: scale(0.98);
}

.share-choice-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.share-choice-icon svg {
  width: 22px;
  height: 22px;
}

.share-choice-icon.text-icon {
  background-color: #E8E7FB;
  color: var(--color-primary);
}

.share-choice-icon.image-icon {
  background-color: #DCFCE7;
  color: #16A34A;
}

.share-choice-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.share-choice-name {
  font-size: 15.5px;
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.25;
}

.share-choice-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.4;
}

.share-choice-chevron {
  width: 20px;
  height: 20px;
  color: #9FA5BC;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.share-choice-chevron svg {
  width: 18px;
  height: 18px;
}

@media (max-width: 380px) {
  .share-choice-card {
    padding: 13px 14px;
    gap: 12px;
  }
  .share-choice-icon {
    width: 40px;
    height: 40px;
  }
  .share-choice-icon svg {
    width: 20px;
    height: 20px;
  }
  .share-choice-name {
    font-size: 14.5px;
  }
  .share-choice-desc {
    font-size: 12px;
  }
}

/* ==========================================================================
   Screen 22: Dedicated Family Sharing & Selective Access Control
   ========================================================================== */
.incoming-shares-alert-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%);
  border: 1.5px solid #F59E0B;
  border-radius: 16px;
  padding: 12px 14px;
  margin-bottom: 14px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.15);
  transition: transform 0.15s ease;
}

.incoming-shares-alert-banner:hover {
  transform: translateY(-1px);
}

.share-alert-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.share-alert-text {
  flex: 1;
  font-size: 13px;
  color: #92400E;
  line-height: 1.35;
}

.share-alert-cta {
  font-size: 12.5px;
  font-weight: 700;
  color: #B45309;
  white-space: nowrap;
}

.family-screen-content {
  padding-bottom: 90px;
}

.family-tab-segmented-bar {
  display: flex;
  background-color: #E2E4F2;
  border-radius: 9999px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 20px;
}

.family-tab-btn {
  flex: 1;
  height: 44px;
  min-height: 44px;
  border-radius: 9999px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-body);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.family-tab-btn.active {
  background-color: #FFFFFF;
  color: var(--color-primary);
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(14, 19, 38, 0.08);
}

.family-tab-count-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9999px;
  background-color: var(--bg-accent-subtle);
  color: var(--color-primary);
  line-height: 1;
}

.family-tab-btn.active .family-tab-count-badge {
  background-color: var(--color-primary);
  color: #FFFFFF;
}

.family-section-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.family-group-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.family-group-heading {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-heading);
}

.family-group-sub {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.family-cards-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.family-request-card,
.family-outgoing-card {
  background-color: var(--bg-surface);
  border-radius: 20px;
  border: 1.5px solid #E2E4F2;
  padding: 16px;
  box-shadow: 0 4px 16px rgba(28, 33, 66, 0.04);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.family-card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.family-card-user-info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.family-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #E8E7FB;
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
}

.family-user-texts {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.family-user-email {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.family-user-sub {
  font-size: 11.5px;
  color: var(--text-muted);
}

.family-role-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
  white-space: nowrap;
  flex-shrink: 0;
}

.family-role-badge.manager {
  background-color: #EDE9FE;
  color: #6D28D9;
  border: 1px solid #DDD6FE;
}

.family-role-badge.viewer {
  background-color: #E0F2FE;
  color: #0284C7;
  border: 1px solid #BAE6FD;
}

.family-properties-box {
  background-color: #F8F9FE;
  border-radius: 12px;
  padding: 10px 12px;
  border: 1px solid #EAEBF6;
}

.family-prop-heading {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
  display: block;
}

.family-prop-chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.family-prop-chip {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-heading);
  background-color: #FFFFFF;
  border: 1px solid #E2E4F2;
  padding: 3px 8px;
  border-radius: 6px;
}

.family-card-actions-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
}

.btn-share-approve {
  flex: 1.4;
  height: 42px;
  min-height: 42px;
  background-color: #16A34A;
  color: #FFFFFF;
  border: none;
  border-radius: 9999px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(22, 163, 74, 0.25);
  transition: transform 0.12s ease;
}

.btn-share-approve:hover {
  background-color: #15803D;
  transform: translateY(-1px);
}

.btn-share-deny {
  flex: 1;
  height: 42px;
  min-height: 42px;
  background-color: #FFFFFF;
  color: #DC2626;
  border: 1.5px solid #FECACA;
  border-radius: 9999px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.12s ease;
}

.btn-share-deny:hover {
  background-color: #FEF2F2;
  border-color: #DC2626;
}

.btn-share-revoke,
.btn-share-leave {
  height: 38px;
  min-height: 38px;
  padding: 0 16px;
  background-color: #FFFFFF;
  color: #DC2626;
  border: 1.5px solid #FECACA;
  border-radius: 9999px;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.12s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-share-revoke:hover,
.btn-share-leave:hover {
  border-color: #DC2626;
  background-color: #FEF2F2;
}

/* Outgoing Share Card: Role Switcher */
.share-role-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background-color: #F8F9FE;
  border-radius: 14px;
  border: 1px solid #EAEBF6;
}

.role-switch-left {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.role-switch-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-heading);
}

.role-switch-sub {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.role-segmented-switcher {
  display: inline-flex;
  align-items: center;
  background-color: #E8EAF6;
  border-radius: 9999px;
  padding: 2.5px;
  flex-shrink: 0;
  border: 1px solid #D9DCF0;
}

.role-segment-btn {
  height: 28px;
  padding: 0 10px;
  border: none;
  background: transparent;
  color: var(--text-body);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.role-segment-btn:hover:not(.active) {
  color: var(--text-heading);
  background-color: rgba(255, 255, 255, 0.6);
}

.role-segment-btn.active.manager {
  background-color: #5452EC;
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(84, 82, 236, 0.3);
  font-weight: 700;
}

.role-segment-btn.active.viewer {
  background-color: #0284C7;
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.3);
  font-weight: 700;
}

.role-segment-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 380px) {
  .share-role-switch-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .role-segmented-switcher {
    width: 100%;
    display: flex;
  }
  .role-segment-btn {
    flex: 1;
    justify-content: center;
  }
}

.active-sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #EFF6FF;
  border: 1px solid #BFDBFE;
  color: #1D4ED8;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11.5px;
  font-weight: 600;
  width: fit-content;
}

.sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #2563EB;
  animation: pulse-dot 1.8s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

.family-status-pill {
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 9999px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.family-status-pill.pending {
  background-color: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.family-status-pill.approved {
  background-color: #DCFCE7;
  color: #16A34A;
  border: 1px solid #BBF7D0;
}

.family-status-pill.denied {
  background-color: #FEE2E2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.family-empty-box {
  background-color: #FFFFFF;
  border: 1.5px dashed #D6D9EE;
  border-radius: 20px;
  padding: 32px 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 10px;
}

.family-empty-icon {
  font-size: 36px;
  margin-bottom: 10px;
}

.family-empty-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 4px;
}

.family-empty-desc {
  font-size: 13px;
  color: var(--text-body);
  max-width: 280px;
  line-height: 1.4;
}

.share-tenancies-checklist {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 240px;
  overflow-y: auto;
  padding: 4px 2px;
}

.share-check-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background-color: var(--bg-surface);
  border: 1.5px solid #E2E4F2;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 6px rgba(28, 33, 66, 0.03);
  user-select: none;
}

.share-check-item input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.share-check-item:hover {
  border-color: #D2D5EE;
  box-shadow: 0 4px 12px rgba(28, 33, 66, 0.06);
}

.share-check-item.selected {
  border-color: var(--color-primary);
  background-color: #F7F7FE;
  box-shadow: 0 4px 14px rgba(84, 82, 236, 0.12);
}

.share-card-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.share-prop-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: #E8E7FB;
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.share-check-item.selected .share-prop-icon {
  background: var(--color-primary);
  color: #FFFFFF;
}

.share-prop-icon svg {
  width: 20px;
  height: 20px;
}

.share-prop-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.share-prop-name {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-heading);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.share-prop-rent {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}

.share-card-check {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid #D6D8EC;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.share-card-check svg {
  width: 13px;
  height: 13px;
  stroke: #FFFFFF;
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.15s ease;
}

.share-check-item.selected .share-card-check {
  background: var(--color-primary);
  border-color: var(--color-primary);
}

.share-check-item.selected .share-card-check svg {
  opacity: 1;
  transform: scale(1);
}

.share-role-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.share-role-card {
  padding: 12px 10px !important;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.role-card-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.role-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-heading);
}

.role-desc {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.35;
}

/* ==========================================================================
   Offline Indicator Banner & Read-Only Badge
   ========================================================================== */
.offline-indicator-banner {
  background: #FEF3C7;
  color: #92400E;
  border-bottom: 1px solid #FDE68A;
  padding: 8px 16px;
  font-size: 12.5px;
  font-weight: 600;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: sticky;
  top: 0;
  z-index: 100;
  animation: slideDownBanner 0.25s ease-out;
}

@keyframes slideDownBanner {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}



