/* Enterprise 페이지 (/enterprise/, /en/enterprise/): Waytive Warp 팀 도입.
   접두어는 ent-. 움직임은 assets/js/enterprise.js 가 맡는다. 스크립트가 없거나 모션을 줄인
   환경에서는 완성된 화면(입력된 글, 로컬 전사 도식)이 그대로 보인다.
   Warp 위젯 모양은 assets/css/warp-demo.css 의 wd- 규칙을 그대로 쓴다. */

.ent {
  --ent-gold: #d7b65e;
  --ent-gold-pale: #f6e6a8;
  --ent-blue: #9bd2f3;
  --ent-line: rgba(255, 255, 255, 0.08);
  --ent-line-strong: rgba(255, 255, 255, 0.16);
  --ent-panel: rgba(13, 13, 13, 0.92);
  --wd-check: #7191ef;
  --wd-widget-scale: 0.86;
  background: var(--wt-bg-deep);
}

/* ---------------------------------------------------------------- 첫 화면 */

.ent-hero {
  position: relative;
  isolation: isolate;
  display: grid;
  align-items: center;
  min-height: max(42rem, min(100svh, 62rem));
  overflow: hidden;
  padding: calc(var(--wt-banner-offset, 40px) + 6rem) 0 12rem;
  text-align: center;
  background:
    radial-gradient(90% 55% at 50% 100%, rgba(215, 182, 94, 0.09), transparent 62%),
    radial-gradient(70% 50% at 50% 0%, rgba(255, 255, 255, 0.045), transparent 70%),
    var(--wt-bg-deep);
}
.ent-field {
  position: absolute;
  inset: 0;
  z-index: -2;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.ent-hero-shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(48% 38% at 50% 42%, rgba(10, 10, 11, 0.72), transparent 72%),
    linear-gradient(180deg, transparent 72%, var(--wt-bg-deep) 100%);
}
.ent-hero-inner { display: flex; flex-direction: column; align-items: center; }
.ent-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  margin: 0;
  color: var(--ent-gold-pale);
  font-family: var(--wt-font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}
.ent-eyebrow::before,
.ent-eyebrow::after {
  content: "";
  width: 2.25rem;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(215, 182, 94, 0.7));
}
.ent-eyebrow::after { transform: scaleX(-1); }
.ent-hero h1 {
  margin: 1.5rem 0 0;
  font-family: var(--wt-font-sans);
  font-size: clamp(2.75rem, 7.2vw, 6.5rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.02;
  word-break: keep-all;
  background: linear-gradient(180deg, #ffffff 35%, rgba(255, 255, 255, 0.58));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.ent-hero h1 span { display: block; }
.ent-lead {
  max-width: 36rem;
  margin: 1.6rem auto 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: clamp(1rem, 1.45vw, 1.125rem);
  line-height: 1.7;
  word-break: keep-all;
}
.ent-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.75rem; margin-top: 2.25rem; }
.ent-actions .btn { min-width: 11.25rem; }
.ent-hero-widget {
  position: absolute;
  left: 50%;
  top: var(--ent-wave-y, 82%);
  z-index: 1;
  transform: translate(-50%, -50%) scale(1.3);
}

/* ---------------------------------------------------------------- 숫자 띠 */

.ent-stats { position: relative; z-index: 2; margin-top: -5.5rem; }
.ent-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
  border: 1px solid var(--ent-line);
  background: rgba(14, 14, 14, 0.78);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.ent-stat {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  gap: 0.6rem;
  padding: 1.75rem 1.5rem;
  border-left: 1px solid var(--ent-line);
  text-align: center;
}
.ent-stat:first-child { border-left: 0; }
.ent-stat dd {
  margin: 0;
  color: #fff;
  font-family: var(--wt-font-sans);
  font-size: clamp(2.1rem, 3.6vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.ent-stat dt { color: rgba(255, 255, 255, 0.56); font-size: 0.875rem; line-height: 1.5; word-break: keep-all; }

/* ---------------------------------------------------------------- 앱 장면 */

.ent-show-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2.5rem, 5vw, 5.5rem);
  align-items: center;
}
.ent-show-copy .section-head { margin-bottom: 0; }
.ent-tabs { margin: 2.25rem 0 0; padding: 0; list-style: none; border-top: 1px solid var(--ent-line); }
.ent-tab {
  position: relative;
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  width: 100%;
  padding: 1.05rem 0;
  border: 0;
  border-bottom: 1px solid var(--ent-line);
  background: none;
  color: rgba(255, 255, 255, 0.46);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: color 200ms ease;
}
.ent-tab:hover { color: rgba(255, 255, 255, 0.8); }
.ent-tab:focus-visible { outline: 2px solid var(--ent-gold); outline-offset: 2px; }
.ent-tab-num {
  display: grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  font-family: var(--wt-font-mono);
  font-size: 0.625rem;
  font-weight: 600;
  transition: background-color 200ms ease, color 200ms ease, border-color 200ms ease;
}
.ent-tab-text strong { display: block; color: inherit; font-size: 1.0625rem; font-weight: 700; letter-spacing: -0.01em; }
.ent-tab-text small { display: block; margin-top: 0.2rem; color: rgba(255, 255, 255, 0.4); font-size: 0.84rem; }
.ent-tab[aria-selected="true"] { color: #fff; }
.ent-tab[aria-selected="true"] .ent-tab-num { border-color: #fff; background: #fff; color: #0a0a0b; }
.ent-tab-progress {
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, var(--ent-gold-pale), var(--ent-gold));
  transform: scaleX(0);
  transform-origin: 0 50%;
}
.ent-tab[aria-selected="true"] .ent-tab-progress { transform: scaleX(var(--ent-progress, 1)); }
.ent-notes { display: grid; gap: 0.6rem; margin: 1.6rem 0 0; padding: 0; list-style: none; color: rgba(255, 255, 255, 0.62); font-size: 0.9rem; }
.ent-notes li { display: flex; align-items: center; gap: 0.7rem; }
.ent-notes li::before { content: ""; width: 0.4rem; height: 0.4rem; border-radius: 50%; background: var(--ent-gold); box-shadow: 0 0 10px rgba(215, 182, 94, 0.6); }

.ent-stage {
  position: relative;
  padding: clamp(1rem, 2.2vw, 1.75rem);
  border: 1px solid var(--ent-line);
  background:
    radial-gradient(70% 55% at 50% 0%, rgba(215, 182, 94, 0.11), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent 40%),
    var(--ent-panel);
  box-shadow: 0 50px 140px -50px rgba(0, 0, 0, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.ent-stage::before {
  content: "";
  position: absolute;
  inset: -1px;
  pointer-events: none;
  background: linear-gradient(120deg, rgba(246, 230, 168, 0.32), transparent 28%, transparent 72%, rgba(246, 230, 168, 0.16));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  padding: 1px;
}
.ent-panel[hidden] { display: none; }
.ent-stage.is-live .ent-panel { animation: ent-panel-in 420ms ease both; }
@keyframes ent-panel-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.ent-speech { display: flex; align-items: baseline; gap: 0.85rem; min-height: 3.4rem; padding: 0.15rem 0.2rem 1rem; }
.ent-speech-label {
  flex: 0 0 auto;
  color: var(--ent-gold);
  font-family: var(--wt-font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.ent-speech p { margin: 0; color: rgba(255, 255, 255, 0.78); font-size: 0.9rem; line-height: 1.6; word-break: keep-all; }
.ent-stage.is-live .ent-speech p span { color: rgba(255, 255, 255, 0.22); transition: color 180ms ease; }
.ent-stage.is-live .ent-speech p span.is-said { color: rgba(255, 255, 255, 0.9); }

.ent-window {
  position: relative;
  min-height: 21rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #111;
  box-shadow: 0 20px 60px -30px rgba(0, 0, 0, 0.9);
}
.ent-window-bar {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  height: 2.4rem;
  padding: 0 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: #171717;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.75rem;
  font-weight: 600;
}
.ent-dots { display: inline-flex; gap: 0.35rem; }
.ent-dots i { width: 0.55rem; height: 0.55rem; border-radius: 50%; background: rgba(255, 255, 255, 0.16); }
.ent-window-body { padding: 0.9rem 1.2rem 5.2rem; color: rgba(255, 255, 255, 0.84); font-size: 0.9rem; line-height: 1.7; }
.ent-row { display: flex; gap: 0.9rem; padding: 0.45rem 0; border-bottom: 1px solid rgba(255, 255, 255, 0.06); font-size: 0.8rem; }
.ent-row .k { flex: 0 0 4.5rem; color: rgba(255, 255, 255, 0.42); }
.ent-row .v { color: rgba(255, 255, 255, 0.82); }
.ent-doc { min-height: 6.5rem; margin-top: 1rem; }
.ent-paste { margin: 0; padding: 0.1rem 0.2rem; word-break: keep-all; }
.ent-doc-title { margin: 0.2rem 0 0.25rem; color: #fff; font-size: 1.15rem; font-weight: 700; letter-spacing: -0.02em; }
.ent-doc-meta { margin: 0; color: rgba(255, 255, 255, 0.42); font-size: 0.8rem; }
.ent-thread { display: grid; gap: 0.95rem; }
.ent-msg { display: grid; grid-template-columns: 2rem minmax(0, 1fr); gap: 0.75rem; }
.ent-avatar {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(155, 210, 243, 0.28), rgba(155, 210, 243, 0.08));
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.78rem;
  font-weight: 700;
}
.ent-msg strong { color: #fff; font-size: 0.82rem; }
.ent-msg p { margin: 0.1rem 0 0; color: rgba(255, 255, 255, 0.72); font-size: 0.86rem; }
.ent-composer {
  position: relative;
  margin-top: 1.4rem;
  min-height: 4.4rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.025);
}
.ent-placeholder { position: absolute; left: 0.85rem; top: 0.7rem; color: rgba(255, 255, 255, 0.3); font-size: 0.86rem; visibility: hidden; }
.ent-composer .ent-paste { font-size: 0.86rem; }
.ent-slot {
  position: absolute;
  left: 50%;
  bottom: 0.6rem;
  z-index: 2;
  transform: translateX(-50%) scale(var(--wd-widget-scale));
  transform-origin: 50% 100%;
}

/* 재생 중: 글은 위젯이 붙여넣는 순간에 한 번에 나타난다 (Warp 는 전사가 끝난 뒤 입력한다). */
.ent-stage.is-live .ent-paste { opacity: 0; transition: opacity 160ms linear, background-color 500ms linear; }
.ent-stage.is-live .ent-panel.has-text .ent-paste { opacity: 1; }
.ent-stage.is-live .ent-panel.is-flashing .ent-paste { background: rgba(215, 182, 94, 0.16); transition: opacity 160ms linear, background-color 0ms; }
.ent-stage.is-live .ent-panel:not(.has-text) .ent-placeholder { visibility: visible; }

/* ---------------------------------------------------------------- 데이터 처리 */

.ent-data-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2.5rem, 5vw, 5.5rem);
  align-items: center;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.ent-data-copy .section-head { margin-bottom: 0; }
.ent-switch { display: inline-flex; margin-top: 1.75rem; padding: 4px; border: 1px solid var(--ent-line-strong); background: rgba(255, 255, 255, 0.03); }
.ent-switch button {
  padding: 0.62rem 1.15rem;
  border: 0;
  background: none;
  color: rgba(255, 255, 255, 0.58);
  font: 600 0.875rem var(--wt-font-body);
  cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease;
}
.ent-switch button:hover { color: #fff; }
.ent-switch button:focus-visible { outline: 2px solid var(--ent-gold); outline-offset: 2px; }
.ent-switch button[aria-selected="true"] { background: #fff; color: #0a0a0b; }
.ent-mode-note { max-width: 30rem; min-height: 3.5em; margin: 1.1rem 0 0; color: rgba(255, 255, 255, 0.68); line-height: 1.7; word-break: keep-all; }
.ent-mode-note[hidden] { display: none; }

.ent-diagram {
  position: relative;
  padding: clamp(0.75rem, 2vw, 1.5rem);
  border: 1px solid var(--ent-line);
  background:
    radial-gradient(60% 60% at 30% 55%, rgba(215, 182, 94, 0.07), transparent 70%),
    radial-gradient(45% 55% at 85% 50%, rgba(155, 210, 243, 0.06), transparent 70%),
    var(--ent-panel);
  box-shadow: 0 40px 120px -50px rgba(0, 0, 0, 0.95);
}
.ent-diagram svg { display: block; width: 100%; height: auto; overflow: visible; }
.ent-box { fill: rgba(255, 255, 255, 0.018); stroke: rgba(255, 255, 255, 0.14); stroke-width: 1; }
.ent-label { fill: rgba(255, 255, 255, 0.6); font-family: var(--wt-font-body); font-size: 13px; font-weight: 600; }
.ent-label--box { fill: rgba(255, 255, 255, 0.82); font-family: var(--wt-font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; }
.ent-label--small { font-size: 12px; }
.ent-node circle,
.ent-node rect { fill: #151515; stroke: rgba(255, 255, 255, 0.2); stroke-width: 1; }
.ent-node path { stroke: rgba(255, 255, 255, 0.55); stroke-width: 1.6; stroke-linecap: round; }
.ent-mic rect { fill: none; stroke: var(--ent-gold-pale); stroke-width: 1.6; }
.ent-mic path { stroke: var(--ent-gold-pale); }
.ent-mic circle { stroke: rgba(215, 182, 94, 0.55); }
.ent-chip rect { stroke: rgba(215, 182, 94, 0.55); }
.ent-chip text { fill: var(--ent-gold-pale); font-family: var(--wt-font-mono); font-size: 12px; font-weight: 600; }
.ent-diagram.is-live[data-mode="local"] .ent-chip rect { animation: ent-chip-work 1.6s ease-in-out infinite; }
@keyframes ent-chip-work {
  0%, 100% { stroke: rgba(215, 182, 94, 0.45); filter: none; }
  50% { stroke: rgba(246, 230, 168, 0.95); filter: drop-shadow(0 0 8px rgba(215, 182, 94, 0.55)); }
}
.ent-out path { stroke: rgba(155, 210, 243, 0.7); }
.ent-track { fill: none; stroke: rgba(255, 255, 255, 0.14); stroke-width: 1.2; }
.ent-track--back { stroke: rgba(155, 210, 243, 0.2); }
.ent-dash { fill: none; stroke: rgba(255, 255, 255, 0.22); stroke-width: 1.2; stroke-dasharray: 4 5; }
.ent-nosend circle { fill: #151515; stroke: rgba(255, 120, 110, 0.6); }
.ent-nosend path:not(.ent-dash) { stroke: rgba(255, 140, 130, 0.9); stroke-width: 1.6; stroke-linecap: round; }
.ent-nosend .ent-label { fill: rgba(255, 170, 160, 0.85); }
.ent-lock rect { fill: #151515; stroke: rgba(155, 210, 243, 0.7); }
.ent-lock path { stroke: rgba(155, 210, 243, 0.7); stroke-width: 1.6; }
.ent-srv-chip path { stroke: rgba(155, 210, 243, 0.75); }
.ent-dot--local,
.ent-dot--up { fill: var(--ent-gold-pale); filter: drop-shadow(0 0 5px rgba(215, 182, 94, 0.9)); }
.ent-dot--back { fill: var(--ent-blue); filter: drop-shadow(0 0 5px rgba(155, 210, 243, 0.9)); }

/* 모드에 따라 켜지는 흐름. 점의 투명도는 스크립트가 점마다 정하므로, 모드는 점을 담은 묶음에 건다. */
.ent-srv, .ent-cloud, .ent-nosend, .ent-chip, .ent-flow { transition: opacity 450ms ease; }
.ent-diagram[data-mode="local"] .ent-srv { opacity: 0.32; }
.ent-diagram[data-mode="local"] .ent-cloud,
.ent-diagram[data-mode="local"] .ent-flow--up,
.ent-diagram[data-mode="local"] .ent-flow--back { opacity: 0; }
.ent-diagram[data-mode="cloud"] .ent-nosend,
.ent-diagram[data-mode="cloud"] .ent-flow--local { opacity: 0; }
.ent-diagram[data-mode="cloud"] .ent-chip { opacity: 0.3; }
.ent-diagram[data-mode="local"] .ent-notkept { opacity: 0; }
.ent-diagram[data-mode="cloud"] .ent-notkept { animation: ent-notkept 2.4s ease-in-out infinite; }
@keyframes ent-notkept { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.ent-diagram:not(.is-live) .ent-flow { opacity: 0; }

.ent-facts { margin-top: 0; }

/* ---------------------------------------------------------------- 도입 절차 · 문의 */

.ent-steps { position: relative; }
.ent-steps::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -1px;
  z-index: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--ent-gold-pale), var(--ent-gold) 60%, transparent);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 1600ms cubic-bezier(0.22, 1, 0.36, 1) 200ms;
}
.ent.is-live .ent-steps:has(.is-in)::before,
.ent:not(.is-live) .ent-steps::before { transform: scaleX(1); }

.ent-cta {
  isolation: isolate;
  padding-block: clamp(3.5rem, 8vw, 6rem) clamp(5rem, 10vw, 7.5rem);
  background: radial-gradient(60% 90% at 50% 100%, rgba(215, 182, 94, 0.12), transparent 70%), rgba(15, 15, 15, 0.96);
}
.ent-cta .ent-field { z-index: -1; }
.ent-cta h2 { position: relative; }

/* ---------------------------------------------------------------- 나타나기 */

.ent.is-live .ent-reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 900ms cubic-bezier(0.22, 1, 0.36, 1), transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--ent-delay, 0ms);
}
.ent.is-live .ent-reveal.is-in { opacity: 1; transform: none; }

/* ---------------------------------------------------------------- 좁은 화면 */

@media (max-width: 1023px) {
  .ent-show-grid,
  .ent-data-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .ent-hero { min-height: max(40rem, 100svh); padding-bottom: 10rem; }
  .ent-hero-widget { transform: translate(-50%, -50%) scale(1.1); }
  .ent-actions { flex-direction: column; align-items: stretch; width: 100%; max-width: 22rem; }
  .ent-stats { margin-top: -3.5rem; }
  .ent-stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ent-stat { padding: 1.35rem 1rem; }
  .ent-stat:nth-child(3) { border-left: 0; }
  .ent-stat:nth-child(n + 3) { border-top: 1px solid var(--ent-line); }
  .ent-speech { flex-direction: column; gap: 0.35rem; }
  .ent-window { min-height: 19rem; }
  .ent-window-body { padding: 0.8rem 0.9rem 4.8rem; font-size: 0.86rem; }
}

@media (max-width: 640px) {
  .ent-diagram { padding: 0.5rem 0.25rem; }
  .ent-label { font-size: 19px; }
  .ent-label--box { font-size: 14px; letter-spacing: 0.08em; }
  .ent-label--small { font-size: 16px; }
  .ent-chip text { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .ent.is-live .ent-reveal { opacity: 1; transform: none; transition: none; }
  .ent-stage.is-live .ent-panel { animation: none; }
  .ent-steps::before { transform: scaleX(1); transition: none; }
  .ent-diagram[data-mode="cloud"] .ent-notkept { animation: none; opacity: 1; }
  .ent-diagram.is-live[data-mode="local"] .ent-chip rect { animation: none; }
}
