/* Home hero — brand-first visual
   Light: clean white + soft brand wash + roast-curve graphic (no dark chart blob)
   Dark: chart photo + curve accent
*/
.home-hero {
  --home-hero-font: "Outfit", "Noto Sans KR", sans-serif;
  --home-hero-body: "Noto Sans KR", "Outfit", sans-serif;
  --home-hero-ink: var(--reonai-text-primary, #1a1a1a);
  --home-hero-muted: var(--reonai-text-secondary, #6b6b6b);
  --home-hero-ghost-border: var(--reonai-border, #e5e5e5);
  --home-hero-ghost-bg: var(--reonai-bg, #ffffff);
  --home-hero-curve: rgba(142, 30, 35, 0.55);
  --home-hero-curve-soft: rgba(142, 30, 35, 0.22);
  --home-hero-curve-grid: rgba(26, 26, 26, 0.06);
  position: relative;
  isolation: isolate;
  min-height: min(88vh, 860px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: var(--home-hero-ink);
  background: var(--reonai-bg, #ffffff);
}

.dark .home-hero {
  --home-hero-ink: #f3f0eb;
  --home-hero-muted: rgba(243, 240, 235, 0.72);
  --home-hero-ghost-border: rgba(243, 240, 235, 0.35);
  --home-hero-ghost-bg: transparent;
  --home-hero-curve: rgba(255, 255, 255, 0.55);
  --home-hero-curve-soft: rgba(156, 43, 48, 0.55);
  --home-hero-curve-grid: rgba(255, 255, 255, 0.08);
  background: #121212;
}

.home-hero__visual {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* Dark chart only in dark mode — causes muddy right blob in light */
.home-hero__img--chart {
  display: none;
}

.dark .home-hero__img--chart {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
  opacity: 0.55;
  transform: scale(1.05);
  animation: home-hero-drift 22s ease-in-out infinite alternate;
  will-change: transform;
}

.home-hero__atmosphere {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 18% 40%, rgba(142, 30, 35, 0.09) 0%, transparent 58%),
    radial-gradient(ellipse 50% 45% at 92% 18%, rgba(142, 30, 35, 0.05) 0%, transparent 55%),
    linear-gradient(180deg, var(--reonai-surface, #fafafa) 0%, var(--reonai-bg, #ffffff) 48%, var(--reonai-bg, #ffffff) 100%);
}

.dark .home-hero__atmosphere {
  background:
    linear-gradient(105deg, rgba(18, 18, 18, 0.92) 0%, rgba(18, 18, 18, 0.7) 42%, rgba(18, 18, 18, 0.35) 100%),
    linear-gradient(180deg, transparent 50%, var(--reonai-bg, #1a1a1a) 100%);
}

.home-hero__curve {
  position: absolute;
  right: -4%;
  top: 8%;
  width: min(72vw, 920px);
  height: auto;
  opacity: 1;
  animation: home-hero-curve-in 1.2s 0.15s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.dark .home-hero__curve {
  opacity: 0.45;
  mix-blend-mode: screen;
}

.home-hero__curve-grid {
  fill: none;
  stroke: var(--home-hero-curve-grid);
  stroke-width: 1;
}

.home-hero__curve-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.home-hero__curve-line--bt {
  stroke: var(--home-hero-curve);
  stroke-width: 3.2;
}

.home-hero__curve-line--et {
  stroke: var(--home-hero-curve-soft);
  stroke-width: 2.4;
}

.home-hero__curve-line--ror {
  stroke: rgba(26, 26, 26, 0.22);
  stroke-width: 1.8;
  stroke-dasharray: 5 7;
}

.dark .home-hero__curve-line--ror {
  stroke: rgba(255, 255, 255, 0.35);
}

.home-hero__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: clamp(5.5rem, 12vh, 8rem) clamp(1.25rem, 4vw, 2.5rem) clamp(3.25rem, 7vh, 5rem);
}

.home-hero__brand {
  margin: 0 0 0.85rem;
  font-family: var(--home-hero-font);
  font-weight: 800;
  font-size: clamp(2.75rem, 8.5vw, 5.75rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  color: var(--reonai-primary, #8e1e23);
  text-wrap: balance;
  animation: home-hero-rise 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.dark .home-hero__brand {
  color: #fff;
}

.home-hero__brand::after {
  content: "";
  display: block;
  width: 3.25rem;
  height: 3px;
  margin-top: 0.85rem;
  border-radius: 1px;
  background: var(--reonai-primary, #8e1e23);
  transform-origin: left center;
  animation: home-hero-rule 1s 0.25s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.home-hero__title {
  margin: 0 0 0.75rem;
  max-width: none;
  font-family: var(--home-hero-body);
  font-weight: 600;
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: var(--home-hero-ink);
  white-space: nowrap;
  animation: home-hero-rise 0.9s 0.12s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.home-hero__lede {
  margin: 0 0 1.75rem;
  max-width: none;
  font-family: var(--home-hero-body);
  font-weight: 400;
  font-size: clamp(0.95rem, 1.6vw, 1.1rem);
  line-height: 1.55;
  color: var(--home-hero-muted);
  white-space: nowrap;
  animation: home-hero-rise 0.9s 0.22s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.home-hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  animation: home-hero-rise 0.9s 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.home-hero__hint {
  margin: 0.85rem 0 0;
  max-width: 36rem;
  font-family: var(--home-hero-body);
  font-size: 0.8125rem;
  line-height: 1.45;
  color: var(--home-hero-muted);
  animation: home-hero-rise 0.9s 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.home-hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  padding: 0.7rem 1.35rem;
  border-radius: 0.55rem;
  font-family: var(--home-hero-body);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.home-hero__btn:hover {
  transform: translateY(-1px);
}

.home-hero__btn--primary {
  background: var(--reonai-primary, #8e1e23);
  color: #fff;
  border: 1px solid transparent;
}

.home-hero__btn--primary:hover {
  background: var(--reonai-primary-hover, #a32a30);
}

.home-hero__btn--ghost {
  background: var(--home-hero-ghost-bg);
  color: var(--home-hero-ink);
  border: 1px solid var(--home-hero-ghost-border);
}

.home-hero__btn--ghost:hover {
  border-color: var(--reonai-primary, #8e1e23);
  color: var(--reonai-primary, #8e1e23);
}

@keyframes home-hero-rise {
  from {
    opacity: 0;
    transform: translateY(1.1rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes home-hero-rule {
  from {
    opacity: 0;
    transform: scaleX(0);
  }
  to {
    opacity: 1;
    transform: scaleX(1);
  }
}

@keyframes home-hero-curve-in {
  from {
    opacity: 0;
    transform: translateX(2%) translateY(1%);
  }
  to {
    opacity: 1;
    transform: translateX(0) translateY(0);
  }
}

@keyframes home-hero-drift {
  from {
    transform: scale(1.05) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.1) translate3d(-1%, -0.5%, 0);
  }
}

.home-hero__hint--mobile {
  display: none;
}

@media (max-width: 640px) {
  .home-hero {
    min-height: min(64vh, 540px);
    align-items: flex-end;
  }

  .home-hero__inner {
    padding: 4.75rem 1.25rem 2rem;
  }

  .home-hero__curve {
    width: 115%;
    right: -20%;
    top: -4%;
    opacity: 0.32;
  }

  .home-hero__brand {
    margin: 0 0 0.55rem;
    font-size: clamp(2.15rem, 9.5vw, 2.65rem);
    line-height: 1;
  }

  .home-hero__brand::after {
    width: 2.5rem;
    margin-top: 0.55rem;
  }

  .home-hero__title {
    margin: 0 0 0.45rem;
    font-size: 1.05rem;
    line-height: 1.4;
    white-space: normal;
  }

  .home-hero__lede {
    margin: 0 0 1.15rem;
    font-size: 0.9rem;
    line-height: 1.5;
    white-space: normal;
  }

  .home-hero__cta {
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
  }

  .home-hero__btn {
    width: 100%;
    min-height: 2.75rem;
  }

  .home-hero__hint {
    margin: 0.65rem 0 0;
    font-size: 0.75rem;
  }

  .home-hero__hint--desk {
    display: none;
  }

  .home-hero__hint--mobile {
    display: block;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-hero__img--chart,
  .home-hero__brand,
  .home-hero__brand::after,
  .home-hero__title,
  .home-hero__lede,
  .home-hero__cta,
  .home-hero__hint,
  .home-hero__hint--desk,
  .home-hero__hint--mobile,
  .home-hero__curve {
    animation: none !important;
  }

  .home-hero__img--chart {
    transform: none;
  }

  .home-hero__btn:hover {
    transform: none;
  }
}
