:root {
  --bg: #090c17;
  --bg-soft: #121a30;
  --text: #f4f4f8;
  --text-dim: #a3aec9;
  --accent: #fbba4f;
  --accent-soft: #fbba4f26;
  --accent2: #7c93d6;
  --border: #232b45;
  --radius: 16px;
  font-family: "Jua", "Pretendard", "Apple SD Gothic Neo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--bg); color: var(--text); scroll-behavior: smooth; overflow-x: clip; }
body { line-height: 1.6; }
a { color: inherit; text-decoration: none; }
strong, b { font-weight: 400; }
img { max-width: 100%; display: block; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(11,11,18,0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
nav {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  padding: 18px 0;
  position: relative;
}
.logo { justify-self: start; font-weight: 400; font-size: 20px; letter-spacing: -0.02em; display: flex; align-items: center; gap: 8px; }
.logo span { color: var(--accent); }
.logo img { height: 28px; width: auto; display: block; }
.nav-links { justify-self: center; display: flex; gap: 28px; font-size: 18px; color: var(--text-dim); }
.nav-links a:hover { color: var(--text); }
.nav-links a.nav-active { color: var(--accent); font-size: 21px; }
.nav-toggle {
  display: none;
  flex: 0 0 auto;
  background: none; border: 1px solid var(--border); border-radius: 10px;
  color: var(--text); font-size: 18px; line-height: 1;
  width: 38px; height: 38px; align-items: center; justify-content: center;
  cursor: pointer; font-family: inherit;
}
.nav-actions { justify-self: end; display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
#lang-toggle { padding: 8px 14px; font-size: 13px; flex: 0 0 auto; height: 40px; }
.nav-back { height: 40px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: 999px;
  font-size: 15px; font-weight: 400;
  font-family: inherit;
  border: 1px solid transparent;
  background: none;
  cursor: pointer;
}
.btn-primary { background: var(--accent); color: #0d1424; }
.btn-primary:hover { opacity: 0.9; }
.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); }

.hero {
  padding: 120px 0 90px;
  text-align: center;
}
.badge {
  display: inline-block; margin-bottom: 24px;
  padding: 6px 14px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  font-size: 14px; font-weight: 400;
}
.hero h1 {
  font-size: clamp(32px, 6vw, 56px);
  font-weight: 400; letter-spacing: -0.03em;
  margin-bottom: 20px;
}
.hero h1 .accent { color: var(--accent); }
.page-title { font-size: 34px; font-weight: 400; color: var(--text); margin-bottom: 16px; }
.hero p {
  max-width: 560px; margin: 0 auto 36px;
  color: var(--text-dim); font-size: 19px;
}
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.btn-lg { padding: 14px 28px; font-size: 16px; }

section { padding: 88px 0; }
.section-head { text-align: center; max-width: 560px; margin: 0 auto 48px; }
.section-head .eyebrow {
  color: var(--accent); font-weight: 400; font-size: 14px;
  text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 12px; display: block;
}
.section-head h2 { font-size: clamp(26px, 4.4vw, 38px); font-weight: 400; letter-spacing: -0.02em; margin-bottom: 12px; }
.section-head p { color: var(--text-dim); font-size: 18px; }

/* Flagship app card */
.flagship {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center;
  border: 1px solid var(--border);
  border-radius: 24px; padding: 48px;
  overflow: hidden;
  background-size: cover; background-position: center;
}
.flagship::before {
  content: ""; position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(100deg, rgba(9,12,23,0.88) 0%, rgba(9,12,23,0.72) 45%, rgba(9,12,23,0.42) 100%);
}
.flagship > * { position: relative; z-index: 1; }
#dallae .flagship { background-image: url("assets/dallae-garden-bg.jpg"); }
#beyondmoment .flagship { background-image: url("assets/beyondmoment-bg.jpg?v=2"); }
.flagship-visual {
  height: 320px; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-dim); font-size: 15px;
  overflow: hidden;
}
.flagship-visual-name { font-size: 22px; font-weight: 400; color: var(--text); text-align: center; }
.app-icon {
  width: 56px; height: 56px; border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: flex; align-items: center; justify-content: center;
  font-weight: 400; font-size: 22px; color: #0b0b12;
  margin-bottom: 20px;
}
.flagship-badge {
  display: inline-block; margin-bottom: 14px;
  padding: 4px 12px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
  font-size: 13px; font-weight: 400;
}
.flagship-body h3 { font-size: 28px; font-weight: 400; margin-bottom: 10px; letter-spacing: -0.01em; color: var(--text); }
.flagship-body .tagline { color: var(--accent2); font-weight: 400; font-size: 17px; margin-bottom: 16px; }
.flagship-headline { font-size: 28px; font-weight: 400; line-height: 1.3; letter-spacing: -0.02em; margin: 0 0 18px; }
.flagship-headline .accent { color: var(--accent); }
.flagship-body p.desc { color: var(--text-dim); font-size: 17px; margin-bottom: 24px; }

.mini-features { display: flex; flex-direction: column; gap: 14px; margin-bottom: 28px; }
.mini-feature { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; }
.mini-feature .dot {
  width: 22px; height: 22px; border-radius: 7px; flex-shrink: 0;
  background: var(--accent-soft); color: var(--accent);
  display: flex; align-items: center; justify-content: center; font-size: 12px; margin-top: 1px;
}
.mini-feature strong { display: block; margin-bottom: 2px; }
.mini-feature span.sub { color: var(--text-dim); }

/* Apps grid */
.apps-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.app-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px;
  display: flex; flex-direction: column; gap: 6px;
}
.app-card.soon { opacity: 0.6; border-style: dashed; }
.app-card .app-icon-sm {
  width: 64px; height: 64px; border-radius: 18px;
  background: var(--accent-soft); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; font-weight: 400; margin-bottom: 16px;
}
.app-card h4 { font-size: 22px; font-weight: 400; }
.app-card p { color: var(--text-dim); font-size: 15px; }
.soon-tag {
  display: inline-block; margin-top: 10px;
  font-size: 14px; font-weight: 400; letter-spacing: 0.04em;
  color: var(--text-dim); text-transform: uppercase;
}

/* Coverflow app carousel */
.cf-carousel {
  --cf-card: clamp(150px, 30vw, 240px);
  position: relative; max-width: 900px; margin: 0 auto; display: flex; align-items: center; gap: 8px;
}
.cf-frame {
  flex: 1 1 auto; overflow: hidden; padding: 30px 0 6px;
  cursor: grab; outline: none; touch-action: pan-y;
  perspective: calc(var(--cf-card) * 3);
}
.cf-frame:active { cursor: grabbing; }
.cf-track {
  position: relative; height: var(--cf-card);
  transform-style: preserve-3d;
}
.cf-card {
  position: absolute; left: 50%; top: 0;
  width: var(--cf-card); aspect-ratio: 1 / 1;
  border-radius: 20px; overflow: hidden;
  background: var(--bg-soft); border: 1px solid var(--border);
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
  will-change: transform; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.cf-card img { width: 100%; height: 100%; object-fit: cover; user-select: none; pointer-events: none; }
.cf-card-soon { border-style: dashed; opacity: 0.75; }
.cf-card-soon .cf-q { font-size: calc(var(--cf-card) * 0.26); color: var(--text-dim); }
.cf-arrow {
  flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--border); background: var(--bg-soft); color: var(--text);
  font-size: 18px; font-family: inherit; cursor: pointer;
  display: flex; align-items: center; justify-content: center; z-index: 200;
}
.cf-arrow:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }
.cf-arrow:disabled { opacity: 0.3; cursor: default; }
.cf-captions {
  position: relative; max-width: 460px; margin: 4px auto 0; text-align: center; min-height: 118px;
}
html[lang="en"] .cf-captions {
  min-height: 160px;
}
.cf-caption {
  position: absolute; inset: 0;
  opacity: 0; transform: translateY(6px); transition: opacity 0.35s, transform 0.35s;
  pointer-events: none;
}
.cf-caption.active { opacity: 1; transform: none; pointer-events: auto; }
.cf-caption h4 { font-size: 26px; font-weight: 400; margin-bottom: 8px; color: #ffd876; text-shadow: 0 2px 12px rgba(0,0,0,0.5); }
.cf-caption p { font-size: 18px; color: #eef1fb; margin-bottom: 10px; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }
.cf-captions .soon-tag { color: #eef1fb; text-shadow: 0 2px 8px rgba(0,0,0,0.55); }
.cf-dots { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 18px; }
.cf-dot {
  width: 8px; height: 8px; border-radius: 999px; background: var(--border);
  border: none; padding: 0; cursor: pointer; transition: width 0.3s, background 0.3s;
}
.cf-dot.active { background: var(--accent); width: 22px; }
.cf-more {
  display: flex; flex-direction: column; align-items: center; gap: 0;
  margin: 26px auto 0; padding: 8px; background: none; border: none; cursor: pointer;
}
.cf-more span {
  width: 18px; height: 18px; margin-top: -8px;
  border-right: 3px solid var(--text-dim); border-bottom: 3px solid var(--text-dim);
  transform: rotate(45deg);
  opacity: 0.3;
  animation: cf-more-bounce 1.6s ease-in-out infinite;
}
.cf-more span:nth-child(1) { animation-delay: 0s; }
.cf-more span:nth-child(2) { animation-delay: 0.15s; }
.cf-more span:nth-child(3) { animation-delay: 0.3s; }
.cf-more:hover span { border-color: var(--accent); }
.cf-more-hidden { display: none; }
@keyframes cf-more-bounce {
  0%, 100% { opacity: 0.25; transform: translateY(0) rotate(45deg); }
  50% { opacity: 1; transform: translateY(5px) rotate(45deg); }
}
#apps { position: relative; overflow: hidden; }
#apps > .wrap { position: relative; z-index: 1; }
.cf-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0;
  transition: opacity 0.9s ease;
  z-index: 0;
}
.cf-bg video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.cf-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(9,12,23,0.46) 0%, rgba(9,12,23,0.24) 45%, rgba(9,12,23,0.6) 100%);
}
.cf-bg.active { opacity: 1; }
.cf-bg-dallae { background-image: url("assets/dallae-hero-bg.jpg"); }
.cf-bg-beyond { background-image: url("assets/beyondmoment-bg.jpg?v=2"); }

#dallae.cf-fade, #beyondmoment.cf-fade {
  box-sizing: border-box;
  overflow: hidden;
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease, max-height 0.6s ease, padding 0.6s ease;
}
#dallae.cf-fade.cf-visible, #beyondmoment.cf-fade.cf-visible {
  max-height: 3000px;
  padding-top: 88px;
  padding-bottom: 88px;
  opacity: 1;
  transform: none;
}
@media (max-width: 780px) {
  .cf-arrow { display: none; }
}

/* Feature cards (used on detail pages) */
.features {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.feature-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px;
}
.feature-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--accent-soft); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; margin-bottom: 18px;
}
.feature-card h3 { font-size: 19px; font-weight: 400; margin-bottom: 8px; }
.feature-card p { color: var(--text-dim); font-size: 16px; }

/* Step flow (used on detail pages) */
.steps {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
}
.step { text-align: center; }
.step-num {
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--accent); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-weight: 400; margin: 0 auto 16px;
}
.step h3 { font-size: 18px; font-weight: 400; margin-bottom: 8px; }
.step p { color: var(--text-dim); font-size: 16px; }

.about {
  text-align: center; max-width: 640px; margin: 0 auto;
}
.about p { color: var(--text-dim); font-size: 18px; }

.cta {
  text-align: center;
  background: linear-gradient(135deg, #7c6cff22, #38e0d022);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 72px 24px;
}
.cta h2 { font-size: clamp(26px, 4.4vw, 38px); font-weight: 400; margin-bottom: 12px; }
.cta p { color: var(--text-dim); font-size: 18px; margin-bottom: 28px; }

.timeline-list {
  max-width: 640px; margin: 0 auto;
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 18px; padding: 4px 28px;
}
.timeline-row {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid var(--border);
  font-size: 17px;
}
.timeline-row:last-child { border-bottom: none; }
.timeline-row .dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
  flex-shrink: 0; margin-top: 7px;
}
.timeline-row.final { color: var(--text-dim); font-style: italic; }
.timeline-row.final .dot { background: var(--accent2); }
.timeline-row .note {
  display: block; font-size: 13px; color: var(--text-dim);
  margin-top: 4px; font-style: normal;
}

@keyframes dallae-float {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-12px) rotate(1deg); }
}
.dallae-icon-float { animation: dallae-float 3.4s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .dallae-icon-float { animation: none; }
}

footer {
  border-top: 1px solid var(--border);
  padding: 40px 0; color: var(--text-dim); font-size: 14px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px;
}
footer .foot-links { display: flex; gap: 20px; }
footer a:hover { color: var(--text); }

@media (max-width: 780px) {
  nav { display: flex; justify-content: space-between; }
  .nav-toggle { display: flex; }
  .nav-cta { display: none; }
  .logo { font-size: 17px; gap: 4px; }
  .nav-actions { gap: 6px; }
  #lang-toggle { padding: 6px 10px; font-size: 12px; height: 32px; }
  .nav-back { padding: 6px 10px; font-size: 12px; height: 32px; }
  .nav-links {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: var(--bg-soft); border-bottom: 1px solid var(--border);
    padding: 4px 24px 12px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 0; border-top: 1px solid var(--border); }
  .flagship { grid-template-columns: 1fr; padding: 28px; }
  .flagship::before {
    background: linear-gradient(180deg, rgba(9,12,23,0.5) 0%, rgba(9,12,23,0.72) 55%, rgba(9,12,23,0.9) 100%);
  }
  #beyondmoment .flagship-visual { order: -1; }
  .apps-grid { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .hero { padding: 88px 0 64px; }
  html[lang="en"] .cf-captions { min-height: 190px; }
}
