/* === OT-VERIFY / OT-SIMULATOR 2026-11-23 (STAGE4) === */
/* 목적: /verify/ 정품 검증 허브 + /simulator/ 반감기 시뮬레이터 전용 스타일 (모바일 퍼스트) */
/* 범위: .otvh-*, .otsm-* 신규 클래스만. 기존 테마 스타일 불변 */
/* 롤백: 이 파일 + page-verify.php / page-simulator.php / ot-simulator.js 삭제 */

.otvh-wrap, .otsm-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 32px 16px 72px;
  color: #E8EBF2;
  overflow-x: hidden;
}

/* 공통 kicker / title */
.otvh-kicker, .otsm-kicker {
  font-family: 'Courier New', Consolas, monospace;
  font-size: 11px; font-weight: 800; letter-spacing: 2px;
  color: #F5C518; text-transform: uppercase;
  margin: 0 0 8px;
}
.otvh-title, .otsm-title {
  margin: 0 0 10px;
  font-size: clamp(24px, 6vw, 38px);
  font-weight: 900; letter-spacing: -.5px; line-height: 1.15;
}
.otvh-sub, .otsm-sub {
  margin: 0 0 24px;
  font-size: 13.5px; line-height: 1.75; color: #9AA3B8;
  max-width: 720px;
}

/* 상단 지표 칩 */
.otvh-stats { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }
.otvh-stat {
  flex: 1 1 110px;
  border: 1px solid #2B3347; border-radius: 12px;
  background: #161B27; padding: 12px 14px;
}
.otvh-stat b { display: block; font-size: 18px; font-weight: 900; color: #F5C518; }
.otvh-stat span { font-family: 'Courier New', monospace; font-size: 9.5px; letter-spacing: 1px; color: #9AA3B8; }

/* 브랜드 그리드 */
.otvh-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 620px) { .otvh-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .otvh-grid { grid-template-columns: repeat(3, 1fr); } }

.otvh-card {
  display: flex; flex-direction: column; gap: 12px;
  border: 1px solid #2B3347; border-radius: 14px;
  background: #161B27; padding: 16px;
  transition: border-color .18s ease, transform .18s ease;
}
.otvh-card:hover { border-color: rgba(245,197,24,.55); transform: translateY(-2px); }
.otvh-top { display: flex; align-items: center; gap: 12px; }
.otvh-logo {
  width: 46px; height: 46px; border-radius: 10px; flex: 0 0 46px;
  background: #0C1018; border: 1px solid #2B3347;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.otvh-logo img { max-width: 38px; max-height: 38px; object-fit: contain; }
.otvh-name { font-size: 14px; font-weight: 800; letter-spacing: .3px; line-height: 1.25; }
.otvh-meta { font-family: 'Courier New', monospace; font-size: 10px; letter-spacing: 1px; color: #9AA3B8; margin-top: 3px; }
.otvh-desc { font-size: 12px; line-height: 1.6; color: #8A93A6; min-height: 34px; }
.otvh-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.otvh-btn {
  flex: 1 1 auto; min-height: 40px; display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; border-radius: 10px; padding: 0 14px;
  font-family: 'Courier New', monospace; font-size: 11px; font-weight: 800; letter-spacing: .8px;
  text-decoration: none; border: 1px solid #2B3347; color: #E8EBF2; background: #0C1018;
  transition: border-color .18s ease, color .18s ease;
}
.otvh-btn:hover { border-color: #F5C518; color: #F5C518; }
.otvh-btn.is-primary { background: #F5C518; border-color: #F5C518; color: #141000; }
.otvh-btn.is-primary:hover { filter: brightness(1.06); color: #141000; }
.otvh-btn[aria-disabled="true"] { opacity: .45; pointer-events: none; }

/* 절차 안내 */
.otvh-steps { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 36px; }
@media (min-width: 780px) { .otvh-steps { grid-template-columns: repeat(3, 1fr); } }
.otvh-step {
  border: 1px solid #2B3347; border-radius: 14px; background: #0C1018; padding: 18px;
}
.otvh-step-no {
  font-family: 'Courier New', monospace; font-size: 11px; font-weight: 800;
  letter-spacing: 1px; color: #F5C518; margin-bottom: 8px;
}
.otvh-step h3 { margin: 0 0 6px; font-size: 14px; font-weight: 800; }
.otvh-step p { margin: 0; font-size: 12.5px; line-height: 1.65; color: #9AA3B8; }

.otvh-note {
  margin-top: 28px; padding: 14px 16px; border-radius: 12px;
  border: 1px solid rgba(245,197,24,.28); background: rgba(245,197,24,.06);
  font-size: 12px; line-height: 1.7; color: #C5C9D6;
}

/* === OT-CALC-SHELL 2026-11-23 (V2) === */
/* 목적: /simulator/ 프로토콜 계산기 전용 레이아웃·폼·반응형 (전역 폼 스타일 침범 차단) */
/* 범위: .ot-calc-shell 하위로 한정. 검증 허브(.otvh-*)·기존 컴포넌트 불변 */
/* 롤백: 이 블록 삭제 (ot-verify.css.bak_simv2_* 복원) */

/* 1) 조상 래퍼 폭·overflow 교정 — 셸이 1200px 울타리에 갇히지 않도록 */
html body.page-template-page-simulator #ot-page-wrap,
html body.page-id-4157 #ot-page-wrap {
  max-width: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  width: 100% !important;
  overflow-x: clip !important;
  overflow-y: visible !important;
}
html body.page-template-page-simulator #ot-footer,
html body.page-id-4157 #ot-footer {
  margin-top: 0 !important;
}

.ot-calc-shell {
  --c-bg: #0E1117;
  --c-card: #161B27;
  --c-card-in: #0D111A;
  --c-line: rgba(255, 255, 255, 0.08);
  --c-line-soft: rgba(255, 255, 255, 0.06);
  --c-ink: #F4F6FA;
  --c-muted: #8E98AE;
  --c-dim: #5E687E;
  --c-gold: #F5C518;
  --c-gold-tint: rgba(245, 197, 24, 0.12);
  --c-danger: #EF4444;
  --c-mono: 'Courier New', Consolas, monospace;

  max-width: 1440px;
  margin: 20px auto 24px;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  color: var(--c-ink);
  box-sizing: border-box;
}
.ot-calc-shell *,
.ot-calc-shell *::before,
.ot-calc-shell *::after { box-sizing: border-box; }

/* 좌측 사이드바 */
.ot-calc-side {
  position: sticky !important;
  top: 88px !important;
  background: #121722;
  border: 1px solid var(--c-line);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 20;
}
.ot-side-cap {
  padding: 6px 10px 12px;
  border-bottom: 1px solid var(--c-line-soft);
  margin-bottom: 2px;
}
.ot-side-cap strong { display: block; font-size: 13.5px; font-weight: 800; color: var(--c-ink); }
.ot-side-cap span { display: block; margin-top: 3px; font-family: var(--c-mono); font-size: 9.5px; letter-spacing: 1px; color: var(--c-dim); }
.ot-tab {
  width: 100%; text-align: left; background: transparent; border: 1px solid transparent;
  color: var(--c-muted); font-family: inherit; font-size: 13px; font-weight: 600;
  padding: 11px 12px; border-radius: 10px; cursor: pointer;
  display: flex; align-items: center; gap: 8px; line-height: 1.35;
}
.ot-tab em {
  font-style: normal; font-family: var(--c-mono); font-size: 10px; letter-spacing: 1px;
  color: var(--c-dim);
}
.ot-tab:hover { color: var(--c-ink); background: rgba(255, 255, 255, 0.03); }
.ot-tab.is-active { background: var(--c-gold-tint); color: var(--c-gold); font-weight: 700; }
.ot-tab.is-active em { color: var(--c-gold); }

/* 메인 컬럼 */
.ot-calc-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ot-pane { display: none; flex-direction: column; gap: 16px; }
.ot-pane.is-active { display: flex; }

/* 헤더 카드 */
.ot-head-card {
  background: var(--c-card); border: 1px solid var(--c-line); border-radius: 16px;
  padding: 22px 24px; display: flex; justify-content: space-between; align-items: flex-start;
  gap: 14px; flex-wrap: wrap;
}
.ot-head-card h1 { margin: 0; font-size: 21px; font-weight: 800; letter-spacing: -0.02em; color: var(--c-ink); }
.ot-head-card p { margin: 6px 0 0; font-size: 13px; line-height: 1.6; color: var(--c-muted); }
.ot-head-meta {
  font-family: var(--c-mono); font-size: 10px; letter-spacing: 1.2px;
  color: var(--c-dim); text-transform: uppercase; white-space: nowrap;
}

/* 카드 */
.ot-card { background: var(--c-card); border: 1px solid var(--c-line); border-radius: 16px; padding: 22px 24px; }
.ot-card-t {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 700; color: var(--c-ink); margin-bottom: 14px;
}
.ot-card-t span { font-family: var(--c-mono); font-size: 10px; letter-spacing: 1px; color: var(--c-dim); font-weight: 500; }

/* 카테고리 필 */
.ot-pills { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.ot-chip {
  background: var(--c-card-in); border: 1px solid var(--c-line); color: var(--c-muted);
  font-family: inherit; font-size: 12px; font-weight: 600; padding: 7px 12px;
  border-radius: 999px; cursor: pointer; white-space: nowrap;
}
.ot-chip:hover { color: var(--c-ink); }
.ot-chip.is-on { background: var(--c-gold); border-color: var(--c-gold); color: #0E1117; font-weight: 700; }

/* 폼 그리드 */
.ot-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.ot-fld { min-width: 0; }
.ot-fld.full { grid-column: 1 / -1; }
.ot-fld > label {
  display: flex; justify-content: space-between; align-items: baseline; gap: 8px;
  font-size: 12px; font-weight: 600; color: var(--c-muted); margin-bottom: 6px;
}
.ot-fld > label em { font-style: normal; font-family: var(--c-mono); font-size: 11px; color: var(--c-gold); }

/* 전역 폼 스타일 차단 — 고명시도 + !important */
html body .ot-calc-shell input.ot-inp,
html body .ot-calc-shell select.ot-sel {
  width: 100% !important;
  height: 44px !important;
  background-color: #0D111A !important;
  color: #F4F6FA !important;
  border: 1px solid rgba(255, 255, 255, 0.10) !important;
  border-radius: 10px !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 0 14px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  line-height: 44px !important;
  -webkit-appearance: none !important;
  appearance: none !important;
  background-image: none !important;
  transition: border-color .15s ease, box-shadow .15s ease;
}
html body .ot-calc-shell select.ot-sel {
  padding-right: 34px !important;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238E98AE' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 12px 8px !important;
}
html body .ot-calc-shell input.ot-inp::-webkit-inner-spin-button,
html body .ot-calc-shell input.ot-inp::-webkit-outer-spin-button {
  -webkit-appearance: none !important; margin: 0 !important;
}
html body .ot-calc-shell input.ot-inp { -moz-appearance: textfield !important; }
html body .ot-calc-shell input.ot-inp:focus,
html body .ot-calc-shell select.ot-sel:focus {
  border-color: #F5C518 !important;
  box-shadow: 0 0 0 3px rgba(245, 197, 24, 0.14) !important;
}
html body .ot-calc-shell input.ot-inp::placeholder { color: #5E687E !important; }

/* 퀵 선택 버튼 */
.ot-qbtns { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
html body .ot-calc-shell .ot-qbtn {
  height: 32px !important;
  border-radius: 8px !important;
  background: #0D111A !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  color: var(--c-muted); font-family: var(--c-mono); font-size: 11.5px;
  padding: 0 10px; cursor: pointer; line-height: 30px;
}
html body .ot-calc-shell .ot-qbtn:hover { color: var(--c-ink); }
html body .ot-calc-shell .ot-qbtn.is-on {
  background: rgba(245, 197, 24, 0.12) !important;
  border-color: #F5C518 !important;
  color: #F5C518 !important;
}

/* 주사기 패널 */
.ot-syr-panel {
  background: var(--c-card); border: 1px solid var(--c-line); border-radius: 16px;
  padding: 22px 24px; display: flex; flex-direction: column; gap: 14px;
}
.ot-syr-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ot-syr-val { font-family: var(--c-mono); font-size: 24px; font-weight: 800; color: var(--c-gold); line-height: 1.1; }
.ot-syr-val span { font-size: 13px; font-weight: 500; color: var(--c-muted); }
.ot-syr-sub { font-family: var(--c-mono); font-size: 11.5px; color: var(--c-muted); }
.ot-svg-syr { width: 100%; height: 68px; display: block; }

/* 경고 바 */
.ot-alert {
  padding: 12px 14px; border-radius: 12px; font-size: 12.5px; line-height: 1.55;
  background: var(--c-card-in); border: 1px solid var(--c-line); color: var(--c-muted);
}
.ot-alert.danger {
  background: rgba(239, 68, 68, 0.12); border-color: rgba(239, 68, 68, 0.4); color: #FECACA;
}

/* 3열 스펙 스트립 */
.ot-spec-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ot-spec { background: var(--c-card-in); border: 1px solid var(--c-line-soft); border-radius: 12px; padding: 14px 16px; }
.ot-spec label { display: block; font-family: var(--c-mono); font-size: 9.5px; letter-spacing: 1px; color: var(--c-dim); margin-bottom: 6px; }
.ot-spec strong { display: block; font-size: 13px; font-weight: 700; color: var(--c-ink); line-height: 1.45; }

/* 3열 요약(반감기) */
.ot-stat-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ot-stat { background: var(--c-card-in); border: 1px solid var(--c-line-soft); border-radius: 12px; padding: 16px; }
.ot-stat label { display: block; font-size: 11.5px; color: var(--c-muted); margin-bottom: 6px; }
.ot-stat strong { display: block; font-family: var(--c-mono); font-size: 19px; font-weight: 800; color: var(--c-ink); }
.ot-stat strong.gold { color: var(--c-gold); }
.ot-stat small { display: block; margin-top: 4px; font-size: 11.5px; color: var(--c-dim); }

/* 반감기 스택 행 */
.ot-pk-row { display: grid; grid-template-columns: 1.5fr 0.9fr 0.9fr 42px; gap: 8px; align-items: center; }
.ot-pk-row + .ot-pk-row { margin-top: 8px; }
.ot-del {
  width: 42px; height: 44px; border-radius: 10px; background: #0D111A;
  border: 1px solid rgba(255, 255, 255, 0.08); color: var(--c-muted);
  cursor: pointer; font-size: 13px;
}
.ot-del:hover { color: var(--c-danger); border-color: var(--c-danger); }
.ot-del:disabled { opacity: .4; cursor: not-allowed; }
.ot-pk-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--c-line-soft); }
.ot-range-wrap { display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--c-muted); }
.ot-range-wrap input[type="range"] { width: 120px; accent-color: #F5C518; }
.ot-range-wrap strong { font-family: var(--c-mono); color: var(--c-gold); }

/* 버튼 */
.ot-btns { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.ot-btn, .ot-btn-gold {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 42px; padding: 0 18px; border-radius: 999px;
  font-family: inherit; font-size: 12.5px; font-weight: 700; text-decoration: none; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.10); background: #0D111A; color: var(--c-ink);
}
.ot-btn:hover { border-color: var(--c-gold); color: var(--c-gold); }
.ot-btn-gold { background: var(--c-gold); border-color: var(--c-gold); color: #0E1117; }
.ot-btn-gold:hover { filter: brightness(1.06); color: #0E1117; }

/* 반응형 */
@media (max-width: 860px) {
  .ot-calc-shell {
    grid-template-columns: minmax(0, 1fr);
    padding: 0 12px; margin-top: 12px; margin-bottom: 18px; gap: 14px;
  }
  .ot-calc-side {
    position: sticky !important; top: 60px !important;
    flex-direction: row !important; padding: 6px !important;
    border-radius: 12px !important; z-index: 30; gap: 6px;
  }
  .ot-side-cap, .ot-tab em { display: none !important; }
  .ot-tab { flex: 1 1 50%; justify-content: center; text-align: center; font-size: 12.5px; padding: 9px 6px; }
  .ot-head-card, .ot-card, .ot-syr-panel { padding: 18px 16px; }
  .ot-grid-2 { grid-template-columns: minmax(0, 1fr); }
  .ot-spec-strip { grid-template-columns: minmax(0, 1fr); }
  .ot-stat-row { grid-template-columns: minmax(0, 1fr); }
  .ot-pk-row { grid-template-columns: 1fr 1fr 42px; gap: 8px; }
  .ot-pk-row > .ot-fld:first-child { grid-column: 1 / -1; }
  html body .ot-calc-shell input.ot-inp,
  html body .ot-calc-shell select.ot-sel { font-size: 16px !important; }
  .ot-head-card h1 { font-size: 19px; }
}
@media (max-width: 420px) {
  .ot-calc-shell { padding: 0 10px; margin-bottom: 16px; }
  .ot-card, .ot-head-card, .ot-syr-panel { padding: 16px 14px; }
  .ot-pills { gap: 6px; }
  .ot-chip { font-size: 11.5px; padding: 6px 10px; }
  .ot-syr-val { font-size: 21px; }
  .ot-btns { justify-content: stretch; }
  .ot-btns > * { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .ot-calc-shell input.ot-inp,
  .ot-calc-shell select.ot-sel { transition: none !important; }
}
