/* Review-Only · 맥킨지 + Review AI 통합 토큰 v0.1 */

:root {
  --ink: #0A0A0A;
  --ink-2: #1a1a1a;
  --paper: #F5F3EE;
  --neon: #00E640;
  --neon-dark: #00B832;
  --mute: #595959; /* P2-13: 6B6B6B → 595959 (5.5:1+ on paper) */
  --line: #E5E5E0;
  --surface: #FFFFFF;
  --white: #ffffff;
  --coral: #FF6B6B;
  --warn: #F5A623;
  --warn-bg: rgba(245, 166, 35, 0.1);
  --warn-fg: #B86E00;
  --warn-border: rgba(245, 166, 35, 0.3);

  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 24px; --sp-6: 32px; --sp-7: 48px; --sp-8: 64px;

  --r-sm: 6px; --r-md: 8px; --r-lg: 12px; --r-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,.06);
  --shadow-cta: 0 4px 12px rgba(0,230,64,.3);
}

/* === P0-08 · :focus-visible 글로벌 (WCAG 2.4.7) === */
*:focus-visible {
  outline: 2px solid var(--neon);
  outline-offset: 2px;
  border-radius: 4px;
}
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.rs-item:focus-visible,
.rs-cta-signup:focus-visible,
.rs-cta-login:focus-visible,
.rs-cta-meet:focus-visible,
.rs-cta-kakao:focus-visible,
.rs-promo-cta:focus-visible,
.rs-logout:focus-visible,
.rs-mobile-toggle:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--neon);
  outline-offset: 2px;
}
.input:focus-visible {
  border-color: var(--neon);
  box-shadow: 0 0 0 3px rgba(0,230,64,0.2);
  outline: 0;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--paper); color: var(--ink); }
body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Noto Sans KR', sans-serif;
  font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 var(--sp-4); }
.container-narrow { max-width: 720px; margin: 0 auto; padding: 0 var(--sp-4); }

/* === Typography === */
.h-hero { font-size: 32px; font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
.h-1 { font-size: 28px; font-weight: 800; line-height: 1.15; letter-spacing: -.015em; }
.h-2 { font-size: 22px; font-weight: 700; line-height: 1.25; }
.h-3 { font-size: 18px; font-weight: 700; line-height: 1.35; }
.t-body-lg { font-size: 18px; line-height: 1.5; }
.t-body { font-size: 16px; line-height: 1.6; }
.t-cap { font-size: 14px; line-height: 1.5; color: var(--mute); }
.t-micro { font-size: 12px; line-height: 1.4; color: var(--mute); text-transform: uppercase; letter-spacing: .08em; }
.t-data { font-family: 'JetBrains Mono', ui-monospace, Menlo, monospace; font-weight: 400; }
.t-data-b { font-family: 'JetBrains Mono', ui-monospace, Menlo, monospace; font-weight: 700; }
.t-em { font-family: 'Pretendard', 'Noto Sans KR', sans-serif; font-weight: 300; font-style: normal; }
.t-mute { color: var(--mute); }

@media (min-width: 768px) {
  .h-hero { font-size: 44px; }
  .h-1 { font-size: 36px; }
}
@media (min-width: 1024px) {
  .h-hero { font-size: 56px; }
  .h-1 { font-size: 40px; }
}

/* === Header === */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245,243,238,.92); backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header__inner { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; letter-spacing: -.01em; }
.logo__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--neon); animation: pulse 2.2s infinite; }
.logo__powered { font-size: 11px; color: var(--mute); margin-left: 8px; }
.header__right { display: flex; align-items: center; gap: 12px; }

/* v0.13 · 헤더 단순화: 사이드바로 메뉴 일원화. promo 배너만 유지 (비로그인) / 로그인 시 빈 헤더 */
.header--minimal { height: 0; min-height: 0; padding: 0; border-bottom: 0; background: transparent; }
.header--minimal:empty { display: none; }
.header--promo { background: var(--ink); border-bottom: 0; }
.header__promo { display: flex; align-items: center; justify-content: center; gap: 12px; height: 44px; color: var(--white); font-size: 13px; }
.header__promo-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--neon); animation: pulse 2.2s infinite; }
.header__promo-text { color: var(--white); }
.header__promo-text b { color: var(--neon); font-weight: 800; }
.header__promo-cta { color: var(--neon); font-weight: 700; text-decoration: underline; }
.header__promo-cta:hover { opacity: .85; }
@media (max-width: 768px) {
  .header__promo { font-size: 12px; gap: 8px; padding: 0 12px; }
  .header__promo-cta { white-space: nowrap; }
}

@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* === Buttons === */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 14px 22px; font-size: 15px; font-weight: 700; border-radius: var(--r-md); border: 0; transition: box-shadow .15s ease, transform .05s ease; }
.btn-cta  { background: var(--neon); color: var(--ink); font-weight: 800; }
.btn-cta:hover  { box-shadow: var(--shadow-cta); }
.btn-cta:active { transform: translateY(1px); }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--surface); }
.btn-lg { padding: 18px 28px; font-size: 16px; }
.btn-block { width: 100%; justify-content: center; }
/* P2-02 · :disabled !important 제거 → specificity 상승 (.btn[disabled].btn) */
.btn[disabled],
.btn:disabled,
button[disabled].btn,
.btn-cta:disabled,
.btn-dark:disabled,
.btn-ghost:disabled {
  background: #ccc;
  color: var(--white);
  cursor: not-allowed;
  box-shadow: none;
}

/* === Inputs === */
.input { width: 100%; height: 56px; padding: 0 16px; font-size: 16px; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--r-md); font-family: inherit; transition: border-color .15s ease; }
.input:focus { outline: 0; border-color: var(--ink); }
.input.error { border-color: var(--coral); }
.input-label { display: block; font-size: 13px; color: var(--mute); margin-bottom: 6px; font-weight: 500; }
.input-help { font-size: 13px; color: var(--mute); margin-top: 6px; }
.input-error { font-size: 13px; color: var(--coral); margin-top: 6px; }
.field { margin-bottom: var(--sp-4); }

/* === Card === */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--sp-5); }
.card-elev { box-shadow: var(--shadow-md); border-color: transparent; }
.card-flat { background: transparent; border: 0; padding: 0; }

/* === Layout === */
.section { padding: var(--sp-7) 0; }
.section-tight { padding: var(--sp-5) 0; }
.divider { height: 1px; background: var(--line); margin: var(--sp-5) 0; border: 0; }
.row { display: flex; gap: var(--sp-4); }
.col { flex: 1; }
.row-wrap { flex-wrap: wrap; }
@media (max-width: 768px) { .row-stack-mobile { flex-direction: column; } }

/* === Source link === */
.src { display: inline-flex; align-items: center; font-size: 12px; color: var(--mute); margin-left: 6px; vertical-align: middle; }
.src::after { content: ' ↗'; }
.src:hover { color: var(--ink); }

/* === Live counter === */
.live-stat { display: flex; align-items: baseline; gap: 8px; font-family: 'JetBrains Mono', monospace; }
.live-stat .num { font-size: 22px; font-weight: 700; color: var(--ink); }
.live-stat .label { font-size: 13px; color: var(--mute); }
.live-stat::before { content: '●'; color: var(--neon); animation: pulse 2.2s infinite; font-size: 10px; }

/* === Progress === */
.progress { width: 100%; height: 8px; background: var(--line); border-radius: 4px; overflow: hidden; }
.progress-bar { height: 100%; background: var(--ink); transition: width .6s ease; }
.progress.success .progress-bar { background: var(--neon); }

/* === Badges === */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; font-size: 12px; color: var(--mute); background: var(--paper); border-radius: var(--r-pill); border: 1px solid var(--line); }
.badge-dark { background: var(--ink); color: var(--white); border-color: var(--ink); }
.badge-neon { background: var(--neon); color: var(--ink); border-color: var(--neon); font-weight: 700; }
/* P2-06 · --warn 토큰 활용 */
.badge-warn { background: var(--warn-bg); color: var(--warn-fg); border: 1px solid var(--warn-border); }

/* === Trust badges (payment) === */
.trust-row { display: flex; flex-wrap: wrap; gap: 10px; padding-top: var(--sp-5); border-top: 1px solid var(--line); margin-top: var(--sp-5); }

/* === Quote table === */
.qtable { width: 100%; border-collapse: collapse; font-family: 'JetBrains Mono', monospace; }
.qtable th, .qtable td { padding: 12px 16px; text-align: right; border-bottom: 1px solid var(--line); font-size: 14px; }
.qtable th { font-weight: 600; color: var(--mute); }
.qtable th:first-child, .qtable td:first-child { text-align: left; font-family: 'Pretendard', sans-serif; }
.qtable tr.discount td { color: var(--mute); }
/* P1-17 · discount는 긍정 가격 변화 → coral(에러 전용) 대신 dark green */
.qtable tr.discount td:last-child { color: var(--neon-dark); font-weight: 700; }
.qtable tr.total td { font-weight: 700; font-size: 18px; border-top: 2px solid var(--ink); border-bottom: 0; padding-top: 16px; }
.qtable tr.subtotal td { color: var(--mute); }

/* === Footer (v27 패턴 · 회사 정보 그대로 + 상품만 구매평 톤) === */
/* P2-02 · 중복 selector (.rv-footer__inner, .rv-footer__brand) 통합 */
.rv-footer { background: var(--ink); color: rgba(255,255,255,.65); padding: 56px 24px 32px; margin-top: var(--sp-8); font-size: 13px; }
.rv-footer__inner {
  max-width: 1200px; margin: 0 auto;
  display: grid;
  /* v0.6 SITEMAP 패턴 — 처음부터 그리드 정의 (이전 2fr/1fr/1fr → 1.4fr/1fr/1.2fr 머지) */
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 40px; padding-bottom: 32px; margin-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.rv-footer__brand {
  max-width: 420px;
  /* v0.16.0 왼쪽 정렬 머지 */
  text-align: left;
}
.rv-footer__name { display: flex; align-items: center; justify-content: flex-start; gap: 8px; color: var(--white); font-weight: 800; font-size: 16px; margin-bottom: 14px; }
.rv-footer__dot { display: inline-block; width: 18px; height: 18px; border: 2px solid var(--neon); border-radius: 50%; }
.rv-footer__tag { color: var(--white); font-family: 'Pretendard', 'Noto Sans KR', sans-serif; font-style: normal; font-weight: 300; font-size: 18px; line-height: 1.3; margin-bottom: 12px; text-align: left; }
.rv-footer__desc { color: rgba(255,255,255,.7); line-height: 1.55; margin-bottom: 12px; }
.rv-footer__desc b { color: var(--neon); font-weight: 700; }
.rv-footer__powered { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: rgba(255,255,255,.4); line-height: 1.5; text-align: left; }
.rv-footer__col h4 { font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: rgba(255,255,255,.4); margin-bottom: 14px; font-weight: 700; }
.rv-footer__col a { display: block; color: rgba(255,255,255,.7); text-decoration: none; font-size: 13px; padding: 6px 0; line-height: 1.4; }
.rv-footer__col a[href]:hover { color: var(--white); }
.rv-footer__bot { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: rgba(255,255,255,.4); font-family: 'JetBrains Mono', monospace; flex-wrap: wrap; gap: 8px; }
.rv-footer__sitemap,
.rv-footer__company { text-align: left; }
.rv-footer__sitemap a, .rv-footer__company a {
  display: block; padding: 4px 0;
  color: rgba(255,255,255,.6); font-size: 13px;
  text-decoration: none; transition: color .15s;
}
.rv-footer__sitemap a:hover, .rv-footer__company a:hover { color: var(--neon); }
.rv-footer__company p {
  font-size: 13px; color: rgba(255,255,255,.5);
  padding: 4px 0; margin: 0; line-height: 1.5;
}
.rv-footer__bottom {
  max-width: 1200px; margin: 32px auto 0; padding: 16px 0 0;
  border-top: 1px solid rgba(255,255,255,.08);
  text-align: left; font-size: 12px;
  color: rgba(255,255,255,.4);
  font-family: 'JetBrains Mono', monospace;
}
@media (max-width: 860px) {
  /* P2-02 · !important 제거 → 동일 selector 내 단일 정의로 specificity 자연 우선 */
  .rv-footer__inner { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .rv-footer__bot { flex-direction: column; align-items: flex-start; }
}

/* P2-03 · legacy .footer dead CSS 삭제 (v0.6 이후 .rv-footer 일원화로 미사용 확인) */

/* === v0.16.0 · 예상 성과 변화 (lp-forecast · landing 의 Starter 베타 대체) === */
/* P2-04/P2-05/P2-07 · #fff→var(--white), #1a1a1a→var(--ink-2), --neon fallback 제거 */
.lp-forecast { padding: 56px 0; background: var(--ink); color: var(--white); }
.lp-forecast .forecast-eyebrow { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: var(--neon); text-transform: uppercase; letter-spacing: .08em; }
.lp-forecast .forecast-title { font-size: 26px; font-weight: 800; margin: 8px 0 28px; color: var(--white); line-height: 1.3; }
.lp-forecast .forecast-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.lp-forecast .forecast-card { padding: 22px; background: var(--ink-2); border-radius: 12px; border: 1px solid rgba(255,255,255,.08); }
.lp-forecast .fc-label { font-size: 11px; color: rgba(255,255,255,.6); margin-bottom: 6px; font-family: 'JetBrains Mono', monospace; letter-spacing: .04em; text-transform: uppercase; }
.lp-forecast .fc-value { font-size: 32px; font-weight: 800; color: var(--neon); margin-bottom: 10px; line-height: 1.1; }
.lp-forecast .fc-source { font-size: 11px; color: rgba(255,255,255,.5); line-height: 1.5; }
.lp-forecast .fc-source a { color: var(--neon); text-decoration: underline; }
.lp-forecast .forecast-note { margin-top: 20px; font-size: 12px; color: rgba(255,255,255,.5); line-height: 1.6; }
@media (max-width: 860px) {
  .lp-forecast .forecast-grid { grid-template-columns: repeat(2, 1fr); }
  .lp-forecast .fc-value { font-size: 26px; }
}
@media (max-width: 480px) {
  .lp-forecast .forecast-grid { grid-template-columns: 1fr; }
}

/* === v0.16.0 · 마이페이지 내 견적 섹션 (dashboard-quotes) === */
.dashboard-quotes { margin: 24px 0; padding: 24px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.dashboard-quotes .dq-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 16px; gap: 12px; flex-wrap: wrap; }
.dashboard-quotes .dq-head h2 { font-size: 18px; font-weight: 800; margin: 0; color: var(--ink); }
.dashboard-quotes .dq-count { font-family: 'JetBrains Mono', monospace; font-size: 13px; color: var(--mute); font-weight: 600; }
.dashboard-quotes .dq-empty { padding: 24px; text-align: center; color: var(--mute); border: 1px dashed var(--line); border-radius: 8px; }
.dashboard-quotes .dq-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 24px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.dashboard-quotes .dq-row:last-child { border-bottom: 0; }
.dashboard-quotes .dq-row-meta { display: flex; gap: 16px; align-items: baseline; flex-wrap: wrap; min-width: 0; }
.dashboard-quotes .dq-date { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--mute); }
.dashboard-quotes .dq-product { font-weight: 700; color: var(--ink); }
.dashboard-quotes .dq-market { font-size: 12px; color: var(--mute); }
.dashboard-quotes .dq-row-amount { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.dashboard-quotes .dq-total { font-family: 'JetBrains Mono', monospace; font-weight: 800; font-size: 16px; color: var(--ink); }
.dashboard-quotes .dq-status { font-size: 11px; padding: 3px 10px; border-radius: 999px; font-weight: 700; }
.dashboard-quotes .dq-status--pending { background: var(--paper); color: var(--mute); border: 1px solid var(--line); }
.dashboard-quotes .dq-status--paid { background: var(--neon); color: var(--ink); }
.dashboard-quotes .dq-row-actions { display: flex; gap: 8px; align-items: center; }
.dashboard-quotes .dq-row-actions .btn { padding: 8px 14px; font-size: 13px; border-radius: 8px; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-decoration: none; cursor: pointer; }
.dashboard-quotes .dq-row-actions .btn-cta { background: var(--neon); border-color: var(--neon); color: var(--ink); font-weight: 700; }
.dashboard-quotes .dq-row-actions .btn:hover { opacity: .92; }
@media (max-width: 768px) {
  .dashboard-quotes .dq-row { grid-template-columns: 1fr; gap: 12px; }
  .dashboard-quotes .dq-row-amount { align-items: flex-start; flex-direction: row; gap: 12px; }
  .dashboard-quotes .dq-row-actions { width: 100%; }
  .dashboard-quotes .dq-row-actions .btn { flex: 1; text-align: center; }
}

/* === 결제 후 프로세스 3카드 높이 통일 === */
.after-pay-guide .apg-grid,
.after-pay-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}
.after-pay-guide .apg-card,
.after-pay-grid > * {
  display: flex;
  flex-direction: column;
  height: 100%;
}
@media (max-width: 768px) {
  .after-pay-guide .apg-grid,
  .after-pay-grid { grid-template-columns: 1fr; }
}

/* === Toast === */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: var(--white); padding: 14px 22px; border-radius: var(--r-md); font-size: 14px; box-shadow: var(--shadow-md); z-index: 100; opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .25s ease; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(-4px); }

/* === Steps === */
.steps { display: flex; gap: var(--sp-2); align-items: center; padding: var(--sp-3) 0; flex-wrap: wrap; }
.step { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--mute); }
.step .num { width: 22px; height: 22px; border-radius: 50%; background: var(--line); color: var(--mute); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 12px; }
.step.done .num { background: var(--ink); color: var(--white); }
.step.curr .num { background: var(--neon); color: var(--ink); }
.step.curr { color: var(--ink); font-weight: 700; }
.step-sep { color: var(--line); }

/* === Steps mobile (6단계 가독성) === */
@media (max-width: 768px) {
  .steps { font-size: 11px; gap: 4px; }
  .step { gap: 4px; font-size: 11px; }
  .step .num { width: 20px; height: 20px; font-size: 11px; }
  .step span:not(.num) { display: none; }
  .step.curr span:not(.num) { display: inline; }
}

/* === Stat card grid === */
.stat-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: var(--sp-3); }
@media (min-width: 768px) { .stat-grid { grid-template-columns: repeat(4,1fr); } }
.stat { padding: var(--sp-4); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.stat .v { font-family: 'JetBrains Mono', monospace; font-size: 26px; font-weight: 700; color: var(--ink); line-height: 1.1; }
.stat .l { font-size: 12px; color: var(--mute); margin-top: 4px; }

/* === Hero specific === */
.hero { padding: var(--sp-7) 0 var(--sp-6); }
.hero .lead { font-size: 16px; color: var(--mute); margin-top: var(--sp-3); max-width: 540px; }
.hero-input { display: flex; gap: 8px; margin-top: var(--sp-5); }
.hero-input .input { flex: 1; height: 64px; font-size: 17px; }
.hero-input .btn { height: 64px; padding: 0 28px; }
@media (max-width: 600px) { .hero-input { flex-direction: column; } .hero-input .btn { width: 100%; } }

.brand-strip { display: flex; gap: 8px 18px; flex-wrap: wrap; margin-top: var(--sp-3); font-size: 13px; color: var(--mute); }
.brand-strip span { display: inline-flex; align-items: center; gap: 4px; }

/* === Demo banner === */
.demo-banner { background: var(--ink); color: var(--neon); text-align: center; padding: 8px 16px; font-size: 12px; font-family: 'JetBrains Mono', monospace; letter-spacing: .04em; }
.demo-banner b { color: var(--white); }

/* === Version label === */
.ver { position: fixed; right: 10px; bottom: 8px; font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--mute); opacity: .6; z-index: 99; }

/* === Stage table (campaign) === */
.stage-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: var(--sp-3); margin-top: var(--sp-4); }
@media (min-width: 768px) { .stage-grid { grid-template-columns: repeat(6,1fr); } }
.stage { padding: var(--sp-3); background: var(--paper); border-radius: var(--r-md); text-align: center; }
.stage .n { font-family: 'JetBrains Mono', monospace; font-size: 18px; font-weight: 700; }
.stage .l { font-size: 11px; color: var(--mute); margin-top: 2px; }
.stage.done { background: var(--ink); color: var(--white); }
.stage.done .l { color: rgba(255,255,255,.6); }
.stage.curr { background: var(--neon); color: var(--ink); }

/* === Reduced motion === */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ─────────────────────────────────────────────────
 * v0.11 좌측 사이드바 (모든 페이지 공통)
 * ─ 220px width · 데스크톱 fixed left
 * ─ 모바일 (<=768px) 햄버거 → 슬라이드인
 * ───────────────────────────────────────────────── */
.rv-sidebar {
  position: fixed; left: 0; top: 0; bottom: 0; z-index: 60;
  width: 220px;
  background: var(--ink); color: var(--white);
  display: flex; flex-direction: column;
  border-right: 1px solid rgba(255,255,255,.08);
  transition: transform .25s ease;
}
.rs-brand {
  padding: 20px 18px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.rs-logo {
  display: flex; align-items: center; gap: 8px;
  font-weight: 800; font-size: 17px; letter-spacing: -.01em;
  color: var(--white); text-decoration: none;
}
.rs-logo:hover { text-decoration: none; }
.rs-logo-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--neon); animation: pulse 2.2s infinite;
}
.rs-powered {
  font-size: 10.5px; color: rgba(255,255,255,.45);
  margin-top: 6px; letter-spacing: .02em;
  font-family: 'JetBrains Mono', monospace;
}
.rs-nav { flex: 1; padding: 12px 0; overflow-y: auto; }
.rs-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 18px;
  font-size: 14px; font-weight: 600;
  color: rgba(255,255,255,.78);
  border-left: 2px solid transparent;
  transition: background .15s, color .15s, border-left-color .15s;
  cursor: pointer;
}
.rs-item:hover {
  background: rgba(255,255,255,.04);
  color: var(--white); text-decoration: none;
}
.rs-item.active {
  background: rgba(0,230,64,.06);
  color: var(--neon);
  border-left-color: var(--neon);
}
.rs-icon {
  width: 18px; text-align: center;
  font-size: 14px; color: var(--neon);
  font-family: 'JetBrains Mono', monospace;
}
.rs-label { flex: 1; }
/* P2-02 · !important 제거 → selector specificity 상승 (.rs-item.rs-item--cta) */
.rs-item.rs-item--cta {
  background: var(--neon); color: var(--ink);
  margin: 4px 12px; border-radius: var(--r-md);
  padding: 12px 14px;
  border-left: 0;
}
.rs-item.rs-item--cta:hover { background: var(--neon); color: var(--ink); box-shadow: 0 4px 12px rgba(0,230,64,.4); }
.rs-item.rs-item--cta .rs-icon { color: var(--ink); }

.rs-foot {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 14px 16px;
}
.rs-user-name { font-size: 13px; font-weight: 700; color: var(--white); }
.rs-user-mail {
  font-size: 11px; color: rgba(255,255,255,.5);
  margin: 2px 0 8px;
  font-family: 'JetBrains Mono', monospace;
  word-break: break-all;
}
.rs-logout {
  background: transparent; border: 1px solid rgba(255,255,255,.18);
  color: rgba(255,255,255,.7); padding: 5px 10px;
  border-radius: var(--r-sm); font-size: 11px;
  cursor: pointer; transition: border-color .15s, color .15s;
}
.rs-logout:hover { border-color: var(--coral); color: var(--coral); }
/* Round 2 P0 · 2026-05-07 · 카카오만 연동 (회원가입 미완료) 상태 시각화 */
.rs-user--pending {
  border: 1px solid rgba(254, 229, 0, .3);
  border-radius: var(--r-sm);
  padding: 8px 10px;
  background: rgba(254, 229, 0, .05);
}
.rs-pending-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  font-size: 10px;
  font-weight: 700;
  background: #FEE500;
  color: #191919;
  border-radius: 3px;
  vertical-align: middle;
}
.rs-pending-cta {
  display: inline-block;
  font-size: 11px;
  color: var(--neon);
  font-weight: 700;
  text-decoration: underline;
  font-family: inherit;
}
.rs-pending-cta:hover { color: var(--white); }
.rs-user--guest .rs-guest-msg {
  font-size: 11.5px; color: rgba(255,255,255,.65);
  line-height: 1.5; margin-bottom: 8px;
}
.rs-user--guest .rs-guest-msg b { color: var(--neon); font-weight: 700; }
/* v0.13 · 비로그인 사이드바 CTA: 회원가입 (Neon Green) + 로그인 보조 링크 */
.rs-cta-signup {
  display: block; padding: 12px 14px;
  background: var(--neon); color: var(--ink);
  border-radius: var(--r-md);
  text-align: center; text-decoration: none;
  font-size: 13px; line-height: 1.4;
  margin-bottom: 8px;
  transition: box-shadow .15s ease, transform .05s ease;
}
.rs-cta-signup b { font-weight: 800; font-size: 14px; }
.rs-cta-signup .rs-cta-sub { font-size: 11px; opacity: .8; font-weight: 600; }
.rs-cta-signup:hover { box-shadow: 0 4px 12px rgba(0,230,64,.45); }
.rs-cta-signup:active { transform: translateY(1px); }
.rs-cta-login {
  display: block; text-align: center;
  font-size: 11px; color: rgba(255,255,255,.55);
  text-decoration: none; padding: 6px 0;
}
.rs-cta-login:hover { color: var(--neon); }
.rs-about {
  display: block; margin-top: 10px;
  font-size: 11px; color: rgba(255,255,255,.45);
  font-family: 'JetBrains Mono', monospace;
  text-decoration: none; letter-spacing: .04em;
}
.rs-about:hover { color: var(--neon); text-decoration: none; }

/* P1-18 · 4-node ring 정본 복원 (Review AI brand reference) */
.rs-brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  vertical-align: middle;
}
.rs-brand-logo .ring {
  position: relative;
  width: 24px; height: 24px;
  border: 2px solid var(--neon);
  border-radius: 50%;
  flex-shrink: 0;
}
/* 4-node 정점 (top/right/bottom/left) */
.rs-brand-logo .ring::before,
.rs-brand-logo .ring::after {
  content: '';
  position: absolute;
  width: 6px; height: 6px;
  background: var(--neon);
  border-radius: 50%;
}
.rs-brand-logo .ring::before {
  top: -3px; left: 50%;
  transform: translateX(-50%);
  box-shadow:
    0 30px 0 var(--neon),                  /* bottom */
    -15px 15px 0 var(--neon),              /* left */
    15px 15px 0 var(--neon);               /* right */
}
.rs-brand-logo .ring::after {
  /* center R/AI dot mask is via .ring-inner; ::after reserved for future glow */
  display: none;
}
.rs-brand-logo .ring-inner {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px; font-weight: 700;
  color: var(--white);
  letter-spacing: 0;
  line-height: 1;
}
/* 단순 dot (사이드바 경량 표기 · 별도 .rs-brand-dot 클래스 분리) */
.rs-brand-dot {
  display: inline-block;
  width: 18px; height: 18px;
  border: 2px solid var(--neon);
  border-radius: 50%;
  vertical-align: middle;
  flex-shrink: 0;
}
.rs-brand-name {
  font-weight: 800; font-size: 17px; letter-spacing: -.01em;
  color: var(--white);
}

/* v0.15.1 · 사이드바 [구글미팅 신청] + [카카오톡 실시간 문의] · 맥킨지 무드 */
/* (검정 사이드바 위에 얹는 패턴 — Ink 배경 + Neon 강조 hover) */
.rs-cta-meet,
.rs-cta-kakao {
  display: block;
  margin: 8px 16px;
  padding: 10px 12px;
  border-radius: var(--r-md);
  background: rgba(255,255,255,.04);
  color: var(--white);
  border: 1px solid rgba(255,255,255,.14);
  text-decoration: none;
  text-align: left;
  transition: border-color .15s, background .15s, transform .1s;
}
.rs-cta-meet { margin-top: 14px; }
.rs-cta-kakao { margin-bottom: 6px; }
.rs-cta-meet:hover,
.rs-cta-kakao:hover {
  border-color: var(--neon);
  background: rgba(0,230,64,.07);
  text-decoration: none;
  transform: translateY(-1px);
}
.rs-cta-title {
  display: block;
  font-size: 13px; font-weight: 700;
  color: var(--white);
  letter-spacing: -.01em;
  margin-bottom: 2px;
}
.rs-cta-hours {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: rgba(255,255,255,.5);
  letter-spacing: .02em;
}
/* P2-03 · dead CSS 삭제 (rs-kakao-chat: v0.15.1 이후 미사용 확인) */

/* v0.14 · 미니 프로모션 배너 (사이드바 하단 · 비로그인 시만) */
.rs-promo {
  margin: 4px 16px 12px;
  padding: 14px 12px;
  background: var(--ink-2);
  border: 1px solid var(--neon);
  border-radius: var(--r-md);
  text-align: center;
}
/* v0.20.4 — promo 박스를 회원가입 진입 링크로 통합 (rs-promo--cta) */
a.rs-promo--cta {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: box-shadow .15s ease, transform .1s ease;
}
a.rs-promo--cta:hover {
  box-shadow: 0 6px 18px rgba(0, 230, 64, .35);
}
a.rs-promo--cta:active { transform: translateY(1px); }
a.rs-promo--cta:focus-visible {
  outline: 2px solid var(--neon);
  outline-offset: 3px;
}
.rs-promo-eyebrow {
  font-size: 10px; color: var(--neon);
  margin-bottom: 4px; letter-spacing: .04em;
  font-weight: 700;
}
.rs-promo-title {
  font-size: 13px; font-weight: 800; color: var(--white);
  line-height: 1.3;
}
.rs-promo-sub {
  font-size: 10px; color: rgba(255,255,255,.6);
  margin: 4px 0 8px; line-height: 1.4;
}
.rs-promo-cta {
  display: inline-block; padding: 6px 12px;
  background: var(--neon); color: var(--ink);
  font-size: 11px; font-weight: 700;
  border-radius: 999px; text-decoration: none;
  transition: box-shadow .15s ease;
}
.rs-promo-cta:hover {
  box-shadow: 0 4px 10px rgba(0,230,64,.45);
  text-decoration: none;
}

/* v23.20 — 추천하기 카드 (Manus 스타일) */
.rs-refer-card {
  display: flex; align-items: center; gap: 12px;
  margin: 8px 16px; padding: 14px 16px;
  background: var(--ink-2);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--r-lg);
  text-decoration: none; color: inherit;
  transition: border-color .2s, box-shadow .3s, background .2s;
  cursor: pointer;
}
.rs-refer-card:hover {
  border-color: var(--neon);
  box-shadow: 0 0 16px rgba(0,230,64,.25), inset 0 0 24px rgba(0,230,64,.05);
  background: rgba(0,230,64,.06);
  text-decoration: none;
}
.rs-refer-icon {
  flex: 0 0 auto;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,230,64,.12);
  border-radius: 50%;
  color: var(--neon);
  transition: background .2s, transform .2s;
}
.rs-refer-card:hover .rs-refer-icon {
  background: rgba(0,230,64,.25);
  transform: scale(1.08);
}
.rs-refer-body { flex: 1; min-width: 0; }
.rs-refer-title {
  display: block;
  font-size: 13px; font-weight: 700; color: #fff;
  line-height: 1.3;
}
.rs-refer-sub {
  display: block;
  font-size: 11px; color: rgba(255,255,255,.5);
  margin-top: 2px;
}
.rs-refer-arrow {
  flex: 0 0 auto;
  font-size: 18px; color: rgba(255,255,255,.3);
  transition: color .2s, transform .2s;
}
.rs-refer-card:hover .rs-refer-arrow {
  color: var(--neon);
  transform: translateX(2px);
}

/* v0.21.2 — 사이드바 컴팩트화 (8메뉴 + 부가영역 모두 보이게)
   사용자 명시: "원쪽 메뉴 8번 안 보임 + 회원 라벨 제거" */
.rs-nav--compact .rs-item {
  padding: 6px 16px;          /* 기존 12px → 6px */
  font-size: 13px;
  gap: 10px;
  min-height: 32px;
}
.rs-nav--compact .rs-item .rs-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 10px; font-weight: 700;
  color: rgba(255,255,255,.5);
  flex-shrink: 0;
}
.rs-nav--compact .rs-item.active .rs-num {
  background: var(--neon); border-color: var(--neon); color: var(--ink);
}
.rs-nav--compact .rs-item .rs-label { font-size: 13px; line-height: 1.3; }
.rs-nav--compact .rs-divider {
  height: 1px; background: rgba(255,255,255,.08);
  margin: 6px 16px;
}
/* v0.21.4 · 추천하기 단순화 — 마이캠페인 동일 스타일 + "이벤트" 작은 라벨만 */
.rs-nav--compact .rs-event-tag {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 6px;
  font-size: 9px; font-weight: 700;
  color: var(--ink);
  background: var(--neon);
  border-radius: 6px;
  letter-spacing: .02em;
  vertical-align: middle;
}
/* 부가 영역(구글미팅 / 카카오 / promo / 로그인) 컴팩트 */
.rv-sidebar .rs-cta-meet,
.rv-sidebar .rs-cta-kakao {
  padding: 8px 12px;
  margin: 4px 12px;
  border-radius: 8px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  display: block; text-decoration: none;
}
.rv-sidebar .rs-cta-meet .rs-cta-title,
.rv-sidebar .rs-cta-kakao .rs-cta-title {
  display: block;
  font-size: 11px; font-weight: 700; color: #fff; margin-bottom: 1px;
}
.rv-sidebar .rs-cta-meet .rs-cta-hours,
.rv-sidebar .rs-cta-kakao .rs-cta-hours {
  display: block;
  font-size: 9px; color: rgba(255,255,255,.45); line-height: 1.3;
}
.rv-sidebar .rs-promo {
  margin: 6px 12px 6px;
  padding: 10px 10px;
}
.rv-sidebar .rs-promo .rs-promo-title { font-size: 12px; line-height: 1.25; }
.rv-sidebar .rs-promo .rs-promo-eyebrow { font-size: 9px; margin-bottom: 2px; }
.rv-sidebar .rs-promo .rs-promo-sub { font-size: 9px; margin: 2px 0 6px; }
.rv-sidebar .rs-promo .rs-promo-cta { font-size: 10px; padding: 4px 10px; }

/* 페이지 본문 좌측 padding (사이드바 폭 만큼) */
body.has-sidebar { padding-left: 220px; }
body.has-sidebar .header { left: 220px; }
body.has-sidebar .promo-sticky { padding-left: 0; }

/* ═══════════════════════════════════════════════════════════════
   v0.21.5 — 반복 실수 영구 fix (사용자 4번째 명시 · 2026-05-07)
   "원쪽메뉴에 본문내용을 바짝 붙여줘 모든 페이지"
   진짜 원인: .container/.quote-main/.camp-wrap/.fr-container/.st-container
              모두 max-width:1080~1280px + margin:0 auto → 가운데 정렬
   → 사이드바 옆 영역에서 컨테이너가 가운데로 정렬되니 빈 공간 발생
   해결: 모든 컨테이너 margin-left:0 !important 강제 + max-width 해제
   ═══════════════════════════════════════════════════════════════ */
body.has-sidebar .container,
body.has-sidebar .container-narrow,
body.has-sidebar .quote-main,
body.has-sidebar .camp-wrap,
body.has-sidebar .fr-container,
body.has-sidebar .st-container,
body.has-sidebar #signupMain,
body.has-sidebar #quoteMain,
body.has-sidebar #dashboardMain,
body.has-sidebar #campaignMain,
body.has-sidebar #friendsMain,
body.has-sidebar #settingsMain,
body.has-sidebar main[role="main"] {
  max-width: none !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 24px !important;
  padding-right: 24px !important;
}
@media (max-width: 880px) {
  body.has-sidebar .container,
  body.has-sidebar .container-narrow,
  body.has-sidebar .quote-main,
  body.has-sidebar .camp-wrap,
  body.has-sidebar .fr-container,
  body.has-sidebar .st-container,
  body.has-sidebar #signupMain,
  body.has-sidebar #quoteMain,
  body.has-sidebar #dashboardMain,
  body.has-sidebar #campaignMain,
  body.has-sidebar #friendsMain,
  body.has-sidebar #settingsMain {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
}
/* P1-16 · 100vw → 100dvw + vw 폴백 (모바일 주소창 변동 대응)
   P2-02 · inline style selector 자체 specificity 높아 !important 제거 가능 */
@media (max-width: 1500px) {
  body.has-sidebar main[style*="max-width: 1280px"],
  body.has-sidebar .camp-wrap,
  body.has-sidebar .quote-main {
    max-width: calc(100vw - 240px);     /* 폴백 */
    max-width: calc(100dvw - 240px);    /* dvw 지원 브라우저 */
  }
}

/* 모바일 햄버거 토글 (P1-14 · WCAG 2.5.5 → 44×44px) */
.rs-mobile-toggle {
  display: none;
  position: fixed; top: 12px; left: 12px; z-index: 70;
  width: 44px; height: 44px;
  background: var(--ink); color: var(--white);
  border: 0; border-radius: var(--r-md);
  font-size: 22px; cursor: pointer;
  box-shadow: var(--shadow-md);
}

@media (max-width: 768px) {
  body.has-sidebar { padding-left: 0; }
  body.has-sidebar .header { left: 0; }
  .rv-sidebar {
    transform: translateX(-100%);
    width: 260px;
    box-shadow: 4px 0 24px rgba(0,0,0,.3);
  }
  .rv-sidebar--open { transform: translateX(0); }
  .rs-mobile-toggle { display: block; }
  /* 사이드바 열려 있을 때 헤더 로고와 햄버거 충돌 방지: 좌측 padding */
  body.has-sidebar .header__inner { padding-left: 56px; }
}
