:root {
  --teal-primary: #0D9488;
  --teal-dark: #0F766E;
  --teal-tint: #E6F7F5;
  --text-primary: #111827;
  --text-secondary: #6B7280;
  --surface: #FFFFFF;
  --background: #F9FAFB;
  --border: #F3F4F6;
  --text-xs: 12px;
  --text-sm: 13px;
  --text-md: 14px;
  --text-lg: 17px;
  --text-xl: 20px;
  --text-2xl: 24px;
  --text-3xl: 28px;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 700;
  --app-viewport-height: 100vh;
}
* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--background);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  min-height: 100dvh;
  background:
    radial-gradient(circle at top left, rgba(13, 148, 136, 0.12), transparent 34%),
    radial-gradient(circle at 90% 12%, rgba(13, 148, 136, 0.12), transparent 28%),
    var(--background);
  color: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.45;
  overscroll-behavior-y: none;
}

button,
input,
select,
textarea {
  font: inherit;
  font-size: max(16px, var(--text-md));
}

button {
  -webkit-tap-highlight-color: transparent;
}

.app-shell {
  width: min(100%, 560px);
  min-height: 100vh;
  min-height: var(--app-viewport-height);
  min-height: 100dvh;
  margin: 0 auto;
  padding: max(14px, env(safe-area-inset-top)) 12px calc(22px + env(safe-area-inset-bottom));
}

.boot {
  min-height: 76vh;
  min-height: min(76vh, calc(var(--app-viewport-height) - 120px));
  display: grid;
  place-items: center;
  align-content: center;
  gap: 9px;
  text-align: center;
}

.boot-logo,
.brand-logo {
  width: 54px;
  height: 54px;
  border-radius: 18px;
}

.boot h1,
h1,
h2,
h3,
p {
  margin: 0;
}

.boot h1 {
  font-size: var(--text-3xl);
  font-weight: var(--weight-semibold);
  line-height: 1.08;
}

.progress {
  width: 150px;
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
}

.progress span {
  display: block;
  width: 45%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--teal-primary), var(--text-secondary));
  animation: loadbar 1.2s ease-in-out infinite alternate;
}

@keyframes loadbar {
  from { transform: translateX(-40%); }
  to { transform: translateX(160%); }
}

.top-card,
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--border);
}

.top-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  margin-bottom: 12px;
}

.brand-copy {
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.brand-copy h1 {
  max-width: 100%;
  font-size: clamp(24px, 6vw, 28px);
  font-weight: var(--weight-semibold);
  line-height: 1.05;
  white-space: normal;
  overflow-wrap: normal;
}

.brand-copy p {
  margin-top: 3px;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.25;
}

.avatar-button {
  display: grid;
  gap: 3px;
  justify-items: center;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
}

.avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  overflow: hidden;
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-weight: var(--weight-semibold);
  border: 2px solid var(--surface);
  box-sizing: border-box;
  line-height: 1;
  text-align: center;
}

.avatar-initials {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.avatar.has-photo .avatar-initials {
  display: none;
}

.avatar.avatar-fallback .avatar-initials {
  display: flex;
}

.avatar img {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border-radius: inherit;
}

.bell {
  position: relative;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 15px;
  border: 1px solid var(--border);
  background: var(--teal-tint);
  color: var(--teal-primary);
  display: grid;
  place-items: center;
  font-size: 18px;
}

.badge-dot {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  padding: 0 6px;
  color: var(--surface);
  background: var(--text-secondary);
  font-size: 11px;
  font-weight: var(--weight-semibold);
  border: 2px solid var(--surface);
}

.tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 6px;
  margin-bottom: 14px;
}

.tab {
  min-height: 44px;
  border-radius: 15px;
  border: 0;
  background: transparent;
  color: var(--text-secondary);
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  display: grid;
  place-items: center;
}

.tab.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-weight: var(--weight-semibold);
  box-shadow: inset 0 0 0 1px rgba(13, 148, 136, 0.34);
}

.card {
  padding: 16px;
  margin-bottom: 14px;
}

.card.cyan { border-top: 4px solid var(--teal-primary); }
.card.violet { border-top: 4px solid var(--text-secondary); }
.card.mango { border-top: 4px solid var(--text-secondary); }
.card.coral { border-top: 4px solid var(--text-secondary); }
.card.green { border-top: 4px solid var(--text-secondary); }

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}

.card h2 {
  font-size: var(--text-xl);
  font-weight: var(--weight-semibold);
  line-height: 1.14;
  letter-spacing: -0.01em;
}

.card h3 {
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
  line-height: 1.18;
}

.pill,
.mini-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: 999px;
  font-weight: var(--weight-medium);
  white-space: nowrap;
}

.pill {
  padding: 6px 9px;
  font-size: var(--text-sm);
  background: var(--background);
  color: var(--text-secondary);
}

.mini-pill {
  padding: 5px 8px;
  font-size: var(--text-xs);
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.mini-pill.success {
  background: var(--background);
  color: var(--text-secondary);
}

.mini-pill.warning {
  background: var(--background);
  color: var(--text-secondary);
}

.mini-pill.danger {
  background: var(--background);
  color: var(--text-secondary);
}

.mini-pill.muted {
  background: var(--background);
  color: var(--text-secondary);
}

.row,
.stack,
.grid2,
.grid3 {
  display: grid;
  gap: 9px;
}

.row {
  display: flex;
  align-items: center;
}

.stack {
  grid-template-columns: 1fr;
}

.grid2 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  color: var(--text-secondary);
  font-weight: var(--weight-medium);
  font-size: var(--text-sm);
}

.input,
.select,
.textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  padding: 10px 12px;
  color: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  outline: none;
}

.textarea {
  min-height: 84px;
  resize: vertical;
}

.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--teal-primary);
  box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.13);
}

.btn {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(13, 148, 136, 0.28);
  border-radius: 14px;
  padding: 10px 13px;
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  color: var(--teal-primary);
  background: var(--teal-tint);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.btn:active,
.tab:active,
.avatar-button:active,
.bell:active {
  background: var(--text-primary);
  color: var(--surface);
}

.btn.secondary {
  background: rgba(223, 250, 255, 0.52);
  color: var(--teal-primary);
  border: 1px solid rgba(13, 148, 136, 0.35);
}

.btn.violet {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(13, 148, 136, 0.28);
}

.btn.mango {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(146, 64, 14, 0.34);
}

.btn.coral {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(153, 27, 27, 0.32);
}

.btn.ghost {
  background: var(--surface);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn.small {
  min-height: 36px;
  font-size: var(--text-sm);
  border-radius: 12px;
  padding: 8px 11px;
}

.card-head .btn.small {
  width: auto;
  min-width: 82px;
  flex: 0 0 auto;
}

.muted {
  color: var(--text-secondary);
}

.help {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.42;
}

.message {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom));
  z-index: 80;
  width: min(calc(100% - 28px), 532px);
  transform: translateX(-50%);
  border-radius: 16px;
  padding: 10px 12px;
  color: var(--text-secondary);
  background: var(--background);
  box-shadow: 0 14px 34px rgba(70, 52, 120, 0.16);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  text-align: center;
}

.message.good {
  color: var(--text-secondary);
  background: var(--background);
}

.message.bad {
  color: var(--text-secondary);
  background: var(--background);
}

.list-card {
  display: grid;
  gap: 10px;
}

.item {
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 13px;
  background: var(--surface);
  display: grid;
  gap: 9px;
}

.item-main {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  padding: 0;
  display: grid;
  gap: 8px;
}

.item-main:active {
  color: var(--teal-primary);
}

.item-title,
.item-main b {
  font-weight: var(--weight-medium);
  font-size: var(--text-lg);
  line-height: 1.22;
}

.item-sub {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.35;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.soft {
  border-radius: 16px;
  padding: 14px;
  background: var(--teal-tint);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.38;
}

.soft b {
  display: inline-block;
  margin-bottom: 2px;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  letter-spacing: 0.01em;
}

.soft.violet { background: var(--background); }
.soft.mango { background: var(--background); }
.soft.coral { background: var(--background); }
.soft.green { background: var(--background); }

.guidance {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin: 4px 0 12px;
}

.guidance > div {
  display: grid;
  gap: 4px;
}

.guidance .btn {
  width: auto;
  flex: 0 0 auto;
}

.celebration-card {
  background: linear-gradient(135deg, var(--background), var(--teal-tint));
}

.celebration-card h2 {
  margin-bottom: 6px;
}

.hidden {
  display: none;
}

.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.switch-row span {
  display: grid;
  gap: 4px;
}

.switch-row small {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.35;
}

.switch-row input {
  width: 46px;
  height: 28px;
  flex: 0 0 auto;
  accent-color: var(--teal-primary);
}

.suggestions {
  max-height: 240px;
  overflow-y: auto;
  display: grid;
  gap: 7px;
  padding: 7px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.86);
}

.suggestion {
  width: 100%;
  border: 1px solid rgba(13, 148, 136, 0.18);
  border-radius: 14px;
  background: var(--teal-tint);
  color: var(--text-primary);
  text-align: left;
  padding: 9px 10px;
  display: grid;
  gap: 3px;
}

.suggestion:active {
  background: var(--text-primary);
  color: var(--surface);
}

.suggestion span,
.empty-suggestions {
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-regular);
}

.compact-share .input {
  min-height: 44px;
}

.dashboard {
  background: var(--background);
  border-color: rgba(13, 148, 136, 0.25);
}

.dashboard.trip {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.24);
}

.dashboard h2 {
  font-size: var(--text-2xl);
  font-weight: var(--weight-semibold);
  line-height: 1.1;
  letter-spacing: -0.015em;
}

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

.dashboard-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: 0 0 auto;
}

.dashboard-actions .btn {
  width: auto;
  min-width: 72px;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: var(--weight-medium);
  white-space: nowrap;
}

.dashboard-actions .btn.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.35);
}

.action-panel {
  animation: panel-in 0.18s ease-out;
}

.list-section {
  display: grid;
  gap: 0;
}

@keyframes panel-in {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.stat {
  border: 1px solid rgba(102, 112, 133, 0.18);
  border-radius: 16px;
  background: rgba(255,255,255,0.62);
  color: var(--text-primary);
  padding: 13px 10px;
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  line-height: 1.15;
  letter-spacing: 0.04em;
}

.stat.active {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(13, 148, 136, 0.34);
  box-shadow: inset 0 0 0 1px rgba(13, 148, 136, 0.18);
}

.stat b {
  display: block;
  margin-bottom: 3px;
  font-size: 30px;
  font-weight: var(--weight-semibold);
  letter-spacing: -0.02em;
  line-height: 1;
}

.section-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.section-buttons .btn {
  min-height: 48px;
  flex-direction: column;
  border-radius: 15px;
  font-size: var(--text-sm);
  line-height: 1.2;
}

.month-selector {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0;
  text-align: center;
}

.month-selector > div {
  flex: 1;
}

.month-selector b {
  font-weight: var(--weight-semibold);
}

.calendar-arrow {
  width: 42px;
  height: 42px;
  border-radius: 15px;
  border: 1px solid rgba(13, 148, 136, 0.35);
  background: var(--surface);
  color: var(--teal-primary);
  font-size: 22px;
  font-weight: var(--weight-medium);
}

.analytics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}

.analytics-card {
  min-height: 108px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--teal-primary);
  border-radius: 16px;
  background: var(--surface);
  color: var(--text-primary);
  padding: 12px;
  text-align: left;
  display: grid;
  align-content: start;
  gap: 6px;
}

.analytics-card.positive {
  background: var(--background);
  border-left-color: var(--text-secondary);
}

.analytics-card.negative {
  background: var(--background);
  border-left-color: var(--text-secondary);
}

.analytics-card span {
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
}

.analytics-card b {
  font-size: var(--text-xl);
  font-weight: var(--weight-semibold);
  line-height: 1.08;
}

.analytics-card small {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.35;
}

.detail-row {
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px;
  background: var(--surface);
  display: grid;
  gap: 9px;
}

.settlement-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.empty {
  text-align: center;
  padding: 20px 16px;
  border: 1px dashed var(--border);
  border-radius: 16px;
  color: var(--text-secondary);
  display: grid;
  gap: 8px;
  justify-items: center;
}

.empty h3 {
  color: var(--text-primary);
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
}

.empty p {
  max-width: 320px;
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.45;
}

.empty .btn {
  margin-top: 6px;
}

.memory-photo-preview {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--border);
}

.memory-photo-actions {
  margin-top: 12px;
}

.file-picker-input {
  position: fixed;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(23, 32, 51, 0.42);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 12px;
}

.drawer {
  width: min(100%, 560px);
  max-height: min(82vh, 760px);
  overflow: auto;
  border-radius: 24px;
  background: var(--surface);
  padding: 16px;
  box-shadow: 0 24px 80px rgba(0,0,0,0.22);
}

.drawer-handle {
  width: 54px;
  height: 5px;
  border-radius: 999px;
  background: var(--border);
  margin: 0 auto 12px;
}

.install-card {
  background: linear-gradient(135deg, var(--teal-tint), var(--background));
}

.install-steps {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.install-steps div {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.86);
}

.install-steps b {
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-weight: 600;
}

.install-steps span {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: 400;
}

@media (max-width: 380px) {
  .app-shell {
    padding-inline: 10px;
  }

  .top-card {
    padding: 11px;
  }

  .brand-logo,
  .boot-logo {
    width: 50px;
    height: 50px;
    border-radius: 17px;
  }

  .brand-copy h1 {
    font-size: 24px;
  }

  .brand-copy p {
    font-size: 12px;
  }

  .avatar {
    width: 36px;
    height: 36px;
  }

  .bell {
    width: 40px;
    height: 40px;
  }

  .tab {
    min-height: 42px;
    font-size: var(--text-sm);
  }

  .card {
    padding: 14px;
  }

  .dashboard h2 {
    font-size: 23px;
  }

  .dashboard-head {
    align-items: flex-start;
  }

  .dashboard-actions {
    gap: 5px;
  }

  .dashboard-actions .btn {
    min-width: 60px;
    min-height: 34px;
    padding: 7px 9px;
    font-size: var(--text-xs);
  }

  .stat b {
    font-size: 28px;
  }

  .section-buttons {
    gap: 6px;
  }

  .section-buttons .btn {
    font-size: var(--text-xs);
  }

  .guidance {
    display: grid;
  }

  .guidance .btn {
    width: 100%;
  }
}

.memory-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(23, 32, 51, 0.42);
}

.memory-dialog {
  width: min(100%, 360px);
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 22px 50px rgba(23, 32, 51, 0.18);
  text-align: center;
}

.memory-dialog h2 {
  margin: 0;
  font-size: var(--text-xl);
  line-height: 1.18;
  font-weight: var(--weight-semibold);
}

.memory-dialog .help {
  font-size: var(--text-sm);
}

.dialog-spinner {
  width: 34px;
  height: 34px;
  margin: 2px auto 0;
  border-radius: 50%;
  border: 3px solid var(--teal-tint);
  border-top-color: var(--teal-primary);
  animation: spin 0.75s linear infinite;
}

.dialog-success {
  width: 42px;
  height: 42px;
  margin: 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--background);
  color: var(--text-secondary);
  font-size: 24px;
  font-weight: var(--weight-semibold);
}

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

.group-settings-card {
  display: grid;
  gap: 12px;
}

.group-settings-media {
  display: flex;
  align-items: center;
  gap: 14px;
}

.group-settings-avatar {
  width: 96px;
  height: 96px;
  flex: 0 0 auto;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--teal-primary);
  color: var(--surface);
  font-size: 34px;
  font-weight: var(--weight-semibold);
}

.group-settings-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.group-member-row {
  grid-template-columns: 1fr;
}

.group-member-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.group-member-actions .btn.small {
  width: auto;
  min-width: 92px;
}

@media (max-width: 430px) {
  .group-settings-media {
    align-items: stretch;
  }

  .group-settings-avatar {
    width: 78px;
    height: 78px;
    font-size: 28px;
  }

  .group-member-actions .btn.small {
    min-width: 0;
    flex: 1 1 120px;
  }
}

.profile-photo-section {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
}

.profile-photo-preview {
  width: 84px;
  height: 84px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-size: 30px;
  font-weight: var(--weight-semibold);
}

.profile-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-photo-copy {
  flex: 1;
  min-width: 0;
}

.profile-photo-copy .btn {
  margin-top: 2px;
}

.profile-crop-tool {
  display: grid;
  justify-items: center;
  gap: 14px;
}

.profile-crop-stage {
  position: relative;
  width: 260px;
  height: 260px;
  max-width: min(260px, 78vw);
  max-height: min(260px, 78vw);
  overflow: hidden;
  border-radius: 50%;
  background: var(--teal-tint);
  border: 3px solid rgba(13, 148, 136, 0.22);
  box-shadow: 0 0 0 999px rgba(17, 24, 39, 0.03);
  touch-action: none;
  cursor: grab;
  user-select: none;
}

.profile-crop-stage:active {
  cursor: grabbing;
}

.profile-crop-stage img {
  position: absolute;
  display: block;
  max-width: none;
  max-height: none;
  user-select: none;
  pointer-events: none;
}

.profile-crop-zoom {
  width: min(320px, 100%);
  display: grid;
  gap: 8px;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}

.profile-crop-zoom input {
  width: 100%;
  accent-color: var(--teal-primary);
}

@media (max-width: 430px) {
  .profile-photo-section {
    align-items: stretch;
  }

  .profile-photo-preview {
    width: 72px;
    height: 72px;
    font-size: 26px;
  }
}

/* UI/UX polish pass: keep Zabat identity, reduce visual weight, and make actions clearer. */
body {
  background:
    radial-gradient(circle at top left, rgba(13, 148, 136, 0.09), transparent 30%),
    radial-gradient(circle at 92% 10%, rgba(13, 148, 136, 0.08), transparent 26%),
    var(--background);
  line-height: 1.45;
}

.app-shell {
  padding: max(14px, env(safe-area-inset-top)) 14px calc(22px + env(safe-area-inset-bottom));
}

.top-card,
.card {
  border-color: var(--border);
  border-radius: 18px;
  box-shadow: var(--border);
}

.card {
  padding: 14px;
  margin-bottom: 12px;
}

.card.cyan,
.card.violet,
.card.mango,
.card.coral,
.card.green {
  border-top-width: 2px;
}

.card h2,
.dashboard h2 {
  font-size: var(--text-xl);
  font-weight: var(--weight-semibold);
  letter-spacing: -0.01em;
}

.card h3 {
  font-size: var(--text-lg);
  font-weight: var(--weight-medium);
}

.help,
.item-sub,
.field label {
  color: var(--text-secondary);
}

.tabs {
  margin-bottom: 12px;
}

.tab {
  min-height: 42px;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
}

.tab.active {
  font-weight: var(--weight-medium);
  box-shadow: inset 0 0 0 1px rgba(13, 148, 136, 0.26);
}

.btn {
  min-height: 42px;
  border-radius: 14px;
  padding: 10px 14px;
  border: 1px solid rgba(13, 148, 136, 0.34);
  background: var(--teal-primary);
  color: var(--surface);
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
}

.btn:active,
.tab:active,
.avatar-button:active,
.bell:active {
  transform: translateY(1px);
  background: var(--teal-primary);
  color: var(--surface);
}

.btn.secondary {
  background: var(--surface);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
}

.btn.ghost {
  background: var(--surface);
  color: var(--text-secondary);
  border-color: var(--border);
}

.btn.violet {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(13, 148, 136, 0.25);
}

.btn.mango {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(245, 158, 11, 0.28);
}

.btn.coral {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(244, 91, 117, 0.28);
}

.btn.small {
  min-height: 34px;
  padding: 7px 11px;
  border-radius: 999px;
  font-size: var(--text-sm);
}

.pill,
.mini-pill {
  font-weight: var(--weight-medium);
}

.pill {
  padding: 5px 8px;
  font-size: var(--text-xs);
  background: var(--background);
  color: var(--text-secondary);
}

.pill.status-pill {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.status-pill.upcoming {
  background: var(--background);
  color: var(--text-secondary);
}

.status-pill.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.status-pill.history {
  background: var(--border);
  color: var(--text-secondary);
}

.status-pill.skipped {
  background: var(--background);
  color: var(--text-secondary);
}

.mini-pill {
  padding: 4px 7px;
  font-size: var(--text-xs);
}

.mini-pill.muted {
  background: var(--border);
  color: var(--text-secondary);
}

.list-card {
  gap: 9px;
}

.item {
  border-radius: 15px;
  padding: 12px;
  gap: 8px;
}

.item-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.item-title,
.item-main b {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
}

.meta-row {
  gap: 6px;
}

.soft {
  border-radius: 15px;
  padding: 12px;
  font-size: var(--text-md);
}

.soft b {
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: 0.03em;
}

.dashboard {
  background: linear-gradient(135deg, var(--background), var(--surface));
  border-color: rgba(13, 148, 136, 0.22);
}

.dashboard.trip,
.dashboard.group-dashboard {
  background: linear-gradient(135deg, var(--teal-tint), var(--surface));
  border-color: rgba(13, 148, 136, 0.22);
}

.dashboard-head {
  gap: 12px;
  margin-bottom: 12px;
}

.dashboard-actions {
  gap: 6px;
}

.dashboard-actions .btn {
  width: auto;
  min-width: 0;
  min-height: 34px;
  padding: 7px 11px;
  font-size: var(--text-sm);
  border-radius: 999px;
}

.dashboard-actions .btn.active {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
}

.stats {
  gap: 8px;
  margin-top: 12px;
}

.stat {
  border-radius: 15px;
  padding: 11px 10px;
  background: rgba(255, 255, 255, 0.72);
}

.stat b {
  font-size: 26px;
  font-weight: var(--weight-semibold);
}

.empty {
  padding: 18px 14px;
  border-radius: 16px;
  background: var(--surface);
}

.empty h3 {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
}

.memory-card {
  border-top: 2px solid var(--text-secondary);
  background: linear-gradient(180deg, var(--surface), rgba(240, 231, 255, 0.32));
}

.memory-photo-preview {
  max-height: 340px;
  border-radius: 16px;
  margin-bottom: 8px;
  border-color: rgba(229, 231, 235, 0.95);
}

.memory-caption {
  margin-bottom: 6px;
}

.profile-card .settings-section-title,
.settings-section-title {
  margin: 14px 0 8px;
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  letter-spacing: 0.01em;
}

.account-section-title {
  margin-top: 16px;
}

.profile-photo-section,
.group-settings-media {
  border-radius: 16px;
  background: var(--surface);
}

.profile-photo-preview,
.group-settings-avatar {
  box-shadow: inset 0 0 0 1px rgba(13, 148, 136, 0.16);
}

.group-settings-avatar {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.group-member-row {
  gap: 8px;
}

.group-member-actions .btn.small {
  min-width: 0;
  padding-inline: 10px;
}

.section-buttons {
  gap: 7px;
}

.input,
.select,
.textarea {
  min-height: 44px;
  border-radius: 14px;
  font-size: var(--text-md);
}

.message {
  box-shadow: 0 12px 28px rgba(17, 24, 39, 0.12);
}

@media (max-width: 380px) {
  .app-shell {
    padding-inline: 12px;
  }

  .card {
    padding: 13px;
  }

  .brand-copy h1 {
    font-size: 23px;
  }

  .dashboard h2 {
    font-size: 20px;
  }

  .dashboard-actions .btn {
    min-height: 32px;
    padding: 6px 9px;
    font-size: var(--text-xs);
  }

  .stat b {
    font-size: 24px;
  }

  .item-topline {
    gap: 8px;
  }
}

/* Login/loading progress experience */
.login-progress-shell {
  min-height: 82vh;
  display: grid;
  place-items: center;
  padding: 22px 8px;
}

.login-progress-card {
  width: min(100%, 360px);
  display: grid;
  justify-items: center;
  gap: 14px;
  text-align: center;
  padding: 24px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 4px solid var(--teal-primary);
  border-radius: 24px;
  box-shadow: var(--border);
}

.login-progress-card h1 {
  margin-top: 8px;
  font-size: var(--text-2xl);
  font-weight: var(--weight-semibold);
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.login-progress {
  width: min(100%, 190px);
  margin-top: 2px;
}

.loading-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 7px;
}

.loading-steps span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--background);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
}

.loading-steps span.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

/* PWA push notification prompt */
.notification-prompt-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin: 10px 0 14px;
  padding: 12px;
  border: 1px solid rgba(13, 148, 136, 0.18);
  border-radius: 18px;
  background: var(--teal-tint);
}

.notification-prompt-card h3 {
  margin: 0 0 4px;
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.notification-prompt-card .help {
  margin: 0;
}

.notification-prompt-card.enabled {
  border-color: rgba(34, 197, 94, 0.22);
  background: rgba(220, 252, 231, 0.82);
}

.notification-prompt-card.warning {
  border-color: rgba(245, 158, 11, 0.24);
  background: rgba(254, 243, 199, 0.78);
}

.notification-prompt-card .btn.small {
  width: auto;
  white-space: nowrap;
}

@media (max-width: 420px) {
  .notification-prompt-card {
    grid-template-columns: 1fr;
  }

  .notification-prompt-card .btn.small {
    justify-self: start;
  }
}

/* Automatic notification permission prompt */
.notification-permission-dialog .dialog-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  margin: 0 auto 2px;
  border-radius: 16px;
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-size: 22px;
}

.notification-permission-dialog .dialog-actions {
  display: grid;
  gap: 8px;
}

.notification-permission-dialog .btn.ghost {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
}


/* Post-outing retention and check-in UX */
.status-pill.ready {
  background: rgba(168, 85, 247, 0.12);
  color: var(--text-secondary);
}

.outing-end-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

.end-outing-soft {
  flex: 0 0 auto;
  min-width: 0;
  border-color: rgba(20, 184, 166, 0.28);
  color: var(--teal-primary);
  background: rgba(255, 255, 255, 0.82);
}

.post-outing-card {
  border-top: 2px solid var(--teal-primary);
  background: linear-gradient(180deg, var(--surface), rgba(236, 254, 255, 0.28));
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

.reaction-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.reaction-chip {
  appearance: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-primary);
  min-height: 44px;
  padding: 9px 10px;
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  cursor: pointer;
  text-align: center;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.04);
}

.reaction-chip.selected {
  border-color: rgba(20, 184, 166, 0.42);
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.post-outing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.post-outing-actions .btn.small {
  width: auto;
}

.muted-action {
  color: var(--text-secondary);
}

@media (max-width: 420px) {
  .reaction-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .post-outing-actions {
    align-items: center;
  }
}

.history-readonly-card {
  position: relative;
}

.history-readonly-card .read-only-item {
  background: rgba(255, 255, 255, 0.72);
}

.history-lock-note {
  margin: 12px 0;
}

/* History outing cards are intentional memory records, not active cards with hidden controls */
.outing-history-item {
  padding: 0;
  overflow: hidden;
  border-color: rgba(20, 184, 166, 0.16);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(236, 254, 255, 0.42));
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.055);
}

.outing-history-item.skipped-history {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 241, 242, 0.5));
  border-color: rgba(251, 113, 133, 0.18);
}

.history-item-main {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  display: grid;
  gap: 12px;
  padding: 14px;
  cursor: pointer;
}

.history-item-main:active {
  color: var(--teal-primary);
}

.history-item-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: flex-start;
  gap: 10px;
}

.history-memory-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid rgba(20, 184, 166, 0.18);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.045);
  font-size: 19px;
}

.history-item-copy {
  min-width: 0;
}

.history-label {
  color: var(--teal-primary);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 2px;
}

.skipped-history .history-label {
  color: var(--text-secondary);
}

.history-date {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  line-height: 1.35;
  margin-top: 2px;
}

.history-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.history-summary-grid span {
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(226, 232, 240, 0.95);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  text-align: center;
  padding: 6px;
}

.history-feedback-line {
  border-radius: 14px;
  background: rgba(13, 148, 136, 0.09);
  color: var(--text-secondary);
  padding: 9px 11px;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
}

.history-open-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--teal-primary);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}

.outing-detail-history {
  background: linear-gradient(180deg, var(--surface), rgba(236, 254, 255, 0.32));
}

.history-detail-summary {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 8px;
  margin-top: 12px;
}

.history-detail-summary div {
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(226, 232, 240, 0.95);
  padding: 10px;
}

.history-detail-summary b,
.history-detail-summary span {
  display: block;
}

.history-detail-summary b {
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  line-height: 1.25;
}

.history-detail-summary span {
  color: var(--text-secondary);
  font-size: var(--text-xs);
  line-height: 1.3;
  margin-top: 2px;
}

.history-section-buttons {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.history-section-buttons .btn:last-child {
  grid-column: 1 / -1;
}

@media (max-width: 420px) {
  .history-summary-grid {
    grid-template-columns: 1fr;
  }

  .history-detail-summary {
    grid-template-columns: 1fr;
  }
}

/* Branded history record imagery and safe confirmation dialogs */
.zabt-logo-fallback {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--teal-tint), var(--background));
}

.zabt-logo-fallback img {
  width: 64%;
  height: 64%;
  object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(15, 23, 42, 0.08));
}

.history-record-image {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid rgba(20, 184, 166, 0.18);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.055);
  flex: 0 0 auto;
}

.history-record-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.history-record-image.no-memory {
  padding: 6px;
  background: rgba(255, 255, 255, 0.86);
}

.history-card-actions {
  display: flex;
  justify-content: flex-end;
  padding: 0 14px 14px;
  margin-top: -2px;
}

.history-card-actions .btn {
  width: auto;
}

.confirmation-dialog {
  text-align: left;
}

.confirmation-dialog h2,
.confirmation-dialog .help {
  text-align: left;
}

.confirmation-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 2px;
}

.confirmation-actions .btn {
  width: 100%;
}

@media (max-width: 420px) {
  .history-record-image {
    width: 48px;
    height: 48px;
    border-radius: 16px;
  }

  .history-card-actions {
    justify-content: stretch;
  }

  .history-card-actions .btn {
    width: 100%;
  }
}

.share-breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.share-chip {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 9px;
}

.linked-accounting-note {
  margin: 12px 0;
}

.expense-source-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-top: 6px;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.12);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 800;
  padding: 5px 9px;
}

/* Trip memories album: redesigned as a core trip feature, not an appended button */
.trip-record-item {
  position: relative;
  padding: 0;
  overflow: hidden;
  border-color: rgba(13, 148, 136, 0.18);
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(239,228,255,0.34));
}

.trip-record-main {
  padding: 13px;
}

.trip-record-layout,
.trip-hero-layout {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
}

.trip-card-cover,
.trip-hero-cover {
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--teal-tint), var(--background));
  display: grid;
  place-items: center;
  border: 1px solid rgba(13, 148, 136, 0.18);
}

.trip-card-cover {
  width: 86px;
  height: 86px;
  min-height: 86px;
}

.trip-hero-cover {
  width: 86px;
  height: 86px;
  min-height: 86px;
}

.trip-card-cover img,
.trip-hero-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.trip-card-cover.no-photo .brand-logo,
.trip-hero-cover.no-photo .brand-logo,
.trip-album-empty .brand-logo {
  width: 44px;
  height: 44px;
  opacity: 0.95;
}

.trip-record-copy,
.trip-hero-copy {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 8px;
}

.trip-card-album-row,
.trip-hero-album-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-radius: 15px;
  background: rgba(255,255,255,0.68);
  border: 1px solid rgba(13, 148, 136, 0.13);
  color: var(--text-secondary);
  padding: 10px 12px;
  font-size: var(--text-sm);
}

.trip-card-album-row b,
.trip-hero-album-callout b {
  color: var(--text-secondary);
  font-weight: var(--weight-semibold);
}


.trip-card-album-row {
  width: calc(100% - 26px);
  margin: 0 13px 13px;
  cursor: pointer;
  appearance: none;
  font: inherit;
  text-align: left;
}

.trip-card-album-row:active {
  transform: translateY(1px);
}

.admin-icon {
  border: 1px solid rgba(244, 114, 182, 0.28);
  background: rgba(255, 228, 236, 0.92);
  color: var(--text-secondary);
  width: 30px;
  height: 30px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 13px;
  line-height: 1;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(244, 114, 182, 0.12);
  cursor: pointer;
  z-index: 3;
}

.admin-icon:active {
  transform: scale(0.97);
}

.trip-card-delete-icon {
  position: absolute;
  top: 12px;
  right: 12px;
}

.trip-detail-delete-icon {
  position: absolute;
  top: 16px;
  right: 16px;
}

.trip-record-main .item-topline {
  padding-right: 36px;
}

.trip-detail-hero .trip-hero-head {
  padding-right: 36px;
}

.trip-card-actions,
.trip-detail-actions,
.trip-album-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 0 13px 13px;
}

.trip-detail-actions,
.trip-album-actions {
  padding: 0;
  margin-top: 12px;
}

.trip-detail-actions .btn:only-child,
.trip-album-actions .btn:only-child {
  grid-column: 1 / -1;
}

.trip-detail-hero {
  position: relative;
  background: linear-gradient(180deg, var(--surface), rgba(223,250,255,0.42));
}

.trip-hero-head {
  margin-bottom: 0;
}

.trip-section-buttons {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.trip-section-buttons .btn.active {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
}

.trip-album-card {
  border-top-color: var(--text-secondary);
  background: linear-gradient(180deg, var(--surface), rgba(239,228,255,0.28));
}

.trip-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.trip-photo-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  display: grid;
}

.trip-photo-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.trip-photo-meta {
  display: grid;
  gap: 7px;
  padding: 8px;
  color: var(--text-secondary);
  font-size: var(--text-xs);
}

.trip-photo-meta .btn.small {
  min-height: 32px;
  padding: 6px 8px;
}

.trip-album-empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 24px 14px;
  border: 1px dashed rgba(13, 148, 136, 0.28);
  border-radius: 18px;
  background: rgba(255,255,255,0.72);
  margin-top: 14px;
  text-align: center;
}

.trip-upload-note {
  margin-top: 12px;
}

@media (max-width: 420px) {
  .trip-record-layout,
  .trip-hero-layout {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .trip-card-cover {
    width: 76px;
    height: 76px;
    min-height: 76px;
  }

  .trip-hero-cover {
    width: 76px;
    height: 76px;
    min-height: 76px;
  }

  .trip-section-buttons {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .trip-card-actions,
  .trip-detail-actions,
  .trip-album-actions {
    grid-template-columns: 1fr;
  }
}

.trip-card-actions .btn:only-child {
  grid-column: 1 / -1;
}

.memory-photo-frame,
.trip-photo-frame {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
}

.memory-photo-frame .memory-photo-preview {
  display: block;
  margin-bottom: 0;
}

.trip-photo-frame img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.photo-delete-icon {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(244, 114, 182, 0.42);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
  color: var(--text-secondary);
  display: inline-grid;
  place-items: center;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  z-index: 3;
}

.photo-delete-icon:active {
  transform: scale(0.96);
}

/* Outing actions redesign: keep the journey shorter and remove unused menu action */
.outing-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.outing-primary-actions,
.outing-tab-actions {
  display: grid;
  gap: 8px;
}

.outing-primary-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.history-outing-actions .outing-primary-actions {
  grid-template-columns: 1fr;
}

.outing-tab-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.outing-actions .btn {
  min-height: 48px;
  border-radius: 15px;
  font-size: var(--text-sm);
  line-height: 1.2;
}

.outing-primary-actions .btn {
  min-height: 52px;
}

@media (max-width: 380px) {
  .outing-tab-actions {
    grid-template-columns: 1fr;
  }
}

/* Outing list/card refinements: non-history count wording, title support, and icon-only delete */
.outing-item,
.outing-history-item,
.outing-detail-card {
  position: relative;
}

.outing-card-delete-icon,
.outing-detail-delete-icon {
  position: absolute;
  top: 12px;
  right: 12px;
}

.outing-item .item-main,
.outing-history-item .history-item-main {
  padding-right: 40px;
}

.outing-detail-card .card-head {
  padding-right: 38px;
}

.label-muted {
  color: var(--text-secondary);
  font-weight: var(--weight-medium);
}

/* Designed bilingual brand wordmark */
.brand-name {
  display: inline-flex;
  align-items: flex-start;
  justify-content: flex-start;
  white-space: nowrap;
  direction: ltr;
  unicode-bidi: isolate;
  line-height: 1;
  overflow: visible;
  vertical-align: baseline;
}

.brand-lockup {
  display: inline-grid;
  grid-template-areas:
    "en"
    "ar";
  justify-items: start;
  align-items: start;
  row-gap: 0.02em;
  line-height: 1;
}

.brand-en {
  grid-area: en;
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
  letter-spacing: -0.035em;
  line-height: 0.94;
}

.brand-ar {
  grid-area: ar;
  font-family: "Tajawal", "Cairo", "Noto Sans Arabic", "Noto Kufi Arabic", "Segoe UI", Arial, sans-serif;
  font-size: 0.48em;
  font-weight: 800;
  letter-spacing: 0;
  color: var(--teal-primary);
  line-height: 1.08;
  padding-inline-start: 0.18em;
  margin-top: 0.03em;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow: visible;
}

.inline-brand {
  vertical-align: -0.08em;
}

.inline-brand .brand-lockup {
  display: inline-flex;
  align-items: baseline;
  gap: 0.24em;
}

.inline-brand .brand-en {
  letter-spacing: -0.018em;
  line-height: 1;
}

.inline-brand .brand-ar {
  font-size: 0.78em;
  line-height: 1;
  padding-inline-start: 0;
  margin-top: 0;
}

.boot .brand-name,
.login-progress-card h1 .brand-name,
.brand-copy h1 .brand-name {
  line-height: 1;
}

.boot .brand-ar,
.login-progress-card h1 .brand-ar,
.brand-copy h1 .brand-ar {
  font-size: 0.46em;
}

.brand-copy h1 {
  line-height: 0.98;
}

.brand-copy p {
  margin-top: 7px;
}

/* Password reset expired state and compact destructive icons */
.reset-expired-card .empty-state {
  text-align: center;
}

.empty-logo {
  width: 52px;
  height: 52px;
  margin-bottom: 8px;
}

.reset-expired-card .action-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

@media (max-width: 420px) {
  .reset-expired-card .action-row {
    grid-template-columns: 1fr;
  }
}

/* Social profile panels */
.profile-subnav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 12px;
}
.profile-subtab {
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.84);
  border-radius: 999px;
  padding: 10px 8px;
  font-weight: 800;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
}
.profile-subtab.active {
  color: var(--text-primary);
  background: rgba(55, 213, 202, 0.18);
  border-color: rgba(55, 213, 202, 0.35);
}
.friend-add-form .action-row,
.friend-invite-panel .action-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.friend-add-status {
  padding: 11px 12px;
}
.friend-add-status b {
  display: block;
  margin-bottom: 3px;
}
.friend-add-form .btn[disabled] {
  opacity: 0.62;
  cursor: wait;
}
.friend-invite-dialog {
  width: min(100%, 390px);
}
.friend-invite-dialog .dialog-icon {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  margin: 0 auto;
  background: var(--background);
  font-size: 21px;
}
.friend-invite-preview {
  text-align: left;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: var(--text-sm);
}
.friend-invite-dialog .action-row {
  justify-content: center;
}
.friend-invite-dialog .btn {
  flex: 1 1 140px;
}
.friend-card {
  align-items: center;
  gap: 12px;
}
.friend-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.friend-picker {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.friend-pick-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
  cursor: pointer;
  min-width: 0;
}
.friend-pick-chip input {
  accent-color: var(--teal-primary);
}
.friend-pick-chip .avatar,
.friend-card .avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
}
.friend-pick-chip span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 800;
  font-size: 13px;
}
@media (max-width: 430px) {
  .profile-subnav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .friend-picker {
    grid-template-columns: 1fr;
  }
  .friend-actions {
    justify-content: flex-start;
  }
}


.phone-privacy-toggle {
  padding: 12px;
  border-radius: 18px;
}

.notification-item {
  display: grid;
  gap: 10px;
}

.notification-main {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
}

.notification-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

/* v62 friend add feedback + searchable outing friend picker */
.friend-select-dropdown {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.84);
  overflow: hidden;
}
.friend-select-dropdown summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 13px;
  cursor: pointer;
  list-style: none;
}
.friend-select-dropdown summary::-webkit-details-marker {
  display: none;
}
.friend-select-dropdown summary b {
  display: block;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}
.friend-select-dropdown summary small {
  display: block;
  color: var(--text-secondary);
  font-size: var(--text-xs);
  margin-top: 2px;
}
.friend-select-panel {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  padding: 10px;
  display: grid;
  gap: 9px;
}
.friend-select-search {
  min-height: 42px;
}
.friend-select-list {
  display: grid;
  gap: 7px;
  max-height: 250px;
  overflow: auto;
  padding-right: 2px;
}
.friend-select-row {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
  cursor: pointer;
}
.friend-select-row input {
  accent-color: var(--teal-primary);
  flex: 0 0 auto;
}
.friend-select-row .avatar {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  font-size: 12px;
}
.friend-select-main {
  min-width: 0;
  display: grid;
  gap: 1px;
}
.friend-select-main b,
.friend-select-main small {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.friend-select-main b {
  font-size: 13px;
  font-weight: var(--weight-semibold);
}
.friend-select-main small {
  color: var(--text-secondary);
  font-size: 11px;
}
.friend-select-empty {
  padding: 11px;
  border-radius: 14px;
  background: rgba(102, 112, 133, 0.08);
  color: var(--text-secondary);
  font-size: var(--text-sm);
  text-align: center;
}
@media (max-width: 430px) {
  .friend-select-dropdown summary {
    align-items: flex-start;
  }
  .friend-select-dropdown summary .pill {
    flex: 0 0 auto;
  }
}

/* v65 usability / retention polish */
.header-create-btn {
  flex: 0 0 auto;
  min-height: 40px;
  border-radius: 14px;
  border: 1px solid rgba(13, 148, 136, 0.34);
  background: var(--teal-primary);
  color: var(--surface);
  padding: 9px 12px;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  box-shadow: 0 10px 22px rgba(13, 148, 136, 0.18);
  white-space: nowrap;
}

.header-create-btn:active {
  transform: translateY(1px);
}

.dashboard-head > div:first-child {
  min-width: 0;
}

.dashboard-head .help {
  margin-top: 4px;
}

.friend-select-row {
  min-height: 46px;
}

.friend-select-row .avatar {
  width: 32px;
  height: 32px;
  border-width: 1px;
}

.post-outing-actions .btn.coral {
  flex: 1 1 auto;
}

@media (max-width: 430px) {
  .header-create-btn {
    order: 5;
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
  }

  .top-card {
    flex-wrap: wrap;
  }

  .brand-copy {
    flex-basis: calc(100% - 118px);
  }
}

/* v67 social-app header redesign */
.social-header {
  display: block;
  padding: 14px;
  margin-bottom: 14px;
}

.social-header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.brand-hero {
  min-width: 0;
  flex: 1;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.social-brand-logo {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  flex: 0 0 72px;
}

.social-brand-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 72px;
}

.social-brand-copy h1 {
  font-size: clamp(28px, 7vw, 34px);
  line-height: 0.95;
}

.social-brand-copy h1 .brand-ar {
  font-size: 0.42em;
}

.social-brand-copy p {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.35;
  max-width: 32ch;
}

.profile-nav-button {
  width: 78px;
  flex: 0 0 78px;
  gap: 6px;
  color: var(--text-primary);
  font-weight: var(--weight-semibold);
}

.profile-nav-button .avatar {
  width: 52px;
  height: 52px;
  border: 3px solid var(--surface);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
}

.profile-nav-button.active {
  color: var(--teal-primary);
}

.social-create-btn {
  width: 100%;
  margin-top: 14px;
  min-height: 54px;
  border-radius: 18px;
  font-size: 22px;
  font-weight: 800;
}

.social-nav {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.social-nav-item {
  position: relative;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.86);
  border-radius: 18px;
  min-height: 72px;
  padding: 10px 6px 8px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 5px;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}

.social-nav-item.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.35);
  box-shadow: inset 0 0 0 1px rgba(13, 148, 136, 0.18);
}

.social-nav-icon {
  font-size: 22px;
  line-height: 1;
}

.social-nav-label {
  line-height: 1.1;
}

.social-nav-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  padding: 0 5px;
  display: grid;
  place-items: center;
  background: var(--text-secondary);
  color: var(--surface);
  font-size: 10px;
  font-weight: 800;
  border: 2px solid var(--surface);
}

.profile-hub-card {
  padding-bottom: 14px;
}

.profile-home-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.profile-home-btn {
  min-height: 48px;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-secondary);
  font-weight: 800;
  font-size: 14px;
}

.profile-home-btn.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.35);
}

.notifications-screen .stack {
  margin-top: 12px;
}

.notifications-screen .notification-item {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  padding: 12px;
  background: rgba(255,255,255,0.86);
}

@media (max-width: 520px) {
  .social-brand-logo {
    width: 62px;
    height: 62px;
    border-radius: 20px;
    flex-basis: 62px;
  }

  .social-brand-copy {
    min-height: 62px;
  }

  .social-brand-copy h1 {
    font-size: 24px;
  }

  .social-brand-copy p {
    font-size: 13px;
    margin-top: 7px;
  }

  .profile-nav-button {
    width: 70px;
    flex-basis: 70px;
    font-size: 12px;
  }

  .profile-nav-button .avatar {
    width: 46px;
    height: 46px;
  }

  .social-nav {
    gap: 6px;
  }

  .social-nav-item {
    min-height: 68px;
    padding-inline: 4px;
    font-size: 10px;
  }

  .social-nav-icon {
    font-size: 20px;
  }
}


/* v68 social header polish pass */
.social-header {
  padding: 16px;
  border-radius: 24px;
  border-color: rgba(15, 23, 42, 0.07);
  background:
    radial-gradient(circle at 8% 0%, rgba(13, 148, 136, 0.11), transparent 36%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.92));
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.social-header-top {
  align-items: center;
}

.brand-hero {
  align-items: center;
  gap: 13px;
}

.social-brand-logo {
  width: 76px;
  height: 76px;
  border-radius: 24px;
  box-shadow: 0 12px 26px rgba(13, 148, 136, 0.18);
}

.social-brand-copy {
  min-height: 76px;
}

.social-brand-copy h1 {
  letter-spacing: -0.04em;
}

.social-brand-copy p {
  color: var(--text-secondary);
  font-weight: 500;
}

.profile-nav-button {
  padding: 6px 4px;
  border-radius: 18px;
  transition: background 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.profile-nav-button .avatar {
  width: 50px;
  height: 50px;
  border-width: 3px;
}

.profile-nav-button span {
  font-size: 12px;
  line-height: 1;
}

.profile-nav-button.active {
  background: rgba(13, 148, 136, 0.1);
}

.social-create-btn {
  min-height: 56px;
  margin-top: 15px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--teal-primary), var(--teal-primary));
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.24);
  letter-spacing: -0.015em;
}

.social-create-btn:active {
  transform: scale(0.985);
}

.social-nav {
  margin-top: 14px;
  gap: 7px;
}

.social-nav-item {
  min-height: 74px;
  border-radius: 20px;
  border-color: rgba(15, 23, 42, 0.06);
  background: rgba(248, 250, 252, 0.86);
  color: var(--text-secondary);
  box-shadow: inset 0 -1px 0 rgba(15, 23, 42, 0.03);
  transition: background 0.16s ease, color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

.social-nav-item:active {
  transform: scale(0.97);
}

.social-nav-item.active {
  background: linear-gradient(180deg, rgba(13, 148, 136, 0.16), rgba(13, 148, 136, 0.08));
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
  box-shadow:
    inset 0 0 0 1px rgba(13, 148, 136, 0.15),
    0 8px 18px rgba(13, 148, 136, 0.1);
}

.social-nav-icon {
  width: 34px;
  height: 28px;
  display: grid;
  place-items: center;
  font-size: 22px;
  line-height: 1;
}

.social-nav-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.social-nav-badge {
  top: 7px;
  right: 7px;
  min-width: 19px;
  height: 19px;
  font-size: 10px;
  box-shadow: 0 4px 10px rgba(248, 113, 113, 0.32);
}

.profile-hub-card {
  border-radius: 22px;
}

.profile-home-actions {
  gap: 9px;
}

.profile-home-btn {
  min-height: 50px;
  border-radius: 18px;
  background: var(--background);
}

.profile-home-btn.active {
  background: linear-gradient(180deg, rgba(13, 148, 136, 0.16), rgba(13, 148, 136, 0.08));
}

.notifications-screen {
  border-radius: 22px;
}

@media (max-width: 520px) {
  .social-header {
    padding: 14px;
    border-radius: 22px;
  }

  .brand-hero {
    gap: 11px;
  }

  .social-brand-logo {
    width: 66px;
    height: 66px;
    border-radius: 21px;
    flex-basis: 66px;
  }

  .social-brand-copy {
    min-height: 66px;
  }

  .social-brand-copy h1 {
    font-size: 27px;
  }

  .social-brand-copy p {
    font-size: 13px;
    max-width: 25ch;
  }

  .profile-nav-button {
    width: 64px;
    flex-basis: 64px;
  }

  .profile-nav-button .avatar {
    width: 44px;
    height: 44px;
  }

  .social-create-btn {
    min-height: 52px;
    font-size: 18px;
  }

  .social-nav {
    gap: 5px;
  }

  .social-nav-item {
    min-height: 64px;
    border-radius: 17px;
    padding: 8px 3px 7px;
  }

  .social-nav-icon {
    width: 30px;
    height: 25px;
    font-size: 19px;
  }

  .social-nav-label {
    font-size: 9.5px;
  }

  .social-nav-badge {
    top: 5px;
    right: 4px;
    min-width: 17px;
    height: 17px;
    font-size: 9px;
    border-width: 1.5px;
  }
}

@media (max-width: 360px) {
  .social-header {
    padding: 12px;
  }

  .social-brand-logo {
    width: 58px;
    height: 58px;
    border-radius: 19px;
    flex-basis: 58px;
  }

  .social-brand-copy {
    min-height: 58px;
  }

  .social-brand-copy h1 {
    font-size: 24px;
  }

  .social-brand-copy p {
    font-size: 12px;
    max-width: 21ch;
  }

  .profile-nav-button {
    width: 58px;
    flex-basis: 58px;
    font-size: 11px;
  }

  .profile-nav-button .avatar {
    width: 40px;
    height: 40px;
  }

  .social-nav-item {
    min-height: 60px;
  }

  .social-nav-label {
    font-size: 9px;
  }
}


/* v69 onboarding and feature discovery */
.first-use-hero {
  display: grid;
  gap: 14px;
  background:
    radial-gradient(circle at 0% 0%, rgba(13, 148, 136, 0.14), transparent 40%),
    rgba(255, 255, 255, 0.96);
}

.first-use-hero h2 {
  margin-top: 8px;
  font-size: 24px;
}

.first-use-actions {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 10px;
}

.help-chip {
  border: 1px solid rgba(13, 148, 136, 0.25);
  background: rgba(13, 148, 136, 0.08);
  color: var(--teal-primary);
  border-radius: 999px;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.card-actions-inline {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.onboarding-dialog,
.feature-guide-dialog {
  width: min(100%, 430px);
  text-align: center;
}

.onboarding-logo {
  width: 74px;
  height: 74px;
  border-radius: 24px;
  margin: 0 auto 10px;
  box-shadow: 0 14px 28px rgba(13, 148, 136, 0.2);
}

.onboarding-dialog h2,
.feature-guide-dialog h2 {
  font-size: 24px;
  line-height: 1.1;
}

.onboarding-benefits {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.onboarding-benefit {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(248, 250, 252, 0.95);
  text-align: left;
}

.onboarding-benefit > span {
  width: 34px;
  height: 34px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--teal-tint);
  font-size: 18px;
  flex: 0 0 34px;
}

.onboarding-benefit b {
  display: block;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.onboarding-benefit p {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.3;
}

.feature-guide-dialog .dialog-icon {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  margin: 0 auto 10px;
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-weight: 900;
}

.feature-guide-list {
  display: grid;
  gap: 9px;
  margin: 16px 0;
  text-align: left;
}

.feature-guide-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 11px;
  border-radius: 16px;
  background: rgba(248, 250, 252, 0.95);
}

.feature-guide-row span {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(13, 148, 136, 0.13);
  color: var(--teal-primary);
  font-size: 12px;
  font-weight: 900;
  flex: 0 0 22px;
}

.feature-guide-row p {
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.35;
}

.feature-guide-dialog .action-row,
.onboarding-dialog .action-row {
  justify-content: center;
}

.feature-guide-dialog .btn,
.onboarding-dialog .btn {
  flex: 1 1 150px;
}

@media (max-width: 520px) {
  .first-use-actions {
    grid-template-columns: 1fr;
  }

  .help-chip {
    width: 100%;
    justify-content: center;
    white-space: normal;
  }

  .card-actions-inline {
    align-items: stretch;
  }

  .onboarding-dialog h2,
  .feature-guide-dialog h2 {
    font-size: 22px;
  }
}


/* v73 compact social header sizing — closer to comfortable social/food-app scale */
.social-header {
  padding: 12px 14px 14px;
  border-radius: 22px;
  margin-bottom: 12px;
}

.social-header-top {
  gap: 10px;
}

.brand-hero {
  gap: 10px;
}

.social-brand-logo {
  width: 58px;
  height: 58px;
  flex-basis: 58px;
  border-radius: 19px;
  box-shadow: 0 8px 18px rgba(13, 148, 136, 0.14);
}

.social-brand-copy {
  min-height: 58px;
}

.social-brand-copy h1 {
  font-size: clamp(22px, 5.4vw, 28px);
  line-height: 0.96;
  letter-spacing: -0.035em;
}

.social-brand-copy h1 .brand-ar {
  font-size: 0.40em;
}

.social-brand-copy p {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.3;
  max-width: 27ch;
  font-weight: 500;
}

.profile-nav-button {
  width: 58px;
  flex-basis: 58px;
  gap: 5px;
  padding: 5px 3px;
  border-radius: 16px;
  font-size: 11px;
  font-weight: 700;
}

.profile-nav-button .avatar {
  width: 42px;
  height: 42px;
  border-width: 2px;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
}

.profile-nav-button span {
  font-size: 11px;
}

.social-create-btn {
  min-height: 46px;
  margin-top: 12px;
  border-radius: 18px;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.01em;
  box-shadow: 0 9px 18px rgba(13, 148, 136, 0.2);
}

.social-nav {
  margin-top: 12px;
  gap: 6px;
}

.social-nav-item {
  min-height: 58px;
  border-radius: 16px;
  padding: 7px 4px 6px;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
}

.social-nav-icon {
  width: 28px;
  height: 23px;
  font-size: 18px;
}

.social-nav-label {
  font-size: 10px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.social-nav-badge {
  top: 4px;
  right: 4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  font-size: 8.5px;
  border-width: 1.5px;
}

@media (max-width: 520px) {
  .social-header {
    padding: 11px 12px 13px;
    border-radius: 20px;
  }

  .brand-hero {
    gap: 9px;
  }

  .social-brand-logo {
    width: 54px;
    height: 54px;
    flex-basis: 54px;
    border-radius: 18px;
  }

  .social-brand-copy {
    min-height: 54px;
  }

  .social-brand-copy h1 {
    font-size: 23px;
  }

  .social-brand-copy p {
    margin-top: 5px;
    font-size: 12px;
    line-height: 1.28;
    max-width: 24ch;
  }

  .profile-nav-button {
    width: 54px;
    flex-basis: 54px;
  }

  .profile-nav-button .avatar {
    width: 38px;
    height: 38px;
  }

  .profile-nav-button span {
    font-size: 10px;
  }

  .social-create-btn {
    min-height: 44px;
    font-size: 16px;
  }

  .social-nav {
    gap: 5px;
  }

  .social-nav-item {
    min-height: 56px;
    border-radius: 15px;
    padding: 7px 3px 6px;
  }

  .social-nav-icon {
    width: 26px;
    height: 22px;
    font-size: 17px;
  }

  .social-nav-label {
    font-size: 9.5px;
  }
}

@media (max-width: 360px) {
  .social-header {
    padding: 10px;
  }

  .social-brand-logo {
    width: 48px;
    height: 48px;
    flex-basis: 48px;
    border-radius: 16px;
  }

  .social-brand-copy {
    min-height: 48px;
  }

  .social-brand-copy h1 {
    font-size: 21px;
  }

  .social-brand-copy p {
    font-size: 11px;
    max-width: 22ch;
  }

  .profile-nav-button {
    width: 48px;
    flex-basis: 48px;
  }

  .profile-nav-button .avatar {
    width: 34px;
    height: 34px;
  }

  .social-create-btn {
    min-height: 42px;
    font-size: 15px;
  }

  .social-nav-item {
    min-height: 52px;
  }

  .social-nav-icon {
    font-size: 16px;
  }

  .social-nav-label {
    font-size: 8.8px;
  }
}


/* v74 compact dashboard/list sections */
.card.dashboard,
.card.list-section,
.card.action-panel {
  padding: 18px 18px;
  border-radius: 22px;
}

.dashboard-head {
  margin-bottom: 10px;
  gap: 10px;
  align-items: flex-start;
}

.dashboard h2,
.list-section .card-head h2,
.action-panel .card-head h2 {
  font-size: 24px;
  line-height: 1.04;
  letter-spacing: -0.02em;
}

.dashboard .help,
.list-section .help,
.action-panel .help {
  font-size: 13px;
  line-height: 1.3;
  margin-top: 4px;
  max-width: 28ch;
}

.dashboard-actions {
  gap: 8px;
  flex-wrap: wrap;
}

.dashboard-actions .btn,
.card-head .btn.small,
.help-chip {
  min-height: 40px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 700;
  border-radius: 999px;
}

.help-chip {
  white-space: nowrap;
}

.stats {
  gap: 8px;
  margin-top: 10px;
}

.stat {
  min-height: 88px;
  padding: 10px 8px;
  border-radius: 16px;
  font-size: 11px;
}

.stat b {
  margin-bottom: 2px;
  font-size: 24px;
  line-height: 1;
}

.soft {
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.25;
}

.card-head {
  margin-bottom: 10px;
  gap: 10px;
}

.card-head .pill {
  padding: 6px 9px;
  font-size: 11px;
}

.list-card {
  gap: 8px;
}

.item {
  padding: 11px 12px;
  border-radius: 18px;
  gap: 7px;
}

.item-title,
.item-main b {
  font-size: 17px;
  line-height: 1.18;
}

.item-sub {
  font-size: 12px;
  line-height: 1.28;
}

.meta-row {
  gap: 6px;
}

.meta-row .pill,
.meta-row span,
.item .pill,
.status-pill {
  font-size: 11px;
}

.btn.icon.only {
  width: 38px;
  height: 38px;
  min-height: 38px;
}

.group-item .row {
  gap: 10px;
}

.group-item .avatar,
.item .avatar {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
}

.item-topline {
  gap: 8px;
}

.item-main .action-row,
.item .action-row {
  gap: 8px;
}

.tag,
.pill {
  white-space: nowrap;
}

@media (max-width: 520px) {
  .card.dashboard,
  .card.list-section,
  .card.action-panel {
    padding: 16px 16px;
    border-radius: 20px;
  }

  .dashboard h2,
  .list-section .card-head h2,
  .action-panel .card-head h2 {
    font-size: 22px;
  }

  .dashboard .help,
  .list-section .help,
  .action-panel .help {
    font-size: 12px;
    max-width: 24ch;
  }

  .dashboard-actions .btn,
  .card-head .btn.small,
  .help-chip {
    min-height: 38px;
    padding: 6px 11px;
    font-size: 11.5px;
  }

  .stats {
    gap: 8px;
    margin-top: 8px;
  }

  .stat {
    min-height: 82px;
    padding: 9px 8px;
    font-size: 10px;
  }

  .stat b {
    font-size: 22px;
  }

  .soft {
    padding: 9px 11px;
    font-size: 13px;
  }

  .item {
    padding: 10px 11px;
    border-radius: 16px;
  }

  .item-title,
  .item-main b {
    font-size: 15px;
  }

  .item-sub {
    font-size: 11px;
  }

  .group-item .avatar,
  .item .avatar {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }
}


/* v75 smaller main cards + more consistent header height */
.social-header {
  padding: 11px 12px 13px;
  border-radius: 20px;
}

.social-header-top {
  gap: 9px;
}

.brand-hero {
  gap: 9px;
}

.social-brand-copy {
  min-height: 54px;
}

.social-brand-copy h1 {
  font-size: clamp(21px, 5vw, 27px);
  line-height: 0.96;
}

.social-brand-copy p {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1.22;
  max-width: 22ch;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.profile-nav-button {
  width: 54px;
  flex-basis: 54px;
  padding: 5px 3px;
}

.profile-nav-button .avatar {
  width: 38px;
  height: 38px;
}

.profile-nav-button span {
  font-size: 10px;
}

.card.friends-card,
.card.profile-hub-card,
.card.dashboard,
.card.list-section,
.card.action-panel {
  padding: 15px 15px;
  border-radius: 20px;
}

.card.friends-card .card-head,
.card.profile-hub-card .card-head,
.card.dashboard .card-head,
.card.list-section .card-head {
  margin-bottom: 8px;
}

.card.friends-card h2,
.card.profile-hub-card h2,
.card.dashboard h2,
.card.list-section .card-head h2 {
  font-size: 20px;
  line-height: 1.04;
  letter-spacing: -0.02em;
}

.card.friends-card .help,
.card.profile-hub-card .help,
.card.dashboard .help,
.card.list-section .help {
  font-size: 12px;
  line-height: 1.28;
  margin-top: 3px;
  max-width: 24ch;
}

.card-actions-inline,
.dashboard-actions {
  gap: 7px;
}

.card-actions-inline .pill,
.card-head .pill,
.dashboard-actions .btn,
.help-chip,
.btn.small {
  min-height: 36px;
  padding: 6px 10px;
  font-size: 11px;
}

.profile-home-actions {
  gap: 8px;
  margin-top: 8px;
}

.profile-home-btn {
  min-height: 42px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 10px;
}

.friends-card .friend-add-form {
  gap: 8px;
}

.friends-card .field {
  gap: 5px;
}

.friends-card .field label {
  font-size: 12px;
}

.friends-card .input,
.friends-card .select,
.friends-card .textarea {
  min-height: 42px;
  padding: 9px 11px;
  font-size: 14px;
  border-radius: 13px;
}

.friend-add-form .action-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.friend-add-form .action-row .btn {
  width: auto;
  min-height: 42px;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.15;
  white-space: normal;
  text-align: center;
}

.friend-add-status,
.friend-invite-panel,
.friends-card .message {
  padding: 10px 11px;
  font-size: 12px;
}

.friend-add-status b,
.friend-invite-panel b {
  margin-bottom: 2px;
  font-size: 13px;
}

.friends-card .help:last-of-type,
.profile-hub-card .help:last-of-type {
  margin-bottom: 0;
}

.stats {
  margin-top: 8px;
}

.stat {
  min-height: 76px;
  padding: 8px 8px;
}

.stat b {
  font-size: 20px;
}

.item {
  padding: 10px 11px;
}

.item-title,
.item-main b {
  font-size: 16px;
}

.item-sub {
  font-size: 11px;
}

.item .pill,
.status-pill,
.meta-row .pill,
.meta-row span {
  font-size: 10.5px;
}

@media (max-width: 520px) {
  .social-brand-copy {
    min-height: 50px;
  }

  .social-brand-copy h1 {
    font-size: 22px;
  }

  .social-brand-copy p {
    font-size: 11.5px;
    max-width: 20ch;
  }

  .card.friends-card,
  .card.profile-hub-card,
  .card.dashboard,
  .card.list-section,
  .card.action-panel {
    padding: 14px 14px;
    border-radius: 18px;
  }

  .card.friends-card h2,
  .card.profile-hub-card h2,
  .card.dashboard h2,
  .card.list-section .card-head h2 {
    font-size: 18px;
  }

  .card.friends-card .help,
  .card.profile-hub-card .help,
  .card.dashboard .help,
  .card.list-section .help {
    font-size: 11.5px;
    max-width: 22ch;
  }

  .profile-home-btn {
    min-height: 40px;
    font-size: 12.5px;
  }

  .friends-card .input,
  .friends-card .select,
  .friends-card .textarea {
    min-height: 40px;
    font-size: 13px;
  }

  .friend-add-form .action-row .btn {
    min-height: 40px;
    font-size: 12px;
    padding: 8px 8px;
  }

  .card-actions-inline .pill,
  .card-head .pill,
  .dashboard-actions .btn,
  .help-chip,
  .btn.small {
    min-height: 34px;
    padding: 5px 9px;
    font-size: 10.5px;
  }

  .stat {
    min-height: 72px;
  }

  .stat b {
    font-size: 18px;
  }
}

@media (max-width: 390px) {
  .friend-add-form .action-row {
    grid-template-columns: 1fr;
  }
}


/* v76 calm production color system
   - Turquoise: primary, share, active
   - Cairo pop light grey: neutral/inactive
   - Light red: delete/remove only
   - Light purple: end outing/trip only
*/
body {
  background:
    radial-gradient(circle at top left, rgba(13, 148, 136, 0.08), transparent 34%),
    var(--background);
}

.card,
.top-card {
  border-color: var(--border);
}

.card.cyan,
.card.violet,
.card.mango,
.card.green,
.dashboard,
.dashboard.trip,
.group-dashboard,
.trip-album-card,
.celebration-card {
  background: var(--surface);
  border-color: var(--border);
}

.card.cyan,
.dashboard,
.dashboard.trip,
.group-dashboard,
.list-section {
  border-top-color: rgba(13, 148, 136, 0.45);
}

.soft,
.soft.violet,
.soft.mango,
.soft.green {
  background: var(--text-secondary);
  color: var(--text-primary);
}

.soft.coral {
  background: var(--background);
  color: var(--text-secondary);
}

.guidance,
.feature-guide-row,
.onboarding-benefit,
.analytics-card,
.detail-row,
.notification-item,
.item,
.trip-card-album-row,
.trip-hero-album-callout {
  background: var(--surface);
  border-color: var(--border);
}

.pill,
.mini-pill,
.status-pill,
.status-pill.upcoming,
.status-pill.history,
.status-pill.skipped,
.mini-pill.muted,
.mini-pill.warning,
.mini-pill.success,
.mini-pill.muted {
  background: var(--text-secondary);
  color: var(--text-primary);
  border-color: var(--border);
}

.status-pill.active,
.social-nav-item.active .social-nav-label,
.profile-home-btn.active,
.profile-nav-button.active {
  color: var(--teal-primary);
}

.mini-pill.danger,
.skipped-history .history-label {
  background: var(--background);
  color: var(--text-secondary);
}

.btn {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.28);
}

.btn.secondary,
.btn.ghost,
.btn.mango,
.btn.violet {
  background: var(--text-secondary);
  color: var(--text-primary);
  border-color: var(--border);
}

.btn.secondary.active,
.btn.active,
.dashboard-actions .btn.active,
.profile-home-btn.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.35);
}

.btn.coral {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(232, 93, 107, 0.28);
}

/* Share / invite / copy actions are intentionally turquoise */
[data-share-invite],
[data-celebration-share],
[data-copy],
[data-group-panel="invite"],
[data-action="copy-outing-link"],
[data-action="copy-trip-link"],
[data-action="copy-group-link"] {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.32);
}

/* Main planning actions remain turquoise */
[data-dashboard-card="create-outing"],
[data-dashboard-card="create-trip"],
[data-dashboard-card="create-group"],
[data-group-panel="create-outing"],
[data-action="quick-create-outing"],
[data-action="onboarding-create-outing"],
[data-action="submit-add-friend"],
button[type="submit"].btn:not(.coral) {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.32);
}

/* End actions: light purple, not red */
[data-action="end-outing"],
[data-action="end-trip"],
.end-outing-soft {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(141, 109, 246, 0.28);
}

/* Delete/remove/destructive actions: light red only */
[data-action^="delete"],
[data-action^="remove"],
[data-delete-outing],
[data-delete-trip],
[data-delete-trip-memory-photo],
[data-delete-memory-photo],
[data-delete-spot],
.photo-delete-icon,
.admin-icon,
.btn.coral:not([data-action="end-trip"]) {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(232, 93, 107, 0.28);
}

/* Keep End trip purple even if it still has the old coral class */
.btn.coral[data-action="end-trip"] {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(141, 109, 246, 0.28);
}

.social-nav-item {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
}

.social-nav-item.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.35);
}

.social-nav-icon {
  filter: grayscale(1) saturate(0.15) opacity(0.68);
}

.social-nav-item.active .social-nav-icon {
  filter: grayscale(0.1) saturate(0.9) opacity(1);
}

.social-nav-badge {
  background: var(--text-secondary);
}

.avatar,
.trip-card-cover.no-photo,
.trip-hero-cover.no-photo,
.trip-album-logo,
.trip-logo {
  background: var(--text-secondary);
  color: var(--text-primary);
}

input,
select,
textarea,
.input,
.select,
.textarea {
  background: var(--surface);
  border-color: var(--border);
}

.feature-guide-dialog .dialog-icon,
.onboarding-benefit > span,
.feature-guide-row span {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.message {
  color: var(--text-primary);
  background: var(--text-secondary);
}

.message.good {
  color: var(--teal-primary);
  background: var(--teal-tint);
}

.message.bad {
  color: var(--text-secondary);
  background: var(--background);
}


/* v78 turquoise in-app date/time picker */
input[type="date"],
input[type="time"] {
  accent-color: var(--teal-primary);
}

.picker-input {
  text-align: left;
  color: var(--text-primary);
  background: var(--surface);
  border-color: var(--border);
  justify-content: flex-start;
  font-weight: var(--weight-regular);
}

.picker-dialog {
  width: min(100%, 390px);
  overflow: hidden;
  padding: 0;
  border-radius: 24px;
}

.picker-dialog-head {
  background: var(--teal-primary);
  color: var(--surface);
  padding: 18px 18px 16px;
  text-align: left;
}

.picker-dialog-head span {
  display: block;
  font-size: 14px;
  font-weight: 700;
  opacity: 0.92;
}

.picker-dialog-head strong {
  display: block;
  margin-top: 4px;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 750;
  letter-spacing: -0.03em;
}

.picker-dialog-body {
  padding: 18px;
  display: grid;
  gap: 10px;
  background: var(--surface);
}

.picker-native-input {
  min-height: 48px;
  font-size: 16px;
  color: var(--text-primary);
  accent-color: var(--teal-primary);
}

.picker-native-input::-webkit-calendar-picker-indicator {
  opacity: 0.78;
  filter: hue-rotate(145deg) saturate(1.7);
}

.picker-dialog-actions {
  padding: 0 18px 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.picker-dialog-actions .btn {
  min-height: 40px;
  font-size: 13px;
  border-radius: 14px;
}

@media (max-width: 520px) {
  .picker-dialog {
    width: min(calc(100vw - 28px), 380px);
  }

  .picker-dialog-head {
    padding: 16px 16px 14px;
  }

  .picker-dialog-head strong {
    font-size: 24px;
  }

  .picker-dialog-body {
    padding: 16px;
  }

  .picker-dialog-actions {
    padding: 0 16px 16px;
  }
}


/* v79 restored group detail flow */
.group-back-btn {
  margin-bottom: 10px;
}

.group-detail-hero {
  padding: 15px;
  border-radius: 20px;
  border-top-color: rgba(13, 148, 136, 0.45);
}

.group-detail-head {
  margin-bottom: 10px;
}

.group-detail-head .avatar {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
}

.group-detail-head h2 {
  font-size: 20px;
  line-height: 1.05;
}

.group-detail-head .help {
  font-size: 12px;
  line-height: 1.25;
}

.group-detail-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.group-detail-actions .btn {
  min-height: 40px;
  padding: 8px 8px;
  border-radius: 14px;
  font-size: 12px;
  font-weight: 700;
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
  white-space: normal;
  line-height: 1.15;
}

.group-detail-actions .btn.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
}

.group-plan-button {
  margin-top: 10px;
  min-height: 44px;
  border-radius: 16px;
  font-size: 15px;
  font-weight: 750;
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
}

.group-create-outing-panel,
.group-share-panel,
.group-spots-panel,
.group-settings-card,
.group-danger-card {
  padding: 15px;
  border-radius: 20px;
}

.group-save-spot-panel,
.group-outing-note {
  background: var(--background);
  color: var(--text-primary);
}

.group-danger-card {
  border-color: rgba(232, 93, 107, 0.20);
  box-shadow: none;
}

@media (max-width: 520px) {
  .group-detail-hero,
  .group-create-outing-panel,
  .group-share-panel,
  .group-spots-panel,
  .group-settings-card,
  .group-danger-card {
    padding: 14px;
    border-radius: 18px;
  }

  .group-detail-actions {
    gap: 6px;
  }

  .group-detail-actions .btn {
    min-height: 38px;
    font-size: 11px;
    padding: 7px 6px;
  }

  .group-plan-button {
    min-height: 42px;
    font-size: 14px;
  }
}


/* v80 Trips action-push copy */
.trip-dashboard-copy {
  margin: 2px 0 10px;
  padding: 10px 12px;
  border-radius: 16px;
  background: var(--background);
  border: 1px solid var(--border);
}

.trip-dashboard-copy b {
  display: block;
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.15;
  margin-bottom: 2px;
}

.trip-dashboard-copy p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.28;
}

@media (max-width: 520px) {
  .trip-dashboard-copy {
    padding: 9px 11px;
    margin-bottom: 8px;
  }

  .trip-dashboard-copy b {
    font-size: 13px;
  }

  .trip-dashboard-copy p {
    font-size: 11.5px;
  }
}


/* v81 shorter group share journey */
.group-share-panel {
  padding: 15px;
  border-radius: 20px;
}

.group-share-link-btn {
  margin-top: 10px;
  min-height: 44px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 750;
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
}


/* v83 flow corrections */
.trip-dashboard-copy {
  display: none;
}

/* Native date/time inputs open directly again; keep browser accent turquoise where supported. */
input[type="date"],
input[type="time"] {
  accent-color: var(--teal-primary);
}

/* Share group is now a direct action, not a separate panel. */
.group-detail-actions [data-share-invite="group"] {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.34);
}


/* v84 compact Friends add card */
.compact-friends-card {
  padding: 13px 14px;
  border-radius: 18px;
}

.friends-card-head {
  align-items: flex-start;
  margin-bottom: 7px;
}

.friends-card-head h2 {
  font-size: 18px;
  line-height: 1.02;
}

.friends-card-head .help {
  max-width: 25ch;
  font-size: 11.5px;
  line-height: 1.22;
}

.compact-friend-add-form {
  gap: 7px;
  margin-top: 0;
}

.compact-phone-field {
  gap: 4px;
}

.compact-phone-field label {
  font-size: 11px;
  margin-bottom: 0;
}

.friend-phone-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px;
  align-items: stretch;
}

.friend-phone-row .input {
  min-height: 38px;
  height: 38px;
  padding: 8px 10px;
  font-size: 13px;
  border-radius: 13px;
}

.contact-mini-btn {
  min-height: 38px;
  height: 38px;
  padding: 7px 10px;
  border-radius: 13px;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

.add-friend-submit {
  min-height: 40px;
  height: 40px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 750;
  padding: 8px 10px;
}

.compact-friends-note {
  margin-top: 2px;
  font-size: 11px;
  line-height: 1.25;
}

.compact-friends-card .friend-add-status,
.compact-friends-card .friend-invite-panel {
  padding: 8px 9px;
  font-size: 11px;
  border-radius: 13px;
}

@media (max-width: 380px) {
  .friend-phone-row {
    grid-template-columns: 1fr;
  }

  .contact-mini-btn {
    width: 100%;
  }
}


/* v85 final production palette
   Strong turquoise for primary/share actions, soft turquoise for active states,
   light grey for neutral UI, soft red for destructive, soft purple for end actions.
*/
/* Neutral base */
body {
  background:
    radial-gradient(circle at top left, rgba(13, 148, 136, 0.08), transparent 34%),
    var(--background);
}

.card,
.top-card,
.item,
.notification-item,
.guidance,
.feature-guide-row,
.onboarding-benefit,
.soft,
.analytics-card,
.detail-row {
  background: var(--surface);
  border-color: var(--border);
}

.soft,
.soft.violet,
.soft.mango,
.soft.green,
.pill,
.mini-pill,
.status-pill {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

/* Solid turquoise for primary action buttons */
.btn,
.social-create-btn,
.group-plan-button,
.add-friend-submit,
[data-dashboard-card="create-outing"],
[data-dashboard-card="create-trip"],
[data-dashboard-card="create-group"],
[data-group-panel="create-outing"],
[data-action="quick-create-outing"],
[data-action="onboarding-create-outing"],
[data-action="submit-add-friend"],
button[type="submit"].btn:not(.coral) {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  box-shadow: 0 10px 20px rgba(13, 148, 136, 0.18);
}

/* Share/copy actions are primary too */
[data-share-invite],
[data-celebration-share],
[data-copy],
[data-action="copy-outing-link"],
[data-action="copy-trip-link"],
[data-action="copy-group-link"],
.group-detail-actions [data-share-invite="group"] {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
}

/* Secondary/neutral buttons */
.btn.secondary,
.btn.ghost,
.btn.mango,
.btn.violet,
.contact-mini-btn,
.profile-home-btn,
.group-detail-actions .btn:not([data-share-invite]) {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
  box-shadow: none;
}

/* Active states remain soft turquoise */
.btn.secondary.active,
.btn.active,
.dashboard-actions .btn.active,
.profile-home-btn.active,
.social-nav-item.active,
.profile-nav-button.active,
.group-detail-actions .btn.active {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.36);
  box-shadow: 0 6px 14px rgba(13, 148, 136, 0.08);
}

.social-nav-item.active .social-nav-label,
.profile-nav-button.active {
  color: var(--teal-primary);
}

/* Inactive nav/icons stay grey */
.social-nav-item {
  background: var(--surface);
  color: var(--text-secondary);
  border-color: var(--border);
}

.social-nav-icon {
  filter: grayscale(1) saturate(0.1) opacity(0.62);
}

.social-nav-item.active .social-nav-icon {
  filter: grayscale(0) saturate(1) opacity(1);
}

/* Delete/remove destructive actions */
.btn.coral,
[data-action^="delete"],
[data-action^="remove"],
[data-delete-outing],
[data-delete-trip],
[data-delete-trip-memory-photo],
[data-delete-memory-photo],
[data-delete-spot],
.photo-delete-icon,
.admin-icon {
  background: var(--background);
  color: var(--text-primary);
  border-color: rgba(232, 93, 107, 0.28);
  box-shadow: none;
}

/* End outing/trip */
[data-action="end-outing"],
[data-action="end-trip"],
.end-outing-soft,
.btn.coral[data-action="end-trip"] {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(141, 109, 246, 0.28);
  box-shadow: none;
}

/* Status/pills should not create rainbow noise */
.status-pill.upcoming,
.status-pill.history,
.status-pill.skipped,
.mini-pill.muted,
.mini-pill.warning,
.mini-pill.success,
.mini-pill.muted {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

.mini-pill.danger,
.skipped-history .history-label {
  background: var(--background);
  color: var(--text-primary);
}

.message.good,
.soft.cyan,
.mini-pill.cyan {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

.message.bad,
.soft.coral {
  background: var(--background);
  color: var(--text-primary);
}

/* Keep inputs calm */
input,
select,
textarea,
.input,
.select,
.textarea {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text-primary);
  accent-color: var(--teal-primary);
}

/* Links and key text */
a,
.link-button,
.help-chip {
  color: var(--teal-primary);
}

.help-chip {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.28);
}

/* Cards with accent borders but neutral bodies */
.card.cyan,
.card.violet,
.card.mango,
.card.green,
.dashboard,
.dashboard.trip,
.group-dashboard,
.list-section,
.action-panel {
  background: var(--surface);
}

.card.cyan,
.dashboard,
.dashboard.trip,
.group-dashboard,
.list-section,
.action-panel {
  border-top-color: rgba(13, 148, 136, 0.45);
}


/* v86 Deeper Teal palette — selected production palette
   Applied globally across primary, secondary, and nested pages.
*/
body {
  background:
    radial-gradient(circle at top left, rgba(13, 148, 136, 0.085), transparent 34%),
    var(--background);
}

/* App shell and cards */
.card,
.top-card,
.item,
.notification-item,
.guidance,
.feature-guide-row,
.onboarding-benefit,
.soft,
.analytics-card,
.detail-row,
.group-detail-hero,
.group-create-outing-panel,
.group-share-panel,
.group-spots-panel,
.group-settings-card,
.profile-hub-card,
.friends-card,
.notifications-screen,
.action-panel,
.list-section {
  background: var(--surface);
  border-color: var(--border);
}

.card.cyan,
.card.violet,
.card.mango,
.card.green,
.dashboard,
.dashboard.trip,
.group-dashboard,
.list-section,
.action-panel,
.profile-hub-card,
.friends-card,
.notifications-screen {
  background: var(--surface);
  border-top-color: rgba(13, 148, 136, 0.50);
}

/* Header and active nav */
.social-create-btn,
.btn,
.group-plan-button,
.add-friend-submit,
[data-dashboard-card="create-outing"],
[data-dashboard-card="create-trip"],
[data-dashboard-card="create-group"],
[data-group-panel="create-outing"],
[data-action="quick-create-outing"],
[data-action="onboarding-create-outing"],
[data-action="submit-add-friend"],
button[type="submit"].btn:not(.coral) {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  box-shadow: 0 10px 20px rgba(13, 148, 136, 0.18);
}

[data-share-invite],
[data-celebration-share],
[data-copy],
[data-action="copy-outing-link"],
[data-action="copy-trip-link"],
[data-action="copy-group-link"],
.group-detail-actions [data-share-invite="group"] {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
}

/* Secondary controls */
.btn.secondary,
.btn.ghost,
.btn.mango,
.btn.violet,
.contact-mini-btn,
.profile-home-btn,
.group-detail-actions .btn:not([data-share-invite]),
.help-chip {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
  box-shadow: none;
}

.btn.secondary.active,
.btn.active,
.dashboard-actions .btn.active,
.profile-home-btn.active,
.social-nav-item.active,
.profile-nav-button.active,
.group-detail-actions .btn.active,
.friend-card .mini-pill.success,
.message.good,
.soft.cyan,
.mini-pill.cyan {
  background: var(--teal-tint);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.36);
  box-shadow: 0 6px 14px rgba(13, 148, 136, 0.08);
}

.social-nav-item.active .social-nav-label,
.profile-nav-button.active,
.help-chip {
  color: var(--teal-primary);
}

.social-nav-item {
  background: var(--surface);
  color: var(--text-secondary);
  border-color: var(--border);
}

.social-nav-badge,
.badge-dot {
  background: var(--text-primary);
}

.social-nav-icon {
  filter: grayscale(1) saturate(0.1) opacity(0.62);
}

.social-nav-item.active .social-nav-icon {
  filter: grayscale(0) saturate(1) opacity(1);
}

/* Neutral chips/pills across all pages */
.pill,
.mini-pill,
.status-pill,
.status-pill.upcoming,
.status-pill.history,
.status-pill.skipped,
.mini-pill.muted,
.mini-pill.warning,
.mini-pill.success,
.mini-pill.muted,
.meta-row .pill,
.trip-card .pill,
.outing-card .pill {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

/* Delete / remove */
.btn.coral,
[data-action^="delete"],
[data-action^="remove"],
[data-delete-outing],
[data-delete-trip],
[data-delete-trip-memory-photo],
[data-delete-memory-photo],
[data-delete-spot],
.photo-delete-icon,
.admin-icon,
.message.bad,
.soft.coral,
.mini-pill.danger,
.skipped-history .history-label {
  background: var(--background);
  color: var(--text-primary);
  border-color: rgba(232, 93, 107, 0.28);
  box-shadow: none;
}

/* End outing / End trip */
[data-action="end-outing"],
[data-action="end-trip"],
.end-outing-soft,
.btn.coral[data-action="end-trip"] {
  background: var(--background);
  color: var(--text-secondary);
  border-color: rgba(141, 109, 246, 0.28);
  box-shadow: none;
}

/* Forms and secondary surfaces */
input,
select,
textarea,
.input,
.select,
.textarea {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text-primary);
  accent-color: var(--teal-primary);
}

input[type="date"],
input[type="time"] {
  accent-color: var(--teal-primary);
}

.trip-dashboard-copy,
.soft,
.group-save-spot-panel,
.group-outing-note,
.avatar,
.trip-card-cover.no-photo,
.trip-hero-cover.no-photo,
.trip-album-logo,
.trip-logo {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

/* Feature/help/onboarding accent */
.feature-guide-dialog .dialog-icon,
.onboarding-benefit > span,
.feature-guide-row span {
  background: var(--teal-tint);
  color: var(--teal-primary);
}

a,
.link-button {
  color: var(--teal-primary);
}


/* v88 compact history + history filters */
.history-filter-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 10px;
}

.history-filter-row label {
  display: grid;
  gap: 4px;
  color: var(--text-secondary);
  font-size: 10.5px;
  font-weight: 750;
}

.memory-filter-row,
.analytics-filter-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.history-filter-select {
  min-height: 36px;
  height: 36px;
  padding: 7px 9px;
  border-radius: 12px;
  font-size: 11px;
  background: var(--background);
  color: var(--text-primary);
  border-color: var(--border);
}

.compact-history-item {
  padding: 10px 11px;
  border-radius: 17px;
  background: var(--surface);
  border-color: var(--border);
}

.compact-history-main {
  gap: 8px;
}

.compact-history-head {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.compact-history-head .history-record-image {
  width: 46px;
  height: 46px;
  border-radius: 15px;
}

.compact-history-head .history-label {
  display: none;
}

.compact-history-head .item-title {
  font-size: 16px;
  line-height: 1.12;
  margin-bottom: 2px;
}

.compact-history-head .history-date {
  font-size: 11px;
  line-height: 1.2;
  color: var(--text-secondary);
}

.history-compact-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

.history-compact-meta span {
  min-height: 28px;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--background);
  color: var(--text-secondary);
  font-size: 10.5px;
  font-weight: 700;
}

.compact-open-row {
  margin-top: 7px;
  padding: 0;
  color: var(--teal-primary);
  font-size: 12px;
  min-height: auto;
}

.history-feedback-line,
.history-summary-grid {
  display: none;
}

.remove-view-icon {
  right: 10px;
  top: 10px;
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
  font-size: 18px;
  line-height: 1;
}

.compact-trip-history-item {
  padding: 10px 11px;
}

.compact-trip-history-item .trip-card-cover,
.compact-trip-history-item .trip-card-cover.no-photo {
  width: 74px;
  height: 74px;
  border-radius: 18px;
}

.compact-trip-history-item .item-title {
  font-size: 16px;
  line-height: 1.12;
}

.compact-trip-history-item .item-sub,
.compact-trip-history-item .mini-pill,
.compact-trip-history-item .pill {
  font-size: 10.5px;
}

.compact-trip-history-item .trip-card-album-row {
  min-height: 38px;
  padding: 8px 10px;
  margin-top: 8px;
  border-radius: 14px;
  background: var(--surface);
  border-color: var(--border);
}

.compact-trip-history-item .trip-card-album-row b {
  color: var(--teal-primary);
}

/* strict v88 history colors */
.outing-history-item .history-label,
.outing-history-item .item-title,
.history-open-row,
.compact-open-row,
.trip-card-album-row b {
  color: var(--teal-primary);
}

.outing-history-item .status-pill,
.compact-history-head .status-pill,
.compact-trip-history-item .status-pill {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

.outing-history-item .history-record-image,
.outing-history-item .history-record-image.no-memory {
  background: var(--background);
  border-color: var(--border);
}

@media (max-width: 520px) {
  .history-filter-row {
    gap: 7px;
  }

  .compact-history-head {
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 8px;
  }

  .compact-history-head .history-record-image {
    width: 42px;
    height: 42px;
  }

  .compact-history-head .item-title {
    font-size: 15px;
  }

  .history-compact-meta span {
    font-size: 10px;
    padding: 5px 7px;
  }

  .compact-trip-history-item .trip-card-cover,
  .compact-trip-history-item .trip-card-cover.no-photo {
    width: 68px;
    height: 68px;
  }
}


/* v89 outing memories album + photo limits */
.outing-memory-album-card {
  padding: 15px;
  border-radius: 20px;
}

.outing-album-actions,
.trip-album-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 8px;
}

.outing-album-actions .btn,
.trip-album-actions .btn {
  min-height: 40px;
  border-radius: 14px;
  font-size: 12px;
}

.outing-photo-grid,
.trip-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.outing-photo-card,
.trip-photo-card {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 16px;
  overflow: hidden;
}

.outing-photo-card .trip-photo-frame,
.trip-photo-card .trip-photo-frame {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--background);
}

.outing-photo-card .trip-photo-frame img,
.trip-photo-card .trip-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.outing-photo-card .trip-photo-meta,
.trip-photo-card .trip-photo-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 8px;
  font-size: 10.5px;
  color: var(--text-secondary);
}

.outing-photo-card .trip-photo-meta span,
.trip-photo-card .trip-photo-meta span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.outing-photo-card .trip-photo-meta .btn,
.trip-photo-card .trip-photo-meta .btn {
  min-height: 28px;
  padding: 5px 7px;
  font-size: 10px;
  border-radius: 10px;
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

.outing-photo-card .photo-delete-icon,
.trip-photo-card .photo-delete-icon {
  top: 7px;
  right: 7px;
}

.outing-memory-album-card .pill,
.trip-album-card .pill {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

/* v90 stronger creation CTAs + contacts-first friends flow */
[data-dashboard-card="create-outing"],
[data-dashboard-card="create-trip"],
[data-dashboard-card="create-group"],
[data-group-panel="create-outing"],
.social-create-btn,
.group-plan-button,
[data-action="quick-create-outing"],
[data-action="onboarding-create-outing"] {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  box-shadow: 0 10px 22px rgba(13, 148, 136, 0.22);
  font-weight: 800;
}

.dashboard-actions [data-dashboard-card="create-trip"],
.dashboard-actions [data-dashboard-card="create-group"],
.dashboard-actions [data-dashboard-card="create-outing"],
.card-head [data-dashboard-card="create-trip"],
.card-head [data-dashboard-card="create-group"],
.card-head [data-dashboard-card="create-outing"] {
  min-height: 38px;
  padding: 7px 13px;
  border-radius: 999px;
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  font-weight: 800;
}

.group-dashboard [data-dashboard-card="create-group"],
.dashboard [data-dashboard-card="create-trip"],
.dashboard [data-dashboard-card="create-outing"] {
  background: var(--teal-primary);
  color: var(--surface);
}

.contact-main-btn {
  min-height: 42px;
  height: 42px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 800;
  padding: 8px 10px;
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  box-shadow: 0 9px 18px rgba(13, 148, 136, 0.18);
}

.manual-add-friend-btn {
  min-height: 38px;
  height: 38px;
  border-radius: 13px;
  font-size: 12px;
  font-weight: 750;
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
  box-shadow: none;
}

.compact-friend-add-form .friend-phone-row {
  grid-template-columns: 1fr;
}

.compact-friend-add-form .contact-mini-btn {
  display: none;
}


/* v92 invite-friends highlight + help */
.invite-friends-highlight {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.34);
  box-shadow: 0 8px 18px rgba(13, 148, 136, 0.08);
}

.invite-friends-highlight > summary {
  background: transparent;
}

.invite-friends-highlight > summary b {
  color: var(--teal-primary);
}

.invite-friends-highlight .pill {
  background: var(--surface);
  color: var(--teal-primary);
  border-color: rgba(13, 148, 136, 0.25);
}

.feature-guide-list {
  display: grid;
  gap: 8px;
  margin: 12px 0;
}

.feature-guide-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 9px;
  align-items: start;
  padding: 9px;
  border-radius: 14px;
  background: var(--background);
  border: 1px solid var(--border);
}

.feature-guide-row span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--teal-tint);
  color: var(--teal-primary);
  font-size: 12px;
  font-weight: 800;
}

.feature-guide-row p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.35;
}


/* v93 specific step-by-step help */
.step-guide-list {
  max-height: min(58vh, 520px);
  overflow: auto;
  padding-right: 2px;
}

.step-guide-row {
  grid-template-columns: 30px minmax(0, 1fr);
}

.step-guide-row span {
  background: var(--teal-primary);
  color: var(--surface);
  font-weight: 850;
}

.feature-guide-dialog .help {
  text-align: left;
}

.feature-guide-dialog .action-row {
  margin-top: 10px;
}


/* v95 shorter help steps */
.step-guide-list {
  max-height: min(50vh, 430px);
}

.step-guide-row p {
  font-size: 12.5px;
  line-height: 1.34;
}


/* v96 compact memory detail actions and outing feedback insights */
.outing-detail-card .outing-tab-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.outing-detail-card .outing-tab-actions .btn {
  min-height: 40px;
  padding: 8px 6px;
  border-radius: 999px;
  font-size: 12px;
}

.memory-teal-btn,
.btn.memory-teal-btn {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.32);
  color: var(--teal-primary);
  box-shadow: none;
}

.post-outing-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.post-outing-actions .btn.small {
  width: 100%;
}

.history-post-actions,
.feedback-selected-card .post-outing-actions {
  grid-template-columns: 1fr;
}

.plan-again-wide {
  min-height: 46px;
}

.selected-feeling-text {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
  margin-top: 3px;
}

.outing-feeling-insights {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(13, 148, 136, 0.18);
  border-radius: 16px;
  background: var(--teal-tint);
}

.outing-feeling-insights > span {
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 750;
}

.outing-feeling-insights > b {
  color: var(--text-secondary);
  font-size: 12px;
}

.outing-feeling-insights > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.feeling-count {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid rgba(13, 148, 136, 0.18);
  font-size: 12px;
  font-weight: 800;
  color: var(--teal-primary);
}

@media (max-width: 380px) {
  .outing-detail-card .outing-tab-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}


/* v98 make View Memories the main action in history detail */
.history-outing-actions .outing-primary-actions {
  grid-template-columns: 1fr;
}

.view-memories-main-btn,
.btn.view-memories-main-btn {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
  min-height: 54px;
  font-weight: 850;
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.18);
}

.history-outing-actions .outing-tab-actions .btn,
.history-outing-actions .outing-tab-actions a.btn {
  min-height: 40px;
}


/* v101 outing admin edit + share-first UX */
.share-outing-main-btn,
.btn.share-outing-main-btn {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
  font-weight: 850;
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.18);
}

.memory-neutral-btn,
.btn.memory-neutral-btn {
  background: var(--background);
  border-color: var(--border);
  color: var(--text-primary);
  box-shadow: none;
}

.outing-admin-edit-row {
  margin-top: 8px;
}

.outing-admin-edit-row .btn {
  width: 100%;
}

.outing-edit-dialog,
.outing-created-dialog {
  max-width: 520px;
}

.outing-created-dialog .action-row .btn,
.outing-edit-dialog .action-row .btn {
  flex: 1 1 0;
}

@media (max-width: 520px) {
  .outing-created-dialog .action-row,
  .outing-edit-dialog .action-row {
    flex-direction: column;
  }
  .outing-created-dialog .action-row .btn,
  .outing-edit-dialog .action-row .btn {
    width: 100%;
  }
}


/* v102 threaded actionable notifications */
.notifications-threaded {
  display: grid;
  gap: 18px;
  margin-top: 12px;
}

.notification-section {
  display: grid;
  gap: 10px;
}

.notification-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-inline: 2px;
}

.notification-section-title h3 {
  font-size: 14px;
  font-weight: 850;
  letter-spacing: -0.01em;
}

.notification-thread {
  position: relative;
  display: grid;
  gap: 10px;
  padding-left: 15px;
}

.notification-thread::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 10px;
  bottom: 10px;
  width: 2px;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.16);
}

.notification-thread-item {
  position: relative;
  display: grid;
}

.notification-thread-dot {
  position: absolute;
  left: -14px;
  top: 20px;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--border);
  border: 2px solid var(--surface);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.06);
  z-index: 1;
}

.notification-thread-item.unread .notification-thread-dot {
  background: var(--teal-primary);
  box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.16);
}

.notifications-screen .notification-item {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  padding: 0;
  overflow: hidden;
  background: var(--surface);
  transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

.notifications-screen .notification-item.notification-new {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.28);
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.10);
}

.notifications-screen .notification-item.notification-read {
  background: rgba(255, 255, 255, 0.96);
}

.notifications-screen .notification-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(15, 23, 42, 0.08);
}

.notification-main {
  padding: 12px;
}

.notification-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
}

.notification-icon {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(13, 148, 136, 0.14);
}

.notification-copy {
  min-width: 0;
  flex: 1 1 auto;
  display: grid;
  gap: 4px;
}

.notification-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.notification-title-row b {
  min-width: 0;
  font-size: 14px;
  font-weight: 850;
  line-height: 1.2;
}

.notification-body {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.35;
}

.notification-meta {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 750;
}

.notification-new-pill {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 8px;
  background: var(--teal-primary);
  color: var(--surface);
  font-size: 11px;
  font-weight: 850;
}

.notification-chevron {
  flex: 0 0 auto;
  color: var(--teal-primary);
  font-size: 24px;
  line-height: 1;
  font-weight: 900;
  margin-top: 4px;
}

.notification-read .notification-chevron {
  color: var(--text-secondary);
}

.notification-actions {
  padding: 0 12px 12px;
}

@media (max-width: 520px) {
  .notification-thread {
    padding-left: 12px;
  }
  .notification-thread-dot {
    left: -12px;
  }
  .notification-line {
    gap: 8px;
  }
}


/* v103 notification CTA validation pass */
.notification-action-chip {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 5px 9px;
  background: rgba(13, 148, 136, 0.10);
  color: var(--teal-dark);
  border: 1px solid rgba(13, 148, 136, 0.18);
  font-size: 11px;
  font-weight: 850;
}

.notification-action-chip::after {
  content: "›";
  font-size: 14px;
  line-height: 1;
}

.notification-new .notification-action-chip {
  background: var(--surface);
  border-color: rgba(13, 148, 136, 0.22);
  color: var(--teal-dark);
}



/* v105 LinkedIn-style notification rows */
.linkedin-notifications {
  padding-left: 0;
  padding-right: 0;
  overflow: hidden;
}

.linkedin-notifications > .card-head {
  padding: 0 16px;
}

.linkedin-notifications .notifications-threaded {
  display: grid;
  gap: 0;
  margin-top: 10px;
}

.linkedin-notifications .notification-section {
  display: grid;
  gap: 0;
}

.linkedin-notifications .notification-section-title {
  padding: 14px 16px 8px;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}

.linkedin-notifications .notification-section-title:first-child {
  border-top: 0;
}

.linkedin-notifications .notification-section-title h3 {
  font-size: 16px;
  font-weight: 900;
}

.linkedin-notifications .notification-list {
  display: grid;
  gap: 0;
}

.linkedin-notifications .notification-row {
  position: relative;
  border: 0;
  border-radius: 0;
  background: var(--surface);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  transition: background 0.16s ease;
}

.linkedin-notifications .notification-row.notification-unread {
  background: var(--teal-tint);
}

.linkedin-notifications .notification-row.notification-read {
  background: var(--surface);
}

.linkedin-notifications .notification-row:hover {
  background: rgba(13, 148, 136, 0.08);
}

.linkedin-notifications .notification-main {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 14px 14px 14px 28px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 22px;
  align-items: flex-start;
  gap: 12px;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
}

.linkedin-notifications .notification-unread-dot {
  position: absolute;
  left: 10px;
  top: 34px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--teal-primary);
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.linkedin-notifications .notification-read .notification-unread-dot {
  background: transparent;
  box-shadow: none;
}

.linkedin-notifications .notification-icon {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(13, 148, 136, 0.16);
  font-size: 22px;
}

.linkedin-notifications .notification-read .notification-icon {
  background: var(--background);
  border-color: var(--border);
}

.linkedin-notifications .notification-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.linkedin-notifications .notification-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
}

.linkedin-notifications .notification-title-row b {
  font-size: 15px;
  line-height: 1.22;
  font-weight: 900;
  color: var(--text-primary);
}

.linkedin-notifications .notification-body {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.35;
}

.linkedin-notifications .notification-time {
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.linkedin-notifications .notification-action-line {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
  margin-top: 2px;
}

.linkedin-notifications .notification-menu {
  color: var(--text-secondary);
  font-size: 22px;
  line-height: 1;
  font-weight: 900;
  padding-top: 2px;
  text-align: center;
}

.linkedin-notifications .notification-actions {
  padding: 0 14px 12px 94px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.linkedin-notifications .notification-thread,
.linkedin-notifications .notification-thread::before,
.linkedin-notifications .notification-thread-dot,
.linkedin-notifications .notification-new-pill,
.linkedin-notifications .notification-chevron,
.linkedin-notifications .notification-action-chip {
  display: none;
}

@media (max-width: 520px) {
  .linkedin-notifications .notification-main {
    grid-template-columns: 48px minmax(0, 1fr) 18px;
    gap: 10px;
    padding-left: 24px;
  }
  .linkedin-notifications .notification-icon {
    width: 46px;
    height: 46px;
    border-radius: 16px;
    font-size: 20px;
  }
  .linkedin-notifications .notification-actions {
    padding-left: 82px;
  }
  .linkedin-notifications .notification-title-row b {
    font-size: 14px;
  }
  .linkedin-notifications .notification-body {
    font-size: 13px;
  }
}


/* v106 simplified notification flow */
.linkedin-notifications .card-head {
  margin-bottom: 8px;
}

.linkedin-notifications .notifications-threaded,
.linkedin-notifications .notification-section,
.linkedin-notifications .notification-section-title {
  display: contents;
}

.linkedin-notifications .notification-flow {
  display: grid;
  gap: 0;
  margin-top: 8px;
}

.linkedin-notifications .card-actions-inline .pill {
  display: none;
}

.linkedin-notifications .notification-row:first-child {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}


/* v107 smoother compact notification rows */
.linkedin-notifications .notification-main {
  grid-template-columns: 42px minmax(0, 1fr) 18px;
  gap: 10px;
  padding: 11px 12px 11px 24px;
}

.linkedin-notifications .notification-icon {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  font-size: 18px;
}

.linkedin-notifications .notification-unread-dot {
  left: 9px;
  top: 27px;
  width: 7px;
  height: 7px;
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.13);
}

.linkedin-notifications .notification-copy {
  gap: 2px;
}

.linkedin-notifications .notification-title-row b {
  font-size: 14px;
  line-height: 1.18;
  font-weight: 850;
}

.linkedin-notifications .notification-body {
  font-size: 12.5px;
  line-height: 1.28;
}

.linkedin-notifications .notification-time {
  font-size: 11px;
  font-weight: 750;
}

.linkedin-notifications .notification-action-line {
  font-size: 11.5px;
  font-weight: 850;
  margin-top: 1px;
}

.linkedin-notifications .notification-menu {
  font-size: 18px;
  padding-top: 0;
}

.linkedin-notifications .notification-actions {
  padding: 0 12px 10px 76px;
  gap: 7px;
}

@media (max-width: 520px) {
  .linkedin-notifications .notification-main {
    grid-template-columns: 40px minmax(0, 1fr) 16px;
    gap: 9px;
    padding: 10px 10px 10px 22px;
  }

  .linkedin-notifications .notification-icon {
    width: 38px;
    height: 38px;
    border-radius: 13px;
    font-size: 17px;
  }

  .linkedin-notifications .notification-actions {
    padding-left: 72px;
  }
}


/* v108 neutral grey notification icons */
.linkedin-notifications .notification-icon,
.linkedin-notifications .notification-unread .notification-icon,
.linkedin-notifications .notification-read .notification-icon {
  background: var(--background);
  border-color: var(--border);
  color: var(--text-secondary);
  filter: grayscale(1) saturate(0);
}

.linkedin-notifications .notification-icon * {
  color: var(--text-secondary);
  filter: grayscale(1) saturate(0);
}

.linkedin-notifications .notification-unread-dot {
  background: var(--text-secondary);
  box-shadow: 0 0 0 3px rgba(100, 116, 139, 0.14);
}

.linkedin-notifications .notification-action-line {
  color: var(--teal-dark);
}


/* v110 notification click loading feedback */
.notification-navigation-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: rgba(248, 250, 251, 0.42);
  backdrop-filter: blur(2px);
}

.notification-loader-card {
  min-width: 112px;
  min-height: 112px;
  border-radius: 28px;
  display: grid;
  place-items: center;
  gap: 10px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(13, 148, 136, 0.18);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.14);
}

.notification-loader-spinner {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 4px solid rgba(13, 148, 136, 0.18);
  border-top-color: var(--teal-primary);
  animation: notification-loader-spin 0.72s linear infinite;
}

.notification-loader-card p {
  margin: 0;
  color: var(--teal-dark);
  font-weight: 850;
  font-size: 13px;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.photo-pagination-footer {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 750;
}

.photo-pagination-spinner {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 3px solid rgba(13, 148, 136, 0.18);
  border-top-color: var(--teal-primary);
  animation: notification-loader-spin 0.72s linear infinite;
}

.photo-pagination-text.muted {
  opacity: 0.72;
}

.explore-pagination-footer {
  margin-top: 4px;
}

.plan-pagination-footer {
  margin-top: 6px;
}


/* v112 clean notification rows: remove left dots */
.linkedin-notifications .notification-unread-dot {
  display: none;
}

.linkedin-notifications .notification-main {
  padding-left: 12px;
  grid-template-columns: 40px minmax(0, 1fr) 18px;
}

@media (max-width: 520px) {
  .linkedin-notifications .notification-main {
    padding-left: 10px;
    grid-template-columns: 38px minmax(0, 1fr) 16px;
  }
}

/* v112 random outing */
.plan-outing-head {
  align-items: flex-start;
}

.plan-outing-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.random-outing-btn,
.btn.random-outing-btn {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
  box-shadow: 0 10px 22px rgba(13, 148, 136, 0.16);
}

.random-outing-dialog {
  max-width: 520px;
}

.random-roulette {
  width: 96px;
  height: 96px;
  margin: 0 auto 12px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  position: relative;
  background: var(--teal-tint);
  border: 1px solid rgba(13, 148, 136, 0.22);
  box-shadow: inset 0 0 0 10px rgba(255,255,255,0.62), 0 18px 38px rgba(13, 148, 136, 0.14);
  overflow: hidden;
}

.random-roulette span {
  position: absolute;
  font-size: 28px;
  filter: grayscale(0.35);
}

.random-roulette span:nth-child(1) { transform: translateY(-30px); }
.random-roulette span:nth-child(2) { transform: translateX(30px); }
.random-roulette span:nth-child(3) { transform: translateY(30px); }
.random-roulette span:nth-child(4) { transform: translateX(-30px); }
.random-roulette span:nth-child(5) {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--surface);
  color: var(--teal-dark);
  font-size: 24px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.10);
}

.random-roulette.rolling {
  animation: random-roulette-spin 0.42s linear infinite;
}

.random-outing-result {
  text-align: left;
}

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

@media (max-width: 520px) {
  .plan-outing-head {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .plan-outing-head-actions {
    justify-content: space-between;
  }
  .random-outing-btn {
    flex: 1 1 auto;
  }
}


/* v113 neutral Memory tab button */
.outing-tab-actions .memory-neutral-btn,
.outing-tab-actions .btn.memory-neutral-btn,
.outing-tab-actions .memory-neutral-btn:focus,
.outing-tab-actions .memory-neutral-btn:focus-visible,
.outing-tab-actions .memory-neutral-btn:hover {
  background: var(--background);
  border-color: var(--border);
  color: var(--text-secondary);
  box-shadow: none;
  outline: none;
}

.outing-tab-actions .memory-neutral-btn:active {
  transform: none;
}


/* v116 friend request actions inside notifications */
.linkedin-notifications .notification-actions.notification-friend-fallback {
  grid-template-columns: 1fr;
}

.linkedin-notifications .notification-actions .btn {
  min-height: 38px;
}


/* v119 unfriend option */
.friend-actions .unfriend-btn,
.btn.unfriend-btn {
  color: var(--text-secondary);
  border-color: rgba(244, 63, 94, 0.24);
  background: rgba(255, 241, 242, 0.74);
}

.friend-actions .unfriend-btn:hover {
  background: rgba(255, 228, 230, 0.95);
}


/* v124 friend request notification action repair */
.linkedin-notifications .friend-request-notification-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}


/* v125 compact friend card and top-right unfriend */
.compact-friend-card {
  padding: 12px 14px;
  gap: 10px;
}

.friend-card-main {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.friend-card-main .avatar {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
}

.friend-card-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.friend-card-top-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  align-self: start;
}

.friend-card-top-actions .mini-pill {
  white-space: nowrap;
}

.friend-card-top-actions .compact-unfriend-btn,
.btn.compact-unfriend-btn {
  width: auto;
  min-width: 0;
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  box-shadow: none;
}

.compact-friend-card > .friend-actions {
  margin-top: 4px;
}

@media (max-width: 520px) {
  .friend-card-main {
    grid-template-columns: 46px minmax(0, 1fr) auto;
    gap: 10px;
  }
  .friend-card-main .avatar {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }
  .friend-card-top-actions {
    gap: 6px;
  }
  .friend-card-top-actions .mini-pill {
    display: none;
  }
}


/* v126 simple UX map */
.simple-home-hero {
  display: grid;
  gap: 18px;
  padding: 24px;
}

.simple-home-copy h2 {
  margin: 8px 0 6px;
  font-size: clamp(26px, 6vw, 40px);
  line-height: 1.05;
}

.simple-home-actions {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr);
  gap: 10px;
}

.home-primary-plan {
  min-height: 58px;
  font-size: 18px;
}

.home-random-btn {
  min-height: 58px;
}

.simple-home-section .card-head {
  align-items: flex-start;
}

.simple-home-list {
  display: grid;
  gap: 8px;
}

.home-attention-item,
.home-plan-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  text-align: left;
  border-radius: 22px;
  padding: 12px;
  width: 100%;
}

.home-attention-icon,
.home-plan-icon {
  width: 40px;
  height: 40px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: var(--background);
  border: 1px solid var(--border);
  filter: grayscale(1) saturate(0);
}

.home-attention-copy,
.home-plan-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.home-attention-copy span,
.home-plan-copy span {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.3;
}

.home-attention-action {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 850;
  text-align: right;
}

.simple-plans-card {
  padding-bottom: 16px;
}

.simple-plans-subnav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.simple-plans-tab {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 20px;
  padding: 12px 10px;
  display: grid;
  gap: 5px;
  place-items: center;
  color: var(--text-secondary);
  font: inherit;
  cursor: pointer;
}

.simple-plans-tab span {
  filter: grayscale(1) saturate(0);
  opacity: 0.8;
}

.simple-plans-tab.active {
  background: var(--teal-tint);
  border-color: rgba(13, 148, 136, 0.45);
  color: var(--teal-dark);
}

.simple-outing-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.simple-more-row {
  grid-template-columns: 1fr;
}

.outing-more-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 560px) {
  .simple-home-actions {
    grid-template-columns: 1fr;
  }

  .home-attention-item,
  .home-plan-item {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .home-attention-action {
    grid-column: 2;
    text-align: left;
  }

  .simple-outing-actions {
    grid-template-columns: 1fr;
  }

  .outing-more-grid {
    grid-template-columns: 1fr;
  }
}


/* v127 Simple UX Map v2 */
.header-quick-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.header-notification-icon {
  position: relative;
  border: 0;
  background: transparent;
  padding: 0;
  min-width: 34px;
  min-height: 34px;
  display: grid;
  place-items: center;
  font: inherit;
  cursor: pointer;
  color: var(--text-secondary);
}

.header-notification-icon span {
  font-size: 25px;
  filter: grayscale(1) saturate(0);
  opacity: 0.82;
}

.header-notification-icon.active span {
  opacity: 1;
}

.header-notification-icon b {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--teal-primary);
  color: var(--surface);
  font-size: 10px;
  line-height: 1;
  box-shadow: 0 8px 16px rgba(13, 148, 136, 0.22);
}

.plans-control-card {
  gap: 16px;
}

.plans-control-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
}

.plans-context-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.plans-context-actions .btn {
  min-height: 44px;
  white-space: nowrap;
}

.plans-context-stats {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.plans-context-stats .stat {
  min-height: 72px;
}

.plans-context-stats .stat b {
  font-size: 28px;
}

.simple-plans-card + .action-panel,
.simple-plans-card + .list-section {
  margin-top: 14px;
}

.simple-plans-card .simple-plans-subnav {
  margin-top: 4px;
}

@media (max-width: 560px) {
  .header-quick-actions {
    gap: 10px;
  }

  .plans-control-head {
    grid-template-columns: 1fr;
  }

  .plans-context-actions {
    justify-content: stretch;
  }

  .plans-context-actions .btn {
    flex: 1 1 auto;
  }

  .plans-context-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}


/* v128 bottom two-button navigation */
.social-header {
  padding-bottom: 22px;
}

.social-header .header-create-btn,
.social-header .social-nav {
  display: none;
}

body {
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}


/* v129 compact stable Plans control card */
.plans-control-card {
  min-height: 365px;
}

.plans-control-head {
  grid-template-columns: 1fr;
  gap: 10px;
}

.plans-control-head > div:first-child .help {
  max-width: 100%;
  line-height: 1.25;
}

.compact-plan-actions,
.plans-context-actions.compact-plan-actions {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 10px;
  width: 100%;
  align-items: stretch;
}

.compact-plan-actions .btn,
.compact-plan-actions .help-chip {
  width: 100%;
  min-height: 48px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  text-align: center;
  white-space: nowrap;
}

.compact-plan-actions .btn {
  font-size: 16px;
  box-shadow: 0 12px 28px rgba(13, 148, 136, 0.14);
}

.compact-plan-actions .help-chip {
  margin: 0;
  padding: 0 10px;
}

.plans-context-stats {
  min-height: 72px;
}

.plans-context-stats .static-stat {
  cursor: default;
  user-select: none;
}

.simple-plans-subnav {
  margin-top: 8px;
}

.simple-plans-tab {
  min-height: 92px;
}

@media (max-width: 560px) {
  .plans-control-card {
    min-height: 356px;
  }

  .compact-plan-actions,
  .plans-context-actions.compact-plan-actions {
    grid-template-columns: 2fr 1fr;
  }

  .compact-plan-actions .btn,
  .compact-plan-actions .help-chip {
    min-height: 46px;
    font-size: 14px;
  }

  .plans-context-stats .stat {
    min-height: 66px;
  }

  .simple-plans-tab {
    min-height: 86px;
  }
}


/* v130 typography normalization
   One app font, fewer weight levels, consistent text rhythm. */
html,
body,
button,
input,
select,
textarea,
a {
  font-family: var(--text-primary);
  font-synthesis-weight: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.45;
}

.brand-ar {
  font-family: var(--text-primary);
  font-weight: var(--weight-semibold);
}

.brand-copy h1,
.boot h1,
.card h2,
.card h3,
.simple-home-copy h2,
.item-title,
.item-main b,
.friend-card-copy .item-title,
.trip-record-copy .item-title,
.profile-name,
.login-progress-card h1 {
  font-family: var(--text-primary);
  font-weight: var(--weight-semibold);
  letter-spacing: -0.015em;
}

.brand-copy h1 {
  font-size: clamp(28px, 6vw, 34px);
  line-height: 1.05;
}

.card h2 {
  font-size: clamp(22px, 5.2vw, 28px);
  line-height: 1.12;
}

.card h3 {
  font-size: var(--text-lg);
  line-height: 1.18;
}

.item-title,
.item-main b {
  font-size: var(--text-lg);
  line-height: 1.22;
}

.brand-copy p,
.help,
.item-sub,
.field label,
.notification-body,
.linkedin-notifications .notification-body,
.home-attention-copy span,
.home-plan-copy span,
.profile-subtitle,
.compact-friends-note {
  font-family: var(--text-primary);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  line-height: 1.38;
  letter-spacing: 0;
}

.btn,
button.btn,
.contact-main-btn,
.manual-add-friend-btn,
.header-create-btn,
.social-create-btn,
.simple-plans-tab,
.profile-nav-button,
.help-chip,
.pill,
.mini-pill,
.stat,
.notification-action-chip,
.notification-actions .btn,
.friend-actions .btn,
.compact-plan-actions .btn,
.compact-plan-actions .help-chip {
  font-family: var(--text-primary);
  font-weight: var(--weight-semibold);
  letter-spacing: 0;
}

.btn,
button.btn {
  font-size: var(--text-md);
}

.btn.small,
button.btn.small,
.help-chip,
.pill {
  font-size: var(--text-sm);
}

.mini-pill {
  font-size: var(--text-xs);
}

.input,
.select,
.textarea {
  font-family: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.35;
}

.stat b,
.plans-context-stats .stat b,
.analytics-card b {
  font-family: var(--text-primary);
  font-weight: var(--weight-semibold);
  letter-spacing: -0.02em;
}

.stat,
.plans-context-stats .stat {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  letter-spacing: 0.01em;
}

.social-nav-item,
.profile-home-btn,
.friend-card-top-actions .compact-unfriend-btn,
.btn.compact-unfriend-btn,
.view-memories-main-btn,
.btn.view-memories-main-btn,
.share-outing-main-btn,
.btn.share-outing-main-btn,
.random-outing-btn,
.btn.random-outing-btn {
  font-weight: var(--weight-semibold);
}

.linkedin-notifications .notification-title,
.notification-title {
  font-family: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  line-height: 1.18;
}

.linkedin-notifications .notification-time,
.notification-time {
  font-family: var(--text-primary);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
}

@media (max-width: 520px) {
  .card h2 {
    font-size: clamp(21px, 5.8vw, 26px);
  }
}


/* v131 flat segmented navigation + white flow background */

/* White app flow */
html,
body,
.app-shell {
  background: var(--surface);
}

body {
  background: var(--surface);
}

.app-shell {
  padding-left: 12px;
  padding-right: 12px;
}

/* Reduce separated-box feeling while keeping readable sections */
.top-card,
.card {
  background: var(--surface);
  box-shadow: none;
  border-color: var(--border);
}

.card {
  border-left-color: transparent;
  border-right-color: transparent;
  border-radius: 0;
  padding-left: 14px;
  padding-right: 14px;
}

.top-card.social-header {
  border-radius: 28px;
  border-color: rgba(225, 232, 236, 0.8);
}

/* Keep high-touch inner controls visible */
.item,
.input,
.select,
.textarea,
.btn,
.help-chip,
.stat,
.friend-card,
.list-card > .item {
  box-shadow: none;
}

/* Plans tabs as flat full-width segments */
.simple-plans-subnav {
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(225, 232, 236, 0.95);
  border-radius: 24px;
  background: var(--surface);
}

.simple-plans-tab {
  border: 0;
  border-radius: 0;
  background: transparent;
  min-height: 88px;
  box-shadow: none;
}

.simple-plans-tab + .simple-plans-tab {
  border-left: 1px solid rgba(225, 232, 236, 0.85);
}

.simple-plans-tab.active {
  background: var(--teal-tint);
  color: var(--teal-dark);
  border: 0;
  box-shadow: none;
}

/* Make the Plans control feel like one flowing section */
.plans-control-card {
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding-top: 18px;
  padding-bottom: 18px;
}

.simple-plans-card + .action-panel,
.simple-plans-card + .list-section,
.card + .card {
  margin-top: 8px;
}

/* Main list/detail sections should feel connected to the page */
.list-section,
.action-panel,
.outing-detail-card,
.trip-detail-card,
.memory-card,
.payments-card,
.people-card {
  border-radius: 0;
  border-left: 0;
  border-right: 0;
}

/* But keep nested items as cards because they are tappable records */
.list-card .item,
.friend-card,
.notification-row,
.linkedin-notifications .notification-row {
  border-radius: 18px;
  border: 1px solid rgba(225, 232, 236, 0.95);
  background: var(--surface);
}

@media (max-width: 520px) {
  .app-shell {
    padding-left: 10px;
    padding-right: 10px;
  }

  .simple-plans-subnav {
    border-radius: 22px;
  }

  .simple-plans-tab {
    min-height: 84px;
  }
}


/* v132 full-width rectangle bottom nav + compact Plans card */

/* Full-width bottom navigation: no rounded sides {
  left: 0;
  right: 0;
  bottom: 0;
  transform: none;
  width: 100vw;
  max-width: none;
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  padding: 0;
  gap: 0;
  box-shadow: none;
  background: var(--surface);
}

body {
  padding-bottom: calc(68px + env(safe-area-inset-bottom));
}

.app-shell {
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}

/* Compact the Plans control card */
.plans-control-card {
  min-height: 0;
  gap: 9px;
  padding-top: 14px;
  padding-bottom: 12px;
}

.plans-control-head {
  gap: 8px;
}

.plans-control-head > div:first-child {
  display: grid;
  gap: 2px;
}

.plans-control-head > div:first-child h2 {
  margin: 0;
  line-height: 1.04;
}

.plans-control-head > div:first-child .help {
  margin: 0;
  line-height: 1.22;
}

/* CTA and Help: same row, CTA 2/3, Help 1/3 */
.compact-plan-actions,
.plans-context-actions.compact-plan-actions {
  grid-template-columns: 2fr 1fr;
  gap: 8px;
  margin-top: 0;
}

.compact-plan-actions .btn,
.compact-plan-actions .help-chip {
  min-height: 44px;
  border-radius: 18px;
}

/* Counters: shorter */
.plans-context-stats {
  min-height: 0;
  gap: 8px;
}

.plans-context-stats .stat {
  min-height: 56px;
  padding: 8px 10px;
}

.plans-context-stats .stat b {
  font-size: 24px;
  margin-bottom: 0;
}

/* Outings / Trips / Groups: shorter flat segments, no extra bottom area */
.simple-plans-subnav {
  margin-top: 2px;
  border-radius: 0;
}

.simple-plans-tab {
  min-height: 62px;
  padding: 8px 6px;
  gap: 2px;
  border-radius: 0;
}

.simple-plans-tab span {
  font-size: 18px;
  line-height: 1;
}

.simple-plans-tab b {
  font-size: 14px;
  line-height: 1.1;
}

/* Remove rounded sides from the internal segmented control too */
.simple-plans-subnav,
.simple-plans-subnav .simple-plans-tab:first-child,
.simple-plans-subnav .simple-plans-tab:last-child {
  border-radius: 0;
}

@media (max-width: 520px) {

  .plans-control-card {
    padding-top: 12px;
    padding-bottom: 10px;
    gap: 8px;
  }

  .compact-plan-actions .btn,
  .compact-plan-actions .help-chip {
    min-height: 42px;
  }

  .plans-context-stats .stat {
    min-height: 52px;
  }

  .simple-plans-tab {
    min-height: 58px;
  }
}


/* v133 Plans card as compact flat rows */
.plans-control-card {
  padding: 0;
  gap: 0;
  min-height: 0;
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  overflow: hidden;
}

.plans-control-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  padding: 14px 12px 0;
  border-bottom: 0;
}

.plans-control-head > div:first-child {
  padding: 0 0 8px;
}

.plans-control-head > div:first-child h2 {
  font-size: 26px;
  line-height: 1.05;
}

.plans-control-head > div:first-child .help {
  font-size: 13px;
  line-height: 1.25;
}

/* Row 1 action strip */
.compact-plan-actions,
.plans-context-actions.compact-plan-actions {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 8px;
  width: 100%;
  padding: 0 0 10px;
  margin: 0;
}

.compact-plan-actions .btn,
.compact-plan-actions .help-chip {
  min-height: 44px;
  border-radius: 18px;
  margin: 0;
}

/* Row 2 counters: flat joined rectangular row */
.plans-context-stats {
  width: calc(100% + 24px);
  margin-left: -12px;
  margin-right: -12px;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid rgba(13, 148, 136, 0.16);
  border-bottom: 1px solid rgba(13, 148, 136, 0.16);
}

.plans-context-stats .stat {
  min-height: 54px;
  padding: 6px 8px;
  border: 0;
  border-radius: 0;
  background: var(--surface);
  box-shadow: none;
}

.plans-context-stats .stat + .stat {
  border-left: 1px solid rgba(225, 232, 236, 0.92);
}

.plans-context-stats .stat.active {
  background: var(--surface);
  border-color: transparent;
  color: var(--text-primary);
}

.plans-context-stats .stat b {
  font-size: 22px;
  line-height: 1;
  margin: 0;
}

/* Row 3 plan selector: flat joined full-width row */
.simple-plans-subnav {
  width: 100%;
  margin: 0;
  gap: 0;
  border: 0;
  border-bottom: 1px solid rgba(13, 148, 136, 0.16);
  border-radius: 0;
  overflow: hidden;
}

.simple-plans-tab {
  min-height: 56px;
  padding: 6px 4px;
  border: 0;
  border-radius: 0;
  background: var(--surface);
  box-shadow: none;
  gap: 2px;
}

.simple-plans-tab + .simple-plans-tab {
  border-left: 1px solid rgba(225, 232, 236, 0.92);
}

.simple-plans-tab.active {
  background: var(--teal-tint);
  color: var(--teal-dark);
}

.simple-plans-tab span {
  font-size: 17px;
  line-height: 1;
}

.simple-plans-tab b {
  font-size: 13px;
  line-height: 1.05;
}

/* Remove extra breathing space directly after the Plans control card */
.simple-plans-card + .action-panel,
.simple-plans-card + .list-section,
.plans-control-card + .action-panel,
.plans-control-card + .list-section {
  margin-top: 6px;
}

/* Group panel should keep the same row structure */
.group-context-stats .static-stat {
  min-height: 54px;
}

@media (max-width: 520px) {
  .plans-control-head {
    padding: 12px 10px 0;
  }

  .plans-control-head > div:first-child {
    padding-bottom: 7px;
  }

  .plans-context-stats {
    width: calc(100% + 20px);
    margin-left: -10px;
    margin-right: -10px;
  }

  .compact-plan-actions .btn,
  .compact-plan-actions .help-chip {
    min-height: 42px;
  }

  .plans-context-stats .stat {
    min-height: 50px;
  }

  .simple-plans-tab {
    min-height: 52px;
  }
}


/* v135 visual system tokens + global component consistency */

/* Design tokens: define once, consume everywhere */
/* Base */
html,
body,
.app-shell {
  background: var(--background);
  color: var(--text-primary);
}

body,
button,
input,
select,
textarea,
a {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Arabic", Arial, sans-serif;
  color: inherit;
  font-synthesis-weight: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.42;
}

/* Header / top app bar */
.top-card.social-header,
.social-header {
  background: var(--surface);
  border: 0;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  box-shadow: none;
  padding: 12px 14px;
  margin: 0 0 12px;
}

.social-header-top {
  align-items: center;
}

.brand-logo,
.social-brand-logo {
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  border-radius: 12px;
  background: var(--teal-primary);
  box-shadow: none;
}

.brand-copy h1,
.social-brand-copy h1,
.brand-en {
  font-size: 24px;
  font-weight: var(--weight-semibold);
  line-height: 1.06;
  letter-spacing: -0.015em;
  color: var(--text-primary);
}

.brand-ar {
  color: var(--teal-primary);
  font-weight: var(--weight-semibold);
}

.brand-copy p,
.social-brand-copy p {
  max-width: 190px;
  margin-top: 3px;
  color: var(--text-secondary);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.header-quick-actions {
  gap: 12px;
}

.header-notification-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  color: var(--text-secondary);
  background: transparent;
  border: 0;
  box-shadow: none;
}

.header-notification-icon span {
  font-size: 24px;
  filter: grayscale(1) saturate(0);
  opacity: 0.72;
}

.profile-nav-button,
.avatar-button.profile-nav-button {
  width: 44px;
  flex: 0 0 44px;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: var(--weight-medium);
  gap: 4px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.profile-nav-button .avatar,
.avatar-button.profile-nav-button .avatar {
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  box-shadow: none;
}

.profile-nav-button span {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: var(--weight-medium);
}

/* Type scale */
.card h2,
.section-title,
.list-section h2,
.action-panel h2,
.plans-control-head h2 {
  font-size: var(--text-xl);
  font-weight: var(--weight-semibold);
  line-height: 1.12;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.card h3 {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.item-title,
.item-main b,
.friend-card-copy .item-title,
.trip-record-copy .item-title,
.outing-title,
.trip-title,
.group-title {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  line-height: 1.22;
  color: var(--text-primary);
}

.help,
.item-sub,
.field label,
.profile-subtitle,
.notification-body,
.linkedin-notifications .notification-body,
.brand-copy p,
.meta-row,
.date-line,
.location-line {
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: 1.35;
  color: var(--text-secondary);
}

.meta-row,
.meta-row *,
.item-sub,
.item-sub *,
.pill-sub,
.compact-friends-note,
.notification-time,
.linkedin-notifications .notification-time {
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  color: var(--text-secondary);
}

/* Primary buttons and CTA: one teal only */
.btn,
button.btn,
.contact-main-btn,
.manual-add-friend-btn,
.share-outing-main-btn,
.btn.share-outing-main-btn,
.home-primary-plan,
.compact-plan-actions .btn,
.header-create-btn,
.social-create-btn {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  letter-spacing: 0;
  box-shadow: none;
}

.btn.secondary,
button.btn.secondary,
.help-chip,
.btn.ghost {
  background: var(--surface);
  border-color: var(--border);
  color: var(--teal-dark);
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  box-shadow: none;
}

.help-chip {
  color: var(--teal-dark);
}

/* Inputs */
.input,
.select,
.textarea {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
}

.input::placeholder,
.textarea::placeholder {
  color: var(--text-secondary);
}

/* Stats */
.stat {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: var(--weight-medium);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.stat b,
.plans-context-stats .stat b,
.analytics-card b {
  font-size: 28px;
  font-weight: var(--weight-semibold);
  line-height: 1;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.simple-plans-subnav {
  background: var(--surface);
  border-color: var(--border);
}

.simple-plans-tab {
  color: var(--text-secondary);
  font-size: var(--text-md);
  font-weight: var(--weight-medium);
  background: transparent;
  border-color: var(--border);
}

.simple-plans-tab span,
.social-nav-icon {
  filter: grayscale(1) saturate(0);
  opacity: 0.72;
}

.simple-plans-tab.active {
  background: var(--teal-tint);
  color: var(--teal-dark);
  font-weight: var(--weight-semibold);
}

.simple-plans-tab.active span {
  opacity: 1;
}

/* Active selected states must use only teal tokens */
.active,
.social-nav-item.active,
.profile-home-btn.active,
.mini-pill.success,
.notification-action-chip,
.pill.active {
  border-color: var(--border);
}

.notification-action-chip {
  background: var(--teal-tint);
  color: var(--teal-dark);
}

/* Reusable list/card component across Outings, Trips, Groups */
.item,
.list-card .item,
.friend-card,
.trip-record-card,
.outing-card,
.group-card,
.notification-row,
.linkedin-notifications .notification-row {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-primary);
  box-shadow: none;
}

.item-main,
.item-main *,
.home-plan-copy,
.home-attention-copy {
  color: inherit;
}

/* Status pills: never teal unless actually selected/nav/CTA */
.pill,
.mini-pill {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  background: var(--border);
  border: 0;
}

.mini-pill.success,
.pill.success {
  color: var(--text-secondary);
  background: var(--border);
}

.mini-pill.warning,
.pill.warning {
  color: var(--text-secondary);
  background: var(--border);
}

.mini-pill.danger,
.pill.danger {
  color: var(--text-secondary);
  background: var(--border);
}

.mini-pill.muted,
.pill.muted {
  color: var(--text-secondary);
  background: var(--border);
}

/* Ensure teal is not used decoratively on section borders/shadows */
.top-card,
.card,
.list-section,
.action-panel,
.plans-control-card,
.outing-detail-card,
.trip-detail-card,
.memory-card,
.payments-card,
.people-card {
  border-color: var(--border);
  box-shadow: none;
}

/* Plans card rows */
.plans-control-card {
  background: var(--surface);
}

.plans-control-card,
.simple-plans-card {
  color: var(--text-primary);
}

.simple-plans-tab b {
  font-size: var(--text-md);
  font-weight: inherit;
}

/* Notifications */
.linkedin-notifications .notification-title,
.notification-title {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.linkedin-notifications .notification-body,
.notification-body {
  color: var(--text-secondary);
}

.linkedin-notifications .notification-row.unread,
.notification-row.unread {
  background: var(--teal-tint);
}

/* Mobile refinements */
@media (max-width: 520px) {
  .brand-logo,
  .social-brand-logo {
    width: 48px;
    height: 48px;
  }

  .brand-copy h1,
  .social-brand-copy h1,
  .brand-en {
    font-size: 23px;
  }

  .card h2,
  .section-title,
  .list-section h2,
  .action-panel h2,
  .plans-control-head h2 {
    font-size: 20px;
  }

  .item-title,
  .item-main b {
    font-size: 17px;
  }
}


/* v136 consolidated visual system components */
html, body, .app-shell { background: var(--background); color: var(--text-primary); }
body, button, input, select, textarea, a { font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Arabic", Arial, sans-serif; }
body { font-size: var(--text-md); font-weight: var(--weight-regular); line-height: 1.42; }
.top-card.social-header, .social-header { background: var(--surface); border: 0; border-bottom: 1px solid var(--border); border-radius: 0; box-shadow: none; }
.brand-logo, .social-brand-logo { width:48px; height:48px; min-width:48px; min-height:48px; border-radius:12px; background: var(--teal-primary); box-shadow:none; }
.brand-copy h1, .social-brand-copy h1, .brand-en { font-size:24px; font-weight:var(--weight-semibold); color:var(--text-primary); line-height:1.06; }
.brand-copy p, .social-brand-copy p, .help, .item-sub, .field label { color:var(--text-secondary); font-size:var(--text-md); font-weight:var(--weight-regular); }
.card h2, .list-section h2, .action-panel h2, .plans-control-head h2 { font-size:var(--text-xl); font-weight:var(--weight-semibold); color:var(--text-primary); line-height:1.12; }
.item-title, .item-main b { font-size:var(--text-lg); font-weight:var(--weight-semibold); color:var(--text-primary); }
.btn, button.btn, .compact-plan-actions .btn { background:var(--teal-primary); border-color:var(--teal-primary); color:var(--surface); font-weight:var(--weight-semibold); }
.btn.secondary, .help-chip, button.btn.secondary { background:var(--surface); border-color:var(--border); color:var(--teal-dark); font-weight:var(--weight-medium); }
.simple-plans-tab { color:var(--text-secondary); background:transparent; font-size:var(--text-md); font-weight:var(--weight-medium); }
.simple-plans-tab.active { background:var(--teal-tint); color:var(--teal-dark); font-weight:var(--weight-semibold); }
.stat { color:var(--text-secondary); background:var(--surface); border-color:var(--border); font-size:12px; font-weight:var(--weight-medium); text-transform:uppercase; }
.stat b { color:var(--text-primary); font-size:28px; font-weight:var(--weight-semibold); }
.item, .outing-item, .trip-item, .group-item, .friend-card, .notification-row { background:var(--surface); border:1px solid var(--border); box-shadow:none; }
.pill, .mini-pill { background:var(--border); color:var(--text-secondary); font-size:var(--text-sm); font-weight:var(--weight-medium); }
.status-pill.active, .status-pill.upcoming { background:var(--border); color:var(--text-primary); }
.status-explain { margin-top:2px; }
.card-quick-actions { display:grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap:8px; margin-top:8px; }
.card-quick-actions.single { grid-template-columns: 1fr; }
.quick-action-btn { min-height:38px; border:1px solid var(--border); border-radius:12px; background:var(--surface); color:var(--teal-dark); font-size:var(--text-sm); font-weight:var(--weight-medium); }
.share-card-btn { background:var(--teal-primary); border-color:var(--teal-primary); color:var(--surface); }
.empty { border:1px dashed var(--border); background:var(--surface); }
.notification-row.notification-unread { background:var(--teal-tint); }
.notification-unread-dot { display:none; }
.notification-row.notification-unread .notification-unread-dot { display:block; width:8px; height:8px; border-radius:50%; background:var(--teal-primary); position:absolute; left:10px; top:22px; }
.notification-row { position:relative; }
.notification-icon { background:var(--background); color:var(--text-secondary); }
.notification-type-friend-request .notification-icon { background:var(--teal-tint); color:var(--teal-dark); }
.notification-type-friend-accepted .notification-icon { background:var(--teal-tint); color:var(--teal-dark); }
.notification-type-outing .notification-icon { background:var(--teal-tint); color:var(--teal-dark); }
.notification-dismiss { position:absolute; right:8px; top:8px; width:32px; height:32px; border:1px solid var(--border); border-radius:999px; background:var(--surface); color:var(--text-secondary); font-size:18px; line-height:1; }
.notification-menu { display:none; }


/* v138 shared Groups card alignment */
.group-card .group-record-layout {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  width: 100%;
}

.group-card .group-record-copy {
  min-width: 0;
  display: grid;
  gap: 8px;
  text-align: left;
}

.group-card .item-topline {
  align-items: start;
}

.group-card .status-pill {
  align-self: start;
  margin-top: 0;
}

/* v138 semantic pill aliases replacing old palette names */
.mini-pill.muted,
.pill.muted {
  color: var(--text-secondary);
  background: var(--background);
}

.mini-pill.success,
.pill.success {
  color: var(--status-success-text);
  background: var(--status-success-bg);
}

.mini-pill.warning,
.pill.warning {
  color: var(--status-warning-text);
  background: var(--status-warning-bg);
}

.mini-pill.danger,
.pill.danger {
  color: var(--status-danger-text);
  background: var(--status-danger-bg);
}


/* v139 compact Friends add card: remove duplicated static invite copy */
.compact-friends-card {
  padding-top: 14px;
  padding-bottom: 14px;
}

.compact-friends-card .card-head {
  margin-bottom: 8px;
}

.compact-friend-add-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.compact-phone-field,
.compact-friend-add-form .friend-add-status {
  grid-column: 1 / -1;
}

.compact-phone-field {
  gap: 4px;
}

.compact-phone-field label {
  font-size: 13px;
  color: var(--text-secondary);
}

.compact-friend-add-form .input {
  min-height: 44px;
}

.compact-friend-add-form .contact-main-btn,
.compact-friend-add-form .manual-add-friend-btn {
  width: 100%;
  min-height: 44px;
  height: 44px;
  border-radius: 14px;
  margin: 0;
  box-shadow: none;
}

.compact-friend-add-form .manual-add-friend-btn {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
}

.compact-friend-add-form .compact-friends-note {
  display: none;
}

.compact-friends-card .friend-add-status {
  margin-top: 2px;
  padding: 10px 11px;
  border-radius: 14px;
}

/* Keep the dynamic result/invite message useful, but not oversized. */
.compact-friends-card .friend-add-status b {
  margin-bottom: 2px;
  font-size: 14px;
}

.compact-friends-card .friend-add-status .help {
  max-width: 100%;
  font-size: 13px;
  line-height: 1.28;
}

@media (max-width: 380px) {
  .compact-friend-add-form {
    grid-template-columns: 1fr;
  }
}


/* v140: center Groups and Spots dashboard counters like Outings and Trips */
.group-context-stats .static-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.group-context-stats .static-stat b {
  width: 100%;
  text-align: center;
}


/* v143 from v140 base: clickable stat active/inactive text state
   Active counter = black. Inactive counter = gray. No shadow/background change. */
.plans-context-stats button.stat {
  cursor: pointer;
}

.plans-context-stats button.stat,
.plans-context-stats button.stat b {
  color: var(--text-secondary);
}

.plans-context-stats button.stat.active,
.plans-context-stats button.stat.active b {
  color: var(--text-primary);
}

.plans-context-stats button.stat.active,
.plans-context-stats button.stat:not(.active) {
  background: var(--surface);
  box-shadow: none;
}

/* Static group/spots stats are not filters, so keep them dark and centered. */
.group-context-stats .static-stat,
.group-context-stats .static-stat b {
  color: var(--text-primary);
}


/* v144 photo visibility + Friends Explore feed */
.trip-photo-frame,
.explore-photo-frame {
  position: relative;
  overflow: hidden;
}

.photo-visibility-pill {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  border: 0;
  border-radius: 999px;
  padding: 7px 12px;
  font: inherit;
  font-size: 13px;
  font-weight: var(--weight-semibold);
  line-height: 1;
  box-shadow: 0 6px 16px rgba(17, 24, 39, 0.14);
}

button.photo-visibility-pill {
  cursor: pointer;
}

.photo-visibility-pill.visible {
  background: var(--teal-primary);
  color: var(--surface);
}

.photo-visibility-pill.private {
  background: #8B95A1;
  color: var(--surface);
}

.photo-visibility-pill span {
  font-size: 9px;
}

.photo-visibility-help {
  display: block;
  margin: 8px 0 12px;
  border-radius: 18px;
  padding: 13px 14px;
  background: var(--teal-tint);
  color: var(--teal-dark);
  font-size: var(--text-md);
  line-height: 1.36;
}

.photo-default-toggle {
  width: 100%;
  min-height: 42px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  margin: 0 0 10px;
}

.photo-default-toggle.visible {
  border-color: rgba(13, 148, 136, 0.34);
  background: var(--teal-tint);
  color: var(--teal-dark);
}

.photo-default-toggle.private {
  border-color: rgba(100, 116, 139, 0.35);
  background: var(--background);
  color: var(--text-secondary);
}

.photo-default-eye {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  line-height: 1;
}

.ios-safari-guidance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 12px;
  border: 1px solid rgba(13, 148, 136, 0.22);
  border-radius: 16px;
  padding: 12px;
  background: rgba(230, 247, 245, 0.78);
  color: var(--teal-dark);
  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.04);
}

.ios-safari-guidance b {
  display: block;
  margin-bottom: 2px;
}

.ios-safari-guidance .help {
  color: var(--teal-dark);
  line-height: 1.35;
}

.ios-safari-guidance .btn {
  flex: 0 0 auto;
}

.friends-explore-header {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--border);
  border-top: 3px solid rgba(13, 148, 136, 0.42);
  border-radius: 22px;
  margin: 0 0 14px;
  padding: 18px 18px 16px;
  box-shadow: 0 16px 32px rgba(17, 24, 39, 0.04);
}

.friends-explore-header h2 {
  color: var(--text-primary);
  font-size: 28px;
  margin: 0;
  line-height: 1.05;
}

.friends-explore-header .help {
  color: var(--text-secondary);
  margin-top: 4px;
}

.explore-helper {
  margin: 0 0 12px;
  color: var(--text-secondary);
  font-size: var(--text-md);
  line-height: 1.35;
}

.explore-helper-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
}

.explore-helper-row .explore-helper {
  margin-bottom: 12px;
}

.explore-privacy-button {
  margin-top: -4px;
}

.explore-feed-list {
  display: grid;
  gap: 16px;
}

.explore-photo-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  overflow: hidden;
}

.explore-photo-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 11px;
  align-items: center;
  padding: 14px;
}

.explore-photo-head .avatar {
  width: 44px;
  height: 44px;
  flex-basis: 44px;
}

.explore-photo-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.explore-source-line {
  display: flex;
  gap: 7px;
  align-items: center;
  min-width: 0;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.explore-type-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border-radius: 999px;
  padding: 3px 7px;
  font-size: 12px;
  font-weight: var(--weight-medium);
}

.explore-type-badge.outing {
  background: var(--teal-tint);
  color: var(--teal-dark);
}

.explore-type-badge.trip {
  background: var(--background);
  color: var(--text-secondary);
}

.explore-countdown {
  border-radius: 999px;
  background: var(--teal-tint);
  color: var(--teal-dark);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: var(--weight-semibold);
  white-space: nowrap;
}

.explore-photo-frame {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--background);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
  display: block;
  padding: 0;
  border-left: 0;
  border-right: 0;
  cursor: zoom-in;
  appearance: none;
  color: inherit;
  font: inherit;
  overflow: hidden;
}

.explore-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.explore-photo-meta {
  padding: 12px 14px 14px;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.photo-like-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 750;
}

.photo-like-row.compact {
  margin-left: auto;
}

.photo-like-row.view-only {
  gap: 0;
}

.photo-social-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.photo-like-btn,
.photo-like-count,
.photo-repost-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  padding: 0;
  cursor: pointer;
}

.photo-like-btn,
.photo-like-heart {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: var(--text-secondary);
  font-size: 21px;
  line-height: 1;
}

.photo-like-btn.liked,
.photo-like-heart.liked {
  color: #e11d48;
}

.photo-repost-btn {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-radius: 999px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 750;
  line-height: 1;
}

.photo-repost-icon {
  width: 22px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  font-size: 19px;
  line-height: 1;
}

.photo-repost-label {
  font-size: 12px;
  line-height: 1;
}

.photo-repost-btn.active {
  color: var(--teal-dark);
}

.photo-like-btn:active,
.photo-repost-btn:active {
  transform: scale(0.92);
}

.photo-like-count {
  min-height: 28px;
  color: var(--text-secondary);
}

.photo-like-count.locked {
  cursor: default;
}

.photo-like-count:active {
  color: var(--teal-dark);
}

.photo-like-count.locked:active {
  color: var(--text-secondary);
}


.explore-like-pulse {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(225, 29, 72, 0.92);
  font-size: clamp(62px, 18vw, 128px);
  opacity: 0;
  transform: scale(0.65);
  pointer-events: none;
  text-shadow: 0 12px 36px rgba(15, 23, 42, 0.24);
}

.explore-like-pulse.show-pulse {
  animation: explore-heart-pop 0.62s ease both;
}

@keyframes explore-heart-pop {
  0% { opacity: 0; transform: scale(0.55); }
  26% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.18); }
}

.photo-viewer-backdrop,
.photo-likers-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(15, 23, 42, 0.72);
  display: grid;
  place-items: center;
  padding: max(18px, env(safe-area-inset-top)) 18px max(18px, env(safe-area-inset-bottom));
}

.photo-viewer-dialog {
  position: relative;
  width: min(94vw, 980px);
  height: min(88vh, 860px);
  display: grid;
  place-items: center;
}

.photo-viewer-dialog.story-viewer-dialog {
  width: min(96vw, 520px);
  height: min(92vh, 860px);
  overflow: hidden;
}

.photo-viewer-dialog img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 14px;
  background: #000;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.story-viewer-dialog img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 18px;
}

.story-viewer-top {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 58px;
  z-index: 4;
  display: grid;
  gap: 10px;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.55);
}

.story-progress-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 4px;
}

.story-progress-segment {
  height: 3px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.36);
}

.story-progress-segment span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: rgba(255, 255, 255, 0.95);
}

.story-progress-segment.complete span {
  width: 100%;
}

.story-progress-segment.active span {
  animation: story-progress-fill 7s linear forwards;
}

@keyframes story-progress-fill {
  from { width: 0; }
  to { width: 100%; }
}

.story-viewer-owner {
  display: inline-grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  max-width: 100%;
}

.story-viewer-owner .avatar {
  width: 34px;
  height: 34px;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.68);
}

.story-viewer-owner b,
.story-viewer-owner span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.story-viewer-owner b {
  font-size: 14px;
}

.story-viewer-owner span {
  font-size: 12px;
  opacity: 0.86;
}

.story-tap-zone {
  appearance: none;
  position: absolute;
  top: 58px;
  bottom: 74px;
  z-index: 3;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.story-tap-zone.previous {
  left: 0;
  width: 42%;
}

.story-tap-zone.next {
  right: 0;
  width: 58%;
}

.photo-viewer-close,
.photo-likers-close {
  appearance: none;
  border: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.photo-viewer-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text-primary);
  font-size: 24px;
  z-index: 2;
}

.photo-likers-backdrop {
  align-items: end;
  background: rgba(15, 23, 42, 0.36);
}

.photo-likers-dialog {
  width: min(100%, 520px);
  max-height: min(72vh, 560px);
  background: var(--surface);
  border-radius: 22px 22px 0 0;
  border: 1px solid var(--border);
  box-shadow: 0 -18px 54px rgba(15, 23, 42, 0.2);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
}

.photo-likers-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
}

.photo-likers-head h2 {
  margin: 0;
  font-size: var(--text-xl);
}

.photo-likers-close {
  width: 34px;
  height: 34px;
  background: var(--background);
  color: var(--text-secondary);
  font-size: 22px;
}

.photo-likers-list {
  overflow: auto;
  padding: 8px 14px 18px;
}

.photo-liker-row,
.photo-likers-loading {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 11px;
  padding: 10px 4px;
}

.photo-liker-row .avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  font-size: 14px;
}

.photo-liker-row b,
.photo-liker-row span {
  display: block;
}

.photo-liker-row b {
  color: var(--text-primary);
  font-size: var(--text-md);
}

.photo-liker-row span {
  color: var(--text-secondary);
  font-size: var(--text-sm);
}

.notification-photo-thumb {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(13, 148, 136, 0.18);
  background: var(--background);
}

.linkedin-notifications .notification-main.has-photo-thumb {
  grid-template-columns: 52px 38px minmax(0, 1fr);
  align-items: center;
}

.notification-photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.notification-type-photo-like .notification-icon {
  background: rgba(225, 29, 72, 0.1);
  color: #e11d48;
}

.notification-type-photo-repost .notification-icon {
  background: var(--teal-tint);
  color: var(--teal-dark);
}

.trip-record-layout.no-cover {
  grid-template-columns: minmax(0, 1fr);
}

@media (max-width: 520px) {
  .friends-explore-header {
    margin-left: 0;
    margin-right: 0;
  }
}


/* v145 corrected Explore bottom navigation */
.friends-explore-screen {
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}


/* v151 share with Zabat friends */
.share-friends-dialog,
.share-choice-dialog {
  text-align: left;
}

.share-choice-dialog h2,
.share-friends-dialog h2 {
  text-align: center;
}

.share-choice-dialog > .help,
.share-friends-dialog > .help {
  text-align: center;
}

.share-friends-list {
  display: grid;
  gap: 9px;
  max-height: min(52vh, 420px);
  overflow: auto;
  padding: 2px;
}

.share-friend-option {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
}

.share-friend-option input {
  width: 18px;
  height: 18px;
  accent-color: var(--teal-primary);
}

.share-friend-option.disabled {
  opacity: 0.72;
  background: var(--background);
}

.share-friend-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.share-friend-copy b {
  color: var(--text-primary);
  font-size: var(--text-md);
  font-weight: var(--weight-semibold);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.share-friend-copy small {
  color: var(--text-secondary);
  font-size: var(--text-sm);
}


/* v152 trip detail: Photos is the primary trip section action */
.trip-section-buttons-no-link {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.trip-photos-main-action,
.trip-photos-main-action.active {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  font-weight: var(--weight-semibold);
}


/* v153 active outing: Photos promoted to primary action */
.outing-photos-main-action,
.outing-photos-main-action.active {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
  font-weight: var(--weight-semibold);
}

.simple-outing-actions {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}


/* v155 unified Plans page */
.unified-plan-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.unified-plan-actions .btn {
  min-height: 40px;
}

.unified-plan-stats {
  margin-top: 8px;
}

.unified-type-filter {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 12px;
  margin-bottom: 0;
}

.unified-plans-list {
  display: grid;
  gap: 12px;
}

.unified-plan-wrapper {
  position: relative;
  display: grid;
  gap: 6px;
}

.unified-plan-type-badge {
  justify-self: start;
  background: var(--teal-tint);
  color: var(--teal-dark);
  border: 1px solid rgba(13, 148, 136, 0.24);
}

.unified-plan-wrapper.trip .unified-plan-type-badge {
  background: var(--background);
  color: var(--text-secondary);
  border-color: var(--border);
}

.unified-plans-list-section .empty {
  margin-top: 0;
}

@media (max-width: 380px) {
  .unified-plan-actions {
    grid-template-columns: 1fr;
  }
}


/* v156 Friends social hub + Explore privacy */
.friends-card-secondary-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.friends-create-group-button {
  justify-content: center;
}

.friends-settings-icon-button {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--background);
  color: var(--text-secondary);
  display: inline-grid;
  place-items: center;
  font-size: 18px;
  line-height: 1;
}

.friends-settings-icon-button:hover,
.friends-settings-icon-button:focus-visible {
  color: var(--text-primary);
  border-color: var(--text-secondary);
}

.friends-groups-toggle {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  text-align: left;
}

.friends-groups-toggle-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.friends-groups-chevron {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  background: var(--surface);
  font-size: 16px;
  line-height: 1;
}

.friends-list-toggle {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  text-align: left;
}

.friends-groups-section.collapsed {
  padding-bottom: 14px;
}

.friends-list-section.collapsed {
  padding-bottom: 14px;
}

.friends-list-section .friends-list-tools {
  grid-template-columns: minmax(0, 1fr);
  margin-top: 12px;
}

.friends-list-head {
  gap: 12px;
}

.friends-list-tools {
  display: grid;
  grid-template-columns: minmax(150px, 220px) auto;
  align-items: center;
  gap: 8px;
}

.friends-search-input {
  min-height: 36px;
  height: 36px;
  font-size: var(--text-sm);
}

@media (max-width: 560px) {
  .friends-list-head,
  .friends-list-tools {
    grid-template-columns: 1fr;
  }

  .friends-list-tools {
    width: 100%;
  }
}

.friends-create-group-panel,
.friends-settings-panel,
.friends-groups-section {
  animation: none;
}

.privacy-friend-list {
  margin-top: 12px;
}

.privacy-friend-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.privacy-toggle-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.privacy-toggle {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  border-radius: 999px;
  min-height: 34px;
  padding: 0 12px;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
}

.privacy-toggle.active {
  background: var(--background);
  color: var(--text-primary);
  border-color: var(--text-secondary);
}

@media (max-width: 560px) {
  .privacy-friend-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .privacy-toggle-group {
    justify-content: stretch;
  }

  .privacy-toggle {
    width: 100%;
  }
}


/* v158 Plans cleanup: no All / Outings / Trips filter row */
.unified-type-filter {
  display: none !important;
}


/* v162 Explore visual consistency: keep Explore header in same soft-card family as Plans/Friends */


/* v164 photo album experience: one full-width photo per row */
.trip-photo-grid,
.outing-photo-grid {
  grid-template-columns: 1fr;
  gap: 16px;
}

.trip-photo-card,
.outing-photo-card {
  border-radius: 22px;
  overflow: hidden;
}

.trip-photo-frame,
.memory-photo-frame {
  border-radius: 22px 22px 0 0;
}

.trip-photo-card img,
.trip-photo-frame img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}

.trip-photo-meta {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  padding: 12px 14px;
  font-size: var(--text-sm);
}

@media (max-width: 380px) {
  .trip-photo-card img,
  .trip-photo-frame img {
    aspect-ratio: 1 / 1;
  }
}


/* v166 mobile browser viewport guard
   Some Android browsers open PWAs with a desktop-width layout viewport.
   When that happens on a phone, scale the app shell back to normal mobile size. */
.mobile-viewport-guard body {
  overflow-x: hidden;
}

.mobile-viewport-guard .app-shell {
  width: min(100%, 560px);
  transform-origin: top center;
  zoom: var(--mobile-viewport-zoom, 1.35);
}

@supports not (zoom: 1) {
  .mobile-viewport-guard .app-shell {
    transform: scale(var(--mobile-viewport-zoom, 1.35));
    transform-origin: top center;
  }
}


/* v169 action buttons: equal default state, teal only when active/pressed */
.outing-action-grid,
.trip-action-grid,
.simple-outing-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  align-items: stretch;
}

.outing-action-grid .btn,
.trip-action-grid .btn,
.app-action-btn {
  min-height: 52px;
  border-radius: 16px;
  line-height: 1.15;
  white-space: normal;
  text-align: center;
}

.app-action-btn.active,
.outing-action-grid .btn.active,
.trip-action-grid .btn.active,
.section-buttons .btn.active,
.app-action-btn:active,
.outing-action-grid .btn:active,
.trip-action-grid .btn:active {
  background: var(--teal-primary);
  border-color: var(--teal-primary);
  color: var(--surface);
}

.outing-photos-main-action,
.outing-photos-main-action.active,
.trip-photos-main-action,
.trip-photos-main-action.active,
.view-memories-main-btn,
.view-memories-main-btn.active {
  background: var(--surface);
  color: var(--teal-primary);
  border-color: var(--border);
  font-weight: var(--weight-semibold);
}

.end-outing-soft,
.end-trip-soft {
  border-color: rgba(20, 184, 166, 0.28);
  color: var(--teal-primary);
  background: rgba(255, 255, 255, 0.82);
}

.end-outing-soft:active,
.end-trip-soft:active {
  background: var(--teal-primary);
  color: var(--surface);
  border-color: var(--teal-primary);
}

@media (max-width: 520px) {
  .outing-action-grid,
  .trip-action-grid,
  .simple-outing-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 380px) {
  .outing-action-grid,
  .trip-action-grid,
  .simple-outing-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Bottom navigation — single source of truth. Edit in place; do not add new versioned blocks below. */
.bottom-two-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  width: 100vw;
  max-width: none;
  min-width: 0;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  gap: 0;
  padding: 0 0 env(safe-area-inset-bottom);
  border: 1px solid var(--border);
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  box-shadow: 0 -10px 26px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.bottom-two-nav-item {
  flex: 1 1 0;
  min-width: 0;
  min-height: 64px;
  padding: 8px 6px 7px;
  border: 0;
  border-left: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
  color: var(--text-secondary);
  display: grid;
  grid-template-rows: auto auto;
  align-content: center;
  justify-items: center;
  gap: 3px;
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  cursor: pointer;
  text-align: center;
}

.bottom-two-nav-item:first-child {
  border-left: 0;
}

.bottom-two-nav-item.active {
  background: var(--teal-tint);
  color: var(--teal-dark);
  font-weight: var(--weight-semibold);
}

.bottom-two-nav-icon {
  position: relative;
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  min-height: 24px;
  font-size: 23px;
  line-height: 1;
  filter: grayscale(1) saturate(0);
  opacity: 0.72;
}

.bottom-two-nav-item.active .bottom-two-nav-icon {
  filter: none;
  opacity: 1;
}

.bottom-two-nav-item span:last-child {
  display: block;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: var(--text-md);
  font-weight: inherit;
}

.bottom-nav-badge {
  position: absolute;
  top: -7px;
  right: -11px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: var(--teal-primary);
  color: var(--surface);
  border: 2px solid var(--surface);
  font-size: 9px;
  font-weight: var(--weight-semibold);
  line-height: 1;
}

body {
  padding-bottom: calc(68px + env(safe-area-inset-bottom));
}

.app-shell {
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}

@media (max-width: 520px) {
  .bottom-two-nav-item {
    min-height: 62px;
    padding-top: 7px;
    padding-bottom: 6px;
  }

  .bottom-two-nav-icon {
    font-size: 22px;
  }

  .bottom-two-nav-item span:last-child {
    font-size: var(--text-sm);
  }
}



/* v171 lightweight background refresh indicator */
.lightweight-refresh-message {
  position: sticky;
  top: 8px;
  z-index: 10;
  margin: 6px 0 8px;
  padding: 8px 12px;
  border-radius: 999px;
  justify-self: center;
  width: fit-content;
  max-width: calc(100% - 24px);
  font-size: var(--text-sm);
}


/* v176 friend picker search fix: hidden rows must override row display rules */
.friend-select-row.hidden {
  display: none !important;
}

/* v188 Explore stories */
.friends-explore-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.explore-stories-band {
  margin: 0 0 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 12px;
  overflow: hidden;
}

.explore-stories-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  overflow-x: auto;
  min-height: 108px;
  padding: 2px 4px 14px;
  scrollbar-width: thin;
}

.story-add-button,
.story-rail-item,
.story-load-more {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  cursor: pointer;
  flex: 0 0 auto;
}

.story-add-button,
.story-rail-item {
  width: 84px;
  display: grid;
  grid-template-rows: 64px minmax(30px, auto);
  align-content: start;
  justify-items: center;
  gap: 7px;
  text-align: center;
}

.story-add-circle,
.story-ring {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  box-sizing: border-box;
  display: grid;
  place-items: center;
  flex: 0 0 64px;
}

.story-add-circle {
  background: var(--teal-primary);
  color: var(--surface);
  font-size: 32px;
  line-height: 1;
  font-weight: var(--weight-bold);
}

.story-ring {
  padding: 3px;
  background: conic-gradient(from 45deg, #0f9f90, #e11d48, #f59e0b, #0f9f90);
}

.story-ring > img,
.story-ring .story-avatar {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 999px;
  background: var(--background);
  border: 2px solid var(--surface);
  box-sizing: border-box;
}

.story-ring > img {
  object-fit: cover;
}

.story-ring .story-avatar {
  color: var(--teal-primary);
}

.story-name,
.story-add-button span:last-child {
  width: 84px;
  max-width: 84px;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.18;
  font-weight: var(--weight-semibold);
  white-space: normal;
  overflow: hidden;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.story-load-more {
  max-width: 74px;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: var(--weight-semibold);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.story-load-more {
  border: 1px solid var(--border);
  border-radius: 999px;
  min-height: 36px;
  padding: 0 12px;
  max-width: none;
}

.explore-type-badge.story {
  background: #fdf2f8;
  color: #be185d;
}

.photo-viewer-social {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--text-primary);
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.22);
}

.story-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 122;
  display: grid;
  place-items: end center;
  padding: max(18px, env(safe-area-inset-top)) 18px max(18px, env(safe-area-inset-bottom));
  background: rgba(15, 23, 42, 0.36);
}

.story-dialog {
  width: min(100%, 520px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px 22px 0 0;
  box-shadow: 0 -18px 54px rgba(15, 23, 42, 0.2);
  padding: 18px;
  display: grid;
  gap: 12px;
}

.story-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.story-dialog-head h2 {
  margin: 0;
  font-size: 22px;
}

.field-label span {
  color: var(--text-secondary);
  font-weight: var(--weight-regular);
}

.story-dialog-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.bad-text {
  color: #be123c;
}

@media (max-width: 560px) {
  .ios-safari-guidance {
    align-items: stretch;
    flex-direction: column;
  }

  .ios-safari-guidance .btn {
    width: 100%;
  }

  .friends-explore-header {
    align-items: stretch;
    flex-direction: column;
  }

  .friends-explore-header .btn {
    width: 100%;
  }

  .photo-viewer-social {
    width: calc(100% - 28px);
    justify-content: space-between;
  }
}

/* v189 story view state */
.story-rail-item.viewed .story-ring {
  background: #CBD5E1;
  filter: saturate(0.45);
  opacity: 0.9;
}

.story-rail-item.viewed .story-name {
  color: var(--text-secondary);
}

.story-view-count-btn {
  appearance: none;
  border: 0;
  border-radius: 999px;
  min-height: 28px;
  padding: 0 10px;
  background: var(--teal-tint);
  color: var(--teal-dark);
  font: inherit;
  font-size: 12px;
  font-weight: var(--weight-semibold);
  cursor: pointer;
  white-space: nowrap;
}

.story-view-count-btn:active {
  transform: scale(0.96);
}

.story-delete-btn {
  appearance: none;
  border: 1px solid rgba(225, 29, 72, 0.26);
  border-radius: 999px;
  background: rgba(255, 241, 242, 0.96);
  color: #be123c;
  min-height: 34px;
  padding: 0 12px;
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  cursor: pointer;
  white-space: nowrap;
}

.story-delete-btn:active {
  transform: scale(0.96);
}
