/* ─── Profile View ──────────────────────────────────────────────────────── */

/* ─── Profile ─────────────────────────────────────────────────────────────── */

/* Wrapper elements — transparent on mobile */
.profile-view,
.profile-sidebar,
.profile-main {
  display: contents;
}

.profile-shell {
  max-width: 560px;
  margin: 0 auto;
  width: 100%;
}

.profile-section {
  padding: var(--sp-4) var(--sp-4) 0;
}

.profile-section:last-child {
  padding-bottom: var(--sp-5);
}

/* Hero header with warm glow */
.profile-hero {
  position: relative;
  padding: var(--sp-6) var(--sp-4) var(--sp-5);
  background:
    radial-gradient(ellipse 120% 80% at 50% 0%, var(--clay-subtle) 0%, transparent 70%);
  display: flex;
  align-items: center;
  gap: var(--sp-4);
}

.profile-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--clay);
  color: var(--ink-on-clay);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.625rem;
  font-weight: 600;
  flex-shrink: 0;
  box-shadow:
    var(--shadow-accent),
    inset 0 1px 0 rgba(255,255,255,.15);
}

.profile-name {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.profile-email {
  font-size: 0.8125rem;
  color: var(--ink-muted);
  margin-top: 3px;
}

/* Stats bar */
.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--s2);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin: 0 var(--sp-4);
  box-shadow: var(--shadow-card);
}

.profile-stat {
  background: var(--s1);
  padding: var(--sp-3) var(--sp-2);
  text-align: center;
}

.profile-stat__num {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1;
}

.profile-stat__label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--ink-muted);
  margin-top: 4px;
  letter-spacing: 0.02em;
}

/* Household grid */
.household-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--sp-3);
  margin-top: var(--sp-3);
}

.household-member {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: var(--sp-3) var(--sp-2);
  border-radius: var(--r-lg);
  background: var(--s1);
  border: 1px solid var(--border-subtle);
  text-align: center;
}

.household-member__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8125rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.2), 0 1px 4px rgba(0,0,0,.1);
}

.household-member__name {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.household-member__portions {
  font-size: 0.6875rem;
  color: var(--ink-muted);
  line-height: 1;
}

.household-manage {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: var(--sp-3);
}

.settings-list {
  list-style: none;
  background: var(--s1);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--card-border);
  margin-top: var(--sp-3);
}

.settings-item {
  display: flex;
  align-items: center;
  padding: 0 var(--sp-4);
  gap: var(--sp-3);
  border-bottom: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: background var(--t-fast);
  min-height: 52px;
}

.settings-item:last-child { border-bottom: none; }
.settings-item:hover  { background: var(--s2); }
.settings-item:active { background: var(--s2); }

.settings-item__icon {
  width: 32px;
  height: 32px;
  border-radius: var(--r-sm);
  background: var(--s2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--ink-secondary);
}

.settings-item__icon svg {
  width: 16px;
  height: 16px;
}

.settings-item__body {
  flex: 1;
  min-width: 0;
  padding: var(--sp-3) 0;
}

.settings-item__label {
  font-size: 0.9375rem;
  color: var(--ink);
}

.settings-item__hint {
  font-size: 0.75rem;
  color: var(--ink-muted);
}

.settings-item__trail {
  color: var(--ink-muted);
  font-size: 0.9375rem;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: var(--sp-1);
}

.settings-item__trail svg {
  opacity: 0.5;
}

.settings-item__value {
  font-size: 0.9375rem;
  color: var(--ink-muted);
}

/* Quiet logout */
.profile-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-5) var(--sp-4) var(--sp-6);
}

.btn--logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  width: 100%;
  max-width: 320px;
  margin: var(--sp-4) auto var(--sp-2);
  padding: var(--sp-3) var(--sp-4);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-md);
  background: transparent;
  color: var(--ink-muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  font-family: var(--font-body);
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.btn--logout:hover {
  background: var(--danger-bg);
  color: var(--error);
  border-color: rgba(239, 68, 68, 0.2);
}

.btn--logout:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

.settings-hint {
  font-size: 0.875rem;
  color: var(--ink-muted);
  font-style: italic;
}

/* ─── Google Auth in Profile ──────────────────────────────────────────────── */
.profile-avatar--img {
  object-fit: cover;
  border: 2px solid var(--card-border);
}

.profile-auth-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  padding: 3px 10px 3px 6px;
  border-radius: var(--r-pill);
  background: rgba(66, 133, 244, 0.08);
  border: 1px solid rgba(66, 133, 244, 0.12);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--ink-secondary);
  line-height: 1;
  letter-spacing: 0.01em;
}

.profile-auth-badge svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

.settings-item--static {
  cursor: default;
}

.settings-item--static:hover {
  background: transparent;
}

.settings-item__badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.settings-item__badge--success {
  background: var(--success-bg, rgba(46, 160, 67, 0.1));
  color: var(--success);
}

/* Google-linked settings row — subtle blue tint */
.settings-item--static .settings-item__icon {
  background: rgba(66, 133, 244, 0.08);
}

/* Google link action row — inviting hover */
.settings-item[data-action="link-google"] .settings-item__icon {
  background: rgba(66, 133, 244, 0.08);
}

.settings-item[data-action="link-google"]:hover .settings-item__icon {
  background: rgba(66, 133, 244, 0.14);
}

/* ─── Theme Options ───────────────────────────────────────────────────────── */
.theme-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-3);
  padding: var(--sp-2) 0;
}

.theme-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-3);
  border-radius: var(--r-lg);
  border: 2px solid var(--s3);
  background: var(--s1);
  cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast), transform var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.theme-option:hover {
  background: var(--s2);
  border-color: var(--ink-muted);
}

.theme-option:active {
  transform: scale(0.96);
}

.theme-option--active {
  border-color: var(--clay);
  background: var(--clay-subtle);
}

.theme-option--active:hover {
  background: var(--clay-subtle);
  border-color: var(--clay);
}

.theme-option__icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--s2);
  color: var(--ink-secondary);
  transition: background var(--t-fast), color var(--t-fast);
}

.theme-option--active .theme-option__icon {
  background: var(--clay);
  color: var(--ink-on-clay);
}

.theme-option__label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-secondary);
  transition: color var(--t-fast);
}

.theme-option--active .theme-option__label {
  color: var(--ink);
}

.theme-option:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

/* ─── Person Chips ────────────────────────────────────────────────────────── */
.person-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: var(--sp-2);
}

.person-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  padding: var(--sp-1) 10px var(--sp-1) var(--sp-1);
  border-radius: 999px;
  border: 2px solid var(--chip-color, var(--clay));
  background: transparent;
  color: var(--chip-color, var(--clay));
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  touch-action: manipulation;
  transition: background var(--t-fast), color var(--t-fast), opacity var(--t-fast);
  min-height: 40px;
  -webkit-tap-highlight-color: transparent;
}

.person-chip__init {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--chip-color, var(--clay)) 18%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6875rem;
  font-weight: 700;
  flex-shrink: 0;
  transition: background var(--t-fast);
}

.person-chip--on .person-chip__init {
  background: var(--chip-color, var(--clay));
  color: #fff;
}

.person-chip--on {
  background: color-mix(in srgb, var(--chip-color, var(--clay)) 12%, transparent);
}

.person-chip--off {
  opacity: 0.45;
  border-style: dashed;
}

.person-chip:focus-visible {
  outline: 2px solid var(--chip-color, var(--clay));
  outline-offset: 2px;
}

/* Static variant (non-interactive, in profile / plan grid) */
.person-chip--static {
  cursor: default;
  pointer-events: none;
}

/* ─── Color Swatches ──────────────────────────────────────────────────────── */
.color-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-top: var(--sp-2);
}

.color-swatch {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 3px solid transparent;
  cursor: pointer;
  transition: transform var(--t-fast), border-color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.color-swatch:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.color-swatch--on {
  border-color: var(--ink);
  transform: scale(1.15);
}

/* ─── Portions-Badge im Chip ──────────────────────────────────────────────── */
.person-chip__portions {
  font-size: 0.6875rem;
  opacity: 0.75;
  margin-left: 1px;
}

/* ─── Portions Steps ──────────────────────────────────────────────────────── */
.portions-steps {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-top: var(--sp-2);
}

.portions-step {
  min-width: 48px;
  height: 40px;
  padding: 0 var(--sp-3);
  border-radius: var(--r-md);
  border: 2px solid var(--s3);
  background: transparent;
  color: var(--ink-muted);
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast), color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.portions-step:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

.portions-step--on {
  border-color: var(--clay);
  background: var(--clay-subtle);
  color: var(--clay);
}

/* ─── Members Modal: Place Cards Design ───────────────────────────────────── */
.members-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-5);
}

.members-title {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.members-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--ink-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--t-fast), color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.members-close:hover {
  background: var(--s2);
  color: var(--ink);
}
.members-close:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

/* Place Cards Container */
.place-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
}

/* Individual Place Card */
.place-card {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-3) var(--sp-4);
  background: var(--s1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: all var(--t-base);
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
.place-card:hover {
  border-color: var(--border);
  box-shadow: var(--shadow-card);
  transform: translateX(4px);
}
.place-card:active {
  transform: scale(0.99);
}
.place-card:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

/* Avatar */
.place-card__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.25);
}

/* Info Section */
.place-card__info {
  flex: 1;
  min-width: 0;
}

.place-card__name {
  font-size: var(--fs-base);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Portions as Plates */
.place-card__portions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.place-card__plate {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--clay-subtle);
  border: 1.5px solid var(--clay);
  position: relative;
  flex-shrink: 0;
}
.place-card__plate::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--clay);
}

.place-card__portions-label {
  font-size: var(--fs-xs);
  color: var(--ink-muted);
  margin-left: 4px;
}

/* Actions */
.place-card__actions {
  display: flex;
  gap: 4px;
  opacity: 0.4;
  transition: opacity var(--t-fast);
}
.place-card:hover .place-card__actions {
  opacity: 1;
}

/* Touch: Always show actions */
@media (hover: none) {
  .place-card__actions {
    opacity: 0.7;
  }
}

.place-card__action {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--s2);
  color: var(--ink-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--t-fast), color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.place-card__action:hover {
  background: var(--s3);
  color: var(--ink);
}
.place-card__action:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}
.place-card__action--del:hover {
  background: var(--danger-bg);
  color: var(--error);
}

/* Add Member Button */
.members-add {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  width: 100%;
  padding: var(--sp-3) var(--sp-4);
  border: 2px dashed var(--border);
  border-radius: var(--r-lg);
  background: transparent;
  color: var(--ink-secondary);
  font-size: var(--fs-sm);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.members-add:hover {
  border-color: var(--clay);
  color: var(--clay);
  background: rgba(224, 120, 86, 0.04);
}
.members-add:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}
.members-add svg {
  width: 18px;
  height: 18px;
}

/* Empty State */
.members-empty {
  text-align: center;
  padding: var(--sp-5) var(--sp-4);
  color: var(--ink-muted);
}
.members-empty__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto var(--sp-3);
  border-radius: 50%;
  background: var(--s2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-muted);
}
.members-empty__text {
  font-size: var(--fs-sm);
  line-height: 1.5;
}

/* Responsive */
@media (max-width: 400px) {
  .place-card {
    padding: var(--sp-3);
    gap: var(--sp-3);
  }
  .place-card__avatar {
    width: 40px;
    height: 40px;
    font-size: 0.875rem;
  }
  .place-card__name {
    font-size: var(--fs-sm);
  }
}

/* ─── Legacy: Keep for backwards compatibility ────────────────────────────── */
.members-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: var(--sp-3);
}

.member-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-3);
  border-radius: var(--r-lg);
  background: var(--s1);
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow-card);
  text-align: center;
  cursor: pointer;
  transition: background var(--t-fast), box-shadow var(--t-base), transform var(--t-fast);
  position: relative;
  -webkit-tap-highlight-color: transparent;
}

.member-tile:hover {
  background: var(--s2);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.member-tile:active {
  transform: scale(0.98);
  box-shadow: var(--shadow-card);
}

.member-tile__avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.2), 0 2px 6px rgba(0,0,0,.12);
}

.member-tile__name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.member-tile__portions {
  font-size: 0.75rem;
  color: var(--ink-muted);
}

.member-tile__actions {
  position: absolute;
  top: 6px;
  right: 6px;
  display: flex;
  gap: 2px;
  opacity: 0;
  transition: opacity var(--t-fast);
}

.member-tile:hover .member-tile__actions {
  opacity: 1;
}

/* Touch devices: always show actions */
@media (hover: none) {
  .member-tile__actions { opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   CARD-BASED PROFILE LAYOUT
   ═══════════════════════════════════════════════════════════════════════════ */

/* Container */
.profile-shell {
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}

/* Profile Card */
.profile-card {
  background: var(--s1);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-card);
  padding: var(--sp-5);
}

.profile-card--flush {
  padding: 0;
  overflow: hidden;
}

/* Profile Header: Avatar + Name + Stats */
.profile-header {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
}

.profile-header__avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--card-border);
}

.profile-header__avatar--initials {
  background: var(--clay);
  color: var(--ink-on-clay);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  border: none;
  box-shadow: var(--shadow-accent);
}

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

.profile-header__row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: 4px;
  flex-wrap: wrap;
}

.profile-header__name {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--ink);
}

.profile-header__badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.6875rem;
  color: var(--ink-muted);
  background: var(--s2);
  padding: 3px 8px;
  border-radius: 999px;
}

.profile-header__badge svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

.profile-header__email {
  font-size: 0.8125rem;
  color: var(--ink-muted);
}

/* Mini Stats */
.profile-header__stats {
  display: flex;
  gap: 1px;
  background: var(--border-subtle);
  border-radius: var(--r-md);
  overflow: hidden;
  flex-shrink: 0;
}

.mini-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--sp-3) var(--sp-4);
  background: var(--s2);
}

.mini-stat__num {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1;
}

.mini-stat__label {
  font-size: 0.6875rem;
  color: var(--ink-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-top: 4px;
}

/* Card Header */
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-4) var(--sp-5);
  border-bottom: 1px solid var(--border-subtle);
}

.card-header__title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}

.card-header__action {
  font-size: 0.8125rem;
  color: var(--clay);
  font-weight: 500;
  cursor: pointer;
  padding: 4px 10px;
  border-radius: var(--r-md);
  background: transparent;
  border: none;
  transition: background var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.card-header__action:hover {
  background: var(--clay-subtle);
}

.card-header__action:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

/* Household Content */
.household-content {
  padding: var(--sp-5);
}

.household-row {
  display: flex;
  gap: var(--sp-4);
  flex-wrap: wrap;
}

/* Household Member — Card Style */
.household-member {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--sp-4);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: background var(--t-fast), transform var(--t-fast);
  min-width: 90px;
  border: none;
  background: transparent;
}

.household-member:hover {
  background: var(--s2);
  transform: translateY(-2px);
}

.household-member__avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  color: white;
  margin-bottom: var(--sp-2);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.household-member__name {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 2px;
}

.household-member__portions {
  font-size: 0.75rem;
  color: var(--ink-muted);
}

/* Add Household Member */
.household-add {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--sp-4);
  border-radius: var(--r-lg);
  cursor: pointer;
  min-width: 90px;
  transition: background var(--t-fast);
  background: transparent;
  border: none;
}

.household-add:hover {
  background: var(--clay-subtle);
}

.household-add:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

.household-add__circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px dashed var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-muted);
  margin-bottom: var(--sp-2);
  transition: border-color var(--t-fast), color var(--t-fast);
}

.household-add:hover .household-add__circle {
  border-color: var(--clay);
  color: var(--clay);
}

.household-add__label {
  font-size: 0.8125rem;
  color: var(--ink-muted);
  font-weight: 500;
}

.household-add:hover .household-add__label {
  color: var(--clay);
}

/* Settings in Card */
.profile-card--flush .settings-list {
  margin: 0;
  border: none;
  border-radius: 0;
  box-shadow: none;
}

/* Logout Card */
.logout-card {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: var(--sp-4);
  text-align: center;
  color: var(--ink-secondary);
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--t-fast);
  width: 100%;
  font-family: var(--font-body);
  -webkit-tap-highlight-color: transparent;
}

.logout-card:hover {
  border-color: var(--error);
  color: var(--error);
  background: var(--danger-bg);
}

.logout-card:focus-visible {
  outline: 2px solid var(--error);
  outline-offset: 2px;
}

/* Responsive: Stack on mobile */
@media (max-width: 600px) {
  .profile-header {
    flex-direction: column;
    text-align: center;
  }

  .profile-header__row {
    flex-direction: column;
    gap: var(--sp-2);
  }

  .profile-header__stats {
    width: 100%;
  }

  .mini-stat {
    flex: 1;
  }

  .household-row {
    justify-content: center;
  }
}

.member-tile__action {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--s2);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-muted);
  transition: background var(--t-fast), color var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}

.member-tile__action:hover {
  background: var(--s3);
  color: var(--ink);
}

.member-tile__action:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

.member-tile__action--del:hover {
  background: #f0dada;
  color: var(--error);
}

/* ─── Settings Members Block ──────────────────────────────────────────────── */
.settings-members {
  background: var(--s1);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

.settings-members__chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

/* ─── Desktop Profile Layout ──────────────────────────────────────────────── */
@media (min-width: 600px) {
  .profile-shell {
    max-width: 600px;
    padding: var(--sp-4) 0;
  }

  .profile-hero {
    border-radius: var(--r-xl);
    margin: 0 var(--sp-4);
    padding: var(--sp-6) var(--sp-5) var(--sp-5);
    background:
      radial-gradient(ellipse 100% 80% at 30% 0%, var(--clay-subtle) 0%, transparent 60%),
      var(--s1);
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow-card);
  }

  .profile-avatar {
    width: 80px;
    height: 80px;
    font-size: 1.75rem;
  }

  .profile-name {
    font-size: 1.5rem;
  }

  .profile-stats {
    margin-top: var(--sp-4);
  }
}

@media (min-width: 900px) {
  .profile-shell {
    max-width: 640px;
    padding-top: var(--sp-5);
  }

  .profile-hero {
    padding: var(--sp-7) var(--sp-6) var(--sp-6);
  }

  .profile-avatar {
    width: 88px;
    height: 88px;
    font-size: 2rem;
  }

  .profile-name {
    font-size: 1.625rem;
  }

  .btn--logout {
    max-width: 240px;
  }
}

