/* ══════════════════════════════════════════════════════════════
   eBOSS VPN — 시안 F (사이드바 대시보드 위젯형) 프로토타입
   ══════════════════════════════════════════════════════════════ */

@font-face {
  font-family: "Pretendard";
  src: url("assets/PretendardVariable.woff2") format("woff2-variations");
  font-weight: 45 920;
  font-style: normal;
  font-display: swap;
}

:root {
  --blue-50: #E8F4FE;
  --blue-100: #CFE8FD;
  --blue-400: #58B4FA;
  --blue-500: #2E9AF2;
  --blue-600: #1F86DE;
  --green-50: #EAF7EE;
  --green-500: #46B173;
  --amber-50: #FEF7DF;
  --amber-500: #E0A72E;
  --violet-50: #F3ECFD;
  --violet-500: #8B5CF6;
  --ink: #1B2433;
  --ink-2: #33465C;
  --muted: #6E7F95;
  --muted-2: #8FA0B5;
  --line: #E7EEF7;
  --bg: #F6F9FE;
  --card-shadow: 0 10px 30px rgba(23, 52, 84, .07);
  --r-lg: 22px;
  --r-md: 14px;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Pretendard", "Noto Sans CJK KR", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: break-word;
}

h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.ic {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
  flex: 0 0 auto;
}

:focus-visible {
  outline: 3px solid rgba(46, 154, 242, .45);
  outline-offset: 2px;
  border-radius: 8px;
}

/* ───────── Sidebar ───────── */
.app { min-height: 100%; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 264px;
  display: flex;
  flex-direction: column;
  padding: 24px 18px 18px;
  background: linear-gradient(178deg, #43B2FE 0%, #2E9AF2 52%, #2C90EC 100%);
  overflow-y: auto;
  z-index: 40;
  scrollbar-width: none;
}
.sidebar::-webkit-scrollbar { display: none; }

.sidebar::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 220px;
  background: radial-gradient(120% 80% at 20% 100%, rgba(255, 255, 255, .22), transparent 70%);
  pointer-events: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 2px 6px;
  position: relative;
  z-index: 1;
}
.brand-mark { width: 42px; height: 42px; display: block; }
.brand-mark svg { width: 100%; height: 100%; display: block; }
.brand-text strong {
  display: block;
  color: #fff;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.brand-text strong em { font-style: normal; font-weight: 600; opacity: .9; }
.brand-text small {
  display: block;
  margin-top: 5px;
  color: rgba(255, 255, 255, .82);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.nav {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  position: relative;
  z-index: 1;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border-radius: 13px;
  color: rgba(255, 255, 255, .94);
  font-size: 14.5px;
  font-weight: 600;
  text-align: left;
  transition: background .18s, color .18s, transform .18s;
}
.nav-item .ic { width: 19px; height: 19px; stroke-width: 1.9; opacity: .95; }
.nav-item:hover { background: rgba(255, 255, 255, .17); }
.nav-item.is-active {
  background: #fff;
  color: #1E86DC;
  box-shadow: 0 8px 20px rgba(11, 67, 120, .22);
}
.nav-item.is-active .ic { opacity: 1; stroke-width: 2; }

.side-bottom {
  margin-top: auto;
  padding-top: 26px;
  position: relative;
  z-index: 1;
}

.side-banner {
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .32);
  border-radius: 18px;
  padding: 15px 14px 12px;
  color: #fff;
  text-align: center;
  backdrop-filter: blur(2px);
}
.side-banner-ico {
  width: 38px; height: 38px; margin: 0 auto 8px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, .24);
}
.side-banner-ico .ic { width: 21px; height: 21px; }
.side-banner-title { font-size: 13px; font-weight: 700; }
.side-banner-title b { font-size: 14.5px; font-weight: 800; }
.side-banner-desc {
  margin-top: 4px;
  font-size: 10.8px;
  line-height: 1.45;
  color: rgba(255, 255, 255, .88);
}
.side-banner-btn {
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 9px 10px;
  border-radius: 10px;
  background: #fff;
  color: #1B7FD4;
  font-size: 12.5px;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(11, 67, 120, .2);
  transition: transform .18s;
}
.side-banner-btn:hover { transform: translateY(-1px); }
.side-banner-btn .ic { width: 13px; height: 13px; stroke-width: 2.4; }
.side-banner-sub {
  display: block;
  width: 100%;
  margin-top: 8px;
  color: rgba(255, 255, 255, .9);
  font-size: 10.5px;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.side-legal {
  margin-top: 12px;
  text-align: center;
  font-size: 9.5px;
  color: rgba(255, 255, 255, .62);
}

.scrim {
  position: fixed;
  inset: 0;
  background: rgba(12, 30, 50, .42);
  z-index: 38;
  border: 0;
}
.scrim[hidden] { display: none; }

/* ───────── Main ───────── */
.main {
  margin-left: 264px;
  padding: 22px 30px 18px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.menu-btn { display: none; }

.hello h1 {
  font-size: clamp(22px, 2.2vw, 29px);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.2;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hello .wave { font-size: .88em; }
.hello p {
  margin-top: 5px;
  font-size: 13.5px;
  color: var(--muted);
  font-weight: 500;
}

.top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 9px;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 6px 16px rgba(23, 52, 84, .08);
  font-size: 12.5px;
  font-weight: 700;
  color: #2C4A36;
  white-space: nowrap;
}
.status-chip .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #38C46E;
  box-shadow: 0 0 0 0 rgba(56, 196, 110, .55);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(56, 196, 110, .5); }
  70% { box-shadow: 0 0 0 7px rgba(56, 196, 110, 0); }
  100% { box-shadow: 0 0 0 0 rgba(56, 196, 110, 0); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform .16s, box-shadow .16s, background .16s, border-color .16s;
}
.btn-primary {
  background: linear-gradient(135deg, #45B2FB, #2E9AF2);
  color: #fff;
  box-shadow: 0 8px 18px rgba(46, 154, 242, .34);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 22px rgba(46, 154, 242, .4); }
.btn-ghost {
  background: #fff;
  color: var(--ink-2);
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px rgba(23, 52, 84, .05);
}
.btn-ghost:hover { border-color: #CFE0F2; }

.icon-btn {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: grid; place-items: center;
  color: var(--ink-2);
  background: #fff;
  border: 1px solid var(--line);
}
.icon-btn:hover { background: #F3F8FE; }
.menu-btn { display: none; }

/* ───────── Cards ───────── */
.card {
  background: #fff;
  border-radius: var(--r-lg);
  border: 1px solid rgba(228, 237, 247, .9);
  box-shadow: var(--card-shadow);
  padding: 20px 22px 16px;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.card-head h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 17.5px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.emo-chip {
  display: inline-grid;
  place-items: center;
  width: 24px; height: 24px;
  font-size: 17px;
  line-height: 1;
}
.link-btn {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--blue-500);
  white-space: nowrap;
}
.link-btn .ic { width: 13px; height: 13px; stroke-width: 2.4; }
.link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }

.card-sub {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
}

/* ───────── Setup steps ───────── */
.setup { position: relative; z-index: 10; }
.lower { position: relative; z-index: 1; }

.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
  margin-top: 15px;
}

.step {
  --bubble: #E7F4FE;
  --badge: #2E9AF2;
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 184px;
  padding: 14px 14px 12px;
  border-radius: 20px;
  background: var(--bubble);
}
.step-blue { --bubble: #E7F4FE; --badge: #2E9AF2; }
.step-green { --bubble: #EDF8E6; --badge: #46B173; }
.step-amber { --bubble: #FEF6DB; --badge: #E0A72E; }
.step-violet { --bubble: #F4EDFD; --badge: #8B5CF6; }

/* speech bubble tail */
.step::after {
  content: "";
  position: absolute;
  left: 20px;
  bottom: -6px;
  width: 16px; height: 16px;
  background: var(--bubble);
  border-radius: 0 0 5px 0;
  transform: rotate(45deg);
  z-index: 0;
}

/* dashed connector */
.step + .step::before {
  content: "";
  position: absolute;
  left: -15px;
  top: 46%;
  width: 15px;
  height: 0;
  border-top: 2px dashed #C9D7E7;
}

.step-badge {
  position: absolute;
  top: 13px; left: 13px;
  width: 26px; height: 26px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--badge);
  color: #fff;
  font-size: 12.5px;
  font-weight: 800;
  z-index: 2;
  box-shadow: 0 4px 10px rgba(23, 52, 84, .16);
}
.step-violet .step-badge { font-size: 13px; }

.step-copy {
  padding-left: 34px;
  padding-right: 0;
  min-height: 62px;
  position: relative;
  z-index: 1;
}
.step-copy h3 {
  font-size: 14.5px;
  font-weight: 800;
  line-height: 1.32;
  letter-spacing: -0.02em;
  color: #17222F;
}
.step-copy p {
  margin-top: 5px;
  padding-right: 56px;
  font-size: 11.6px;
  line-height: 1.5;
  color: #5C6E84;
  font-weight: 500;
}

.step-art {
  position: absolute;
  right: 4px;
  top: 44px;
  width: 58px;
  height: 52px;
  z-index: 1;
  pointer-events: none;
}
.step-art svg { width: 100%; height: 100%; display: block; }

.step-control {
  margin-top: auto;
  padding-top: 12px;
  position: relative;
  z-index: 3;
}
.step-control-row { display: flex; gap: 7px; }

.step-meta {
  margin-top: 7px;
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10.2px;
  font-weight: 600;
  color: #8797AB;
  position: relative;
  z-index: 1;
}
.step-meta .ic { width: 11px; height: 11px; stroke-width: 2.6; color: #7BC48F; }
.step-amber .step-meta { justify-content: space-between; }

/* select */
.select { position: relative; }
.select-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 11px;
  border-radius: 11px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 4px 12px rgba(23, 52, 84, .07);
  font-size: 12.8px;
  font-weight: 700;
  color: #22303F;
}
.select-btn:hover { box-shadow: 0 6px 16px rgba(23, 52, 84, .11); }
.select-ico { display: grid; place-items: center; color: #3E5468; }
.select-ico .ic { width: 15px; height: 15px; }
.select-label { flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.select-chev { width: 14px; height: 14px; color: #8397AE; stroke-width: 2.2; }

.select-menu {
  position: absolute;
  top: calc(100% + 5px);
  left: 0; right: 0;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px rgba(18, 42, 72, .18);
  padding: 5px;
  z-index: 30;
  animation: pop .14s ease-out;
}
.select-menu[hidden] { display: none; }
@keyframes pop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.select-menu li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 9px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 600;
  color: #3B4C61;
  cursor: pointer;
}
.select-menu li .ic { width: 15px; height: 15px; color: #7A8EA6; }
.select-menu li:hover { background: #F3F9FF; }
.select-menu li[aria-selected="true"] { background: #E8F4FE; color: #1E7FD2; font-weight: 800; }
.select-menu li[aria-selected="true"] .ic { color: #2E9AF2; }

/* app chips */
.app-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.app-chip {
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 9px 8px;
  border-radius: 11px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 4px 12px rgba(23, 52, 84, .07);
  font-size: 11.6px;
  font-weight: 800;
  color: #22303F;
  transition: transform .16s, box-shadow .16s, border-color .16s;
}
.app-chip:hover {
  transform: translateY(-1px);
  border-color: #BFE3C9;
  box-shadow: 0 8px 18px rgba(35, 110, 70, .16);
}
.app-chip-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app-chip .ic { width: 11px; height: 11px; color: #8CA0B6; stroke-width: 2.2; }

.btn-solid {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 10px 10px;
  border-radius: 11px;
  background: #2E9AF2;
  color: #fff;
  font-size: 12.2px;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(46, 154, 242, .3);
}
.btn-solid:hover { background: #228FE8; }
.btn-solid .ic { width: 13px; height: 13px; stroke-width: 2.2; }

.btn-mini {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 11px;
  border-radius: 11px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, .95);
  box-shadow: 0 4px 12px rgba(23, 52, 84, .07);
  font-size: 12px;
  font-weight: 800;
  color: #33465C;
  white-space: nowrap;
}
.btn-mini:hover { border-color: #D6E4F3; }
.btn-mini .ic { width: 13px; height: 13px; }

.btn-violet {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 10px;
  border-radius: 11px;
  background: linear-gradient(135deg, #A175F8, #7C4DEB);
  color: #fff;
  font-size: 12.2px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(124, 77, 235, .32);
}
.btn-violet:hover { filter: brightness(1.04); }

/* ───────── Lower widgets ───────── */
.lower {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.44fr);
  gap: 16px;
  margin-top: 16px;
}

/* Instant connection */
.instant { display: flex; flex-direction: column; }
.demo-tag {
  padding: 3px 8px;
  border-radius: 999px;
  background: #F1F6FC;
  color: #8598AF;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
}
.instant .card-sub { margin-top: 6px; }

.sub-tabs {
  display: inline-flex;
  align-self: flex-start;
  gap: 2px;
  margin-top: 11px;
  padding: 3px;
  border-radius: 10px;
  background: #F2F6FB;
}
.sub-tab {
  padding: 6px 11px;
  border-radius: 8px;
  font-size: 11.5px;
  font-weight: 700;
  color: #7A8BA1;
}
.sub-tab.is-active {
  background: #fff;
  color: #1E7FD2;
  box-shadow: 0 2px 6px rgba(23, 52, 84, .09);
}

.instant-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 144px;
  gap: 13px;
  margin-top: 11px;
}

.sub-row {
  padding: 8px 10px;
  margin-bottom: 7px;
  background: #F7FAFD;
  border: 1px solid #ECF3FA;
  border-radius: 11px;
}
.sub-row-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.sub-name { font-size: 11px; font-weight: 700; color: #6B7D93; }
.copy-btn {
  width: 24px; height: 24px;
  border-radius: 7px;
  background: #fff;
  border: 1px solid #E3ECF6;
  color: #5E82A9;
  display: grid; place-items: center;
  transition: background .16s, color .16s;
}
.copy-btn:hover { background: #E9F4FE; color: #1E86DC; }
.copy-btn .ic { width: 12.5px; height: 12.5px; }
.sub-url {
  display: block;
  margin-top: 3px;
  font-size: 11px;
  color: #34465B;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sub-meta {
  display: grid;
  gap: 4px;
  padding: 2px 3px 0;
}
.sub-meta li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 10.8px;
  color: #8394A9;
}
.sub-meta b { color: #3D4F65; font-weight: 700; }

.qr-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding-top: 2px;
}
.qr-frame {
  position: relative;
  padding: 8px;
  background: #fff;
  border: 1px solid #E8F0F9;
  border-radius: 14px;
  box-shadow: 0 6px 16px rgba(23, 52, 84, .07);
}
.qr-box {
  width: 112px; height: 112px;
  display: grid; place-items: center;
  overflow: hidden;
  border-radius: 6px;
}
.qr-box img, .qr-box canvas { width: 112px !important; height: 112px !important; display: block; }
.qr-sun {
  position: absolute;
  top: -9px; right: -7px;
  font-size: 17px;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .08));
}
.qr-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.qr-caption {
  display: flex;
  align-items: center;
  gap: 1px;
  font-size: 10px;
  color: #8B9BB0;
  font-weight: 600;
}
.qr-arrow { width: 10px; height: 10px; color: #A3B3C7; stroke-width: 2.4; }
.qr-proto {
  font-size: 9.5px;
  font-weight: 700;
  color: #A9B8CA;
  letter-spacing: .02em;
}

.card-foot-link {
  margin-top: auto;
  padding-top: 9px;
  border-top: 1px dashed #E9F0F8;
  display: flex;
  align-items: center;
  gap: 3px;
  width: 100%;
  font-size: 11.5px;
  font-weight: 700;
  color: #2E9AF2;
  text-align: left;
}
.card-foot-link .ic { width: 12px; height: 12px; stroke-width: 2.4; }
.card-foot-link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Plans */
.plans { display: flex; flex-direction: column; }
.plan-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
}
.plan-top .card-sub { margin: 0; }

.seg {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 2px;
  padding: 3px;
  border-radius: 999px;
  background: #F2F6FB;
}
.seg-btn {
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 10.8px;
  font-weight: 700;
  color: #7A8BA1;
  white-space: nowrap;
}
.seg-btn.is-active {
  background: #fff;
  color: #1E7FD2;
  box-shadow: 0 2px 6px rgba(23, 52, 84, .1);
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
  margin-top: 11px;
}

.plan-card {
  --tint: #EBF6FE;
  --accent: #3D9BF0;
  --accent-deep: #1E7FD2;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 12px 11px 10px;
  border-radius: 16px;
  background: var(--tint);
  border: 1.5px solid transparent;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.plan-card:nth-child(2) { --tint: #E9F9EF; --accent: #4CB878; --accent-deep: #2C8F5B; }
.plan-card:nth-child(3) { --tint: #FEF8E3; --accent: #E7B23C; --accent-deep: #A97C11; }
.plan-card:nth-child(4) { --tint: #F7EDFD; --accent: #8B5CF6; --accent-deep: #6E3FD4; }
.plan-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, .9);
  box-shadow: 0 14px 28px rgba(23, 52, 84, .12);
}
.plan-card.is-selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(76, 184, 120, .16);
}
.plan-badge {
  position: absolute;
  top: -8px; left: 50%;
  transform: translateX(-50%);
  padding: 2.5px 9px;
  border-radius: 999px;
  background: #46B173;
  color: #fff;
  font-size: 9.5px;
  font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(46, 150, 100, .28);
}
.plan-name {
  font-size: 16.5px;
  font-weight: 800;
  color: var(--accent-deep);
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.plan-sub {
  margin-top: 2px;
  font-size: 10px;
  font-weight: 600;
  color: #6D7F94;
}
.plan-price {
  margin-top: 9px;
  display: flex;
  align-items: baseline;
  gap: 2px;
  color: #202E3E;
}
.plan-price .cny {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
}
.plan-price .unit { font-size: 10px; font-weight: 700; color: #6D7F94; }
.plan-list-price {
  font-size: 9.5px;
  color: #93A2B6;
  text-decoration: line-through;
  margin-left: 3px;
}
.plan-krw {
  margin-top: 3px;
  font-size: 11px;
  font-weight: 700;
  color: #55677D;
}
.plan-month {
  display: inline;
  margin-left: 3px;
  font-size: 9.8px;
  font-weight: 600;
  color: #8294AA;
}
.plan-list {
  display: grid;
  gap: 2.5px;
  margin-top: 8px;
  font-size: 10px;
  font-weight: 600;
  color: #5F7188;
}
.plan-list li {
  display: flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.plan-list li::before {
  content: "✓";
  color: var(--accent);
  font-weight: 800;
  font-size: 9.5px;
}
.plan-btn {
  margin-top: 9px;
  padding: 7px 6px;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-size: 11.3px;
  font-weight: 800;
  box-shadow: 0 5px 12px rgba(23, 52, 84, .12);
  transition: filter .16s;
}
.plan-btn:hover { filter: brightness(1.05); }
.plan-note {
  margin-top: 9px;
  font-size: 10px;
  color: #94A4B8;
  font-weight: 500;
}

/* ───────── Status bar ───────── */
.statusbar {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr .92fr 1.3fr;
  align-items: center;
  padding: 11px 8px;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(228, 237, 247, .9);
  box-shadow: var(--card-shadow);
}
.status-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 15px;
  min-width: 0;
}
.status-item + .status-item::before {
  content: "";
  position: absolute;
  left: 0; top: 4px; bottom: 4px;
  width: 1px;
  background: #EDF2F9;
}
.status-item .dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: #38C46E;
  box-shadow: 0 0 0 4px rgba(56, 196, 110, .14);
  flex: 0 0 auto;
}
.status-item b {
  display: block;
  font-size: 11.4px;
  font-weight: 800;
  color: #22303F;
}
.status-item span:not(.dot):not(.tip-ico) {
  display: block;
  font-size: 10.4px;
  color: #8697AC;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.node-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  width: 26px;
  flex: 0 0 auto;
}
.node-dots i {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #55C883;
}
.tip-ico { font-size: 14px; flex: 0 0 auto; }
.status-tip { padding-right: 8px; }
.status-more {
  margin-left: auto;
  width: 24px; height: 24px;
  border-radius: 7px;
  display: grid; place-items: center;
  color: #9AABC0;
}
.status-more:hover { background: #F2F8FF; color: #2E9AF2; }
.status-more .ic { width: 13px; height: 13px; stroke-width: 2.4; }

.foot {
  margin-top: auto;
  padding: 12px 4px 2px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 10px;
  color: #9DACBE;
  letter-spacing: 0;
}

/* ───────── Chat ───────── */
.chat-wrap {
  position: fixed;
  right: 22px;
  bottom: 20px;
  z-index: 60;
  transition: opacity .2s;
}
.chat-wrap.is-hidden { opacity: 0; pointer-events: none; }
.chat-fab {
  position: relative;
  width: 54px; height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4CB4FB, #2E9AF2);
  color: #fff;
  display: grid; place-items: center;
  border: 3px solid #fff;
  box-shadow: 0 12px 26px rgba(37, 130, 210, .4);
  transition: transform .18s;
}
.chat-fab:hover { transform: translateY(-2px) scale(1.03); }
.chat-fab .ic { width: 25px; height: 25px; stroke-width: 1.9; }
.chat-fab-dot {
  position: absolute;
  top: 3px; right: 4px;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: #FF5A5A;
  border: 2px solid #fff;
}
.chat-pop {
  position: absolute;
  right: 0;
  bottom: 64px;
  width: 292px;
  padding: 14px 15px 12px;
  background: #fff;
  border-radius: 18px;
  border: 1px solid #EEF4FB;
  box-shadow: 0 24px 54px rgba(16, 40, 70, .22);
  animation: pop .16s ease-out;
}
.chat-pop[hidden] { display: none; }
.chat-pop-head { position: relative; padding-right: 26px; }
.chat-pop-head b { display: block; font-size: 14px; font-weight: 800; }
.chat-pop-head span { display: block; margin-top: 2px; font-size: 10.5px; color: #8A9BB0; }
.chat-close {
  position: absolute;
  top: -4px; right: -4px;
  width: 26px; height: 26px;
  border: 0;
  background: transparent;
  color: #9AABC0;
}
.chat-close:hover { background: #F3F7FC; }
.chat-close .ic { width: 14px; height: 14px; }
.chat-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid #F1F5FA;
}
.chat-row:first-of-type { margin-top: 10px; }
.chat-row b { display: block; font-size: 12px; font-weight: 800; }
.chat-row small { display: block; font-size: 10.5px; color: #7F91A7; }
.chat-row .btn-mini { margin-left: auto; padding: 6px 10px; font-size: 11px; border-color: #E4ECF6; background: #F7FAFE; }
.chat-logo {
  width: 30px; height: 30px;
  border-radius: 9px;
  display: grid; place-items: center;
  font-size: 14px;
  font-weight: 900;
  flex: 0 0 auto;
}
.chat-logo.wechat { background: #2BB741; color: #fff; }
.chat-logo.kakaotalk { background: #FEE500; color: #3A1D1D; }
.chat-note { margin-top: 2px; font-size: 10px; color: #98A8BB; }

/* ───────── Toast ───────── */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translate(-50%, 14px);
  z-index: 100;
  padding: 11px 18px;
  border-radius: 999px;
  background: #18293D;
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: 0 16px 34px rgba(10, 25, 45, .3);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s, transform .2s;
  max-width: calc(100vw - 32px);
  text-align: center;
}
.toast.is-show { opacity: 1; transform: translate(-50%, 0); }

/* ───────── Modal ───────── */
.modal-root { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 18px; }
.modal-root[hidden] { display: none; }
.modal-scrim { position: absolute; inset: 0; background: rgba(14, 30, 50, .44); backdrop-filter: blur(2px); }
.modal {
  position: relative;
  width: min(580px, 100%);
  max-height: 88vh;
  overflow: auto;
  padding: 24px 24px 20px;
  background: #fff;
  border-radius: 22px;
  box-shadow: 0 34px 80px rgba(8, 22, 40, .34);
  animation: pop .18s ease-out;
}
.modal-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 30px; height: 30px;
  border: 0;
  background: #F4F8FD;
  color: #7E90A7;
}
.modal-close .ic { width: 14px; height: 14px; }

.m-eyebrow {
  display: inline-block;
  padding: 4px 9px;
  border-radius: 999px;
  background: #EEF7FF;
  color: #2383D6;
  font-size: 10.5px;
  font-weight: 800;
}
.m-title {
  margin-top: 10px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.025em;
}
.m-sub { margin-top: 6px; font-size: 12.5px; color: #6E7F95; line-height: 1.55; }

.m-price-box {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #F6FAFF;
  border: 1px solid #E8F1FB;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.m-price { display: flex; align-items: baseline; gap: 4px; }
.m-price b { font-size: 27px; font-weight: 800; letter-spacing: -0.03em; }
.m-price span { font-size: 12px; color: #71829A; font-weight: 600; }
.m-price small { font-size: 12px; color: #8B9CB1; }
.m-permonth { font-size: 11.5px; color: #5C7B9C; font-weight: 700; }

.m-list { margin-top: 14px; display: grid; gap: 6px; }
.m-list li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 12.5px;
  color: #42536A;
}
.m-list li::before {
  content: "✓";
  color: #46B173;
  font-weight: 800;
  line-height: 1.3;
}

.m-note {
  margin-top: 14px;
  padding: 11px 13px;
  border-radius: 12px;
  background: #FFF9E8;
  border: 1px solid #F6EBC8;
  font-size: 11.5px;
  color: #7A6222;
  line-height: 1.5;
}
.m-note b { font-weight: 800; }

.m-actions { margin-top: 16px; display: flex; gap: 8px; flex-wrap: wrap; }
.m-actions .btn { flex: 1; min-width: 120px; }

.m-table-wrap { margin-top: 14px; overflow-x: auto; border-radius: 12px; border: 1px solid #ECF2FA; }
.m-table { width: 100%; border-collapse: collapse; font-size: 11.5px; min-width: 460px; }
.m-table th, .m-table td { padding: 8px 10px; text-align: left; border-bottom: 1px solid #F0F5FB; white-space: nowrap; }
.m-table th { background: #F7FAFE; font-weight: 800; color: #5B6E86; font-size: 10.5px; }
.m-table td { color: #3D4F65; }
.m-table tr:last-child td { border-bottom: 0; }
.m-table .strong { font-weight: 800; color: #1E7FD2; }
.m-table .was { color: #9AAABD; text-decoration: line-through; font-size: 10.5px; margin-left: 3px; }
.m-table caption { caption-side: bottom; padding: 8px 10px; font-size: 10.5px; color: #93A3B7; text-align: left; }

/* device guide modal */
.guide-tabs { display: flex; gap: 4px; margin-top: 14px; flex-wrap: wrap; }
.guide-tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 11px;
  border-radius: 9px;
  background: #F4F8FD;
  font-size: 11.5px;
  font-weight: 700;
  color: #6B7E95;
}
.guide-tab .ic { width: 13px; height: 13px; }
.guide-tab.is-active { background: #E8F4FE; color: #1E7FD2; }
.guide-steps { margin-top: 14px; display: grid; gap: 10px; }
.guide-step {
  display: flex;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 12px;
  background: #F8FBFF;
  border: 1px solid #EDF4FC;
}
.guide-num {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #2E9AF2;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: grid; place-items: center;
  flex: 0 0 auto;
}
.guide-step b { display: block; font-size: 12.5px; font-weight: 800; }
.guide-step p { margin-top: 3px; font-size: 11.5px; color: #62748B; line-height: 1.55; }
.guide-step .btn { margin-top: 7px; padding: 6px 10px; font-size: 11px; }

/* FAQ modal */
.faq-list { margin-top: 12px; display: grid; gap: 8px; }
.faq-item {
  border: 1px solid #ECF2FA;
  border-radius: 12px;
  overflow: hidden;
}
.faq-item summary {
  padding: 11px 13px;
  font-size: 12.5px;
  font-weight: 700;
  color: #2C3B4D;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: #8FA1B7; font-weight: 700; }
.faq-item[open] summary::after { content: "–"; }
.faq-item p {
  padding: 0 13px 12px;
  font-size: 12px;
  color: #62748B;
  line-height: 1.6;
}

/* ───────── Responsive ───────── */
@media (max-width: 1330px) {
  .main { padding: 20px 22px 16px; }
  .step { padding: 13px 12px 11px; }
  .step-copy p { padding-right: 46px; }
  .step-copy h3 { font-size: 13.8px; }
  .step-copy p { font-size: 11.2px; }
  .step-art { width: 50px; height: 44px; right: 6px; }
  .step-meta { font-size: 9.6px; }
  .plan-list li { font-size: 9.6px; }
  .plan-month { display: block; margin-left: 0; }
  .plan-name { font-size: 15.5px; }
  .plan-price .cny { font-size: 19.5px; }
  .plan-sub { font-size: 9.6px; }
}

@media (min-width: 901px) and (max-width: 1330px) {
  .plan-list-price { display: none; }
}

@media (max-width: 1140px) {
  .lower { grid-template-columns: minmax(0, 1fr); }
  .instant-body { grid-template-columns: minmax(0, 1fr) 160px; }
  .qr-box, .qr-box img, .qr-box canvas { width: 128px; height: 128px; }
}

@media (max-width: 900px) {
  .sidebar {
    width: 282px;
    transform: translateX(-102%);
    transition: transform .26s cubic-bezier(.3, .8, .3, 1);
    border-radius: 0 22px 22px 0;
    box-shadow: 0 0 60px rgba(10, 30, 50, .3);
  }
  .sidebar.is-open { transform: none; }
  .main { margin-left: 0; padding: 14px 14px 84px; }
  .menu-btn { display: grid; }
  .topbar { gap: 10px; flex-wrap: wrap; }
  .hello { flex: 1 1 auto; min-width: 0; }
  .hello h1 { font-size: 21px; }
  .hello p { font-size: 11.5px; }
  .top-actions { width: 100%; margin-left: 0; justify-content: space-between; gap: 7px; }
  .top-actions .btn { flex: 1; padding: 9px 12px; font-size: 12.5px; }
  .status-chip { order: 0; padding: 8px 12px; font-size: 11.5px; }
  .status-chip-label { display: inline; }

  .card { padding: 16px 15px 13px; border-radius: 18px; }
  .card-head h2 { font-size: 15.5px; }

  .steps { grid-template-columns: 1fr; gap: 22px; margin-top: 14px; }
  .step { min-height: 0; padding: 14px 14px 12px; }
  .step + .step::before { display: none; }
  .step-copy { padding-right: 76px; min-height: 0; }
  .step-copy h3 { font-size: 15px; }
  .step-copy p { font-size: 12px; }
  .step-art { top: 8px; width: 64px; height: 56px; }
  .step .step-control { margin-top: 12px; padding-top: 0; }
  .step-meta { margin-top: 8px; }
  .step-violet .step-control-row { flex-direction: column; }
  .step-violet .step-control-row .btn { width: 100%; padding: 11px 10px; font-size: 12.8px; }

  .instant-body { grid-template-columns: minmax(0, 1fr); }
  .qr-panel { flex-direction: row; align-items: center; gap: 12px; padding: 2px 0 0; }
  .qr-frame { padding: 6px; }
  .qr-box, .qr-box img, .qr-box canvas { width: 96px; height: 96px; }
  .qr-text { align-items: flex-start; gap: 4px; }
  .qr-caption { font-size: 11.5px; color: #6E8199; }
  .qr-proto { font-size: 10.5px; }

  .plan-top { flex-wrap: wrap; }
  .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .plan-name { font-size: 17px; }
  .plan-price .cny { font-size: 22px; }

  .statusbar { grid-template-columns: 1fr; gap: 0; padding: 4px 6px; }
  .status-item { padding: 9px 10px; }
  .status-item + .status-item::before {
    left: 10px; right: 10px; top: 0; bottom: auto;
    width: auto; height: 1px;
  }
  .status-item span:not(.dot):not(.tip-ico) { white-space: normal; }

  .chat-wrap { right: 12px; bottom: 14px; }
  .chat-fab { width: 46px; height: 46px; }
  .chat-pop { width: min(292px, calc(100vw - 28px)); bottom: 58px; }
  .toast { bottom: 82px; }

  .foot { padding-bottom: 4px; }
}

@media (max-width: 420px) {
  .main { padding: 12px 11px 84px; }
  .hello h1 { font-size: 19.5px; }
  .top-actions .btn { font-size: 11.8px; padding: 9px 8px; }
  .status-chip { font-size: 10.5px; padding: 7px 10px; }
  .card { padding: 14px 13px 12px; }
  .plan-grid { gap: 8px; }
  .plan-card { padding: 11px 9px 9px; }
  .plan-price .cny { font-size: 20px; }
  .plan-list li { font-size: 9.3px; }
  .plan-btn { font-size: 11px; }
  .modal { padding: 20px 16px 16px; border-radius: 18px; }
  .m-actions .btn { min-width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
