/* ── Design Tokens ─────────────────────────────────────────── */
:root {
  --accent:         #2f9d91;
  --accent-dim:     rgba(47, 157, 145, 0.15);
  --text:           #141413;
  --text-secondary: #4d4942;
  --bg:             #f5efe5;
  --surface:        #fffaf1;
  --surface-strong: #ece3d5;
  --muted:          #6f6a60;
  --muted-soft:     #a59d91;
  --line:           rgba(68, 50, 28, 0.10);
  --line-strong:    rgba(68, 50, 28, 0.18);
  --radius:         16px;
  --radius-sm:      8px;
  --radius-pill:    9999px;
  --max:            1200px;
  --header-h:       64px;
  --shadow:         0 4px 16px rgba(65, 45, 24, 0.07);
  --shadow-lg:      0 12px 40px rgba(65, 45, 24, 0.12);
  --on-accent:      #ffffff;
  --transition:     160ms ease;
}

body.dark {
  --accent:         #1ed760;
  --accent-dim:     rgba(30, 215, 96, 0.12);
  --text:           #ffffff;
  --text-secondary: #b0b0b0;
  --bg:             #121212;
  --surface:        #1c1c1c;
  --surface-strong: #242424;
  --muted:          #a0a0a0;
  --muted-soft:     #606060;
  --line:           rgba(255, 255, 255, 0.08);
  --line-strong:    rgba(255, 255, 255, 0.15);
  --radius:         8px;
  --shadow:         0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg:      0 16px 48px rgba(0, 0, 0, 0.6);
  --on-accent:      #000000;
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Pretendard Variable", Pretendard, Inter, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  transition: background var(--transition), color var(--transition);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
img, iframe, video { display: block; max-width: 100%; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* ── Typography ─────────────────────────────────────────────── */
h1, h2, h3 { font-weight: 600; line-height: 1.2; letter-spacing: 0; }
h1 { font-size: clamp(2.4rem, 5vw, 4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: 1.1rem; }
em { font-family: "EB Garamond", Georgia, serif; font-style: italic; font-weight: 400; }

/* ── Layout helpers ─────────────────────────────────────────── */
.section-inner {
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 24px;
}

/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition), opacity var(--transition);
}
.btn:hover  { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: 0 2px 12px var(--accent-dim);
}
.btn-primary:hover { box-shadow: 0 4px 20px var(--accent-dim); }

.btn-ghost {
  border: 1px solid var(--line-strong);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ── Header / Nav ────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-h);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: background var(--transition);
}
.nav-inner {
  max-width: var(--max);
  height: 100%;
  margin-inline: auto;
  padding-inline: 24px;
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand {
  font-family: "EB Garamond", serif;
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--text);
  flex-shrink: 0;
}
.nav-links {
  display: flex;
  gap: 24px;
  flex: 1;
}
.nav-links a {
  font-size: 0.875rem;
  color: var(--muted);
  transition: color var(--transition);
  position: relative;
}
.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--accent);
  transition: width var(--transition);
}
.nav-links a:hover        { color: var(--text); }
.nav-links a:hover::after { width: 100%; }

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.cross-link {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 5px 12px;
  transition: color var(--transition), border-color var(--transition);
}
.cross-link:hover { color: var(--accent); border-color: var(--accent); }

.icon-btn {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-pill);
  color: var(--muted);
  border: 1px solid var(--line);
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}
.icon-btn:hover { color: var(--text); border-color: var(--line-strong); background: var(--surface); }

.lang-btn { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.05em; }

/* sun/moon toggle */
body:not(.dark) .icon-moon { display: none; }
body.dark       .icon-sun  { display: none; }

/* ── Hero ────────────────────────────────────────────────────── */
.hero-section {
  min-height: calc(84dvh - var(--header-h));
  display: flex;
  align-items: center;
  padding-block: 96px 72px;
  padding-inline: 24px;
}
.hero-inner {
  max-width: 980px;
  width: 100%;
  margin-inline: auto;
  display: flex;
  justify-content: center;
  text-align: center;
}
.hero-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.hero-label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.hero-title {
  font-size: clamp(4rem, 9vw, 7.6rem);
  line-height: 0.98;
  letter-spacing: 0;
}
.hero-title em {
  font-size: 1.1em;
  color: var(--accent);
  display: block;
}
.hero-desc {
  max-width: 560px;
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
}
.hero-chip-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  max-width: 680px;
}
.hero-chip-row span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
}
.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 4px;
  justify-content: center;
}

/* ── Section shared ─────────────────────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}
.section-header p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ── Works ───────────────────────────────────────────────────── */
.works-section {
  padding-block: 80px;
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.video-showcase {
  display: flex;
  flex-direction: column;
  gap: 56px;
}
.video-category {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.video-category-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}
.video-category-header h3 {
  font-size: clamp(1.35rem, 2vw, 1.75rem);
}
.video-category-header p {
  max-width: 520px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
  text-align: right;
}
.portfolio-video-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.portfolio-video-grid-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.portfolio-video-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.portfolio-video-link {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
  aspect-ratio: 16 / 9;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition), opacity var(--transition);
}
.portfolio-video-link:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
.portfolio-video-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
.portfolio-video-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition), opacity var(--transition);
}
.portfolio-video-link:hover img {
  opacity: 0.82;
  transform: scale(1.03);
}
.portfolio-video-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.44), rgba(0, 0, 0, 0.04));
}
.video-play-icon {
  position: absolute;
  inset: 50% auto auto 50%;
  z-index: 1;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 3px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #111111;
  font-size: 1.1rem;
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.3);
}
.portfolio-video-card h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}
.portfolio-video-card p {
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.55;
}
.collab-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.92fr);
  gap: 32px;
  align-items: center;
}
.collab-detail {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: 24px 0;
}
.collab-detail-kicker {
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.collab-detail h4 {
  color: var(--text);
  font-size: clamp(1.25rem, 2vw, 1.65rem);
  line-height: 1.3;
}
.collab-detail p:not(.collab-detail-kicker) {
  max-width: 420px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.75;
}
.collab-credit-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.collab-credit-list li {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface-strong);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
}

/* ── Tools ───────────────────────────────────────────────────── */
.tools-section { padding-block: 80px; }
.tools-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 32px;
}
.tool-chip {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 18px 9px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: border-color var(--transition), background var(--transition);
}
.tool-chip:hover { border-color: var(--accent); background: var(--accent-dim); }
.tool-logo {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: block;
  border-radius: 6px;
  object-fit: contain;
}
.tool-logo-gemini {
  object-fit: cover;
  object-position: left center;
}
.tool-logo-capcut {
  background: #ffffff;
  padding: 3px;
}
.tool-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
}
.tool-tag {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-strong);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}
.tools-note {
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted);
  max-width: 540px;
  margin-inline: auto;
  line-height: 1.7;
}

/* ── Contact ─────────────────────────────────────────────────── */
.contact-section {
  padding-block: 100px;
  background: var(--surface);
  border-top: 1px solid var(--line);
  text-align: center;
}
.contact-section h2 { margin-bottom: 16px; }
.contact-desc {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 36px;
}
.contact-btn {
  font-size: 1rem;
  padding: 14px 32px;
}

/* ── Footer ──────────────────────────────────────────────────── */
.site-footer {
  padding-block: 24px;
  border-top: 1px solid var(--line);
}
.footer-inner {
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--muted);
}
.footer-inner a:hover { color: var(--accent); }

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 900px) {
  .hero-inner {
    text-align: center;
  }
  .hero-cta-group { justify-content: center; }
  .collab-feature {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .collab-detail {
    padding: 0;
  }
  .portfolio-video-grid,
  .portfolio-video-grid-two { grid-template-columns: 1fr; }
  .video-category-header {
    align-items: start;
    flex-direction: column;
  }
  .video-category-header p { text-align: left; }
  .nav-links { display: none; }
}

@media (max-width: 620px) {
  .hero-section {
    min-height: calc(78dvh - var(--header-h));
    padding-block: 56px 44px;
  }
  .hero-title { font-size: 3.2rem; }
  .hero-desc { font-size: 0.98rem; }
  .hero-chip-row span { font-size: 0.74rem; }
  .works-section, .tools-section, .contact-section { padding-block: 56px; }
  .cross-link { display: none; }
  .footer-inner { flex-direction: column; gap: 8px; text-align: center; }
}
