:root {
  --accent: #e6007e;
  --accent-dark: #b80065;
  --accent-soft: #fde6f2;
  --ink: #1d1d1f;
  --ink-2: #4a4a4f;
  --muted: #8a8a91;
  --line: #e6e6ea;
  --bg: #f5f5f7;
  --card: #ffffff;
  --ok: #0a7a4b;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(0,0,0,.04), 0 6px 20px rgba(0,0,0,.06);
  font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", system-ui, sans-serif;
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
img { max-width: 100%; }

/* ── 머리글 ── */
.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.site-header .inner { max-width: 1200px; margin: 0 auto; padding: 0 16px; height: 64px; display: flex; align-items: center; gap: 24px; }
.logo { font-size: 21px; font-weight: 800; letter-spacing: -.5px; display: flex; align-items: center; gap: 8px; }
.logo .dot { width: 26px; height: 26px; border-radius: 8px; background: var(--accent); display: inline-grid; place-items: center; color: #fff; font-size: 14px; }
.site-header nav { display: flex; gap: 20px; font-weight: 600; color: var(--ink-2); }
.site-header nav a.active { color: var(--accent); }
.site-header .call { margin-left: auto; font-weight: 700; color: var(--accent); white-space: nowrap; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ── 상단 소개 ── */
.hero { background: linear-gradient(120deg, #2b0a1d 0%, #6b0a40 55%, var(--accent) 100%); color: #fff; }
.hero .wrap { padding-top: 40px; padding-bottom: 40px; display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.hero h1 { margin: 0 0 8px; font-size: 32px; letter-spacing: -1px; }
.hero p { margin: 0; opacity: .85; }
.hero .stamp { max-width: 100%; overflow: hidden; text-overflow: ellipsis; font-size: 13px; background: rgba(255,255,255,.15); padding: 6px 12px; border-radius: 999px; white-space: nowrap; }

/* ── 필터 ── */
.page-title { display: flex; align-items: flex-end; justify-content: space-between; margin: 32px 0 16px; gap: 12px; flex-wrap: wrap; }
.page-title h2 { margin: 0; font-size: 26px; letter-spacing: -.6px; }
.filters { background: #fff; border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); display: grid; gap: 14px; }
.filter-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.filter-row .label { width: 64px; font-weight: 700; font-size: 14px; color: var(--ink-2); flex: none; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 16px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.toolbar { display: flex; align-items: center; justify-content: space-between; margin: 22px 0 12px; gap: 12px; flex-wrap: wrap; }
.toolbar .count { color: var(--ink-2); font-size: 14px; }
.toolbar .count b { color: var(--accent); }
select, input[type=text], input[type=tel], input[type=number], input[type=password], textarea {
  font: inherit; border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; background: #fff; color: var(--ink);
}
select:focus, input:focus, textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.search { min-width: 220px; }

/* ── 상품 카드 ── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; margin-bottom: 48px; }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 18px 20px; display: flex; flex-direction: column; position: relative; transition: transform .15s, box-shadow .15s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgba(0,0,0,.10); }
.card .badges { display: flex; gap: 6px; min-height: 22px; flex-wrap: wrap; }
.badge { font-size: 11.5px; font-weight: 700; padding: 3px 8px; border-radius: 6px; background: var(--accent-soft); color: var(--accent-dark); }
.badge.gray { background: #eef0f3; color: var(--ink-2); }
.badge.new { background: #e6f0ff; color: #1b5fb3; }
.badge.best { background: #fff1dc; color: #b55d00; }
.muted-inline { font-weight: 500; font-size: 12.5px; color: var(--muted); margin-left: 6px; }
.card-select { width: 100%; }
.notes-box { margin-bottom: 60px; }
.notes-box h3 { margin: 0 0 10px; font-size: 17px; }
.notes-box ul { margin: 0; padding-left: 18px; color: var(--ink-2); font-size: 13.5px; line-height: 1.75; }
.notes-links { display: flex; gap: 18px; margin-top: 12px; font-weight: 700; }
.notes-links a { color: var(--accent); }
/* 고객센터 · 신청확인 */
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin: 28px 0 18px; overflow-x: auto; }
.tabs button { border: none; background: none; padding: 12px 16px; font-weight: 700; color: var(--muted); border-bottom: 3px solid transparent; white-space: nowrap; }
.tabs button.on { color: var(--ink); border-bottom-color: var(--accent); }
.board-list { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.board-item { padding: 16px 20px; border-bottom: 1px solid var(--line); cursor: pointer; }
.board-item:last-child { border-bottom: none; }
.board-item .t { font-weight: 700; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.board-item .m { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.board-item .body { margin-top: 10px; font-size: 14px; line-height: 1.7; color: var(--ink-2); white-space: pre-wrap; display: none; }
.board-item.open .body { display: block; }
.board-item .answer { margin-top: 10px; background: #f7f7f9; border-radius: 10px; padding: 12px 14px; font-size: 14px; white-space: pre-wrap; }
.stars { color: #f5a623; letter-spacing: 1px; }
.board-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; gap: 10px; flex-wrap: wrap; }
.form-panel label { display: block; font-size: 13px; font-weight: 700; margin: 12px 0 6px; }
.form-panel input, .form-panel textarea, .form-panel select { width: 100%; }
.order-item { border: 1px solid var(--line); border-radius: 14px; padding: 16px; margin-top: 12px; background: #fff; }
.order-item .st { font-weight: 800; }
.st.s-접수 { color: #1b5fb3; } .st.s-상담중 { color: #b55d00; } .st.s-개통완료 { color: var(--ok); } .st.s-취소 { color: var(--muted); }
.card .photo { height: 210px; display: grid; place-items: center; margin: 8px 0 14px; }
.card .photo img { max-height: 200px; max-width: 88%; object-fit: contain; }
.noimg { width: 92px; height: 170px; border: 6px solid #d9d9de; border-radius: 22px; position: relative; }
.noimg::after { content: "사진 준비중"; position: absolute; inset: auto 0 -30px; font-size: 12px; color: var(--muted); text-align: center; white-space: nowrap; margin-left: -20px; margin-right: -20px; }
.card .name { font-size: 18px; font-weight: 800; letter-spacing: -.4px; margin: 0 0 6px; }
.carriers { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 12px; }
.carrier { font-size: 11px; font-weight: 700; border: 1px solid var(--line); border-radius: 5px; padding: 2px 6px; color: var(--ink-2); }
.card .release { font-size: 13px; color: var(--muted); }
.card .release s { margin-left: 4px; }
.card .price-line { display: flex; align-items: baseline; justify-content: space-between; margin-top: 4px; }
.card .price-line .k { font-size: 13px; color: var(--ink-2); }
.card .price-line .v { font-size: 22px; font-weight: 800; letter-spacing: -.5px; }
.card .price-line .v.accent { color: var(--accent); }
.card .monthly { font-size: 13px; color: var(--ink-2); text-align: right; margin-top: 2px; }
.card .cond { font-size: 12px; color: var(--muted); margin-top: 10px; border-top: 1px dashed var(--line); padding-top: 10px; }
.card .ask { font-size: 18px; font-weight: 800; color: var(--accent); }
.empty { text-align: center; color: var(--muted); padding: 80px 0; background: #fff; border-radius: var(--radius); }

/* ── 상세 ── */
.crumbs { font-size: 13px; color: var(--muted); margin: 22px 0 12px; }
.detail { display: grid; grid-template-columns: 1fr 460px; gap: 28px; align-items: start; margin-bottom: 60px; }
.panel { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }
.gallery { display: grid; place-items: center; min-height: 460px; position: sticky; top: 88px; }
.gallery img { max-height: 420px; max-width: 90%; object-fit: contain; }
.detail h1 { margin: 6px 0 4px; font-size: 28px; letter-spacing: -.8px; }
.section { margin-top: 22px; }
.section h3 { font-size: 15px; margin: 0 0 10px; color: var(--ink-2); }
.seg { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; }
.seg button { border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: 12px 8px; font-weight: 700; color: var(--ink-2); }
.seg button small { display: block; font-weight: 500; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.seg button.on { border: 2px solid var(--accent); color: var(--accent); padding: 11px 7px; background: #fff7fb; }
.seg button:disabled { opacity: .35; cursor: not-allowed; }
.plans { display: grid; gap: 8px; }
.plan { display: flex; justify-content: space-between; align-items: center; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fff; text-align: left; }
.plan.on { border: 2px solid var(--accent); padding: 11px 13px; background: #fff7fb; }
.plan .t { font-weight: 700; }
.plan .s { font-size: 12.5px; color: var(--muted); }
.plan .p { font-weight: 800; color: #e0102f; white-space: nowrap; font-size: 16px; }
.summary { margin-top: 24px; border-radius: 16px; background: #fafafb; border: 1px solid var(--line); padding: 18px; }
.summary .row { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14.5px; }
.summary .row .k { color: var(--ink-2); }
.summary .row.minus .v { color: var(--accent); }
.summary .row.total { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 12px; font-weight: 800; font-size: 17px; }
.summary .row.total .v { color: var(--accent); font-size: 22px; }
.summary .note { font-size: 12px; color: var(--muted); margin-top: 10px; line-height: 1.55; }
.monthly-box { margin-top: 14px; background: var(--ink); color: #fff; border-radius: 14px; padding: 16px 18px; }
.monthly-box .row { display: flex; justify-content: space-between; font-size: 14px; padding: 3px 0; opacity: .9; }
.monthly-box .row.big { font-size: 20px; font-weight: 800; opacity: 1; margin-top: 6px; }
.cta { margin-top: 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn { border: none; border-radius: 12px; padding: 15px; font-weight: 800; font-size: 16px; }
.btn.primary { background: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-dark); }
.btn.ghost { background: #fff; border: 1px solid var(--ink); color: var(--ink); }
.compare { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.compare th, .compare td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: right; }
.compare th:first-child, .compare td:first-child { text-align: left; }
.compare tr.on td { background: #fff7fb; font-weight: 700; }
.compare td.best { color: var(--accent); font-weight: 800; }

/* ── 상담 신청 창 ── */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: none; align-items: center; justify-content: center; z-index: 50; padding: 16px; }
.modal.open { display: flex; }
.modal .box { background: #fff; border-radius: 20px; width: 100%; max-width: 440px; padding: 24px; }
.modal h3 { margin: 0 0 6px; }
.modal .sub { font-size: 13px; color: var(--ink-2); margin-bottom: 16px; }
.modal label { display: block; font-size: 13px; font-weight: 700; margin: 12px 0 6px; }
.modal input, .modal textarea { width: 100%; }
.modal .agree { display: flex; gap: 8px; align-items: flex-start; font-weight: 500; font-size: 12.5px; color: var(--ink-2); }
.modal .agree input { width: auto; margin-top: 2px; }
.modal .actions { display: grid; grid-template-columns: 1fr 2fr; gap: 8px; margin-top: 18px; }
.msg { font-size: 13px; margin-top: 10px; }
.msg.err { color: #c62828; }

/* ── 인터넷·TV / 결합 할인 ── */
.hero-home { background: linear-gradient(120deg, #0b1f3a 0%, #134a8e 55%, #1b7fd6 100%); }
.hero-bundle { background: linear-gradient(120deg, #1a0b3a 0%, #4b1a8e 55%, var(--accent) 100%); }
a.stamp { color: #fff; font-weight: 700; }
a.stamp:hover { background: rgba(255,255,255,.25); }
.home-card { gap: 2px; }
.home-card .speed { display: flex; flex-direction: column; margin: 14px 0 6px; }
.home-card .speed b { font-size: 34px; letter-spacing: -1px; color: var(--ink); line-height: 1.1; }
.home-card .speed span { font-size: 12.5px; color: var(--muted); }
.home-card .tvline { font-size: 13px; color: var(--ink-2); min-height: 20px; margin-bottom: 10px; }
.home-card .monthly s { color: var(--muted); }
.gifts { margin-top: 12px; border-top: 1px dashed var(--line); padding-top: 10px; display: grid; gap: 4px; }
.gifts div { display: flex; justify-content: space-between; font-size: 13.5px; color: var(--ink-2); }
.gifts div b { color: var(--ink); }
.gifts div.hot b { color: var(--accent); }
.home-card .apply { margin-top: 14px; padding: 12px; font-size: 15px; }
.fine { font-size: 12.5px; color: var(--muted); line-height: 1.6; margin: 0 0 48px; }
.bundle-layout { grid-template-columns: 1fr 1fr; margin-top: 28px; margin-bottom: 20px; }
#offers { display: grid; gap: 14px; }
.offer { cursor: pointer; border: 2px solid transparent; }
.offer.on { border-color: var(--accent); }
.offer h3 { margin: 8px 0 4px; font-size: 19px; }
.offer p { margin: 0 0 12px; color: var(--ink-2); font-size: 14px; line-height: 1.55; }
.offer .compare th { text-align: left; white-space: nowrap; color: var(--ink-2); }
.offer .compare td { text-align: left; }
.offer ul { margin: 12px 0 0; padding-left: 18px; color: var(--ink-2); font-size: 13.5px; line-height: 1.7; }
.home-tip { margin-top: 18px; border-radius: 14px; border: 1px solid #cfe0f7; background: #f3f8ff; padding: 14px 16px; font-size: 14px; }
.home-tip h4 { margin: 0 0 6px; font-size: 15px; }
.home-tip .line { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; color: var(--ink-2); }
.home-tip .line b { color: var(--ink); white-space: nowrap; }
.home-tip a { display: inline-block; margin-top: 8px; color: #1b5fb3; font-weight: 700; }

footer { border-top: 1px solid var(--line); background: #fff; color: var(--muted); font-size: 13px; }
footer .wrap { padding-top: 26px; padding-bottom: 40px; line-height: 1.7; }

@media (max-width: 900px) {
  .detail { grid-template-columns: 1fr; }
  .gallery { position: static; min-height: 300px; }
  .gallery img { max-height: 300px; }
  .hero h1 { font-size: 24px; }
  .hero .wrap { flex-direction: column; align-items: flex-start; }
  .site-header .inner { flex-wrap: wrap; height: auto; padding-top: 10px; row-gap: 4px; }
  .site-header nav { order: 3; width: 100%; gap: 16px; font-size: 14px; overflow-x: auto; white-space: nowrap; padding: 6px 0 10px; }
  .site-header .call { margin-left: auto; font-size: 13px; }
  .bundle-layout { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .card { padding: 12px; }
  .card .photo { height: 150px; }
  .card .photo img { max-height: 140px; }
  .card .name { font-size: 15px; }
  .card .price-line .v { font-size: 17px; }
  .filter-row .label { width: 100%; }
  .noimg { width: 64px; height: 120px; }
  .logo { font-size: 17px; gap: 6px; white-space: nowrap; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .logo .dot { width: 22px; height: 22px; font-size: 12px; flex: none; }
  .site-header nav { gap: 14px; font-size: 13.5px; }
  .home-grid { grid-template-columns: 1fr; }
  .home-card { padding: 16px; }
}

/* 상세 페이지 사양표 */
.media-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.media-col .gallery { position: static; }
@media (min-width: 901px) {
  .media-col { position: sticky; top: var(--stick-top, 88px); }
  .media-col .gallery { min-height: 360px; }
  .media-col .gallery img { max-height: 330px; }
}
.spec-panel h3 { margin: 0 0 10px; font-size: 17px; letter-spacing: -.3px; }
.spec-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.spec-table th { width: 110px; text-align: left; font-weight: 600; color: var(--ink-2); padding: 10px 12px 10px 0; vertical-align: top; border-top: 1px solid var(--line); white-space: nowrap; }
.spec-table td { padding: 10px 0; border-top: 1px solid var(--line); line-height: 1.5; word-break: keep-all; }
.spec-table tr:first-child th, .spec-table tr:first-child td { border-top: none; }
.spec-note { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
@media (max-width: 600px) { .spec-table th { width: 88px; } .spec-table { font-size: 13px; } }
@media (max-width: 900px) { .media-col { display: contents; } .media-col .spec-panel { order: 2; } }

/* 통신사·할인방법 비교표: 휴대폰에서는 줄마다 카드로 */
.compare th { white-space: nowrap; }
.compare .cmp-best { display: none; }
@media (max-width: 600px) {
  .compare, .compare tbody { display: block; width: 100%; }
  .compare tr:first-child { display: none; }
  .compare tr[data-c] { display: block; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 10px; background: #fff; }
  .compare tr[data-c].on { border-color: var(--accent); background: #fff7fb; }
  .compare tr.on td { background: transparent; }
  .compare td { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; border: none; text-align: right; font-size: 13.5px; }
  .compare td::before { content: attr(data-l); color: var(--muted); font-weight: 500; text-align: left; white-space: nowrap; }
  .compare td.head { display: block; text-align: left; font-size: 15px; font-weight: 800; padding: 2px 0 8px; margin-bottom: 4px; border-bottom: 1px dashed var(--line); }
  .compare td.head::before { content: none; }
  .compare .cmp-best { display: inline-block; margin-left: 6px; font-size: 11px; font-weight: 700; color: #fff; background: var(--accent); border-radius: 6px; padding: 1px 6px; vertical-align: 2px; }
  .compare td.total { font-weight: 800; color: #e0102f; }
}
