*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --accent: #1f9d55;
  --accent-dark: #167c43;
  --accent-soft: #eaf7ef;
  --accent-border: #b7e4c7;
  --bg-outer: #e5e7eb;
  --bg-page: #f4f5f7;
  --bg-card: #ffffff;
  --text-main: #111827;
  --text-sub: #4b5563;
  --text-muted: #6b7280;
  --border: #e5e7eb;
  --border-strong: #d1d5db;
  --warn-bg: #fef3c7;
  --warn-text: #92400e;
  --danger-text: #dc2626;
  --danger-border: #fecaca;
  --danger-bg: #fef2f2;
  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-pill: 999px;
}

html,
body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-outer);
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font-family: inherit;
  font-size: inherit;
}

/* Mobile 390px centered shell */
.app-shell {
  width: 100%;
  max-width: 390px;
  min-height: 100vh;
  margin: 0 auto;
  background-color: var(--bg-page);
  position: relative;
  padding-bottom: 84px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.app-shell.no-tabbar {
  padding-bottom: 32px;
}

/* Top App Bar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 54px;
  padding: 0 16px;
  background-color: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.topbar-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-left: -6px;
  border-radius: 8px;
  font-size: 18px;
  color: var(--text-sub);
}

.topbar-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background-color: var(--accent);
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.topbar-meta {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

/* Page content */
.content {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Cards */
.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
}

.card-muted {
  background-color: #f9fafb;
  opacity: 0.78;
}

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

.section-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.section-sub {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}

.badge-accent {
  background-color: var(--accent-soft);
  color: var(--accent-dark);
}

.badge-gray {
  background-color: #f3f4f6;
  color: var(--text-sub);
}

.badge-warn {
  background-color: var(--warn-bg);
  color: var(--warn-text);
}

.badge-req {
  background-color: var(--accent-soft);
  color: var(--accent-dark);
  border: 1px solid var(--accent-border);
}

.badge-opt {
  background-color: #f3f4f6;
  color: var(--text-muted);
}

/* Chips */
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 11px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong);
  background-color: #ffffff;
  color: var(--text-sub);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
}

.chip-selected {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  font-weight: 600;
}

.chip-soft {
  background-color: #f3f4f6;
  border-color: #e5e7eb;
  color: var(--text-sub);
  font-size: 12px;
  padding: 4px 10px;
}

.chip-remove {
  font-size: 13px;
  color: var(--text-muted);
  margin-left: 2px;
}

.chip-add {
  border-style: dashed;
  color: var(--accent-dark);
  border-color: var(--accent-border);
  background-color: var(--accent-soft);
  font-size: 12px;
  padding: 4px 10px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 16px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
}

.btn-full {
  width: 100%;
}

.btn-primary {
  background-color: var(--accent);
  color: #ffffff;
}

.btn-outline {
  background-color: #ffffff;
  border-color: var(--border-strong);
  color: var(--text-main);
}

.btn-accent-outline {
  background-color: var(--accent-soft);
  border-color: var(--accent-border);
  color: var(--accent-dark);
}

.btn-danger-outline {
  background-color: #ffffff;
  border-color: var(--danger-border);
  color: var(--danger-text);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 8px;
}

.btn-google {
  width: 100%;
  background-color: #ffffff;
  border: 1px solid var(--border-strong);
  color: var(--text-main);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

/* Forms */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field + .field {
  margin-top: 12px;
}

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

.field-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

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

.input,
.select {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  background-color: #ffffff;
  color: var(--text-main);
  font-size: 14px;
}

.input-readonly {
  background-color: #f3f4f6;
  color: var(--text-sub);
  border-color: var(--border);
}

.row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  align-items: start;
}
.row-2 > .field { min-width: 0; margin-top: 0; }
.req { color: #dc2626; font-weight: 700; }

.range-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}

.range-sep {
  color: var(--text-muted);
  font-weight: 600;
}

.chip-input-box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  background-color: #ffffff;
}

.chip-input-inline {
  border: none;
  outline: none;
  flex: 1;
  min-width: 110px;
  font-size: 13px;
  padding: 4px 2px;
  background: transparent;
}

/* Toggle Switch (CSS only) */
.switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

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

.slider {
  position: absolute;
  inset: 0;
  background-color: #d1d5db;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.slider::before {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  top: 3px;
  background-color: #ffffff;
  border-radius: 50%;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
  transition: transform 0.15s ease;
}

.switch input:checked + .slider {
  background-color: var(--accent);
}

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

/* Segmented Tabs */
.tabs {
  display: flex;
  background-color: #e5e7eb;
  padding: 3px;
  border-radius: var(--radius-md);
  gap: 3px;
}

.tab-item {
  flex: 1;
  text-align: center;
  padding: 8px 6px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-sub);
}

.tab-active {
  background-color: #ffffff;
  color: var(--accent-dark);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

/* Bottom Tab Bar */
.tabbar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 390px;
  height: 64px;
  background-color: var(--bg-card);
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  z-index: 30;
}

.tabbar-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
}

.tabbar-link svg {
  width: 21px;
  height: 21px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tabbar-link.active {
  color: var(--accent);
  font-weight: 700;
}

.home-steps { margin-bottom: 28px; }
.home-step-card { margin-bottom: 0; }
.home-step-card h2 { margin: 6px 0 18px; }
.home-step-done { padding: 8px 4px; color: var(--text-muted); font-size: 13px; }
.home-listings-heading { display: flex; align-items: center; justify-content: space-between; margin: 8px 0 12px; }
.home-listings-heading h2 { margin: 0; font-size: 18px; }

/* Specific helper layouts */
.hero-box {
  text-align: center;
  padding: 20px 16px 18px;
}

.hero-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 10px;
  border-radius: 14px;
  background-color: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.hero-desc {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--text-sub);
}

.divider-text {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-size: 12px;
  margin: 2px 0;
}

.divider-text::before,
.divider-text::after {
  content: "";
  flex: 1;
  height: 1px;
  background-color: var(--border);
}

.notice-box {
  background-color: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent-dark);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.45;
}

.note-muted {
  margin: 10px 0 0;
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

/* Target card */
.target-cat {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-dark);
  margin-bottom: 3px;
}

.target-title {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
}

.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.meta-pill {
  background-color: #f3f4f6;
  color: var(--text-sub);
  font-size: 12px;
  padding: 3px 8px;
  border-radius: 6px;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  margin-top: 10px;
  border-top: 1px solid var(--border);
}

.link-action {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-dark);
}

/* Sub-category group */
.sub-group {
  padding-top: 10px;
  margin-top: 10px;
  border-top: 1px solid var(--border);
}

.sub-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-sub);
  margin-bottom: 6px;
}

.suggest-box {
  margin-top: 6px;
  padding: 8px 10px;
  background-color: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.suggest-title {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 5px;
}

/* Notify slots */
.slot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.slot-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 6px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-strong);
  background-color: #ffffff;
  color: var(--text-sub);
  font-size: 14px;
  font-weight: 600;
}

.slot-btn span {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 2px;
}

.slot-btn.on {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
}

.slot-btn.on span {
  color: #e2f5ea;
}

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

.channel-row + .channel-row {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.channel-info h3 {
  margin: 0 0 3px;
  font-size: 14px;
  font-weight: 700;
}

.topic-box {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  padding: 5px 10px;
  background-color: #f3f4f6;
  border-radius: 6px;
  font-size: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--text-main);
}

/* Results listing */
.listing-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.listing-badges {
  display: flex;
  align-items: center;
  gap: 6px;
}

.listing-time {
  font-size: 11px;
  color: var(--text-muted);
}

.listing-title {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-main);
}

.listing-price {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.price-old {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: line-through;
}

.price-new {
  color: var(--accent-dark);
}

/* Size recommendation rows */
.size-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.size-model {
  min-width: 0;
  flex: 1;
}

.size-model-name {
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.size-model-sub {
  margin: 0 0 6px;
  font-size: 12px;
  color: var(--text-muted);
}

.size-rec {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-dark);
  background-color: var(--accent-soft);
  padding: 3px 9px;
  border-radius: 6px;
}

.size-rec span {
  font-weight: 500;
  font-size: 12px;
  color: var(--text-sub);
}

/* Admin rows */
.admin-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 12px;
}

.admin-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.admin-name {
  font-size: 15px;
  font-weight: 700;
}

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

.btn-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 0;
}

.member-row + .member-row {
  border-top: 1px solid var(--border);
}

.member-main {
  min-width: 0;
}

.member-name {
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.member-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Interactive enhancements & mockup utilities */
.chip,
.tab-item,
.slot-btn,
.topbar-back,
.link-action {
  cursor: pointer;
}

.chip-remove {
  cursor: pointer;
  background: none;
  border: none;
  padding: 0 2px;
  font-size: 13px;
  line-height: 1;
}

.card-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.link-danger {
  font-size: 13px;
  font-weight: 600;
  color: var(--danger-text);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

.field-error {
  margin: 6px 0 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--danger-text);
}

.mockup-note {
  margin: 0;
  padding: 4px 14px 14px;
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
}

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

.index-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 13px 15px;
  transition: border-color 0.15s ease;
}

.index-card:hover {
  border-color: var(--accent-border);
}

.index-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background-color: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

.index-info {
  flex: 1;
  min-width: 0;
}

.index-title {
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.index-desc {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.index-arrow {
  color: var(--text-muted);
  font-size: 16px;
  flex-shrink: 0;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 76px;
  transform: translateX(-50%) translateY(12px);
  max-width: 358px;
  width: max-content;
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  background-color: rgba(17, 24, 39, 0.92);
  color: #ffffff;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 60;
}

.toast.toast-no-tabbar {
  bottom: 24px;
}

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

/* 서비스 이름·로고 자리 */
.hero-sub { margin: -4px 0 8px; font-size: 13px; color: #6b7280; text-align: center; }
.topbar-sub { font-size: 12px; font-weight: 400; color: #6b7280; margin-left: 4px; }
.logo-slot-sm { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin-right: 8px; border: 1.5px dashed #1f9d55; border-radius: 8px; font-size: 10px; color: #1f9d55; }

/* 검색 조건 모바일 화면 */
.targets-heading,.card-footer,.card-actions,.section-header,.range-row{display:flex;align-items:center;justify-content:space-between;gap:10px}
.targets-heading{margin-bottom:12px}.targets-heading h2{margin:0}.target-cat{color:#64748b;font-size:13px}.meta-line,.chip-row{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0}.meta-pill,.chip{display:inline-flex;align-items:center;border-radius:999px;padding:6px 10px;background:#f1f5f9;font-size:13px}.chip-selected{background:#dcfce7;color:#166534}.chip input{accent-color:#15803d}.sub-group{margin-top:16px;padding-top:12px;border-top:1px solid #e5e7eb}.sub-label{font-size:13px;font-weight:600;margin:8px 0}.sub-options[hidden]{display:none}.range-row>*{min-width:0;flex:1}.exclude-inputs{display:grid;gap:8px}.card-actions form,.card-footer form{margin:0}.link-danger{color:#dc2626;background:none;border:0}.link-action{color:#15803d;background:none;border:0;text-decoration:none;padding:6px}.field-hint{font-size:12px;color:#64748b}.btn-full{width:100%;margin:12px 0 24px}.error{color:#b91c1c}.app-shell{padding-bottom:72px}.bottom{z-index:10}
.dev-badge{background:#dc2626;color:#fff;padding:4px 8px;border-radius:99px;font-size:12px}.chip-input-inline{min-width:120px;flex:1;border:0;outline:0;padding:6px}.chip-input-box{display:flex;flex-wrap:wrap;align-items:center;gap:6px}.chip-input-box .chip button{border:0;background:transparent;color:inherit;margin-left:5px}

/* 칩 선택 표시: 네이티브 라디오/체크박스는 숨기고 선택된 칩을 색으로 표시 */
.chip input { position: absolute; opacity: 0; width: 0; height: 0; }
.chip { position: relative; cursor: pointer; }
.chip:has(input:checked) { background: #dcfce7; color: #166534; font-weight: 600; box-shadow: inset 0 0 0 1.5px #1f9d55; }
.chip-row[hidden], .sub-options[hidden] { display: none; }
.content > .topbar-back { position: static; display: inline-block; width: auto; margin: 0 0 10px; white-space: nowrap; }

/* Real service screens */
.app-shell { max-width: 430px; padding-bottom: calc(88px + env(safe-area-inset-bottom)); }
.no-tabbar { padding-bottom: 32px; }
.topbar-right { display: flex; align-items: center; gap: 8px; white-space: nowrap; font-size: 12px; color: var(--accent-dark); }
.service-name { font-size: 14px; font-weight: 800; white-space: nowrap; }
.topbar-title { font-size: 15px; }
.logo-slot-sm { flex: 0 0 32px; margin-right: 0; }
.topbar-back { flex: 0 0 32px; margin: 0; }
.content > * { min-width: 0; max-width: 100%; }
.field { min-width: 0; }
.field .input, .field .select { margin-top: 3px; }
.toggle-line { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.size-results-form { display: flex; flex-direction: column; gap: 10px; }
.size-result-row { display: flex; flex-direction: column; gap: 7px; }
.size-result-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.size-choice-label { display: inline-flex; align-items: center; gap: 7px; color: var(--text-sub); font-size: 12px; white-space: nowrap; }
.size-choice { width: auto; min-width: 86px; height: 36px; padding: 0 8px; }
.home-step-action { display: flex; width: 100%; min-height: 44px; }
.btn-full { min-height: 44px; }
.size-result-row h3, .size-result-row p { margin: 0; }
.size-row-controls { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px; }
.size-result-row .field-hint { color: var(--text-sub); }
.notice, .error { padding: 9px 11px; border-radius: 9px; background: var(--danger-bg); color: var(--danger-text); }
.exclude-word { gap: 6px; }
.tabbar { max-width: 430px; height: calc(64px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); }
.tabbar-link { gap: 1px; }
.tabbar-link span:first-child { font-size: 17px; line-height: 1.15; }
@media (max-width: 360px) { .topbar { padding: 0 10px; gap: 4px; } .topbar-left { gap: 5px; } .topbar-title { font-size: 13px; } .content { padding-right: 10px; padding-left: 10px; } }

/* 브랜드 로고 */
.logo-icon { width: 32px; height: 32px; border-radius: 8px; flex: 0 0 32px; display: block; }
.logo-horizontal { display: block; width: 240px; max-width: 80%; height: auto; margin: 0 auto 8px; }
.logo-horizontal-sm { width: 160px; margin: 0 auto 12px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* 홈 단계 카드: 크게 */
.home-step-card { padding: 28px 22px 24px; text-align: center; }
.home-step-image { display: block; width: 100%; max-width: 300px; height: auto; margin: 0 auto 8px; }
.home-step-card h2 { margin: 8px 0 24px; font-size: 22px; line-height: 1.4; }
.home-step-card .home-step-action { min-height: 56px; font-size: 18px; }

/* 추천 결과 카드: 1줄 모델명 + 추가, 2줄 추천 사이즈 + 키 범위 */
.size-result-row { gap: 12px; padding: 16px; }
.size-result-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.size-result-top .size-model-name { flex: 1; min-width: 0; margin: 0; font-size: 17px; text-align: left; overflow-wrap: anywhere; }
.size-add { flex: 0 0 auto; min-width: 64px; min-height: 40px; }
.size-result-bottom { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.size-choice-label { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-sub); }
.select-wrap { position: relative; display: inline-block; }
.select-wrap::after { content: ""; position: absolute; right: 12px; top: 50%; width: 7px; height: 7px; margin-top: -6px; border-right: 2px solid #1f9d55; border-bottom: 2px solid #1f9d55; transform: rotate(45deg); pointer-events: none; }
.select-wrap .size-choice { appearance: none; -webkit-appearance: none; width: 108px; min-width: 108px; height: 44px; padding: 0 30px 0 14px; border: 1.5px solid #cfe8d8; border-radius: 12px; background: #f4fbf7; color: #14532d; font-size: 16px; font-weight: 700; text-align: center; text-align-last: center; }
.select-wrap .size-choice:focus { outline: none; border-color: #1f9d55; box-shadow: 0 0 0 3px rgba(31, 157, 85, 0.2); }
.size-range { color: var(--text-sub); font-size: 14px; }

/* 추천 탭: 단계 흐름 */
.wizard-nav { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 12px; }
.wizard-arrow { width: 44px; height: 44px; border: 1.5px solid #cfe8d8; border-radius: 50%; background: #fff; color: #1f9d55; font-size: 26px; line-height: 1; cursor: pointer; }
.wizard-arrow:disabled { opacity: 0.35; cursor: default; }
.wizard-dots { display: flex; flex: 1; justify-content: center; gap: 8px; margin: 0; padding: 0; list-style: none; font-size: 12px; color: var(--text-sub); }
.wizard-dots li { display: flex; align-items: center; gap: 4px; cursor: pointer; }
.wizard-dots li span { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: #e5e7eb; color: #555; font-weight: 700; }
.wizard-dots li.active { color: #14532d; font-weight: 700; }
.wizard-dots li.active span, .wizard-dots li.done span { background: #1f9d55; color: #fff; }
.wizard-js .wizard-step[hidden], .wizard-js .wizard-form-card[hidden] { display: none; }
.wizard-actions { display: flex; gap: 10px; margin-top: 14px; }
.wizard-actions .btn { flex: 1; min-height: 48px; }
.wizard-clear { margin-top: 16px; }
.wizard:not(.wizard-js) .wizard-nav, .wizard:not(.wizard-js) .wizard-go { display: none; }

.size-added { background: #f1f5f9; color: #64748b; border: 1px solid #e2e8f0; cursor: default; }


/* 홈: 내 검색 대상 */
.home-targets .home-listings-heading { margin: 0 0 8px; }
.home-target-list { margin: 0; padding: 0; list-style: none; }
.home-target-list li { display: flex; flex-direction: column; gap: 2px; padding: 10px 0; border-top: 1px solid #eef0f3; }
.home-target-list li:first-child { border-top: 0; }
.home-target-list li span { color: var(--text-sub); font-size: 13px; }
.home-target-list li.is-off { opacity: 0.55; }

/* 4단계 사이즈 추천 마법사 모바일 배치 */
.wizard-dots { gap: 3px; font-size: 10px; }
.wizard-dots li { gap: 2px; white-space: nowrap; }
.wizard-dots li span { width: 20px; height: 20px; flex: 0 0 20px; }
.wizard .field { min-width: 0; }
.wizard-step[data-step="3"] > h2 { margin-bottom: 14px; }
.wizard-step[data-step="3"] .chip-input-box { min-height: 48px; padding: 6px 9px; border: 1px solid var(--border, #d1d5db); border-radius: 10px; }
.wizard-step[data-step="3"] .chip-input-box .chip { max-width: 100%; overflow-wrap: anywhere; }
@media (max-width: 390px) {
  .wizard-nav { gap: 3px; }
  .wizard-arrow { width: 36px; height: 36px; flex: 0 0 36px; }
  .wizard-dots { gap: 1px; font-size: 9px; }
  .wizard-dots li span { width: 18px; height: 18px; flex-basis: 18px; }
}
.tabbar { grid-template-columns: repeat(4, 1fr); }
.wizard-dots { gap: 4px; font-size: 11px; }
.wizard-dots li { flex-direction: column; text-align: center; gap: 2px; }

/* 추천 결과 브랜드 그룹: 브랜드 헤더는 진한 초록, 본문 바탕은 연한 초록, 모델 카드는 흰색 */
.brand-group { border-radius: 14px; background: var(--accent-soft); border: 1px solid var(--accent-border); overflow: hidden; }
.brand-group-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; background: var(--accent-dark); color: #fff; }
.brand-group-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.brand-group-name { font-weight: 800; font-size: 17px; overflow-wrap: anywhere; }
.brand-group-count { font-weight: 500; font-size: 13px; opacity: .85; white-space: nowrap; }
.brand-add-all { flex: none; background: #fff; color: var(--accent-dark); border: 1px solid #fff; font-weight: 700; }
.brand-group-body { display: flex; flex-direction: column; gap: 10px; padding: 12px; }
.brand-group-body .size-result-row { background: var(--bg-card); box-shadow: none; border: 1px solid var(--border); }
