:root {
  --bg: #050506;
  --bg-deep: #030305;
  --ink: #f7f7f9;
  --muted: rgba(247, 247, 249, 0.62);
  --accent: #0b1f4a;
  --accent-2: #1f3b7a;
  --card: rgba(10, 10, 14, 0.6);
  --outline: rgba(247, 247, 249, 0.12);
  --glow: rgba(63, 110, 255, 0.25);
  --soft: rgba(247, 247, 249, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", "Pretendard", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 30% 10%, #0b0c12 0%, var(--bg) 55%, var(--bg-deep) 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 80px 80px;
  opacity: 0.25;
  pointer-events: none;
  z-index: 0;
}

#fx {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.7;
  pointer-events: none;
}

main,
header,
footer {
  position: relative;
  z-index: 2;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px clamp(22px, 6vw, 80px);
  position: sticky;
  top: 0;
  backdrop-filter: blur(8px);
  background: linear-gradient(to bottom, rgba(5, 5, 6, 0.92), rgba(5, 5, 6, 0));
  transition: opacity 0.3s ease;
  z-index: 10;
  pointer-events: auto;
}

.site-header.hidden {
  opacity: 0;
}

.site-header.visible {
  opacity: 1;
}

.logo {
  font-family: "Fraunces", serif;
  font-size: 1.45rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  gap: 20px;
  font-size: 0.95rem;
}

.site-nav a {
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, color 0.3s ease;
  pointer-events: auto;
}

.site-nav a:hover {
  border-color: var(--accent-2);
  color: #c9d7ff;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  padding: 80px 6vw 40px;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  padding-top: 110px;
}

.hero-content h1 {
  font-family: "Fraunces", serif;
  font-size: clamp(2.4rem, 4vw, 4rem);
  margin: 10px 0 16px;
  line-height: 1.1;
}

.hero-kicker {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  color: var(--accent-2);
  font-weight: 600;
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: none;
  word-break: keep-all;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  margin-top: 24px;
}

.primary-btn {
  border: none;
  background: var(--accent);
  color: #fff;
  padding: 12px 26px;
  border-radius: 999px;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 14px 40px var(--glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.primary-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 50px rgba(63, 110, 255, 0.35);
}

.hero-note {
  font-size: 0.85rem;
  color: var(--muted);
}

.hero-card {
  padding: 24px;
  border-radius: 18px;
  background: var(--card);
  border: 1px solid var(--outline);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  display: grid;
  gap: 16px;
  backdrop-filter: blur(10px);
}

.hero-card-label {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.7rem;
  color: var(--muted);
}

.hero-card-value {
  font-family: "Fraunces", serif;
  font-size: 2.6rem;
}

.hero-card-bar {
  height: 6px;
  border-radius: 999px;
  background: rgba(247, 247, 249, 0.08);
  overflow: hidden;
}

.hero-card-fill {
  height: 100%;
  width: 40%;
  background: linear-gradient(120deg, var(--accent), #2f5eff);
  transition: width 0.4s ease;
}

section {
  padding: 50px 6vw;
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid rgba(247, 247, 249, 0.04);
}

.section-title h2 {
  font-family: "Fraunces", serif;
  font-size: clamp(1.8rem, 2.5vw, 2.6rem);
  margin: 0 0 12px;
}

.section-title p {
  color: var(--muted);
  max-width: none;
  word-break: keep-all;
  white-space: pre-line;
}

#aboutBody {
  white-space: pre-wrap;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 26px;
}

.about-item {
  padding: 18px;
  border-radius: 14px;
  background: rgba(10, 10, 14, 0.7);
  border: 1px solid var(--outline);
  color: var(--muted);
}

.content-block {
  display: grid;
  gap: 12px;
}

.block-text {
  padding: 18px;
  border-radius: 14px;
  background: rgba(10, 10, 14, 0.7);
  border: 1px solid var(--outline);
  color: var(--muted);
}

.block-image {
  border-radius: 18px;
  border: 1px solid var(--outline);
  overflow: hidden;
  background: rgba(10, 10, 14, 0.7);
}

.block-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 26px;
}

.project-card {
  padding: 20px;
  border-radius: 16px;
  background: linear-gradient(140deg, rgba(11, 13, 20, 0.9), rgba(10, 10, 14, 0.6));
  border: 1px solid rgba(247, 247, 249, 0.08);
  position: relative;
  overflow: hidden;
  min-height: 180px;
  display: grid;
  gap: 12px;
}

.project-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  border: 1px solid rgba(63, 110, 255, 0.12);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.project-card:hover::after {
  opacity: 1;
}

.project-card h3 {
  margin: 0 0 8px;
  font-size: 1.2rem;
}

.project-card p {
  color: var(--muted);
  white-space: pre-line;
}

.project-bullets {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  display: grid;
  gap: 6px;
}

.project-bullets li {
  line-height: 1.5;
}

.project-image {
  border-radius: 12px;
  border: 1px solid rgba(247, 247, 249, 0.08);
  overflow: hidden;
  background: rgba(0, 0, 0, 0.4);
}

.project-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tag {
  font-size: 0.75rem;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--soft);
}

.contact {
  display: grid;
  gap: 16px;
}

.contact-extra {
  display: grid;
  gap: 12px;
}

.contact-link {
  font-size: 1.2rem;
  color: #6fa2ff;
  text-decoration: none;
  font-weight: 600;
}

.contact-link:hover {
  text-decoration: underline;
}

.site-footer {
  padding: 30px 6vw 50px;
  font-size: 0.85rem;
  color: var(--muted);
}

@media (max-width: 720px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .site-nav {
    flex-wrap: wrap;
  }
}

body.mode-2 {
}

body.entered .intro {
  opacity: 0;
  pointer-events: none;
  transform: scale(1.05);
}

body.home .intro {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 50% 40%, rgba(11, 31, 74, 0.25), transparent 55%);
  transition: opacity 0.8s ease, transform 0.8s ease;
  z-index: 3;
  touch-action: none;
}

body.home:not(.entered) .site-header {
  opacity: 0;
  pointer-events: none;
}

.intro-center {
  text-align: center;
  display: grid;
  gap: 18px;
}

.seed {
  width: 240px;
  height: 240px;
  margin: 0 auto;
  position: relative;
  transform: translate3d(0, 0, 0);
  transition: transform 0.2s ease;
  filter: drop-shadow(0 0 20px rgba(63, 110, 255, 0.35));
}

.seed-rays {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: conic-gradient(from 0deg, rgba(31, 59, 122, 0.3), transparent 25%, rgba(31, 59, 122, 0.2) 50%, transparent 75%, rgba(31, 59, 122, 0.3));
  mask: radial-gradient(circle, transparent 40%, black 42%, black 68%, transparent 70%);
  animation: spin 8s linear infinite;
  opacity: 0.75;
}

.seed-orbit {
  position: absolute;
  inset: 20px;
  border-radius: 999px;
  border: 1px dashed rgba(111, 162, 255, 0.25);
  animation: spin 12s linear infinite;
}

.seed-orbit::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(111, 162, 255, 0.7);
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 12px rgba(111, 162, 255, 0.7);
}

.seed-orbit.inner {
  inset: 52px;
  border-style: solid;
  border-color: rgba(247, 247, 249, 0.15);
  animation-duration: 6s;
}

.seed-orbit.inner::after {
  width: 6px;
  height: 6px;
  background: rgba(247, 247, 249, 0.8);
}

.seed-core {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 16px;
  height: 16px;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  background: #f7f7f9;
  box-shadow: 0 0 18px rgba(111, 162, 255, 0.6);
}

.seed-ring,
.seed-halo {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  border: 1px solid rgba(247, 247, 249, 0.25);
}

.seed-ring {
  width: 170px;
  height: 170px;
  animation: pulse 3.6s ease-in-out infinite;
}

.seed-halo {
  width: 240px;
  height: 240px;
  border-color: rgba(31, 59, 122, 0.4);
  animation: pulse 4.8s ease-in-out infinite;
}

.intro-text {
  color: var(--muted);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

body.home main {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}

body.home.entered main {
  opacity: 1;
  transform: translateY(0);
}

body.editor-page main {
  opacity: 1;
  transform: none;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
  50% { transform: translate(-50%, -50%) scale(1.06); opacity: 0.35; }
  100% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
}

@keyframes floatIn {
  from {
    opacity: 0.6;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
