/* =========================================================
   Tile Craft — First Fold
   Apple × Toss hybrid · liquid dark/light tech
   ========================================================= */

:root {
  --ink: #0a0a0b;
  --mist: rgba(244, 245, 247, 0.92);
  --line: rgba(255, 255, 255, 0.16);
  --line-strong: rgba(255, 255, 255, 0.32);
  --glow: rgba(255, 255, 255, 0.08);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --liquid-x: 50%;
  --liquid-y: 50%;
  --liquid-intensity: 0;
  --liquid-scale: 1;
  --liquid-blur: 0px;
  --liquid-hue: 0deg;
  --bg-zoom: 1.85;
  --bg-tx: 0px;
  --bg-ty: 0px;
  --bg-scale: 1;
  --nav-vp-x: 0%;
  --nav-vp-y: 0%;
  --nav-vp-w: 100%;
  --nav-vp-h: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  background: var(--ink);
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- Background Stage ---------- */
.bg-stage {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #0a0a0b;
}

.bg-layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  overflow: hidden;
  transition: opacity 0.9s var(--ease-out);
  will-change: opacity, filter;
  filter:
    blur(var(--liquid-blur))
    hue-rotate(var(--liquid-hue))
    saturate(calc(1 + var(--liquid-intensity) * 0.35))
    contrast(calc(1 + var(--liquid-intensity) * 0.12));
}

/* Legacy flash/tile layers still use CSS background */
.bg-layer[style*='background-image'],
#bg-flash,
#bg-tile {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.bg-photo {
  position: absolute;
  left: 0;
  top: 0;
  max-width: none;
  width: auto;
  height: auto;
  transform-origin: 0 0;
  transform: translate3d(var(--bg-tx, 0px), var(--bg-ty, 0px), 0) scale(var(--bg-scale, 1));
  will-change: transform;
  user-select: none;
  pointer-events: none;
}

body.is-grid-view,
body.is-preview-nav {
  --bg-zoom: 1.85;
}

body.is-preview-nav .bg-veil,
body.is-grid-view .bg-veil {
  background:
    radial-gradient(ellipse 75% 60% at 50% 48%, rgba(10, 10, 11, 0.08) 0%, rgba(10, 10, 11, 0.32) 62%, rgba(10, 10, 11, 0.55) 100%),
    linear-gradient(180deg, rgba(10, 10, 11, 0.22) 0%, transparent 20%, transparent 80%, rgba(10, 10, 11, 0.35) 100%);
}

/* Disable approximate liquidWave transform when using camera transform */
body.is-grid-view.is-liquid .bg-layer.is-active,
body.is-preview-nav.is-liquid .bg-layer.is-active {
  animation: none;
}

.bg-layer.is-active {
  opacity: 1;
}

.bg-layer.is-flash {
  opacity: 1;
  animation: flashPulse 1s var(--ease-out) forwards;
  z-index: 2;
}

.bg-layer.is-fadein {
  opacity: 0;
  animation: fadeInBg 1.4s var(--ease-out) forwards;
  z-index: 3;
}

@keyframes flashPulse {
  0% {
    opacity: 0;
    filter: brightness(2.4) contrast(1.3) blur(0px);
  }
  18% {
    opacity: 1;
    filter: brightness(1.8) contrast(1.2) blur(0px);
  }
  55% {
    opacity: 1;
    filter: brightness(1.15) contrast(1.05) blur(1px);
  }
  100% {
    opacity: 0;
    filter: brightness(1) contrast(1) blur(2px);
  }
}

@keyframes fadeInBg {
  from {
    opacity: 0;
    filter: blur(8px) brightness(1.2);
  }
  to {
    opacity: 1;
    filter: blur(0px) brightness(1);
  }
}

.bg-veil {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 55% at 50% 48%, rgba(10, 10, 11, 0.18) 0%, rgba(10, 10, 11, 0.55) 58%, rgba(10, 10, 11, 0.78) 100%),
    linear-gradient(180deg, rgba(10, 10, 11, 0.35) 0%, transparent 22%, transparent 78%, rgba(10, 10, 11, 0.5) 100%);
}

.liquid-distort {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  opacity: calc(var(--liquid-intensity) * 0.85);
  background:
    radial-gradient(
      circle 38vmax at var(--liquid-x) var(--liquid-y),
      rgba(255, 255, 255, 0.09) 0%,
      rgba(255, 255, 255, 0.03) 28%,
      transparent 62%
    );
  mix-blend-mode: soft-light;
  transition: opacity 0.35s var(--ease-out);
}

.liquid-distort::before,
.liquid-distort::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(28px);
  mix-blend-mode: overlay;
}

.liquid-distort::before {
  width: 42vmax;
  height: 42vmax;
  left: var(--liquid-x);
  top: var(--liquid-y);
  transform: translate(-50%, -50%) scale(calc(0.7 + var(--liquid-intensity) * 0.55));
  background: radial-gradient(circle, rgba(255, 255, 255, 0.22) 0%, transparent 70%);
  opacity: calc(var(--liquid-intensity) * 0.9);
}

.liquid-distort::after {
  width: 28vmax;
  height: 28vmax;
  left: calc(var(--liquid-x) + 4%);
  top: calc(var(--liquid-y) - 3%);
  transform: translate(-50%, -50%) scale(calc(0.5 + var(--liquid-intensity) * 0.8));
  background: radial-gradient(circle, rgba(180, 200, 255, 0.18) 0%, transparent 68%);
  opacity: calc(var(--liquid-intensity) * 0.7);
}

body.is-liquid .bg-layer.is-active {
  animation: none;
}

body.is-liquid:not(.is-grid-view):not(.is-preview-nav) #bg-flash.is-active,
body.is-liquid:not(.is-grid-view):not(.is-preview-nav) #bg-tile.is-active {
  animation: none;
}

/* ---------- Brand Mark (top-left) ---------- */
.site-header {
  padding: 0;
}

.brand-mark {
  display: inline-block;
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  margin: 0;
  padding: 0;
  background: transparent;
  background-color: transparent;
  background-image: none;
  box-shadow: none;
  border: none;
  text-decoration: none;
}

.brand-title {
  display: block;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
  color: #ffffff;
  text-shadow:
    1px 1px 3px rgba(0, 0, 0, 0.9),
    0 0 8px rgba(0, 0, 0, 0.7);
}

.brand-subtitle {
  display: block;
  width: max-content;
  max-width: none;
  margin-top: 0.4rem;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: #ffffff;
  text-shadow:
    1px 1px 3px rgba(0, 0, 0, 0.9),
    0 0 8px rgba(0, 0, 0, 0.7);
}

.brand-subtitle-en {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: #ffffff;
  text-shadow:
    1px 1px 3px rgba(0, 0, 0, 0.9),
    0 0 8px rgba(0, 0, 0, 0.7);
}

.brand-subtitle-ko {
  margin-left: 0.4em;
  font-family:
    'Noto Sans KR',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-transform: none;
  color: #ffffff;
  opacity: 1;
  text-shadow:
    1px 1px 3px rgba(0, 0, 0, 0.9),
    0 0 8px rgba(0, 0, 0, 0.7);
}

@media (min-width: 768px) {
  .brand-mark {
    top: 2.5rem;
    left: 2.5rem;
  }

  .brand-title {
    font-size: 1.55rem;
  }

  .brand-subtitle {
    font-size: 14px;
  }

  .brand-subtitle-ko {
    font-size: 13px;
  }
}

/* ---------- Navigator ---------- */
.navigator {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 60;
  width: 196px;
}

@media (min-width: 768px) {
  .navigator {
    top: 2rem;
    right: 2.25rem;
    width: 220px;
  }
}

.navigator-frame {
  border: 1px solid var(--line-strong);
  background: rgba(10, 10, 11, 0.42);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  padding: 10px;
  transition: border-color 0.35s var(--ease-out), background 0.35s var(--ease-out), transform 0.35s var(--ease-out);
}

.navigator:hover .navigator-frame {
  border-color: rgba(255, 255, 255, 0.48);
  background: rgba(10, 10, 11, 0.55);
  transform: translateY(-1px);
}

.navigator-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 9px;
  letter-spacing: 0.22em;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 8px;
}

.nav-refresh {
  appearance: none;
  margin-left: auto;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.7);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 8px;
  letter-spacing: 0.14em;
  padding: 3px 6px;
  cursor: pointer;
  line-height: 1;
}

.nav-refresh:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.5);
}

.navigator-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #7CFFB2;
  box-shadow: 0 0 8px rgba(124, 255, 178, 0.7);
  animation: pulseDot 2s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes pulseDot {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.45;
  }
}

.navigator-cats {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 8px;
  max-height: 132px;
  overflow-y: auto;
  padding-right: 2px;
}

.nav-cat {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.48);
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 9px;
  letter-spacing: 0.06em;
  text-transform: none;
  padding: 5px 7px;
  cursor: pointer;
  line-height: 1.1;
  text-align: left;
  width: 100%;
  transition:
    color 0.25s ease,
    border-color 0.25s ease,
    background 0.25s ease;
}

.nav-cat:hover {
  color: rgba(255, 255, 255, 0.85);
  border-color: rgba(255, 255, 255, 0.35);
}

.nav-cat.is-active {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.12);
}

.navigator-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3px;
  min-height: 72px;
}

.nav-cell {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background-color: rgba(255, 255, 255, 0.04);
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  opacity: 0.62;
  aspect-ratio: 1;
  transition:
    border-color 0.25s ease,
    transform 0.25s var(--ease-spring),
    opacity 0.25s ease;
}

.nav-cell:hover {
  border-color: rgba(255, 255, 255, 0.45);
  transform: scale(1.04);
  opacity: 1;
  z-index: 1;
}

.nav-cell.is-active {
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
  opacity: 1;
}

.nav-minimap {
  position: relative;
  margin-top: 8px;
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(0, 0, 0, 0.55);
  overflow: hidden;
  cursor: crosshair;
  user-select: none;
  touch-action: none;
  display: grid;
  place-items: center;
}

.nav-minimap.is-active {
  border-color: rgba(255, 255, 255, 0.55);
}

.nav-minimap.is-dragging {
  border-color: rgba(255, 255, 255, 0.85);
  cursor: grabbing;
}

.nav-minimap-frame {
  position: relative;
  overflow: hidden;
  background: #000;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.nav-minimap-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
  user-select: none;
}

.nav-viewport {
  position: absolute;
  left: var(--nav-vp-x, 0%);
  top: var(--nav-vp-y, 0%);
  width: var(--nav-vp-w, 100%);
  height: var(--nav-vp-h, 100%);
  border: 1.5px solid rgba(255, 255, 255, 0.95);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.45),
    inset 0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 18px rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.1);
  pointer-events: none;
  box-sizing: border-box;
}

.navigator-meta {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 2px 8px;
  margin-top: 8px;
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-size: 8px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.5);
}

#nav-cat-name {
  grid-column: 1 / -1;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

#nav-set-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#nav-mode {
  text-align: right;
}
/* ---------- Text Glass (readability over mosaic) ---------- */
.text-glass {
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0.85rem 1.1rem;
  color: #fff;
}

/* ---------- Value Rail (teaser + hover popup) ---------- */
.value-rail {
  position: absolute;
  left: 1.5rem;
  bottom: 1.75rem;
  z-index: 20;
  width: max-content;
  max-width: min(440px, calc(100vw - 3rem));
  pointer-events: auto;
  cursor: pointer;
}

@media (min-width: 768px) {
  .value-rail {
    left: 2.5rem;
    bottom: 2.5rem;
  }
}

.value-teaser {
  appearance: none;
  position: relative;
  display: inline-block;
  margin: 0;
  padding: 0 0 0.2em;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(0.82rem, 1.4vw, 0.95rem);
  font-weight: 300;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.92);
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.8),
    0 0 10px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  animation: valueTeaserPulse 2.8s ease-in-out infinite;
  transition:
    color 0.3s var(--ease-out),
    opacity 0.25s ease,
    filter 0.3s var(--ease-out);
}

.value-teaser::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.85);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.35s var(--ease-out);
  pointer-events: none;
}

.value-teaser:hover,
.value-rail:hover .value-teaser,
.value-rail:focus-within .value-teaser {
  animation: none;
  opacity: 1;
  color: #ffffff;
  filter: brightness(1.12);
}

.value-teaser:hover::after,
.value-rail:hover .value-teaser::after,
.value-rail:focus-within .value-teaser::after {
  transform: scaleX(1);
}

@keyframes valueTeaserPulse {
  0%,
  100% {
    opacity: 0.55;
  }
  50% {
    opacity: 1;
  }
}

.value-popup {
  position: absolute;
  left: 0;
  bottom: calc(100% + 0.75rem);
  width: min(420px, calc(100vw - 3rem));
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.95rem 1.1rem;
  background-color: #1a1a1c;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
  color: #fff;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  pointer-events: none;
  transition:
    opacity 0.35s var(--ease-out),
    transform 0.35s var(--ease-out),
    visibility 0.35s;
}

.value-rail:hover .value-popup,
.value-rail:focus-within .value-popup {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.value-line {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.45rem 0.7rem;
  line-height: 1.2;
}

.value-bold {
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-weight: 700;
  font-size: clamp(0.78rem, 1.35vw, 0.95rem);
  letter-spacing: -0.02em;
  color: #fff;
}

.value-sub {
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(calc(0.75rem + 1px), 1.2vw, calc(0.85rem + 1px));
  font-weight: 500;
  color: #fff;
  letter-spacing: -0.01em;
  word-break: keep-all;
}

body.is-computing .value-rail {
  opacity: 0.35;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .value-teaser {
    animation: none;
    opacity: 0.85;
  }

  .value-popup {
    transition: none;
  }
}

/* ---------- Gravity Dropzone ---------- */
.dropzone {
  position: relative;
  width: min(78vw, 520px);
  aspect-ratio: 1.15 / 1;
  max-height: min(68vh, 480px);
  display: grid;
  place-items: center;
  cursor: pointer;
  outline: none;
  transition: transform 0.55s var(--ease-spring);
}

.dropzone:focus-visible {
  outline: 1px solid rgba(255, 255, 255, 0.45);
  outline-offset: 10px;
}

.dropzone.is-dragover {
  transform: scale(1.035);
}

.dropzone.is-absorbing {
  pointer-events: none;
}

.dropzone-orbit {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  pointer-events: none;
}

.dropzone-orbit--a {
  inset: 2%;
  animation: orbitSpin 28s linear infinite;
  border-style: dashed;
  border-color: rgba(255, 255, 255, 0.18);
  opacity: 0.85;
}

.dropzone-orbit--b {
  inset: 9%;
  animation: orbitSpin 18s linear infinite reverse;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 60px rgba(255, 255, 255, 0.03);
}

.dropzone-orbit--c {
  inset: 18%;
  animation: orbitPulse 4.5s var(--ease-out) infinite;
  border-color: rgba(255, 255, 255, 0.22);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.08), transparent 45%),
    radial-gradient(circle at 65% 70%, rgba(255, 255, 255, 0.04), transparent 50%);
  backdrop-filter: blur(2px);
}

@keyframes orbitSpin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes orbitPulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.85;
  }
  50% {
    transform: scale(1.025);
    opacity: 1;
  }
}

.dropzone-core {
  position: relative;
  z-index: 2;
  width: 68%;
  aspect-ratio: 1;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.5rem;
  background-color: rgba(255, 255, 255, 0.08);
  background-image:
    radial-gradient(circle at 50% 42%, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.03) 42%, rgba(10, 10, 11, 0.22) 100%);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04),
    0 20px 60px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition:
    border-color 0.35s ease,
    box-shadow 0.35s ease,
    background 0.35s ease,
    transform 0.55s var(--ease-spring);
}

.dropzone.is-dragover .dropzone-core {
  border-color: rgba(255, 255, 255, 0.65);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 80px rgba(255, 255, 255, 0.12),
    0 24px 70px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transform: scale(1.02);
}

.dropzone.is-absorbing .dropzone-core {
  animation: coreSuck 1.1s var(--ease-spring) forwards;
}

@keyframes coreSuck {
  0% {
    transform: scale(1);
    filter: brightness(1);
  }
  35% {
    transform: scale(1.08) rotate(4deg);
    filter: brightness(1.25);
  }
  100% {
    transform: scale(0.92) rotate(-2deg);
    filter: brightness(1.1);
  }
}

.dropzone-ripple {
  position: absolute;
  inset: -6%;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  animation: rippleOut 3.2s var(--ease-out) infinite;
  pointer-events: none;
}

.dropzone-ripple.delay {
  animation-delay: 1.05s;
}

@keyframes rippleOut {
  0% {
    transform: scale(0.92);
    opacity: 0.55;
  }
  100% {
    transform: scale(1.28);
    opacity: 0;
  }
}

.dropzone-copy-wrap {
  position: relative;
  z-index: 1;
  max-width: 16.5em;
  text-align: center;
  background: transparent;
  background-color: transparent;
  padding: 0;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: #fff;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7);
}

.dropzone-copy {
  margin: 0;
  color: #fff;
  line-height: 1.4;
  background: transparent;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7);
}

.dropzone-lead {
  display: block;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(1.05rem, 2.4vw, 1.45rem);
  font-weight: 700;
  font-style: normal;
  letter-spacing: -0.01em;
  color: #fff;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7);
}

.dropzone-action,
.dropzone-action-ko {
  display: block;
  margin-top: 0.45rem;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif !important;
  font-size: clamp(1.15rem, 2.4vw, 1.45rem) !important;
  font-weight: 850 !important;
  font-style: normal !important;
  color: #fff !important;
  word-break: keep-all;
  line-height: 1.45;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7) !important;
}

.dropzone-hint {
  margin: 1.1rem 0 0;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: #fff;
  background: transparent;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7);
}

body.is-computing .dropzone {
  opacity: 0.25;
  transform: scale(0.94);
  transition: opacity 0.6s ease, transform 0.6s var(--ease-out);
}

body.is-complete .dropzone {
  opacity: 0.55;
}

/* ---------- Absorption ---------- */
.absorb-stage {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  overflow: hidden;
}

.absorb-token {
  position: absolute;
  width: 56px;
  height: 56px;
  margin-left: -28px;
  margin-top: -28px;
  border-radius: 10px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(220, 220, 225, 0.75));
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  animation: absorbSpin 1.15s var(--ease-spring) forwards;
  will-change: transform, opacity;
}

.absorb-token svg {
  width: 26px;
  height: 26px;
  opacity: 0.75;
}

.absorb-token::after {
  content: '';
  position: absolute;
  inset: -40%;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.35);
  animation: tokenRing 1.15s linear forwards;
}

@keyframes absorbSpin {
  0% {
    transform: translate(var(--ax), var(--ay)) scale(1) rotate(0deg);
    opacity: 1;
  }
  40% {
    transform: translate(calc(var(--ax) * 0.55), calc(var(--ay) * 0.55)) scale(0.85) rotate(280deg);
    opacity: 1;
  }
  75% {
    transform: translate(calc(var(--ax) * 0.15), calc(var(--ay) * 0.15)) scale(0.45) rotate(540deg);
    opacity: 0.85;
  }
  100% {
    transform: translate(0, 0) scale(0.08) rotate(720deg);
    opacity: 0;
  }
}

@keyframes tokenRing {
  to {
    transform: rotate(-720deg) scale(0.2);
    opacity: 0;
  }
}

.absorb-shard {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.7);
  animation: shardIn 1s var(--ease-spring) forwards;
  will-change: transform, opacity;
}

@keyframes shardIn {
  0% {
    transform: translate(var(--sx), var(--sy)) scale(1) rotate(0deg);
    opacity: 0.9;
  }
  100% {
    transform: translate(0, 0) scale(0) rotate(480deg);
    opacity: 0;
  }
}

/* ---------- Process Status ---------- */
.process-status {
  position: absolute;
  bottom: 2rem;
  right: 1.5rem;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  font-size: 10px;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.65);
}

@media (min-width: 768px) {
  .process-status {
    bottom: 2.5rem;
    right: 2.5rem;
  }
}

.process-status.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.4s ease, transform 0.4s var(--ease-out);
}

.process-bar {
  width: 48px;
  height: 1px;
  background: rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.process-bar::after {
  content: '';
  position: absolute;
  inset: 0;
  background: #fff;
  transform: translateX(-100%);
}

body.is-computing .process-bar::after {
  animation: barRun 1.8s ease-in-out infinite;
}

@keyframes barRun {
  0% {
    transform: translateX(-100%);
  }
  50% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(100%);
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .dropzone-orbit,
  .dropzone-ripple,
  .navigator-dot,
  body.is-liquid .bg-layer.is-active {
    animation: none !important;
  }

  .absorb-token,
  .absorb-shard {
    animation-duration: 0.01ms !important;
  }
}

/* =========================================================
   Force overrides — dropzone KO readability
   (must stay last to beat Tailwind / shared .text-glass)
   ========================================================= */
#dropzone .dropzone-copy-wrap,
#dropzone .dropzone-copy-wrap.text-glass {
  background: transparent !important;
  background-color: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  box-shadow: none !important;
  border: none !important;
  padding: 0 !important;
}

#dropzone .dropzone-lead,
#dropzone .dropzone-action,
#dropzone .dropzone-action-ko,
#dropzone .dropzone-hint {
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif !important;
  color: #ffffff !important;
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 0 10px rgba(0, 0, 0, 0.7) !important;
}

#dropzone .dropzone-lead {
  font-weight: 700 !important;
  font-style: normal !important;
}

#dropzone .dropzone-action,
#dropzone .dropzone-action-ko {
  font-weight: 850 !important;
  font-style: normal !important;
  font-size: clamp(1.15rem, 2.4vw, 1.45rem) !important;
}

#dropzone .dropzone-hint {
  font-family: 'IBM Plex Mono', ui-monospace, monospace !important;
}

/* ---------- Launch Modal ---------- */
.launch-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1.25rem;
}

.launch-modal[hidden] {
  display: none !important;
}

.launch-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.launch-modal-panel {
  position: relative;
  z-index: 1;
  width: min(100%, 520px);
  max-height: min(88vh, 720px);
  overflow-y: auto;
  background-color: #111;
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 2rem 1.75rem 1.75rem;
  color: #fff;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  animation: launchModalIn 0.35s var(--ease-out);
}

@keyframes launchModalIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.launch-modal-close {
  appearance: none;
  position: absolute;
  top: 0.7rem;
  right: 0.75rem;
  width: 2rem;
  height: 2rem;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.72);
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: color 0.2s ease;
}

.launch-modal-close:hover {
  color: #fff;
}

.launch-modal-title {
  margin: 0 1.5rem 0 0;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(1.35rem, 3.2vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  color: #ffffff;
  word-break: keep-all;
}

.launch-modal-title-ko {
  margin: 0.45rem 0 0;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(0.9rem, 1.8vw, 1.05rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.72);
  word-break: keep-all;
}

.launch-modal-body {
  margin-top: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
}

.launch-modal-en,
.launch-modal-ko {
  margin: 0;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: clamp(0.88rem, 1.6vw, 0.98rem);
  font-weight: 400;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.88);
  word-break: keep-all;
}

.launch-modal-ko {
  color: rgba(255, 255, 255, 0.78);
}

.launch-modal-form {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.launch-modal-input,
.launch-modal-textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 0.9rem;
  line-height: 1.5;
  padding: 0.85rem 0.95rem;
  outline: none;
  word-break: keep-all;
}

.launch-modal-input {
  min-height: 2.75rem;
}

.launch-modal-textarea {
  resize: vertical;
  min-height: 96px;
}

.launch-modal-input::placeholder,
.launch-modal-textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.launch-modal-input:focus,
.launch-modal-textarea:focus {
  border-color: rgba(255, 255, 255, 0.45);
}

.launch-modal-submit:disabled {
  opacity: 0.55;
  cursor: wait;
}

.launch-toast {
  position: fixed;
  left: 50%;
  bottom: 2rem;
  z-index: 120;
  transform: translateX(-50%) translateY(12px);
  width: min(92vw, 440px);
  padding: 1rem 1.15rem;
  background: #111;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.55;
  text-align: center;
  word-break: keep-all;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.3s var(--ease-out),
    transform 0.3s var(--ease-out);
}

.launch-toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.launch-toast.is-error {
  border-color: rgba(255, 120, 120, 0.45);
}

.launch-modal-submit {
  appearance: none;
  align-self: flex-start;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-family:
    'Noto Sans KR',
    Pretendard,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.7rem 1.15rem;
  cursor: pointer;
  transition:
    background 0.25s ease,
    border-color 0.25s ease;
}

.launch-modal-submit:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.55);
}

body.is-modal-open {
  overflow: hidden;
}

@media (min-width: 768px) {
  .launch-modal-panel {
    padding: 2.35rem 2.25rem 2rem;
  }
}
