/* ===== ShopKitty Vote App - Mobile First CSS ===== */

:root {
  --pink: #ff6b9d;
  --pink-light: #ff8fb8;
  --pink-dark: #e8527a;
  --purple: #c084fc;
  --purple-dark: #9333ea;
  --green: #22c55e;
  --green-light: #bbf7d0;
  --red: #ef4444;
  --red-light: #fecaca;
  --yellow: #fbbf24;
  --bg: #fdf2f8;
  --bg-card: #ffffff;
  --text: #1e1e2e;
  --text-muted: #6b7280;
  --border: #f3e8ff;
  --shadow: 0 4px 24px rgba(236, 72, 153, 0.12);
  --radius: 16px;
  --radius-sm: 10px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}

/* ===== Layout ===== */

.app {
  max-width: 430px;
  margin: 0 auto;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 0 20px 40px;
}

.header {
  text-align: center;
  padding: 24px 0 8px;
}

.logo {
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.logo .cat {
  font-size: 32px;
  -webkit-text-fill-color: initial;
}

.subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ===== Cards ===== */

.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  margin-top: 20px;
}

.card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ===== Forms ===== */

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: inherit;
  transition: border-color 0.2s;
  background: #faf5ff;
  color: var(--text);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--pink);
  background: white;
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

/* Single-line comment fields in multi-item vote forms */
#pickComment,
.rate-item-comment {
  min-height: unset;
  height: auto;
  resize: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #c4b5d0;
}

/* ===== Input with Action Button ===== */

.input-with-action {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.input-with-action input {
  flex: 1;
  min-width: 0;
  width: auto;
}

.btn-preview {
  flex-shrink: 0;
  width: 48px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: #faf5ff;
  font-size: 20px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-preview:hover {
  border-color: var(--purple);
  background: #f3e8ff;
}

.btn-preview:active {
  transform: scale(0.95);
}

/* ===== Buttons ===== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  text-decoration: none;
}

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

.btn-primary {
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: white;
  box-shadow: 0 4px 16px rgba(236, 72, 153, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 6px 24px rgba(236, 72, 153, 0.4);
}

.btn-success {
  background: linear-gradient(135deg, var(--green), #16a34a);
  color: white;
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.3);
}

.btn-success:hover {
  box-shadow: 0 6px 24px rgba(34, 197, 94, 0.4);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--pink-light);
  background: #fdf2f8;
}

.btn-sm {
  padding: 10px 16px;
  font-size: 14px;
}

/* ===== Vote Buttons ===== */

.vote-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 20px 0;
}

.vote-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px 16px;
  border: 3px solid var(--border);
  border-radius: var(--radius);
  background: white;
  cursor: pointer;
  transition: all 0.25s;
  font-family: inherit;
}

.vote-btn .emoji {
  font-size: 48px;
  transition: transform 0.25s;
}

.vote-btn .label {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
}

.vote-btn:active {
  transform: scale(0.95);
}

.vote-btn.selected-up {
  border-color: var(--green);
  background: var(--green-light);
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.2);
}

.vote-btn.selected-up .emoji {
  transform: scale(1.2);
}

.vote-btn.selected-up .label {
  color: var(--green);
}

.vote-btn.selected-down {
  border-color: var(--red);
  background: var(--red-light);
  box-shadow: 0 4px 16px rgba(239, 68, 68, 0.2);
}

.vote-btn.selected-down .emoji {
  transform: scale(1.2);
}

.vote-btn.selected-down .label {
  color: var(--red);
}

/* ===== Comment Chips ===== */

.comment-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.comment-chips.hidden {
  display: none;
}

.comment-chip {
  background: var(--border-color, #f3e8ff);
  color: #9333ea;
  border: 1.5px solid #e9d5ff;
  border-radius: 16px;
  padding: 5px 14px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.comment-chip.selected {
  background: #9333ea;
  color: #fff;
  border-color: #9333ea;
}

/* ===== Results ===== */

.results-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
}

.bar-container {
  flex: 1;
  height: 32px;
  border-radius: 16px;
  background: #f1f5f9;
  overflow: hidden;
  display: flex;
}

.bar-up {
  height: 100%;
  background: linear-gradient(90deg, var(--green), #4ade80);
  transition: width 0.5s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.bar-down {
  height: 100%;
  background: linear-gradient(90deg, #f87171, var(--red));
  transition: width 0.5s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.bar-label {
  font-size: 12px;
  font-weight: 700;
  color: white;
  white-space: nowrap;
}

.vote-count {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin: 12px 0;
}

.vote-count-item {
  text-align: center;
}

.vote-count-item .count {
  font-size: 36px;
  font-weight: 800;
}

.vote-count-item .count.up {
  color: var(--green);
}

.vote-count-item .count.down {
  color: var(--red);
}

.vote-count-item .count-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ===== Comments ===== */

.comments-section {
  margin-top: 20px;
}

.comments-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.comment-card {
  background: #faf5ff;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 10px;
}

.comment-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.comment-vote-icon {
  font-size: 16px;
}

.comment-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.comment-text {
  font-size: 15px;
  line-height: 1.4;
  color: var(--text);
}

.no-comments {
  text-align: center;
  padding: 20px;
  color: var(--text-muted);
  font-size: 14px;
}

/* ===== Product Preview ===== */

.product-preview {
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid var(--border);
  margin-bottom: 16px;
}

.product-preview .product-url-bar {
  background: #faf5ff;
  padding: 10px 14px;
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: hidden;
}

.product-preview .product-url-bar .url-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-preview .product-frame {
  width: 100%;
  height: 360px;
  border: none;
  background: white;
}

.product-context {
  background: linear-gradient(135deg, #fdf2f8, #f3e8ff);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 16px;
  font-size: 15px;
  line-height: 1.5;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.product-context .context-icon {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ===== Feedback focus tags (vote + results context cards) ===== */
.feedback-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.feedback-tags-label {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  align-self: center;
}

.feedback-tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 11px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 600;
  background: linear-gradient(135deg, #fdf4ff, #f0f5ff);
  color: var(--purple);
  border: 1.5px solid #e9d5ff;
  white-space: nowrap;
}

/* Feedback categories with per-category context notes (vertical list) */
.feedback-notes {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}
.feedback-note-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}
.feedback-note {
  font-size: 13px;
  color: var(--text);
  line-height: 1.35;
  padding-left: 4px;
}

/* ===== Structured Feedback rating cards ===== */
.sf-product-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 13px;
  color: var(--purple);
  text-decoration: none;
  font-weight: 500;
}
.sf-product-link:hover { text-decoration: underline; }

.sf-category-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 10px;
  transition: border-color 0.15s;
}
.sf-category-card.sf-category-rated { border-color: var(--purple); }

.sf-category-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 10px;
}

.sf-category-note {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
  margin: -4px 0 10px;
  padding: 8px 10px;
  background: var(--surface-alt, #f7f7fb);
  border-left: 3px solid var(--purple);
  border-radius: 6px;
}

.sf-rating-buttons {
  display: flex;
  gap: 8px;
}

.sf-rating-btn {
  flex: 1;
  padding: 8px 4px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.sf-rating-btn:hover { border-color: var(--purple); }

.sf-rating-btn[data-val="no"].selected    { background: #fee2e2; border-color: #f87171; color: #b91c1c; }
.sf-rating-btn[data-val="maybe"].selected { background: #fef9c3; border-color: #fbbf24; color: #92400e; }
.sf-rating-btn[data-val="100%"].selected  { background: linear-gradient(135deg, #f0fdf4, #dcfce7); border-color: #4ade80; color: #166534; }

/* Structured rate-each — per-product category ratings inside the stepper */
.rate-sf-ratings { margin-top: 10px; text-align: left; }

/* Structured feedback — results display */
.sf-result-category {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 12px;
}
.sf-result-category-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.sf-result-category-name { font-size: 14px; font-weight: 700; color: var(--text); }
.sf-result-category-total { font-size: 12px; color: var(--text-muted); }
.sf-result-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.sf-result-row:last-child { margin-bottom: 0; }
.sf-result-label { font-size: 13px; width: 78px; flex-shrink: 0; }
.sf-result-bar-wrap {
  flex: 1;
  height: 18px;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 6px;
  overflow: hidden;
}
.sf-result-bar-fill { height: 100%; border-radius: 6px; transition: width 0.3s ease; min-width: 2px; }
.sf-bar-no    { background: #f87171; }
.sf-bar-maybe { background: #fbbf24; }
.sf-bar-yes   { background: #4ade80; }
.sf-result-count { font-size: 13px; font-weight: 600; color: var(--text-muted); width: 22px; text-align: right; flex-shrink: 0; }

/* ===== Share Link Box ===== */

.link-box {
  background: #faf5ff;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 16px 0;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 2px dashed var(--purple);
}

.link-box .link-text {
  flex: 1;
  font-size: 13px;
  color: var(--purple-dark);
  word-break: break-all;
  font-weight: 500;
}

.link-box .copy-btn {
  flex-shrink: 0;
  background: var(--purple);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}

.link-box .copy-btn:active {
  transform: scale(0.95);
}

/* ===== Success State ===== */

.success-state {
  text-align: center;
  padding: 20px 0;
}

.success-state .checkmark {
  font-size: 64px;
  margin-bottom: 12px;
}

.success-state h2 {
  font-size: 22px;
  margin-bottom: 8px;
}

.success-state p {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 4px;
}

/* ===== App Download Buttons ===== */

.app-download-section {
  margin-top: 24px;
  text-align: center;
}

.app-download-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.app-open-hint {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 4px;
  margin-bottom: 0;
}

.app-download-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.app-store-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #1a1a1a;
  color: #fff;
  border-radius: 10px;
  padding: 10px 16px;
  text-decoration: none;
  min-width: 140px;
  transition: opacity 0.15s;
}

.app-store-btn:hover { opacity: 0.85; }

.app-store-btn--android { background: #2d6a2d; }

.app-store-btn--disabled,
.app-store-btn--disabled.app-store-btn--android {
  background: #c0c0c0;
  color: #888;
  pointer-events: none;
  cursor: default;
  opacity: 1;
}
.app-store-btn--disabled:hover { opacity: 1; }

/* Disabled button — same greyed-out treatment as the app-store pills above.
   Applied explicitly rather than via :disabled so the vote-submit buttons,
   which start disabled until a choice is made, keep their current look. */
.btn--disabled,
.btn--disabled:hover {
  background: #c0c0c0;
  color: #888;
  box-shadow: none;
  pointer-events: none;
  cursor: default;
  opacity: 1;
}

.app-store-btn .store-icon {
  font-size: 22px;
  flex-shrink: 0;
}

.app-store-btn .store-text {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.app-store-btn .store-sub {
  font-size: 10px;
  opacity: 0.75;
  line-height: 1.2;
}

.app-store-btn .store-name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
}

/* ===== Test Banner ===== */

.test-banner {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-top: 16px;
  font-size: 13px;
  color: #92400e;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  border: none;
  width: 100%;
  font-family: inherit;
  text-align: left;
}

.test-banner:active {
  transform: scale(0.98);
}

/* ===== Verdict ===== */

.verdict {
  text-align: center;
  padding: 16px;
  border-radius: var(--radius-sm);
  margin: 16px 0;
}

.verdict.positive {
  background: linear-gradient(135deg, #dcfce7, #bbf7d0);
}

.verdict.negative {
  background: linear-gradient(135deg, #fef2f2, #fecaca);
}

.verdict.neutral {
  background: linear-gradient(135deg, #f5f3ff, #ede9fe);
}

.verdict .verdict-emoji {
  font-size: 40px;
  margin-bottom: 8px;
}

.verdict .verdict-text {
  font-size: 16px;
  font-weight: 700;
}

/* ===== Waiting state ===== */

.waiting-state {
  text-align: center;
  padding: 24px;
  color: var(--text-muted);
}

.waiting-state .waiting-emoji {
  font-size: 48px;
  margin-bottom: 12px;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* ===== Utility ===== */

.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.text-center { text-align: center; }
.hidden { display: none !important; }

.divider {
  height: 1px;
  background: var(--border);
  margin: 16px 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.badge-purple {
  background: #f3e8ff;
  color: var(--purple-dark);
}

/* ===== Toast ===== */

.toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--text);
  color: white;
  padding: 12px 24px;
  border-radius: 30px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
  transition: transform 0.3s ease;
  z-index: 1000;
  white-space: nowrap;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

/* ===== Responsive ===== */

@media (max-width: 430px) {
  .app {
    padding: 0 16px 32px;
  }
}

/* ===== Product link fallback ===== */

.product-link-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: #faf5ff;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  margin-bottom: 16px;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.2s;
}

.product-link-card:hover {
  border-color: var(--pink-light);
}

.product-link-card .link-icon {
  font-size: 32px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.thumb-tap-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  flex-shrink: 0;
}

.thumb-hint {
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.product-link-card .link-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.product-link-card .link-info .link-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.product-link-card .link-info .link-url {
  font-size: 14px;
  font-weight: 600;
  color: var(--pink-dark);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-link-card .link-info .link-product-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  margin-top: 2px;
  line-height: 1.3;
}

.product-link-card .link-info .link-product-price {
  font-size: 13px;
  color: var(--purple);
  font-weight: 600;
  margin-top: 1px;
}

.product-link-card .arrow {
  font-size: 18px;
  color: var(--text-muted);
}

.product-link-card .link-arrow {
  font-size: 18px;
  color: var(--text-muted);
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s;
  flex-shrink: 0;
}

.product-link-card .link-arrow:hover {
  background: rgba(0,0,0,0.06);
}

.product-thumb-img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

/* ===== Product image card ===== */
.product-image-card {
  padding: 0;
  overflow: hidden;
}

.product-image-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  padding: 14px 16px 10px;
  line-height: 1.3;
  text-align: center;
}

.product-image-full {
  width: 100%;
  display: block;
  object-fit: contain;
  max-height: 320px;
  background: #f8f8f8;
}

.product-brand-box {
  margin: 12px 12px 0;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-align: center;
  background: var(--bg-soft, #f7f6fb);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.product-url-under {
  display: block;
  padding: 10px 16px 14px;
  font-size: 13px;
  color: var(--purple);
  text-align: center;
  text-decoration: none;
  word-break: break-all;
}

.product-url-under:hover { text-decoration: underline; }

/* Extra photos the requester took of the same product, under its picture. A row of small
   squares rather than a second full-width image: they are supporting shots, not the product. */
.extra-images {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.extra-image {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border, #e5e7eb);
  cursor: pointer;
}
.extra-image:hover { opacity: 0.9; }

/* Pick-one categories before a product has been chosen: on the page so voters know they are
   part of the flow, but plainly not ready to be used yet. */
.sf-awaiting-pick {
  opacity: 0.45;
  pointer-events: none;
}

/* The request title on the voting screens — what is being decided, above the question. */
.vote-request-title {
  font-size: 17px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 2px 0 8px;
}

.image-status {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: -10px;
  margin-bottom: 8px;
  padding: 0 4px;
}

.product-description {
  font-size: 13px;
  line-height: 1.45;
  color: var(--text-muted);
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--bg-soft, #f7f6fb);
  border-radius: 10px;
}

/* ===== Image popup ===== */

.image-popup {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-popup.hidden {
  display: none;
}

.image-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.image-popup-content {
  position: relative;
  z-index: 1;
  background: #fff;
  border-radius: 16px;
  padding: 12px;
  max-width: min(90vw, 480px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.image-popup-content img {
  display: block;
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 10px;
}

.image-popup-close {
  position: absolute;
  top: -18px;
  right: -12px;
  height: 36px;
  padding: 0 12px 0 14px;
  border-radius: 18px;
  background: #fff;
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  white-space: nowrap;
}

.image-popup-close-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--pink-dark);
}

.image-popup-close-x {
  font-size: 15px;
}

.image-popup-close:hover {
  color: var(--text);
}

/* ===== Name input ===== */

.inline-name {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 16px;
}

.inline-name input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: inherit;
  background: #faf5ff;
}

.inline-name input:focus {
  outline: none;
  border-color: var(--pink);
  background: white;
}

/* ===== Request List (homepage) ===== */

.request-list-row {
  display: flex;
  align-items: stretch;
  gap: 8px;
  margin-bottom: 10px;
}

.request-list-row .request-list-item {
  flex: 1;
  margin-bottom: 0;
}

.btn-delete-request {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  background: #fff0f0;
  border: 2px solid #ffd0d0;
  border-radius: var(--radius-sm);
  font-size: 18px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  padding: 0;
}

.btn-delete-request:hover {
  background: #ffe0e0;
  border-color: #ff9999;
}

.btn-delete-request:active {
  transform: scale(0.95);
}

.request-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: #faf5ff;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  margin-bottom: 10px;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.2s;
}

.request-list-item:hover {
  border-color: var(--pink-light);
}

.request-list-item:active {
  transform: scale(0.98);
}

.request-list-item .request-item-info {
  flex: 1;
  min-width: 0;
}

/* ===== Request list thumbnails ===== */

.request-item-thumb {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.request-item-thumb--img {
  object-fit: cover;
}

.request-item-thumb--icon {
  font-size: 22px;
  background: #f3e8ff;
}

.request-item-thumb--multi {
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: white;
  font-size: 16px;
  font-weight: 800;
  flex-direction: column;
  gap: 0;
  text-align: center;
  line-height: 1.1;
}

.request-list-item .request-item-context {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.request-list-item .request-item-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.request-list-item .arrow {
  font-size: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ===== Multi-item Request Form ===== */

.form-section-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

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

.items-count-hint {
  font-size: 12px;
  color: var(--text-muted);
}

.item-row {
  margin-bottom: 10px;
}

.item-row-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.item-row-top .input-with-action {
  flex: 1;
}

.item-number-badge {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: white;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-remove-item {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: 2px solid #fecaca;
  background: #fff5f5;
  border-radius: 8px;
  font-size: 13px;
  color: var(--red);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s;
}

.btn-remove-item:hover {
  background: var(--red-light);
  border-color: var(--red);
}

.btn-add-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--purple-dark);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  font-family: inherit;
  margin-top: 4px;
}

.btn-add-item:hover {
  border-color: var(--purple);
  background: #f3e8ff;
}

.item-meta-preview {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  margin-left: 34px;
  padding: 6px 10px;
  background: #f9f5ff;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.item-meta-preview.hidden { display: none; }

.meta-thumb {
  width: 32px;
  height: 32px;
  object-fit: cover;
  border-radius: 6px;
  flex-shrink: 0;
}

.meta-thumb-ph {
  font-size: 20px;
  flex-shrink: 0;
}

.meta-preview-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

.meta-preview-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--purple);
  white-space: nowrap;
  flex-shrink: 0;
}

.item-meta-loading {
  display: flex;
  align-items: center;
  margin-top: 4px;
  margin-left: 34px;
}

.item-meta-loading.hidden { display: none; }

.meta-loading-text {
  font-size: 12px;
  color: var(--text-muted);
}

/* ===== Vote Type Selector ===== */

.vote-type-section {
  margin-bottom: 16px;
  padding: 16px;
  background: #faf5ff;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.vote-type-section.hidden { display: none; }

.vote-type-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.vote-type-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  text-align: left;
  font-family: inherit;
}

.vote-type-option:hover {
  border-color: var(--purple);
  background: #f9f5ff;
}

.vote-type-option.selected {
  border-color: var(--pink);
  background: linear-gradient(135deg, #fff0f5, #f5f0ff);
  box-shadow: 0 2px 12px rgba(236, 72, 153, 0.15);
}

.vote-type-emoji {
  font-size: 22px;
  flex-shrink: 0;
}

.vote-type-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.vote-type-text strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

.vote-type-text span {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.3;
}

/* ===== Multi-vote hint ===== */

.multi-vote-hint {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
  margin-top: -8px;
}

/* ===== Pick One Carousel (vote.html) ===== */

.pick-carousel-section { overflow: hidden; }

.pick-carousel-wrap {
  margin: 0 -20px;
  overflow: hidden;
}

.pick-carousel {
  display: flex;
  gap: 12px;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 8px 20px 12px;
}
.pick-carousel::-webkit-scrollbar { display: none; }

.pick-carousel-card {
  scroll-snap-align: center;
  flex-shrink: 0;
  width: calc(72vw - 20px);
  max-width: 280px;
  min-width: 170px;
  border: 2.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
  transition: border-color 0.18s, box-shadow 0.18s;
  overflow: hidden;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.pick-carousel-card:active { transform: scale(0.97); }

.pick-carousel-card.selected {
  border-color: var(--pink);
  box-shadow: 0 4px 18px rgba(236, 72, 153, 0.28);
}

.pick-carousel-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pick-carousel-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pick-carousel-ph { font-size: 48px; }

.pick-carousel-num {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 26px;
  height: 26px;
  background: rgba(255,255,255,0.92);
  color: var(--purple-dark);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}

.pick-carousel-card.selected .pick-carousel-num {
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: white;
}

.pick-carousel-ext {
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 30px;
  height: 30px;
  background: rgba(255,255,255,0.92);
  color: var(--text-muted);
  border-radius: 50%;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  transition: background 0.12s, color 0.12s;
}
.pick-carousel-ext:hover { background: white; color: var(--purple); }

.pick-carousel-check {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  background: var(--pink);
  color: white;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 6px rgba(236, 72, 153, 0.45);
}
.pick-carousel-check.hidden { display: none; }

.pick-carousel-info {
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pick-carousel-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pick-carousel-store {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Compact product card shown above the ratings on rate_each */
.rate-product-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px;
  background: var(--card-bg, #fff);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 12px;
  text-align: left;
}

.rate-product-card-img {
  width: 84px;
  height: 84px;
  object-fit: contain;
  background: #fff;
  border-radius: 8px;
  flex-shrink: 0;
}

.rate-product-card-ph {
  font-size: 34px;
  width: 84px;
  text-align: center;
  flex-shrink: 0;
}

.rate-product-card-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.rate-product-card-brand {
  font-size: 11px;
  font-weight: 600;
  color: var(--purple);
  text-transform: uppercase;
}

.rate-product-card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.rate-product-card-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--purple);
}

.rate-product-card-store {
  font-size: 11px;
  color: var(--text-muted);
}

.rate-product-card-link {
  font-size: 12px;
  font-weight: 600;
  color: var(--purple);
  text-decoration: none;
  margin-top: 4px;
}

.pick-carousel-price {
  font-size: 13px;
  color: var(--purple);
  font-weight: 600;
}

/* Carousel dots */
.pick-carousel-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 2px 0 10px;
}

.pick-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.18s, transform 0.18s, width 0.18s;
}

.pick-dot.active {
  background: var(--pink);
  width: 20px;
  border-radius: 4px;
}

/* None of the above option */
.pick-none-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  background: white;
  cursor: pointer;
  transition: border-color 0.18s, background 0.18s, opacity 0.18s;
  text-align: left;
  font-family: inherit;
  margin-top: 8px;
  opacity: 0.72;
  -webkit-tap-highlight-color: transparent;
}
.pick-none-card:hover { opacity: 1; border-color: var(--text-muted); }
.pick-none-card.selected {
  opacity: 1;
  border-style: solid;
  border-color: var(--pink);
  background: linear-gradient(135deg, #fff0f5, #f5f0ff);
}
.pick-none-num { font-size: 18px; width: 28px; text-align: center; flex-shrink: 0; }

/* Shared: pick info / check used by none card */
.pick-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pick-item-title { font-size: 14px; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pick-item-url { font-size: 12px; color: var(--text-muted); }
.pick-item-price { font-size: 13px; color: var(--purple); font-weight: 600; }

.pick-check {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: var(--pink);
  color: white;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pick-check.hidden { display: none; }



/* ===== Rate Each Vote (vote.html) ===== */

.rate-item-block {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.rate-item-image {
  border-radius: 10px;
  margin-top: 6px;
}

.rate-item-block:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.rate-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.rate-item-thumb {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.rate-item-thumb-ph {
  font-size: 28px;
  flex-shrink: 0;
  width: 44px;
  text-align: center;
}

.rate-item-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.rate-item-num {
  font-size: 11px;
  font-weight: 700;
  color: var(--pink);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.rate-item-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rate-item-url { font-size: 12px; color: var(--text-muted); }

.rate-item-link {
  flex-shrink: 0;
  font-size: 16px;
  color: var(--text-muted);
  padding: 6px;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.15s;
}

.rate-item-link:hover { background: rgba(0, 0, 0, 0.05); }

.rate-item-comment {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: inherit;
  resize: vertical;
  min-height: unset;
  background: #faf5ff;
  color: var(--text);
  transition: border-color 0.2s;
}

.rate-item-comment:focus {
  outline: none;
  border-color: var(--pink);
  background: white;
}

.rate-item-comment::placeholder { color: #c4b5d0; }

/* ===== Rate Each — per-item vote buttons ===== */

.rate-vote-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.rate-vote-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border: 2.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  color: var(--text-muted);
}

.rate-vote-btn:hover { border-color: var(--pink-light); }

.rate-vote-btn.rate-vote-selected-up {
  border-color: var(--green);
  background: var(--green-light);
  color: var(--green);
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.18);
}

.rate-vote-btn.rate-vote-selected-down {
  border-color: var(--red);
  background: var(--red-light);
  color: var(--red);
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.18);
}

/* ===== Pick One Results (results.html) ===== */

.pick-result-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.pick-result-row:last-child { border-bottom: none; }

.pick-result-row.winner {
  background: linear-gradient(90deg, #fffbeb, transparent);
  margin: 0 -24px;
  padding: 12px 24px;
  border-radius: 4px;
}

.pick-result-num {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  background: #f3e8ff;
  color: var(--purple-dark);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pick-result-thumb {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.pick-result-thumb-ph {
  font-size: 26px;
  flex-shrink: 0;
  width: 96px;
  text-align: center;
  height: 96px;
}

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

.pick-result-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pick-result-url { font-size: 11px; color: var(--text-muted); }

.pick-bar-wrap {
  height: 8px;
  background: #f1f5f9;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 3px;
}

.pick-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--pink), var(--purple));
  border-radius: 4px;
  transition: width 0.6s ease;
}

.pick-result-count-block {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  min-width: 32px;
}

.pick-result-count {
  font-size: 22px;
  font-weight: 800;
  color: var(--pink-dark);
}

.pick-trophy { font-size: 14px; }

.pick-result-link {
  flex-shrink: 0;
  font-size: 16px;
  color: var(--text-muted);
  padding: 6px;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.15s;
}

.pick-result-link:hover { background: rgba(0, 0, 0, 0.05); }

/* ===== Rate Each Results (results.html) ===== */

.rate-result-item {
  margin-bottom: 12px;
  padding: 16px;
  background: #faf5ff;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.rate-result-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.rate-result-thumb {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.rate-result-thumb-ph {
  font-size: 26px;
  flex-shrink: 0;
  width: 96px;
  text-align: center;
  height: 96px;
}

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

.rate-result-num {
  font-size: 11px;
  font-weight: 700;
  color: var(--pink);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.rate-result-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rate-result-url { font-size: 12px; color: var(--text-muted); }

/* Product brand labels */
.pick-result-brand,
.rate-result-brand,
.pick-carousel-brand,
.rate-item-brand,
.link-product-brand {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--purple-dark, #7c3aed);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rate-result-link {
  flex-shrink: 0;
  font-size: 16px;
  color: var(--text-muted);
  padding: 6px;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.15s;
}

.rate-result-link:hover { background: rgba(0, 0, 0, 0.05); }

.rate-result-no-comments {
  font-size: 13px;
  color: var(--text-muted);
  font-style: italic;
  padding: 4px 0;
}

/* ===== Vote wizard: intro screen ===== */
.intro-badge {
  display: inline-block;
  align-self: flex-start;
  font-size: 13px;
  font-weight: 700;
  color: var(--purple);
  background: #f3e8ff;
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 14px;
}

.intro-asker {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 10px;
  line-height: 1.25;
}

.intro-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
}

.intro-context {
  margin-bottom: 14px;
}

.intro-date {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 14px;
}

/* ===== Vote wizard: rate-each stepper ===== */
.rate-step-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.rate-step-count {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  white-space: nowrap;
}

.rate-step-progress {
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
  margin-bottom: 16px;
}

.rate-step-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  transition: width 0.25s ease;
}

.rate-step-nav {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

/* ===== Phase-1 parity: account, feedback tags, photos, my-picks ===== */

.header { position: relative; }

.account-btn {
  position: absolute;
  top: 20px;
  right: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  font-size: 18px;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform 0.12s ease;
}
.account-btn:active { transform: scale(0.94); }
/* On Home the icon sits on the page itself: held inside the page, clear of the screen edge,
   rather than against the window's own edge. */
.app:has(> .account-btn) { position: relative; }
.app > .account-btn { top: 16px; right: 16px; }

/* ===== Home page (matches iOS HomeView) ===== */
.home-hero {
  text-align: center;
  padding: 40px 0 4px;
}
.home-flags {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 12px;
}
.home-flag { width: 86px; height: 86px; object-fit: contain; }
.home-cat { font-size: 72px; line-height: 1; }
.home-logo {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin: 0;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.home-lede {
  font-size: 15px;
  color: var(--text-muted);
  margin: 12px auto 0;
  max-width: 340px;
  line-height: 1.5;
}
.home-cta {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 28px;
}
.home-cta .btn { margin: 0; }
.home-tagline {
  font-size: 13px;
  color: var(--purple);
  text-align: center;
  margin: 16px auto 0;
  max-width: 320px;
}
.home-how { margin-top: 20px; }
.btn-plus { font-size: 22px; font-weight: 700; line-height: 1; margin-right: 2px; }
.home-footer { margin-top: 24px; text-align: center; font-size: 12px; line-height: 1.6; color: var(--text-muted); }
.shared-footer { margin-top: auto; padding-top: 24px; }
.home-how-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 16px;
}
.home-step {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}
.home-step:first-of-type { margin-top: 0; }
.home-step-num {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.home-step-text { font-size: 14px; color: var(--text); line-height: 1.4; }

/* ===== Bottom tab bar (matches iOS TabView: Home · Ask friends · My picks) ===== */
.app.has-tabbar { padding-bottom: 84px; }
.tab-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  display: flex;
  max-width: 430px;
  margin: 0 auto;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
  box-shadow: 0 -2px 14px rgba(0, 0, 0, 0.05);
}
.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 0;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  transition: color 0.12s ease;
}
.tab-item .tab-ico { font-size: 21px; line-height: 1; opacity: 0.55; transition: opacity 0.12s ease; }
.tab-item.active { color: var(--purple-dark); }
.tab-item.active .tab-ico { opacity: 1; }
.tab-item:active { transform: scale(0.96); }

.field-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 4px 0 0;
}

.edit-banner {
  background: #f3e8ff;
  color: var(--purple-dark);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 16px;
}

/* ---- Modal ---- */
.sk-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 30, 46, 0.5);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: max(20px, env(safe-area-inset-top)) 20px max(20px, env(safe-area-inset-bottom));
  /* A dialog taller than the screen scrolls instead of losing its top edge. */
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  z-index: 1000;
}
.sk-modal-overlay[hidden] { display: none; }

.sk-modal {
  position: relative;
  /* Centred while it fits; from the top, scrollable, once it doesn't. */
  margin: auto 0;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px 20px 20px;
  width: 100%;
  max-width: 380px;
  box-shadow: var(--shadow);
  animation: skModalIn 0.18s ease;
}
@keyframes skModalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to   { opacity: 1; transform: none; }
}

.sk-modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: none;
  background: none;
  font-size: 24px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
}
.sk-modal-title { font-size: 18px; margin-bottom: 6px; }
.sk-modal-sub { font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }

/* ---- Results: iOS-style verdict header, tally row and detail blocks ---- */
.verdict-header { text-align: center; padding: 8px 0 20px; }
.verdict-header .verdict-emoji { font-size: 60px; line-height: 1; }
.verdict-headline { font-size: 22px; font-weight: 800; color: var(--text); margin-top: 8px; }
.verdict-responses { font-size: 14px; color: var(--text-muted); margin-top: 2px; }

.product-image-link { display: block; }
.product-image-full {
  width: 100%;
  max-height: 280px;
  object-fit: contain;
  border-radius: 10px;
  background: #fff;
}

.tally-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 16px;
  min-height: 24px;
}
.tally-counts { display: flex; gap: 18px; font-size: 15px; font-weight: 600; }
.tally-ico { margin-right: 5px; }
.tally-up { color: var(--green-dark, #16a34a); }
.tally-down { color: var(--red-dark, #dc2626); }
.tally-comments {
  position: absolute;
  right: 0;
  border: none;
  background: none;
  font-size: 12px;
  font-weight: 600;
  color: var(--purple-dark);
  cursor: pointer;
}
.tally-comments:disabled { color: var(--text-muted); cursor: default; }

/* The comments link under a rate-each product sits on its own line, right-aligned. */
/* The winner marker iOS puts on the leading product. */
.pick-winner-pill {
  display: inline-block;
  align-self: flex-start;
  margin-bottom: 4px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--grad, linear-gradient(120deg, #ec4899, #a855f7));
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .03em;
}

/* A card heading with a link on its trailing edge. */
.card-title--row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.card-title-link { position: static; }

.rate-result-categories {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.rate-result-cat-head {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.rate-result-comments {
  position: static;
  display: block;
  margin: 8px 0 0 auto;
  padding: 0;
}

.detail-block { margin-top: 16px; }
.detail-label { font-size: 12px; color: var(--text-muted); margin-bottom: 4px; }
.detail-title { font-size: 15px; font-weight: 700; color: var(--text); }
.detail-price { font-size: 15px; font-weight: 600; color: var(--purple-dark); margin-top: 4px; }
.detail-body { font-size: 15px; color: var(--text); }
.detail-shop-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--purple-dark);
}
.link-brand {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--purple-dark);
}

/* ---- Sign out (account modal) ---- */
.btn-signout {
  display: block;
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm, 10px);
  background: none;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.btn-signout:hover { color: var(--text); }

/* ---- Product preview modal (create form) ---- */
.product-preview { margin-bottom: 16px; }
.product-preview-img,
.product-preview-ph {
  width: 100%;
  height: 260px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--border);
  object-fit: contain;
  display: block;
}
.product-preview-ph {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 56px;
}
.product-preview-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-top: 14px;
}
.product-preview-muted { color: var(--text-muted); font-weight: 600; }
.meta-preview-muted { color: var(--text-muted); font-style: italic; }
.product-preview-note {
  margin-top: 14px;
  padding: 12px;
  border-radius: 10px;
  background: var(--bg-soft, #fdf2f8);
  border: 1px solid var(--border);
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}
.product-preview-note strong { color: var(--text); }

.product-preview-price {
  font-size: 19px;
  font-weight: 600;
  color: var(--purple-dark);
  margin-top: 6px;
}
/* The inline strip reopens the popup, so it should look tappable. */
.item-meta-preview { cursor: pointer; }

/* ---- Suggestion box (account modal) ---- */
.suggestion-box {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}
.suggestion-head { font-size: 15px; font-weight: 700; color: var(--text); }
.suggestion-sub { font-size: 12px; color: var(--text-muted); margin: 4px 0 10px; }
.suggestion-input {
  width: 100%;
  box-sizing: border-box;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  padding: 10px;
  resize: vertical;
  margin-bottom: 10px;
}
.suggestion-input:focus {
  outline: none;
  border-color: var(--purple);
}
.suggestion-done {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 0;
}
.suggestion-thanks { font-size: 14px; font-weight: 600; color: #16a34a; }
.suggestion-again {
  border: none;
  background: none;
  color: var(--purple-dark);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}

/* ---- Store directory ("Find a shop") ---- */
.btn-browse-shops {
  width: 100%;
  margin-top: 8px;
  border: 1.5px dashed var(--purple);
  background: #faf5ff;
  color: var(--purple-dark);
  border-radius: var(--radius-sm);
  padding: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.btn-grab-url {
  width: 100%;
  margin-bottom: 12px;
  border: none;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: #fff;
  border-radius: var(--radius-sm);
  padding: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(192, 132, 252, 0.3);
}
.btn-grab-url:active { transform: translateY(1px); }
.shop-modal { max-width: 460px; }
.shop-search-row {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  margin-bottom: 12px;
}
.shop-search-ico { font-size: 15px; }
.shop-search-row input {
  flex: 1;
  border: none;
  outline: none;
  font: inherit;
  font-size: 14px;
  background: transparent;
  color: var(--text);
}
.shop-country {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px 6px;
  font-size: 12px;
  background: var(--bg-card);
  color: var(--text);
}
.shop-list {
  max-height: 50vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.shop-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}
.shop-row:hover { border-color: var(--purple); }
.shop-row-ico { font-size: 18px; }
.shop-row-text { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.shop-row-name { font-size: 14px; font-weight: 600; color: var(--text); }
.shop-row-domain { font-size: 12px; color: var(--text-muted); }
.shop-row-go { color: var(--text-muted); }
.shop-empty { font-size: 13px; color: var(--text-muted); text-align: center; padding: 16px 0; }
.shop-guess {
  display: block;
  width: 100%;
  border: none;
  background: none;
  color: var(--purple-dark);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
}

/* ---- Results screen: refresh, close/reopen, requested tags ---- */
/* The results header carries a back link and a refresh button, so it needs room above
   the centred logo for both. */
.app > .header:has(.results-back) { padding-top: 34px; }

/* Back to the list, top-left of the results header. */
.results-back {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  font-size: 14px;
  font-weight: 600;
  color: var(--purple-dark);
  text-decoration: none;
}

.results-refresh {
  position: absolute;
  top: 8px;
  right: 14px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  color: var(--purple-dark);
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
}
.results-refresh.spinning { animation: sk-spin 0.5s linear; }
@keyframes sk-spin { from { transform: rotate(0); } to { transform: rotate(360deg); } }
.requested-box {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #faf5ff;
}
.requested-head { font-size: 13px; font-weight: 700; color: var(--purple-dark); margin: 0 0 8px; }
.requested-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.requested-tag {
  font-size: 12px;
  font-weight: 600;
  color: var(--purple-dark);
  background: #fff;
  border: 1px solid var(--purple);
  border-radius: 999px;
  padding: 4px 10px;
}
.requested-note { font-size: 12px; color: var(--text-muted); margin: 8px 0 0; }
.btn-danger-outline { color: #dc2626; border-color: #fecaca; }

/* Close voting is a real, full-width button — it was a faint outline that read as a
   caption rather than something to press. */
.btn-close-voting {
  display: block;
  width: 100%;
  background: var(--bg-card);
  color: #dc2626;
  border: 1.5px solid #fecaca;
  font-weight: 700;
}
.btn-close-voting:hover { background: #fff5f5; }
.close-hint { font-size: 12px; color: var(--text-muted); text-align: center; margin: 10px 0 0; }
.closed-badge { font-size: 15px; font-weight: 700; color: var(--text); text-align: center; margin: 0 0 4px; }
.closed-when { font-size: 12px; color: var(--text-muted); text-align: center; margin: 0 0 12px; }
.more-photos { margin-top: 14px; }
.more-photos-head { font-size: 13px; font-weight: 700; color: var(--text); margin: 0 0 8px; }
.more-photos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.more-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  cursor: zoom-in;
}

/* ---- Structured feedback tag picker ---- */
.feedback-tag-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.feedback-tag {
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.12s ease;
}
.feedback-tag.selected {
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: #fff;
  border-color: transparent;
}
.feedback-tag.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.feedback-note-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
}
.feedback-note-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--purple-dark);
}
.feedback-note-input {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
}

/* ---- Extra photos ---- */
.photo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.photo-tile {
  position: relative;
  width: 84px;
  height: 84px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1.5px solid var(--border);
}
.photo-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-remove {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 12px;
  cursor: pointer;
}
.photo-add {
  width: 84px;
  height: 84px;
  border: 1.5px dashed var(--purple);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--purple-dark);
  font-size: 22px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}
.photo-add span { font-size: 11px; font-weight: 600; }
.photo-add.loading { font-size: 20px; }

/* Extra-photos card on the products step (matches iOS ExtraPhotosSection) */
.extra-photos {
  margin: 12px 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
}
.extra-photos-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.extra-photos-label { font-size: 14px; font-weight: 600; color: var(--text); }
.extra-photos-count { font-size: 12px; color: var(--text-muted); }
.extra-photos .photo-add { width: 100%; height: auto; flex-direction: row; padding: 10px; font-size: 15px; gap: 6px; }
.extra-photos .photo-add span { font-size: 14px; }

/* ---- My picks list ---- */
.sync-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #f3e8ff;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 13px;
  color: var(--purple-dark);
  margin-bottom: 14px;
}
.btn-link {
  border: none;
  background: none;
  color: var(--purple-dark);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  text-decoration: underline;
  white-space: nowrap;
}
.mypicks-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  margin-bottom: 12px;
}
/* The screen title, centred, with Refresh on the right. */
.mypicks-title { grid-column: 2; margin: 0; font-size: 16px; }
.mypicks-head .btn-refresh { grid-column: 3; justify-self: end; }
/* No header above the list any more, so the page keeps its own top margin. */
.app.mypicks-page { padding-top: 20px; }
.mypicks-head .account-btn { position: static; grid-column: 1; grid-row: 1; justify-self: start; }
.mypicks-title { grid-row: 1; }
.btn-refresh {
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  /* The glyph is small for its em size, so it needs most of the circle to read as an arrow. */
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--purple-dark);
}

/* ---- My Picks: sort control ---- */
.sort-control {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.sort-label { font-size: 12px; font-weight: 600; color: var(--text-muted); }
.sort-pill {
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px;
  cursor: pointer;
}
.sort-pill.active {
  background: var(--purple);
  border-color: var(--purple);
  color: #fff;
  font-weight: 600;
}

/* ---- My Picks: grid of cards (iOS parity) ---- */
.mypicks-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.mypicks-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pick-card {
  position: relative;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  overflow: visible;
}
.pick-card-link {
  display: block;
  padding: 10px;
  text-decoration: none;
  color: inherit;
}
.pick-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
  min-height: 34px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  padding-right: 22px;
}
.pick-image {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(0,0,0,0.05);
  margin: 6px 0 8px;
}
.pick-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pick-img--icon {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
}
.pick-leading {
  position: absolute;
  top: 6px;
  left: 6px;
  font-size: 9px;
  font-weight: 700;
  color: #fff;
  background: rgba(147, 51, 234, 0.85);
  border-radius: 6px;
  padding: 3px 6px;
}
.pick-type {
  font-size: 11px;
  font-weight: 500;
  color: var(--purple-dark);
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
.pick-products {
  font-size: 9px;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(0,0,0,0.06);
  border-radius: 999px;
  padding: 1px 6px;
}
.pick-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}
.pick-breakdown {
  font-size: 11px;
  color: var(--text);
  margin-top: 2px;
}
.pick-dates {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
}
.pick-menu-wrap { position: absolute; top: 6px; right: 6px; z-index: 5; }
.pick-menu-btn {
  border: none;
  background: var(--bg-card);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  font-size: 14px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.pick-menu {
  position: absolute;
  top: 28px;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
  padding: 4px;
  min-width: 140px;
}
.pick-menu button {
  display: block;
  width: 100%;
  text-align: left;
  border: none;
  background: none;
  padding: 8px 10px;
  font-size: 13px;
  color: var(--text);
  border-radius: 6px;
  cursor: pointer;
}
.pick-menu button:hover { background: rgba(0,0,0,0.05); }
.pick-menu button.danger { color: #dc2626; }

.request-card {
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  margin-bottom: 12px;
  background: var(--bg-card);
}
.request-card .request-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}
.status-badge {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.status-badge.open { background: var(--green-light); color: #15803d; }
.status-badge.closed { background: var(--red-light); color: #b91c1c; }

.request-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}
.request-tag {
  font-size: 11px;
  font-weight: 600;
  color: var(--purple-dark);
  background: #f3e8ff;
  border-radius: 999px;
  padding: 1px 8px;
}

.request-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.request-action-btn {
  border: 1.5px solid var(--border);
  background: var(--bg);
  border-radius: 999px;
  padding: 6px 11px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.12s ease;
}
.request-action-btn:active { transform: scale(0.95); }
.request-action-btn.danger { color: var(--red); border-color: var(--red-light); }
.request-action-btn:disabled { opacity: 0.5; cursor: default; }

/* ============================================================
   Create-request wizard (step-by-step)
   ============================================================ */
.wizard { position: relative; }

.wizard-header { margin-bottom: 18px; }
.wiz-topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.wiz-back,
.wiz-toggle {
  border: 1.5px solid var(--border);
  background: var(--bg);
  color: var(--text);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.12s ease;
}
.wiz-back:active,
.wiz-toggle:active { transform: scale(0.95); }
.wiz-toggle { margin-left: auto; }
.wiz-step-count {
  flex-basis: 100%;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}
.wiz-step-title,
.wiz-step-count span { color: var(--purple-dark); }

.wiz-progress {
  display: flex;
  gap: 6px;
}
.wiz-seg {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  transition: background 0.2s ease;
}
.wiz-seg.done {
  background: linear-gradient(90deg, var(--pink), var(--purple));
}

.wizard-step { animation: wizFade 0.18s ease; }
@keyframes wizFade {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Keep every step the same height so short steps (e.g. Products) don't shrink the
   card into a small box. Skipped in one-page mode, where all steps stack. */
.wizard:not(.onepage) .wizard-step:not(.hidden) {
  min-height: 360px;
  display: flex;
  flex-direction: column;
}

.req-tag { color: var(--red); font-weight: 600; font-size: 0.85em; }
.opt-tag { color: var(--text-muted); font-weight: 400; font-size: 0.85em; }

/* Vote-kind selector */
.kind-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.kind-option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  text-align: left;
  border: 2px solid var(--border);
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  padding: 14px;
  cursor: pointer;
  transition: all 0.14s ease;
}
.kind-option:active { transform: scale(0.99); }
.kind-option.selected {
  border-color: var(--purple);
  background: #faf5ff;
  box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.12);
}
.kind-emoji { font-size: 24px; line-height: 1; flex-shrink: 0; }
.kind-text { display: flex; flex-direction: column; gap: 3px; }
.kind-text strong { font-size: 15px; color: var(--text); }
.kind-text span { font-size: 13px; color: var(--text-muted); line-height: 1.35; }

/* ⓘ info button overlaid on each kind card (nested buttons are invalid, so sibling) */
.kind-option-wrap { position: relative; }
.kind-option-wrap .kind-option { width: 100%; padding-right: 44px; }
.kind-info {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border: none;
  background: none;
  color: var(--purple);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.12s ease;
}
.kind-info:hover { background: #f3e8ff; }
.kind-info:active { transform: scale(0.9); }

/* Kind info modal */
.kind-info-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 100;
  padding: 0;
  animation: kindInfoFade 0.15s ease;
}
@keyframes kindInfoFade { from { opacity: 0; } to { opacity: 1; } }
.kind-info-modal {
  background: var(--bg-card);
  width: 100%;
  max-width: 480px;
  max-height: 88vh;
  border-radius: 20px 20px 0 0;
  display: flex;
  flex-direction: column;
  animation: kindInfoSlide 0.22s ease;
}
@keyframes kindInfoSlide { from { transform: translateY(24px); } to { transform: translateY(0); } }
.kind-info-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 18px 18px 12px;
  border-bottom: 1px solid var(--border);
}
.kind-info-title { font-size: 18px; font-weight: 700; color: var(--text); }
.kind-info-close {
  border: none;
  background: var(--bg);
  color: var(--text-muted);
  width: 30px;
  height: 30px;
  border-radius: 999px;
  font-size: 14px;
  cursor: pointer;
  flex-shrink: 0;
}
.kind-info-close:active { transform: scale(0.9); }
.kind-info-body {
  padding: 16px 18px;
  overflow-y: auto;
}
.kind-info-summary { font-size: 14px; color: var(--text-muted); line-height: 1.45; margin: 0 0 16px; }
.kind-info-section-label { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.kind-info-steps {
  list-style: none;
  counter-reset: kinfo;
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.kind-info-steps li {
  counter-increment: kinfo;
  position: relative;
  padding-left: 34px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.kind-info-steps li::before {
  content: counter(kinfo);
  position: absolute;
  left: 0;
  top: 0;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--pink), var(--purple));
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.kind-info-steps li strong { font-size: 14px; color: var(--text); }
.kind-info-steps li span { font-size: 13px; color: var(--text-muted); line-height: 1.4; }
.kind-info-results {
  background: var(--bg);
  border-radius: 10px;
  padding: 12px;
}
.kind-info-results p { font-size: 13px; color: var(--text-muted); line-height: 1.45; margin: 0; }
.kind-info-foot {
  padding: 12px 18px 20px;
  border-top: 1px solid var(--border);
}
.kind-info-foot .btn { margin: 0; }

/* Feedback preview (No / Maybe / 100%) */
.feedback-preview { margin-top: 4px; }
.feedback-preview-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 7px 0;
  border-top: 1px dashed var(--border);
}
.feedback-preview-tag { font-size: 13px; font-weight: 600; color: var(--text); }
.rating-chips { display: flex; gap: 6px; }
.rating-chip {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 2px 9px;
  white-space: nowrap;
}

/* Summary / review */
.summary-title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 14px;
  color: var(--text);
}
.summary-note { margin: -4px 0 12px; font-size: 13px; color: var(--text-muted); }
.summary-card {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.sum-row {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.sum-row:last-child { border-bottom: none; }
.sum-row-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 5px;
}
.sum-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text-muted);
}
.sum-edit {
  border: none;
  background: none;
  color: var(--purple-dark);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}
.sum-edit:active { opacity: 0.6; }
.sum-val { font-size: 15px; color: var(--text); line-height: 1.4; }
.sum-muted { font-size: 14px; color: var(--text-muted); font-style: italic; }
.sum-products { display: flex; flex-direction: column; gap: 8px; }
.sum-product {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sum-num {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: var(--purple);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sum-thumb {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg);
}
.sum-thumb-ph {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.sum-name { font-size: 14px; color: var(--text); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sum-price { font-size: 13px; font-weight: 700; color: var(--purple-dark); flex-shrink: 0; }

/* Inline share block on the summary screen (matches iOS RequestSuccessView) */
.review-share {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
}
.review-link-card {
  padding: 12px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.review-link-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}
.review-link-label { font-size: 12px; color: var(--text-muted); }
.review-link-url {
  display: block;
  font-size: 13px;
  color: var(--text);
  word-break: break-all;
  user-select: all;
}

.wizard-footer { margin-top: 20px; }
.wiz-hint {
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
  margin: 0 0 10px;
}

/* Add a product by photo (per-row, matches iOS "Or add a photo from your phone") */
.btn-item-photo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  margin: 6px 0 2px;
  padding: 6px 4px;
  border: none;
  background: none;
  color: var(--purple-dark);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}
.btn-item-photo:active { opacity: 0.6; }
.item-photo-thumb {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg);
}
.item-photo-thumb.ph {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.item-photo-name {
  flex: 1;
  min-width: 0;
  padding: 10px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
}
.item-photo-name:focus {
  outline: none;
  border-color: var(--purple);
}
.item-photo-status {
  font-size: 12px;
  color: var(--text-muted);
  margin: 6px 0 0 34px;
}
.item-photo-status.error { color: var(--red); }
.link-btn {
  border: none;
  background: none;
  color: var(--purple-dark);
  font-weight: 600;
  font-size: 12px;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}



/* ===== Results: one layout per kind of request ===== */

.rx-head { text-align: center; padding: 4px 0 0; }
.rx-head .rx-link { display: block; margin: 6px auto 0; }
.rx-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 20px;
  background: #fff; border: 1.5px solid #f3c4e3;
  font-size: 12.5px; font-weight: 700; color: #be2d86;
}
.rx-badge--pick { border-color: #dcc3f7; color: #8b3fd1; }
.rx-title {
  margin: 0 0 10px; font-size: 21px; line-height: 1.2; font-weight: 800; letter-spacing: -.015em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text);
}
.rx-link {
  border: 0; background: none; padding: 2px 4px; margin-top: 4px;
  font-size: 13px; font-weight: 600; color: #c026d3; cursor: pointer;
}
.rx-context {
  margin: 4px 0 0; padding: 10px 12px; border-radius: 12px; background: #fff;
  font-size: 14px; line-height: 1.45; color: var(--text-muted); text-align: left;
}

.rx-card {
  margin: 12px 0 0; background: #fff; border-radius: 22px; padding: 16px 18px;
  box-shadow: 0 8px 24px rgba(236, 72, 153, .08);
}
.rx-card--comments { padding-bottom: 8px; }
.rx-card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px 8px; margin-bottom: 12px; }
.rx-card-title { font-size: 15px; font-weight: 700; }
.rx-sub-title { font-size: 14px; font-weight: 700; }
.rx-count { font-weight: 500; color: var(--text-muted); font-size: 13px; }
.rx-divider { margin-top: 16px; padding-top: 14px; border-top: 1px solid #f8e8f3; }
.rx-empty { margin: 10px 0 8px; font-size: 13.5px; color: #9a94ad; }
.rx-hint { margin: 8px 0 0; text-align: center; font-size: 11.5px; color: #9a94ad; }
.rx-ph {
  display: flex; align-items: center; justify-content: center; font-size: 18px;
  background: repeating-linear-gradient(135deg, #fde4f0 0 6px, #fbd3e7 6px 12px);
}

/* Product tabs (rate each) */
.rx-tabs { display: flex; gap: 6px; margin-top: 16px; }
.rx-tab {
  flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 7px 2px 6px; border-radius: 14px; border: 2px solid #f6e1f1;
  background: rgba(255, 255, 255, .6); cursor: pointer;
}
.rx-tab.active { border-color: #e879c9; background: #fff; }
.rx-tab-thumb { width: 34px; height: 42px; border-radius: 8px; object-fit: cover; font-size: 14px; }
.rx-tab-name {
  max-width: 100%; padding: 0 4px; font-size: 11.5px; color: #5b5670;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rx-tab.active .rx-tab-name { font-weight: 700; color: var(--text); }
.rx-tab-pct { font-size: 11px; color: var(--text-muted); white-space: nowrap; }
.rx-tab.active .rx-tab-pct { font-weight: 700; color: #1e8e4e; }

/* Product block */
.rx-product { display: flex; gap: 14px; align-items: center; }
.rx-product-info { flex: 1; min-width: 0; }
.rx-photo { flex: none; border-radius: 14px; overflow: hidden; }
.rx-photo--md { width: 76px; height: 94px; }
.rx-photo--sm { width: 60px; height: 74px; border-radius: 12px; }
.rx-photo-btn { border: 0; padding: 0; background: none; cursor: zoom-in; }
.rx-photo-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rx-brand { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--text-muted); }
.rx-product-title { font-size: 16px; font-weight: 700; line-height: 1.2; }
.rx-product-title a { color: inherit; text-decoration: none; }
.rx-price { font-size: 14px; color: var(--text-muted); margin-top: 2px; font-variant-numeric: tabular-nums; }

/* Verdict + yes/no bar */
.rx-verdict { margin-top: 8px; display: flex; align-items: center; gap: 8px; }
.rx-verdict-emoji { font-size: 30px; line-height: 1; }
.rx-verdict-text { font-size: 20px; font-weight: 800; letter-spacing: -.01em; }
.rx-verdict--big { justify-content: center; gap: 10px; margin-top: 4px; }
.rx-verdict--big .rx-verdict-emoji { font-size: 40px; }
.rx-verdict--big .rx-verdict-text { font-size: 26px; letter-spacing: -.015em; }
.rx-yes { color: #1e8e4e; }
.rx-maybe { color: #a8670a; }
.rx-no { color: #d64550; }
.rx-yn-labels {
  margin-top: 14px; display: flex; justify-content: space-between;
  font-size: 12px; font-weight: 700; letter-spacing: .04em;
}
.rx-yn-bar { margin-top: 5px; display: flex; gap: 3px; height: 12px; border-radius: 6px; overflow: hidden; background: #f8e8f3; }
.rx-seg { display: block; }
.rx-seg--yes { background: #6fcf97; }
.rx-seg--maybe { background: #f7c25c; }
.rx-seg--no { background: #f28b8b; }

/* Category ratings */
.rx-legend { display: flex; gap: 10px; font-size: 11px; color: var(--text-muted); white-space: nowrap; }
.rx-legend span { display: flex; align-items: center; gap: 4px; }
.rx-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.rx-dot--yes { background: #6fcf97; }
.rx-dot--maybe { background: #f7c25c; }
.rx-dot--no { background: #f28b8b; }
.rx-cats { display: flex; flex-direction: column; gap: 11px; }
.rx-cat { display: grid; grid-template-columns: minmax(44px, auto) minmax(0, 1fr) 84px; align-items: center; gap: 10px; }
.rx-cat-name { font-size: 13.5px; font-weight: 600; }
.rx-cat-bar { display: flex; height: 10px; gap: 2px; border-radius: 5px; overflow: hidden; background: #f8e8f3; }
.rx-cat-lead { font-size: 12px; color: var(--text-muted); text-align: right; font-variant-numeric: tabular-nums; }

/* Comments */
.rx-comment { display: flex; gap: 10px; padding: 12px 0; border-bottom: 1px solid #f8e8f3; }
.rx-comment:last-of-type { border-bottom: 0; }
.rx-avatar {
  width: 32px; height: 32px; flex: none; border-radius: 50%;
  background: linear-gradient(135deg, #f472b6, #c084fc); color: #fff;
  font-size: 14px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.rx-comment-body { flex: 1; min-width: 0; }
.rx-comment-name { display: flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; }
.rx-mark { font-size: 13px; }
.rx-comment-text { margin: 2px 0 0; font-size: 14px; line-height: 1.4; color: #3a3550; }
.rx-more { display: block; width: 100%; padding: 10px 0 6px; font-size: 14px; }
.rx-chips { margin-left: auto; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.rx-chip { font-size: 10.5px; font-weight: 700; padding: 2px 6px; border-radius: 7px; }
.rx-chip--yes { background: #e3f6ea; color: #1e8e4e; }
.rx-chip--maybe { background: #fff1d6; color: #a8670a; }
.rx-chip--no { background: #fde4e4; color: #d64550; }

/* Pick one */
.rx-banner { padding: 18px; }
.rx-trophy { text-align: center; font-size: 34px; line-height: 1; }
.rx-banner-sub { text-align: center; margin-top: 4px; font-size: 13px; color: var(--text-muted); }
.rx-banner-title { text-align: center; font-size: 22px; font-weight: 800; letter-spacing: -.01em; margin-top: 2px; }
.rx-pick-list { display: flex; flex-direction: column; gap: 4px; margin-top: 14px; }
.rx-pick-row {
  display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 10px;
  width: 100%; background: none; border: 0; border-radius: 12px; padding: 6px 8px;
  text-align: left; cursor: pointer; color: inherit;
}
.rx-pick-row:hover { background: #fdf6fa; }
.rx-pick-row.active { background: #fdf0f7; }
.rx-pick-row--none { cursor: default; opacity: .7; }
.rx-pick-row--none:hover { background: none; }
.rx-pick-thumb { width: 30px; height: 36px; border-radius: 7px; object-fit: cover; font-size: 13px; box-sizing: border-box; }
.rx-pick-row.active .rx-pick-thumb { border: 1.5px solid #e879c9; }
.rx-pick-mid { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.rx-pick-name { font-size: 13px; color: #5b5670; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rx-pick-row.active .rx-pick-name { font-weight: 700; color: var(--text); }
.rx-pick-track { height: 7px; border-radius: 4px; background: #fbe5f1; overflow: hidden; display: flex; }
.rx-pick-fill { display: block; background: linear-gradient(90deg, #ff6b9d, #c084fc); border-radius: 4px; }
.rx-pick-count { font-size: 14px; font-weight: 700; color: #5b5670; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rx-pick-row.active .rx-pick-count { font-weight: 800; color: var(--text); }
.rx-none {
  margin-top: 14px; padding: 14px; border-radius: 14px; background: #fdf6fa;
  text-align: center; font-size: 13.5px; color: var(--text-muted);
}

/* Single product */
.rx-gallery { display: grid; gap: 6px; height: 200px; margin-bottom: 12px; }
.rx-gallery--1 { grid-template-columns: 1fr; }
.rx-gallery--2 { grid-template-columns: 2fr 1fr; }
.rx-gallery--3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; }
.rx-gallery--3 .rx-gallery-main { grid-row: span 2; }
.rx-gallery-photo { border-radius: 12px; overflow: hidden; min-height: 0; }
.rx-gallery-main { border-radius: 14px; }
.rx-single-line { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.rx-single-line .rx-price { margin-top: 0; flex: none; }
.rx-single-verdict { margin-top: 14px; padding-top: 14px; border-top: 1px solid #f8e8f3; }
.rx-single-verdict .rx-yn-labels { margin-top: 12px; }

/* Results: Back, the title and Refresh share one row. */
.app > .header.results-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  column-gap: 8px;
  padding-top: 14px;
}
.results-header .results-back { position: static; grid-row: 1; grid-column: 1; justify-self: start; }
.results-header .logo { grid-row: 1; grid-column: 2; font-size: 17px; white-space: nowrap; }
.results-header .results-refresh { position: static; grid-row: 1; grid-column: 3; justify-self: end; }

/* Wizard: product photos open bigger on tap */
.item-meta-preview .meta-thumb, .photo-tile img, img.item-photo-thumb { cursor: zoom-in; }

/* ===== Plans, account and sign-in ===== */

.btn-danger { background: #dc2626; color: #fff; }
.btn-danger:hover { background: #b91c1c; }

/* Sign-in dialog */
.signin-back { display: block; margin: 12px auto 0; }
.signin-error { margin-top: 12px; font-size: 13px; color: #dc2626; text-align: center; }

/* Plans page */
.plans-page { padding-bottom: 32px; }
.plans-hero { text-align: center; padding: 8px 0 16px; }
.plans-emoji { font-size: 44px; line-height: 1; }
.plans-title { margin: 10px 0 6px; font-size: 22px; font-weight: 800; color: var(--text); }
.plans-sub { font-size: 14.5px; line-height: 1.45; color: var(--text-muted); }
.plan-options { display: flex; flex-direction: column; gap: 10px; }
.plan-option {
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 16px; border-radius: 16px; border: 2px solid var(--border); background: #fff;
  text-align: left; cursor: pointer; font: inherit; color: inherit;
}
.plan-option.selected { border-color: var(--pink); box-shadow: 0 6px 18px rgba(236, 72, 153, 0.15); }
.plan-radio { width: 20px; height: 20px; flex: none; border-radius: 50%; border: 2px solid #d8c9ea; }
.plan-option.selected .plan-radio { border: 6px solid var(--pink); }
.plan-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.plan-name { font-size: 16px; font-weight: 700; }
.plan-note { font-size: 13px; color: var(--text-muted); }
.plan-price { font-size: 18px; font-weight: 800; white-space: nowrap; }
.plan-price small { font-size: 12px; font-weight: 500; color: var(--text-muted); }
.plan-badge {
  position: absolute; top: -10px; right: 14px; padding: 2px 8px; border-radius: 10px;
  background: linear-gradient(135deg, var(--pink), var(--purple)); color: #fff; font-size: 11px; font-weight: 700;
}
.plans-cancel-note { margin: 14px 2px 16px; font-size: 13px; line-height: 1.45; color: var(--text-muted); }
.pay-buttons { display: flex; flex-direction: column; gap: 10px; }
.pay-btn {
  display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; height: 50px;
  border-radius: 12px; border: 0; font: inherit; font-size: 19px; font-weight: 600; cursor: pointer;
}
.pay-apple { background: #000; color: #fff; }
.pay-google { background: #fff; color: #3c4043; border: 1.5px solid #dadce0; }
.pay-g {
  font-weight: 700;
  background: conic-gradient(from -45deg, #ea4335 0 25%, #4285f4 0 50%, #34a853 0 75%, #fbbc05 0);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.pay-paypal { background: #ffc439; font-style: italic; font-weight: 800; }
.pay-pp { color: #003087; }
.pay-pal { color: #009cde; margin-left: -6px; }
.plans-test-note { margin-top: 10px; text-align: center; font-size: 12px; color: var(--text-muted); }
.plans-onplan { margin: 0 0 12px; font-size: 14.5px; line-height: 1.45; color: var(--text); }
#onPlanCard .btn + .btn { margin-top: 10px; }
.plans-test { margin-top: 28px; padding-top: 16px; border-top: 1px dashed #e5d4f5; text-align: center; }

/* Account page */
.acct-card { padding: 18px; }
.acct-label { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--text-muted); }
.acct-email { margin-top: 4px; font-size: 16px; font-weight: 600; color: var(--text); word-break: break-all; }
.acct-name { margin-top: 2px; font-size: 14px; color: var(--text-muted); }
.acct-plan { margin: 6px 0 2px; font-size: 20px; font-weight: 800; color: var(--text); }
.acct-plan-sub { font-size: 14.5px; color: var(--text); }
.acct-meter { margin-top: 10px; height: 8px; border-radius: 4px; background: #fbe5f1; overflow: hidden; }
.acct-meter-fill { height: 100%; background: linear-gradient(90deg, var(--pink), var(--purple)); border-radius: 4px; }
/* Links styled as buttons: wrapped text centered, like a real button */
a.btn { text-align: center; }
.acct-pack { margin-top: 14px; }
/* Test version's "released soon" page */
.soon-card { display: flex; flex-direction: column; gap: 14px; }
.soon-consent { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; line-height: 1.45; color: var(--text); cursor: pointer; }
.soon-consent input { width: 22px; height: 22px; margin: 1px 0 0; flex-shrink: 0; accent-color: var(--purple); }
.soon-consent b { overflow-wrap: anywhere; }
.soon-saved { margin: 0; font-size: 14px; color: #15803d; text-align: center; }
.acct-meter-pack { background: #e6f6ee; }
.acct-meter-pack .acct-meter-fill { background: linear-gradient(90deg, #22c55e, #14b8a6); }
.acct-plan-detail { margin-top: 10px; font-size: 13px; line-height: 1.45; color: var(--text-muted); }
.acct-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.acct-actions .hidden { display: none !important; }
.acct-cancel { align-self: center; color: #dc2626; }
.acct-confirm { margin-top: 14px; padding: 14px; border-radius: 12px; background: #fff5f5; border: 1px solid #fecaca; }
.acct-confirm p { font-size: 14px; line-height: 1.45; color: var(--text); margin: 0 0 12px; }
.acct-confirm-row { display: flex; gap: 10px; }
.acct-confirm-row .btn { flex: 1; }
.acct-signout { margin-top: 4px; }
.profile-plan-link { margin-top: 10px; }
/* No plans in the test version, so nothing to link to. */
body.test-version .profile-plan-link { display: none; }

/* The test version marks itself on every page */
.test-version-mark {
  position: fixed; top: max(6px, env(safe-area-inset-top)); left: 50%; transform: translateX(-50%);
  z-index: 2000; padding: 2px 10px; border-radius: 10px; background: #f59e0b; color: #fff;
  font-size: 11px; font-weight: 800; letter-spacing: .06em; pointer-events: none;
}

/* Real app: a page waiting on sign-in shows nothing behind the dialog */
body.signin-gated .app, body.signin-gated .tab-bar { visibility: hidden; }
/* Profile dialog, signed in: the email is the sign-in, changed on the account page */
.field-readonly { background: #f6f3fa !important; color: var(--text-muted) !important; }
.change-email-link { display: inline-block; margin-top: 6px; font-size: 13px; font-weight: 600; color: var(--purple-dark); }
.acct-change-email { margin-top: 8px; padding: 0; }
.acct-email-change { margin-top: 14px; padding-top: 14px; border-top: 1px solid #f3e8ff; }
.acct-email-change .btn-link { display: block; margin: 10px auto 0; }

/* Plans page "Not now", and the My picks banner after it */
.plans-not-now { display: block; margin: 18px auto 0; font-size: 14px; }
.plans-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-bottom: 12px; padding: 12px 14px; border-radius: 12px;
  background: #fff7ed; border: 1px solid #fed7aa; font-size: 14px; color: var(--text);
}
.onepage-head { display: flex; justify-content: flex-end; margin-bottom: 8px; }

/* Plans page: the extra request pack */
.pack-card { margin-top: 4px; }
.pack-title { font-size: 17px; font-weight: 800; color: var(--text); margin: 0 0 6px; }
.pack-sub { font-size: 14.5px; line-height: 1.45; color: var(--text-muted); margin: 0 0 14px; }
