:root {
  --bg: #05070d;
  --bg-2: #0a0f1d;
  --text: #ecf2ff;
  --muted: #8f9bb5;
  --line: rgba(167, 187, 229, 0.2);
  --accent: #ff8e75;
  --display: 'Sora', 'Noto Sans KR', sans-serif;
  --body: 'Sora', 'Noto Sans KR', sans-serif;
  --mono: 'IBM Plex Mono', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body);
  color: var(--text);
  background:
    radial-gradient(1200px 640px at 6% -8%, rgba(255, 143, 117, 0.15), transparent 62%),
    radial-gradient(980px 580px at 92% -6%, rgba(124, 143, 255, 0.14), transparent 60%),
    linear-gradient(180deg, var(--bg), var(--bg-2));
  line-height: 1.72;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  padding: 16px 28px;
  backdrop-filter: none;
  background: transparent;
}

.brand {
  color: var(--text);
  text-decoration: none;
  font-family: var(--display);
  letter-spacing: -0.7px;
  font-size: clamp(20px, 2.3vw, 30px);
  font-weight: 800;
  line-height: 1;
}

.menu {
  display: flex;
  justify-content: center;
  gap: 26px;
  flex-wrap: wrap;
}

.menu a {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.2s ease;
}

.menu a:hover {
  color: var(--text);
}

.lang-toggle {
  justify-self: end;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(14, 20, 36, 0.85);
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.8px;
  padding: 8px 12px;
  cursor: pointer;
}

main {
  width: min(1180px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 26px 0 70px;
}

.hero {
  padding: 68px 0 48px;
  border-bottom: 1px solid var(--line);
}

.hero h1 {
  font-family: var(--display);
  font-size: clamp(38px, 7.6vw, 88px);
  line-height: 0.98;
  letter-spacing: -1.4px;
  max-width: 1080px;
  margin-bottom: 18px;
}

.hero-copy {
  color: var(--muted);
  max-width: 840px;
  font-size: clamp(15px, 2vw, 19px);
}

.hero-actions {
  margin-top: 20px;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  text-decoration: none;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.6px;
  color: var(--text);
  background: rgba(13, 19, 34, 0.72);
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.hero-btn:hover {
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

.section {
  padding: 52px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 86px;
}

.section h2 {
  font-family: var(--display);
  font-size: clamp(24px, 4vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.8px;
  margin-bottom: 24px;
}

.lines {
  list-style: none;
  display: grid;
  gap: 14px;
}

.lines li {
  display: grid;
  grid-template-columns: 56px 1fr;
  align-items: start;
  gap: 16px;
  padding: 10px 0;
  border-top: 1px solid rgba(164, 184, 224, 0.12);
}

.lines li span {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 12px;
  margin-top: 4px;
}

.lines li p {
  color: var(--text);
  font-size: clamp(16px, 2.3vw, 22px);
  line-height: 1.45;
}

.products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px;
}

.products article {
  padding-right: 20px;
}

.products article + article {
  border-left: 1px solid rgba(164, 184, 224, 0.16);
  padding-left: 34px;
}

.tag {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 11px;
  letter-spacing: 0.8px;
  margin-bottom: 8px;
}

.products h3 {
  font-family: var(--display);
  font-size: clamp(26px, 4vw, 42px);
  letter-spacing: -0.8px;
  margin-bottom: 10px;
}

.product-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.product-title-row h3 {
  margin-bottom: 0;
}

.product-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 11px;
  border: 1px solid rgba(167, 187, 229, 0.26);
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.product-btn:hover {
  border-color: var(--accent);
  color: #fff;
}

.products p {
  color: var(--muted);
  font-size: 15px;
}

.products ul {
  margin-top: 16px;
  list-style: none;
  display: grid;
  gap: 8px;
}

.products li {
  color: var(--text);
  font-size: 14px;
  padding-left: 14px;
  position: relative;
}

.products li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.foot {
  width: min(1180px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 22px 0 40px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .products {
    grid-template-columns: 1fr;
  }

  .products article + article {
    border-left: 0;
    border-top: 1px solid rgba(164, 184, 224, 0.16);
    padding-left: 0;
    padding-top: 24px;
  }
}

@media (max-width: 760px) {
  .topbar {
    grid-template-columns: 1fr auto;
    gap: 10px;
    padding: 14px;
  }

  .menu {
    grid-column: 1 / -1;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  main,
  .foot {
    width: min(1180px, calc(100vw - 28px));
  }
}

/* Inline Chat */
.chat-subtitle {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 24px;
}

.chat-inline {
  border: 1px solid rgba(164, 184, 224, 0.12);
  border-radius: 12px;
  background: rgba(8, 12, 24, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.chat-messages {
  overflow-y: auto;
  padding: 24px 24px 8px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 160px;
  max-height: 520px;
  scroll-behavior: smooth;
}

.chat-msg {
  font-size: 14px;
  line-height: 1.7;
  word-break: break-word;
  white-space: pre-wrap;
  max-width: 88%;
}

.chat-msg.user {
  align-self: flex-end;
  color: var(--text);
  background: rgba(255, 142, 117, 0.1);
  border: 1px solid rgba(255, 142, 117, 0.18);
  border-radius: 16px 16px 4px 16px;
  padding: 10px 16px;
}

.chat-msg.assistant {
  align-self: flex-start;
  color: var(--muted);
  padding: 0 4px;
}

.chat-msg p {
  margin: 0;
}

.chat-typing {
  color: var(--muted);
  font-size: 12px;
  font-family: var(--mono);
  letter-spacing: 0.3px;
  padding: 0 4px;
}

/* Preset Questions */
.chat-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 24px 16px;
}

.chat-preset {
  background: rgba(255, 142, 117, 0.12);
  border: 1px solid rgba(255, 142, 117, 0.35);
  border-radius: 999px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.3px;
  padding: 8px 14px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}

.chat-preset:hover {
  background: rgba(255, 142, 117, 0.22);
  border-color: var(--accent);
  color: #fff;
}

/* Input Bar */
.chat-form {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 12px 0 24px;
  margin: 0;
  border-top: 1px solid rgba(164, 184, 224, 0.1);
  background: rgba(10, 15, 29, 0.5);
}

.chat-form input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: var(--body);
  font-size: 14px;
  padding: 16px 0;
  outline: none;
}

.chat-form input::placeholder {
  color: rgba(143, 155, 181, 0.35);
}

.chat-send {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: none;
  border: 1px solid rgba(167, 187, 229, 0.2);
  border-radius: 8px;
  color: var(--accent);
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.chat-send:hover {
  border-color: var(--accent);
  background: rgba(255, 142, 117, 0.08);
}

.chat-send:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

@media (max-width: 760px) {
  .chat-messages {
    padding: 16px 16px 8px;
    max-height: 400px;
  }

  .chat-presets {
    padding: 8px 16px 12px;
  }

  .chat-preset {
    font-size: 11px;
    padding: 6px 11px;
  }

  .chat-form {
    padding: 0 10px 0 16px;
  }
}
