/* ═══════════════════════════════════════════════════════════════════════
   AIvance Homepage — self-contained stylesheet
   Design tokens copied from the AIvance Design System (tokens/*.css) and
   distilled into reusable component classes so the page runs without the
   design-component runtime (x-dc / x-import).
   ═══════════════════════════════════════════════════════════════════════ */

/* ─── Webfonts ─────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;500;700;900&family=Space+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;700&display=swap');

/* ─── Design tokens ────────────────────────────────────────────────────── */
:root {
  /* Brand — AIvance */
  --aiv-blue-50:  #EFF5FF; --aiv-blue-100: #DBE8FE; --aiv-blue-200: #BFD5FE;
  --aiv-blue-300: #93B8FD; --aiv-blue-400: #6094FA; --aiv-blue-500: #2563EB;
  --aiv-blue-600: #1D4ED8; --aiv-blue-700: #1E40AF; --aiv-blue-800: #1E3A8A;
  --aiv-blue-900: #172554;

  /* AI-signal — electric indigo */
  --aiv-signal-100: #E6E4FD; --aiv-signal-300: #B3ACFA; --aiv-signal-500: #6D5EF6;
  --aiv-signal-600: #5B4CE0; --aiv-signal-700: #4B3DC2;

  /* Neutrals — slate */
  --slate-0: #FFFFFF; --slate-50: #F8FAFC; --slate-100: #F1F5F9;
  --slate-200: #E2E8F0; --slate-300: #CBD5E1; --slate-400: #94A3B8;
  --slate-500: #64748B; --slate-600: #475569; --slate-700: #334155;
  --slate-800: #1E293B; --slate-900: #0F172A; --ink: #1E2A38;

  /* Semantic */
  --success-100: #DCFCE7; --success-500: #16A34A; --success-700: #15803D;
  --warning-100: #FEF3C7; --warning-500: #F59E0B; --warning-700: #B45309;
  --danger-100:  #FEE2E2; --danger-500:  #DC2626; --danger-700:  #B91C1C;
  --info-100:    #E0F2FE; --info-500:    #0EA5E9; --info-700:    #0369A1;

  /* Product accents */
  --cura-500:  #12B3A6;  --cura-600:  #0E9488;  --cura-50: #E7FBF8;
  --copia-500: #7C3AED;  --copia-600: #6D28D9;  --copia-50: #F3EBFF;
  --creo-500:  #F0568C;  --creo-600:  #DB2F72;  --creo-50: #FEECF3;

  /* Semantic aliases */
  --brand: var(--aiv-blue-500); --brand-hover: var(--aiv-blue-600);
  --brand-active: var(--aiv-blue-700); --brand-subtle: var(--aiv-blue-50);
  --accent: var(--aiv-signal-500);

  --text-strong: var(--slate-900); --text-body: var(--slate-700);
  --text-muted: var(--slate-500); --text-subtle: var(--slate-400);
  --text-on-brand: #FFFFFF; --text-link: var(--aiv-blue-600);

  --surface-page: var(--slate-50); --surface-card: #FFFFFF;
  --surface-sunken: var(--slate-100); --surface-ink: var(--ink);
  --surface-hover: var(--slate-50);

  --border-subtle: #F0F0F0; --border-default: var(--slate-200);
  --border-strong: var(--slate-300); --border-focus: var(--aiv-blue-500);

  /* Typography */
  --font-sans: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Space Grotesk', 'Noto Sans KR', sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;
  --fw-regular: 400; --fw-medium: 500; --fw-semibold: 600; --fw-bold: 700; --fw-black: 900;

  /* Radius */
  --radius-xs: 4px; --radius-sm: 6px; --radius-md: 0.75rem;
  --radius-lg: 1rem; --radius-xl: 1.5rem; --radius-pill: 999px;

  /* Elevation */
  --shadow-xs:   0 1px 2px rgba(15,23,42,.06);
  --shadow-sm:   0 1px 3px rgba(15,23,42,.08);
  --shadow-card: 0 1px 3px rgba(15,23,42,.08), 0 1px 2px rgba(15,23,42,.04);
  --shadow-md:   0 4px 12px rgba(15,23,42,.10);
  --shadow-lg:   0 8px 24px rgba(15,23,42,.12);
  --shadow-xl:   0 16px 40px rgba(15,23,42,.16);
  --shadow-focus: 0 0 0 3px rgba(37,99,235,.35);

  /* Motion */
  --ease-out: cubic-bezier(.16,1,.3,1);
  --ease-inout: cubic-bezier(.65,0,.35,1);
  --dur-fast: .12s; --dur-base: .15s; --dur-slow: .3s;
  --lift: translateY(-3px);

  /* Layout */
  --container-max: 1120px;
}

/* ─── Base ─────────────────────────────────────────────────────────────── */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text-body);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.section-eyebrow {
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand);
  font-weight: 700;
}
.section-title {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 700;
  color: var(--text-strong);
  margin: 8px 0 10px;
  letter-spacing: -.02em;
}
.section-sub { font-size: 15px; color: var(--text-muted); margin: 0; }

/* ─── Button primitive ────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .5rem;
  padding: .55rem 1.15rem;
  font-family: var(--font-sans); font-size: 1rem; font-weight: var(--fw-semibold);
  line-height: 1.2;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer; white-space: nowrap;
  transition: background var(--dur-base), color var(--dur-base),
              border-color var(--dur-base), box-shadow var(--dur-base);
}
.btn:focus-visible { outline: none; box-shadow: var(--shadow-focus); }
.btn-sm { padding: .35rem .8rem; font-size: .875rem; gap: .35rem; }
.btn-lg { padding: .8rem 1.6rem; font-size: 1.125rem; gap: .55rem; }

.btn-primary { background: var(--brand); color: #fff; border-color: var(--brand); }
.btn-primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); }

.btn-outline { background: transparent; color: var(--brand); border-color: currentColor; }
.btn-outline:hover { background: var(--brand); color: #fff; }

.btn-ghost { background: transparent; color: var(--text-body); }
.btn-ghost:hover { background: var(--surface-hover); }

.btn-light { background: #fff; color: var(--ink); border-color: #fff; }
.btn-light:hover { background: var(--slate-100); border-color: var(--slate-100); }

.btn-ghost-invert { background: transparent; color: #fff; border-color: rgba(255,255,255,.35); }
.btn-ghost-invert:hover { background: rgba(255,255,255,.12); }

/* ─── Badge ───────────────────────────────────────────────────────────── */
.badge-soft {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600;
  color: var(--brand);
  background: var(--brand-subtle);
  padding: 5px 13px;
  border-radius: var(--radius-pill);
}

/* ─── Card ────────────────────────────────────────────────────────────── */
.card {
  display: flex; flex-direction: column;
  background: var(--surface-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--dur-base), transform var(--dur-base);
}
.card--interactive:hover { box-shadow: var(--shadow-lg); transform: var(--lift); }
.card--accent-cura  { border-top: 3px solid var(--cura-500); }
.card--accent-copia { border-top: 3px solid var(--copia-500); }
.card--accent-creo  { border-top: 3px solid var(--creo-500); }

.chip {
  font-size: 12px; color: var(--text-body);
  background: var(--slate-100);
  padding: 3px 9px; border-radius: var(--radius-pill);
}

/* ─── Header / Nav ────────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-subtle);
}
.nav {
  height: 64px; display: flex; align-items: center; gap: 28px;
}
.brand {
  display: flex; align-items: center; gap: 9px;
  font-family: var(--font-display); font-weight: 700; font-size: 22px;
  letter-spacing: -.02em; color: var(--text-strong);
}
.brand .ai { color: var(--brand); }
.nav-links { display: flex; gap: 22px; font-size: 14px; font-weight: 500; color: var(--text-body); }
.nav-links a:hover { color: var(--text-strong); }
.nav-cta { margin-left: auto; }
.nav-toggle { display: none; }

/* ─── Hero ────────────────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(165deg, #ffffff 0%, #eff5ff 55%, #e6e4fd 100%);
  border-bottom: 1px solid var(--border-subtle);
}
.hero-inner { padding: 96px 24px 84px; text-align: center; }
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(38px, 6vw, 60px);
  font-weight: 700; letter-spacing: -.03em; line-height: 1.08;
  color: var(--text-strong); margin: 22px 0 18px;
}
.hero-lead {
  font-size: 18px; line-height: 1.6; color: var(--text-muted);
  max-width: 560px; margin: 0 auto 30px;
}
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 40px; justify-content: center; margin-top: 52px; flex-wrap: wrap; }
.stat-num { font-family: var(--font-display); font-size: 30px; font-weight: 700; color: var(--text-strong); }
.stat-label { font-size: 13px; color: var(--text-muted); }

/* ─── Sections ────────────────────────────────────────────────────────── */
.section { padding: 84px 0; }
.section-center { text-align: center; margin-bottom: 48px; }

.products-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.product-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.product-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; font-size: 19px;
}
.product-icon--cura  { background: var(--cura-50);  color: var(--cura-600); }
.product-icon--copia { background: var(--copia-50); color: var(--copia-600); }
.product-icon--creo  { background: var(--creo-50);  color: var(--creo-600); }
.product-name { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--text-strong); }
.product-name .ai-cura  { color: var(--cura-500); }
.product-name .ai-copia { color: var(--copia-500); }
.product-name .ai-creo  { color: var(--creo-500); }
.product-tag { font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.product-tag--cura  { color: var(--cura-600); }
.product-tag--copia { color: var(--copia-600); }
.product-tag--creo  { color: var(--creo-600); }
.product-desc { font-size: 14px; line-height: 1.65; color: var(--text-muted); margin: 0 0 14px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }

/* Clickable product card → sample design, with homepage link pinned bottom */
.product-card { position: relative; text-decoration: none; }
.product-links {
  margin-top: 18px; padding-top: 16px;
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px; flex-wrap: wrap;
  border-top: 1px solid var(--border-subtle);
}
.product-view { font-size: 13px; font-weight: 700; white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; }
.product-view--cura  { color: var(--cura-600); }
.product-view--copia { color: var(--copia-600); }
.product-view--creo  { color: var(--creo-600); }
.product-home {
  position: relative; z-index: 2;
  font-size: 13px; color: var(--text-muted); white-space: nowrap;
  display: inline-flex; align-items: center; gap: 5px;
}
.product-home:hover { color: var(--text-strong); }
/* stretched link — whole card navigates to the sample page */
.stretched-link::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
}

/* Why / Philosophy */
.why {
  background: var(--surface-page);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.why-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.why-card {
  background: #fff; border: 1px solid var(--border-default);
  border-radius: 12px; padding: 24px; box-shadow: var(--shadow-card);
}
.why-card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.why-card-head i { font-size: 20px; }
.why-card-head span { font-weight: 700; color: var(--text-strong); }
.why-card p { font-size: 14px; line-height: 1.65; color: var(--text-muted); margin: 0; }

/* SEO + GEO highlight panel */
.why-seo {
  margin-top: 20px;
  background: linear-gradient(135deg, #fff 0%, var(--brand-subtle) 100%);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 32px;
}
.why-seo-head { text-align: center; max-width: 720px; margin: 0 auto 24px; }
.why-seo-head h3 {
  font-family: var(--font-display); font-size: 24px; font-weight: 700;
  letter-spacing: -.02em; color: var(--text-strong); margin: 14px 0 10px;
}
.why-seo-head p { font-size: 14.5px; line-height: 1.7; color: var(--text-muted); margin: 0; }
.why-seo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.why-seo-card {
  background: #fff; border: 1px solid var(--border-default);
  border-radius: var(--radius-md); padding: 18px 20px; border-top: 3px solid var(--brand);
}
.why-seo-card--cura  { border-top-color: var(--cura-500); }
.why-seo-card--copia { border-top-color: var(--copia-500); }
.why-seo-card--creo  { border-top-color: var(--creo-500); }
.wsc-head { font-weight: 700; color: var(--text-strong); font-size: 15px; margin-bottom: 8px; }
.wsc-head i { margin-right: 4px; }
.why-seo-card--cura .wsc-head i  { color: var(--cura-600); }
.why-seo-card--copia .wsc-head i { color: var(--copia-600); }
.why-seo-card--creo .wsc-head i  { color: var(--creo-600); }
.why-seo-card--cura .ai-cura   { color: var(--cura-500); }
.why-seo-card--copia .ai-copia { color: var(--copia-500); }
.why-seo-card--creo .ai-creo   { color: var(--creo-500); }
.why-seo-card p { font-size: 13.5px; line-height: 1.65; color: var(--text-muted); margin: 0; }
@media (max-width: 860px) {
  .why-seo-grid { grid-template-columns: 1fr; }
}

/* Tech */
.tech { padding: 72px 0; text-align: center; }
.tech-eyebrow {
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--text-subtle); font-weight: 700; margin-bottom: 20px;
}
.tech-tags { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.tech-tag {
  font-family: var(--font-mono); font-size: 13px; color: var(--text-body);
  background: var(--slate-100); padding: 8px 14px; border-radius: 8px;
}

/* CTA */
.cta { padding: 0 0 84px; }
.cta-box {
  background: var(--ink); border-radius: 24px;
  padding: 56px 48px; text-align: center; color: #fff;
}
.cta-box h2 { font-family: var(--font-display); font-size: 32px; font-weight: 700; margin: 0 0 12px; letter-spacing: -.02em; }
.cta-box p { color: var(--slate-400); font-size: 16px; margin: 0 auto 26px; max-width: 520px; }
.cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ─── FAQ ─────────────────────────────────────────────────────────────── */
.faq { border-top: 1px solid var(--border-subtle); }
.faq-list { max-width: 820px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: #fff; border: 1px solid var(--border-default);
  border-radius: var(--radius-md); box-shadow: var(--shadow-card);
  overflow: hidden;
}
.faq-item summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 12px;
  padding: 18px 22px;
  font-size: 15px; font-weight: 600; color: var(--text-strong);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "\F282"; font-family: "bootstrap-icons"; margin-left: auto;
  font-size: 15px; color: var(--text-subtle); transition: transform var(--dur-base);
}
.faq-item[open] summary::after { transform: rotate(180deg); }
.faq-item summary:hover { color: var(--brand); }
.faq-answer {
  padding: 0 22px 20px; font-size: 14px; line-height: 1.75; color: var(--text-muted);
}
.faq-answer a { color: var(--text-link); font-weight: 600; }
.faq-answer a:hover { text-decoration: underline; }
.faq-answer strong { color: var(--text-body); }

/* ─── Contact form ────────────────────────────────────────────────────── */
.contact { background: var(--surface-page); border-top: 1px solid var(--border-subtle); }
.contact-grid {
  display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 40px; align-items: start;
}
.contact-intro h2 {
  font-family: var(--font-display); font-size: 34px; font-weight: 700;
  letter-spacing: -.02em; color: var(--text-strong); margin: 8px 0 14px;
}
.contact-intro p { font-size: 15px; line-height: 1.7; color: var(--text-muted); margin: 0 0 24px; }
.contact-point { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.contact-point i { color: var(--brand); font-size: 18px; margin-top: 2px; }
.contact-point-t { font-weight: 700; color: var(--text-strong); font-size: 14px; }
.contact-point-d { font-size: 13px; color: var(--text-muted); }

.contact-card {
  background: #fff; border: 1px solid var(--border-default);
  border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow-card);
}
.form-row { margin-bottom: 16px; }
.form-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-label {
  display: block; font-size: 13px; font-weight: 600; color: var(--text-body); margin-bottom: 6px;
}
.form-label .req { color: var(--danger-500); margin-left: 2px; }
.form-control {
  width: 100%; padding: .6rem .75rem;
  font-family: var(--font-sans); font-size: 14px; color: var(--text-strong);
  background: #fff; border: 1px solid var(--border-default); border-radius: var(--radius-sm);
  transition: border-color var(--dur-base), box-shadow var(--dur-base);
}
.form-control::placeholder { color: var(--text-subtle); }
.form-control:focus { outline: none; border-color: var(--border-focus); box-shadow: var(--shadow-focus); }
textarea.form-control { resize: vertical; min-height: 120px; }
.form-error { display: block; font-size: 12px; color: var(--danger-500); margin-top: 5px; min-height: 0; }
.form-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-alert {
  display: none; align-items: flex-start; gap: 10px;
  padding: 12px 14px; border-radius: var(--radius-sm); font-size: 14px; margin-bottom: 16px;
}
.form-alert.show { display: flex; }
.form-alert.success { background: var(--success-100); color: var(--success-700); }
.form-alert.error { background: var(--danger-100); color: var(--danger-700); }
.form-alert i { font-size: 17px; margin-top: 1px; }

.btn[disabled] { opacity: .6; cursor: not-allowed; }

@media (max-width: 860px) {
  .contact-grid { grid-template-columns: 1fr; gap: 28px; }
  .form-row.two { grid-template-columns: 1fr; }
}

/* Footer */
.site-footer { border-top: 1px solid var(--border-subtle); background: #fff; }
.footer-inner { padding: 32px 24px; display: flex; flex-direction: column; gap: 20px; }
.footer-top {
  display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 20px;
}
.footer-brand-block { display: flex; flex-direction: column; gap: 14px; }
.footer-brand {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-display); font-weight: 700; font-size: 18px; color: var(--text-strong);
}
.footer-domains { display: flex; gap: 18px; font-size: 13px; color: var(--text-muted); }
.footer-domains a:hover { color: var(--brand); }
.footer-contact {
  display: grid; grid-template-columns: auto auto;
  gap: 8px 16px; justify-content: end; align-items: baseline;
}
.fc-item { display: contents; }
.fc-label { font-size: 12px; color: var(--text-subtle); text-align: right; white-space: nowrap; }
.fc-label i { color: var(--brand); margin-right: 3px; }
.fc-value { font-size: 13px; font-weight: 600; color: var(--text-body); text-align: right; }
a.fc-value:hover { color: var(--brand); }
.footer-copy {
  font-size: 13px; color: var(--text-subtle); text-align: center;
  border-top: 1px solid var(--border-subtle); padding-top: 16px;
}

/* ─── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .products-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .footer-top { flex-direction: column; align-items: flex-start; }
  .footer-contact { justify-content: start; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto; }
  .card--interactive:hover { transform: none; }
}
