/* ===================== Design tokens ===================== */
:root {
  --navy: #0b1f3a;
  --navy-2: #10294b;
  --blue: #1e6bff;
  --cyan: #00c2d1;
  --ink: #16202e;
  --muted: #5b6b7f;
  --line: #e5eaf1;
  --bg: #ffffff;
  --bg-alt: #f5f8fc;
  --white: #ffffff;
  --radius: 14px;
  --shadow-sm: 0 2px 8px rgba(11, 31, 58, 0.06);
  --shadow-md: 0 12px 32px rgba(11, 31, 58, 0.10);
  --maxw: 1120px;
  --header-h: 68px;
}

/* ===================== Base ===================== */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  margin: 0;
  font-family: "Pretendard", "Pretendard Variable", -apple-system, BlinkMacSystemFont,
    system-ui, "Segoe UI", Roboto, "Apple SD Gothic Neo", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -0.02em; margin: 0; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 24px;
}

/* ===================== Buttons ===================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: 1rem;
  padding: 13px 24px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: var(--white);
  box-shadow: 0 8px 20px rgba(30, 107, 255, 0.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(30, 107, 255, 0.36); }
.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.4);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.12); }
.btn-block { width: 100%; }

/* ===================== Header ===================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.site-header.scrolled {
  border-bottom-color: var(--line);
  box-shadow: var(--shadow-sm);
}
.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand-mark { flex: none; }
.brand-text {
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.03em;
  color: var(--navy);
}

.nav { display: flex; align-items: center; gap: 6px; }
.nav-link {
  padding: 8px 14px;
  border-radius: 8px;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.15s ease, background 0.15s ease;
}
.nav-link:hover, .nav-link.active { color: var(--navy); background: var(--bg-alt); }
.nav-cta {
  margin-left: 8px;
  padding: 9px 18px;
  border-radius: 9px;
  font-weight: 600;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 6px 16px rgba(30, 107, 255, 0.25);
}
.nav-cta:hover { transform: translateY(-1px); }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}
.nav-toggle span {
  width: 20px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===================== Hero ===================== */
.hero {
  position: relative;
  color: var(--white);
  padding: clamp(80px, 14vw, 150px) 0 clamp(70px, 11vw, 120px);
  overflow: hidden;
  isolation: isolate;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(1000px 500px at 78% -10%, rgba(0, 194, 209, 0.35), transparent 60%),
    radial-gradient(800px 500px at 0% 100%, rgba(30, 107, 255, 0.35), transparent 55%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(90% 90% at 50% 30%, #000, transparent 80%);
}
.hero-eyebrow {
  display: inline-block;
  margin: 0 0 18px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #bfe6ff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}
.hero-title {
  font-size: clamp(2.1rem, 5.4vw, 3.6rem);
  font-weight: 800;
  margin-bottom: 22px;
}
.hero-title .accent {
  background: linear-gradient(120deg, #6fd0ff, var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-lead {
  max-width: 620px;
  font-size: clamp(1rem, 2.2vw, 1.18rem);
  color: rgba(255, 255, 255, 0.82);
  margin: 0 0 34px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 40px;
  list-style: none;
  margin: 52px 0 0;
  padding: 34px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats strong { font-size: 1.15rem; font-weight: 700; }
.hero-stats span { font-size: 0.9rem; color: rgba(255, 255, 255, 0.6); }

/* ===================== Sections ===================== */
.section { padding: clamp(64px, 10vw, 110px) 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-head { max-width: 680px; margin-bottom: 46px; }
.section-tag {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}
.section-head h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); font-weight: 800; color: var(--navy); }
.section-sub { margin: 14px 0 0; color: var(--muted); font-size: 1.05rem; }

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: start;
}
.about-text p { margin: 0 0 18px; font-size: 1.06rem; color: #2b3a4d; }
.about-text strong { color: var(--navy); }
.about-points { list-style: none; margin: 0; padding: 26px; background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); }
.section-alt .about-points { background: var(--white); }
.about-points li { display: flex; align-items: center; gap: 12px; padding: 11px 0; font-weight: 500; color: var(--ink); }
.about-points li + li { border-top: 1px solid var(--line); }
.dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--cyan)); }

/* Brand meaning */
.brand-meaning {
  margin-top: 44px;
  padding: clamp(28px, 5vw, 44px);
  border-radius: var(--radius);
  text-align: center;
  color: var(--white);
  background:
    radial-gradient(600px 300px at 50% -20%, rgba(0, 194, 209, 0.35), transparent 70%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
  box-shadow: var(--shadow-md);
}
.bm-label {
  display: inline-block;
  margin: 0 0 16px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #bfe6ff;
}
.bm-word {
  margin: 0 0 14px;
  font-size: clamp(1.35rem, 4vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.75);
}
.bm-hl {
  color: #fff;
  background: linear-gradient(120deg, #6fd0ff, var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 800;
}
.bm-desc {
  max-width: 620px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.02rem;
}

/* Services cards */
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: rgba(30, 107, 255, 0.35); }
.card-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--blue);
  background: linear-gradient(135deg, rgba(30, 107, 255, 0.12), rgba(0, 194, 209, 0.12));
  margin-bottom: 18px;
}
.card h3 { font-size: 1.18rem; font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.card p { margin: 0; color: var(--muted); font-size: 0.97rem; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 40px; align-items: start; }
.contact-info { list-style: none; margin: 0; padding: 0; }
.contact-info li { padding: 20px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.contact-info li:first-child { padding-top: 0; }
.ci-label { font-size: 0.82rem; font-weight: 700; letter-spacing: 0.04em; color: var(--blue); }
.contact-info a { font-size: 1.1rem; font-weight: 600; color: var(--navy); }
.contact-info a:hover { color: var(--blue); }
.todo { font-size: 0.8rem; color: #b23b3b; font-style: normal; }

.contact-form {
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
}
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 0.9rem; font-weight: 600; color: var(--ink); margin-bottom: 8px; }
.field input, .field textarea {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 10px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(30, 107, 255, 0.15);
}
.field textarea { resize: vertical; }
.form-note { margin: 14px 0 0; font-size: 0.92rem; min-height: 1.2em; }
.form-note.ok { color: #1c7a4a; }
.form-note.err { color: #b23b3b; }

/* ===================== Footer ===================== */
.site-footer { background: var(--navy); color: rgba(255, 255, 255, 0.72); padding: 44px 0; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center; }
.footer-brand .brand-text { color: var(--white); }
.footer-brand p { margin: 4px 0 0; font-size: 0.92rem; }
.footer-meta { text-align: right; }
.footer-meta p { margin: 2px 0; font-size: 0.9rem; }

/* ===================== Reveal animation ===================== */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ===================== Responsive ===================== */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 28px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-meta { text-align: left; }
}

@media (max-width: 720px) {
  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 14px 20px 22px;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    transform: translateY(-120%);
    transition: transform 0.28s ease;
  }
  .nav.open { transform: translateY(0); }
  .nav-link { padding: 12px 14px; }
  .nav-cta { margin: 6px 0 0; text-align: center; }
  .nav-toggle { display: flex; }
}

@media (max-width: 520px) {
  .cards { grid-template-columns: 1fr; }
  .hero-stats { gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
