/* 사이트 플래너 — 화면 구성 기준: IKEA Kreativ */
.is-planner { overflow: hidden; background: #fff; }
.pl { --bg: #f2f1ee; --card: #fff; position: fixed; inset: 0; display: grid; grid-template-columns: 372px 1fr; background: #fff; font-size: 14px; }
.pl-side { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: #fff; z-index: 3; }
.pl-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); flex: none; }
.pl-tabs button { height: 56px; display: flex; align-items: center; justify-content: center; gap: 8px; font-weight: 500; color: var(--ink-3); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.pl-tabs button.is-active { color: var(--ink); border-color: var(--ink); }
.pl-tabs svg { width: 18px; height: 18px; }
.pl-n { font: 600 11px/18px var(--font-en); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--lime); color: var(--lime-ink); font-style: normal; }
.pl-sheet-x { display: none !important; }
.pl-pane { flex: 1; min-height: 0; overflow-y: auto; padding: 14px 16px 24px; scrollbar-width: thin; }
.pl-search { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 16px; background: var(--bg); border-radius: 22px; margin-bottom: 12px; }
.pl-search svg { width: 18px; height: 18px; flex: none; }
.pl-search input { flex: 1; min-width: 0; border: 0; background: none; outline: none; font-size: 14.5px; }
.pl-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.pl-chips button { height: 34px; padding: 0 14px; border-radius: 17px; background: var(--bg); font-size: 13px; font-weight: 500; transition: background .15s, color .15s; }
.pl-chips button:hover { background: var(--bg-2); }
.pl-chips button.is-active { background: var(--ink); color: #fff; }
.pl-sub button { height: 30px; padding: 0 12px; font-weight: 400; background: #fff; border: 1px solid var(--line-2); }
.pl-sub:empty { display: none; }
.pl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px 10px; }
.pl-card { display: grid; gap: 3px; text-align: left; align-content: start; cursor: grab; }
.pl-card-img { display: grid; place-items: center; aspect-ratio: 1; background: #fff; border: 1px solid transparent; transition: border-color .15s, transform .2s var(--ease); overflow: hidden; }
.pl-card-img img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.pl-card-img svg { width: 46%; height: 46%; color: #4f7a3a; }
.pl-card-x .pl-card-img { background: #eef3e4; }
.pl-card:hover .pl-card-img { border-color: var(--ink); }
.pl-card:active .pl-card-img { transform: scale(.96); }
.pl-card b { font-weight: 600; font-size: 12.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pl-card small { font-size: 11px; color: var(--ink-3); line-height: 1.3; }
.pl-more { grid-column: 1 / -1; height: 40px; border: 1px solid var(--line-2); border-radius: 20px; font-weight: 500; margin-top: 6px; }
.pl-more:hover { background: var(--bg); }
.pl-empty { grid-column: 1 / -1; color: var(--ink-3); padding: 22px 0; font-size: 13.5px; }
.pl-list-head { display: flex; justify-content: space-between; align-items: center; margin: 6px 0 8px; font-size: 13px; } .pl-list-head span { color: var(--ink-3); }
.pl-list { display: grid; gap: 4px; margin-bottom: 18px; }
.pl-list li { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; padding: 6px 10px 6px 6px; background: var(--bg); cursor: pointer; }
.pl-list li:hover { background: var(--bg-2); }
.pl-list-x li { grid-template-columns: 1fr auto; padding: 10px; }
.pl-list b { display: block; font-weight: 500; font-size: 13.5px; } .pl-list small { color: var(--ink-3); font: 11px var(--mono); } .pl-list i { font-style: normal; font-weight: 600; font-family: var(--font-en); }
.pl-sum { margin: 4px 0 16px; border-top: 1px solid var(--line); } .pl-sum > div { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; } .pl-sum dt { color: var(--ink-2); }
#pllist .btn { margin-top: 6px; } #pllist .btn[disabled] { opacity: .4; pointer-events: none; }

.pl-main { position: relative; display: grid; grid-template-rows: 56px 1fr; min-width: 0; min-height: 0; }
.pl-top { display: flex; align-items: center; gap: 6px; padding: 0 12px 0 8px; border-bottom: 1px solid var(--line); background: #fff; z-index: 2; min-width: 0; }
.pl-ic { width: 38px; height: 38px; display: inline-grid; place-items: center; border-radius: 50%; flex: none; transition: background .15s; }
.pl-ic:hover { background: var(--bg); } .pl-ic svg { width: 19px; height: 19px; }
.pl-logo { width: 84px; flex: none; margin: 0 6px 0 2px; }
.pl-title { flex: 1; min-width: 60px; border: 0; background: none; font-weight: 600; font-size: 14.5px; padding: 8px 10px; border-radius: 6px; outline: none; text-overflow: ellipsis; }
.pl-title:hover, .pl-title:focus { background: var(--bg); }
.pl-top-tools { display: flex; align-items: center; gap: 2px; flex: none; }
.pl-sep { width: 1px; height: 22px; background: var(--line-2); margin: 0 6px; }
.pl-quote { height: 38px; border-radius: 19px; margin-left: 8px; text-transform: none; letter-spacing: 0; font-size: 13.5px; font-weight: 600; }
.pl-stage { position: relative; overflow: hidden; background: #dfe3e0; min-height: 0; }
.pl-canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; touch-action: none; outline: none; }
.pl[data-mode="terrain"] .pl-canvas, .pl[data-mode="surface"] .pl-canvas, .pl[data-mode="measure"] .pl-canvas { cursor: crosshair; }
.pl-zoom { position: absolute; top: 16px; right: 16px; display: grid; background: #fff; border-radius: 22px; box-shadow: 0 2px 10px rgba(0, 0, 0, .12); overflow: hidden; }
.pl-zoom button { width: 44px; height: 44px; font-size: 22px; font-weight: 400; } .pl-zoom button:hover { background: var(--bg); } .pl-zoom button + button { border-top: 1px solid var(--line); }
.pl-status { position: absolute; left: 16px; top: 16px; font: 11.5px var(--mono); color: var(--ink-2); background: rgba(255, 255, 255, .7); padding: 6px 10px; border-radius: 14px; backdrop-filter: blur(6px); pointer-events: none; }
.pl-hint { position: absolute; left: 50%; top: 16px; transform: translateX(-50%); background: var(--ink); color: #fff; font-size: 12.5px; padding: 8px 14px; border-radius: 16px; pointer-events: none; max-width: calc(100% - 140px); text-align: center; }
.pl-bar { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; gap: 10px; z-index: 2; max-width: calc(100% - 24px); }
.pl-bar-g { display: flex; gap: 2px; padding: 5px; background: #fff; border-radius: 28px; box-shadow: 0 4px 18px rgba(0, 0, 0, .14); }
.pl-bar button { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 16px; border-radius: 21px; font-size: 13px; font-weight: 600; white-space: nowrap; transition: background .15s; }
.pl-bar button:hover { background: var(--bg); } .pl-bar button.is-active { background: var(--bg-2); }
.pl-bar [data-group="tool"] button.is-active { background: var(--ink); color: #fff; }
.pl-bar svg { width: 19px; height: 19px; }
.pl-ctx { position: absolute; right: 16px; top: 118px; width: 292px; max-height: calc(100% - 210px); overflow: auto; background: #fff; border-radius: 14px; box-shadow: 0 6px 28px rgba(0, 0, 0, .16); padding: 16px; display: grid; gap: 12px; z-index: 2; }
.pl-ctx h3 { font-weight: 600; font-size: 15px; padding-right: 30px; }
.pl-ctx-x { position: absolute; top: 9px; right: 9px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; } .pl-ctx-x:hover { background: var(--bg); } .pl-ctx-x svg { width: 16px; height: 16px; }
.pl-seg { display: grid; grid-template-columns: repeat(auto-fit, minmax(48px, 1fr)); gap: 3px; background: var(--bg); padding: 3px; border-radius: 10px; }
.pl-seg button { display: grid; justify-items: center; gap: 3px; padding: 8px 2px; border-radius: 8px; font-size: 11.5px; font-weight: 500; } .pl-seg svg { width: 18px; height: 18px; }
.pl-seg button.is-active { background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .14); }
.pl-range { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; font-size: 12.5px; color: var(--ink-2); align-items: center; }
.pl-range input { grid-column: 1 / -1; width: 100%; accent-color: var(--ink); } .pl-range output { font: 12px var(--mono); color: var(--ink); grid-row: 1; grid-column: 2; }
.pl-tip { font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.pl-link { justify-self: start; font-size: 12.5px; text-decoration: underline; text-underline-offset: 3px; color: var(--ink-2); }
.pl-surfs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.pl-surfs button { display: flex; align-items: center; gap: 8px; padding: 5px; border-radius: 8px; border: 1px solid var(--line); font-size: 12px; text-align: left; line-height: 1.2; }
.pl-surfs i { width: 28px; height: 28px; border-radius: 5px; flex: none; border: 1px solid rgba(0, 0, 0, .1); }
.pl-surfs button.is-active { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.pl-size { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-2); }
.pl-size label { display: grid; gap: 3px; } .pl-size input { width: 64px; height: 36px; border: 1px solid var(--line-2); padding: 0 8px; border-radius: 6px; font-size: 14px; color: var(--ink); }
.pl-size .btn { height: 36px; border-radius: 18px; }
.pl-check { display: flex; gap: 9px; align-items: center; font-size: 13px; } .pl-check input { width: 17px; height: 17px; accent-color: var(--ink); }
.pl-float { position: absolute; left: 0; top: 0; background: #fff; border-radius: 12px; box-shadow: 0 6px 24px rgba(0, 0, 0, .18); padding: 8px 8px 6px; display: grid; gap: 4px; pointer-events: auto; z-index: 1; white-space: nowrap; }
.pl-float-name { display: flex; gap: 8px; align-items: baseline; padding: 0 6px; font-size: 13px; } .pl-float-name b { font-weight: 600; max-width: 200px; overflow: hidden; text-overflow: ellipsis; } .pl-float-name em { font: 11px var(--mono); color: var(--ink-3); font-style: normal; }
.pl-float-btns { display: flex; gap: 2px; } .pl-float-btns > * { width: 36px; height: 34px; display: grid; place-items: center; border-radius: 8px; } .pl-float-btns > *:hover { background: var(--bg); } .pl-float-btns svg { width: 17px; height: 17px; }
.pl-measure { position: absolute; left: 0; top: 0; background: var(--ink); color: #fff; padding: 6px 10px; border-radius: 8px; display: grid; text-align: center; pointer-events: none; font-size: 12px; } .pl-measure b { font: 600 14px var(--font-en); } .pl-measure span { opacity: .8; font-family: var(--mono); font-size: 11px; }
.pl-start { position: absolute; inset: 56px 0 0 0; z-index: 4; background: rgba(240, 240, 238, .86); backdrop-filter: blur(10px); display: grid; place-items: center; padding: 20px; overflow: auto; animation: fade .3s; }
.pl-start-box { background: #fff; padding: clamp(22px, 3vw, 40px); width: min(920px, 100%); display: grid; gap: 16px; box-shadow: 0 20px 80px rgba(0, 0, 0, .16); justify-items: start; }
.pl-start-box h2 { font-weight: 500; font-size: clamp(22px, 2.4vw, 30px); letter-spacing: -.02em; }
.pl-tpls { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; width: 100%; }
.pl-tpls button { display: grid; gap: 4px; text-align: left; align-content: start; }
.pl-tpls b { font-weight: 600; font-size: 15px; margin-top: 6px; } .pl-tpls small { color: var(--ink-2); font-size: 12px; line-height: 1.35; }
.pl-tpl-art { display: block; aspect-ratio: 4 / 3; background: #cfe0b4; border: 1px solid transparent; position: relative; overflow: hidden; transition: border-color .15s; }
.pl-tpls button:hover .pl-tpl-art { border-color: var(--ink); }
.pl-tpl-park { background: radial-gradient(circle at 56% 54%, #a8a9a6 0 17%, transparent 17.500%), radial-gradient(circle at 20% 76%, #6fb1c9 0 9%, transparent 9.500%), linear-gradient(8deg, transparent 47%, #c9c1b2 47% 55%, transparent 55%), radial-gradient(circle at 22% 26%, #6f9348 0 24%, transparent 40%), #86a85a; }
.pl-tpl-play { background: radial-gradient(circle at 80% 76%, #e3d2a4 0 11%, transparent 11.500%), radial-gradient(ellipse at 50% 50%, #e2b33c 0 24%, #4f9a63 24.500% 40%, transparent 40.500%), #86a85a; }
.pl-tpl-dog { background: radial-gradient(circle at 18% 22%, #7a5a3f 0 11%, transparent 11.500%), linear-gradient(170deg, transparent 44%, #cdb590 44% 53%, transparent 53%), radial-gradient(circle at 76% 34%, #6f9348 0 20%, transparent 34%), #86a85a; }
.pl-tpl-empty { background: repeating-linear-gradient(0deg, transparent 0 15px, rgba(0, 0, 0, .08) 15px 16px), repeating-linear-gradient(90deg, transparent 0 15px, rgba(0, 0, 0, .08) 15px 16px), #86a85a; }

@media (max-width: 1100px) { .pl { grid-template-columns: 300px 1fr; } .pl-grid { grid-template-columns: repeat(2, 1fr); } .pl-bar button span { display: none; } .pl-bar button { padding: 0 13px; } .pl-logo { display: none; } }

/* 모바일: 제품 패널은 아래에서 올라오는 시트, 도구 바는 그 위 */
@media (max-width: 760px) {
  .pl { grid-template-columns: 1fr; }
  .pl-side { position: fixed; inset: auto 0 0 0; height: 62svh; transform: translateY(calc(100% - 54px)); transition: transform .35s var(--ease); border-right: 0; border-radius: 16px 16px 0 0; box-shadow: 0 -8px 32px rgba(0, 0, 0, .16); z-index: 6; }
  .pl-side.is-open { transform: none; }
  .pl-tabs { grid-template-columns: 1fr 1fr 54px; } .pl-tabs button { height: 54px; }
  .pl-sheet-x { display: flex !important; } .pl-side.is-open .pl-sheet-x svg { transform: rotate(180deg); } .pl-sheet-x svg { transform: rotate(0); transition: transform .3s; width: 18px; height: 18px; }
  .pl-side:not(.is-open) .pl-sheet-x svg { transform: rotate(180deg); } .pl-side.is-open .pl-sheet-x svg { transform: none; }
  .pl-grid { grid-template-columns: repeat(3, 1fr); }
  .pl-main { grid-template-rows: 52px 1fr; height: 100svh; }
  .pl-top-tools [data-act="shot"], .pl-top-tools [data-act="ar"], .pl-top-tools [data-open="lang"], .pl-sep { display: none; }
  .pl-quote { padding: 0 12px; } .pl-quote svg { display: none; }
  .pl-bar { bottom: 66px; gap: 5px; left: 0; right: 0; transform: none; max-width: none; padding: 6px 8px; overflow-x: auto; scrollbar-width: none; justify-content: safe center; } .pl-bar::-webkit-scrollbar { display: none; } .pl-bar-g { flex: none; padding: 4px; } .pl-bar button { height: 38px; padding: 0 9px; }
  .pl-ctx { left: 10px; right: 10px; top: auto; bottom: 122px; width: auto; max-height: 44svh; }
  .pl-zoom { display: none; } .pl-status { top: 10px; left: 10px; } .pl-hint { top: 44px; max-width: calc(100% - 20px); }
  .pl-tpls { grid-template-columns: 1fr 1fr; } .pl-start { inset: 52px 0 0 0; place-items: start center; }
}
