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

:root {
  --blue: #00428c;
  --blue-10: rgba(0,66,140,0.08);
  --blue-15: rgba(0,66,140,0.15);
  --blue-20: rgba(0,66,140,0.20);
  --white: #ffffff;
  --bg: #f5f7fa;
  --text: #1a1a1a;
  --text-muted: #6b7280;
  --border: rgba(0,0,0,0.08);
  --nav-h: 68px;
  --ff-en: 'Inter', sans-serif;
  --ff-ja: 'Noto Sans JP', sans-serif;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--ff-ja);
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* ── Utilities ── */
.en { font-family: var(--ff-en); }
.container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.section-label {
  font-family: var(--ff-en);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--blue);
  display: block;
  margin-bottom: 12px;
}
.section-title {
  font-family: var(--ff-en);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.15;
}

/* ── Header ── */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  display: flex;
  align-items: center;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}
.logo {
  font-family: var(--ff-en);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.06em;
  color: var(--blue);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}
nav { display: flex; align-items: center; gap: 32px; }
nav a {
  font-family: var(--ff-en);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
  position: relative;
  padding-bottom: 2px;
}
nav a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--blue);
  border-radius: 1px;
  transition: width 0.25s ease;
}
nav a:hover, nav a.active { color: var(--blue); }
nav a:hover::after, nav a.active::after { width: 100%; }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
  transition: all 0.3s;
}

/* ── Mobile menu ── */
.mobile-menu {
  display: none;
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 24px;
  z-index: 99;
  flex-direction: column;
  gap: 0;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: var(--ff-en);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.mobile-menu a:last-child { border-bottom: none; }

/* ── Hero ── */
#hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: var(--white);
  padding-top: var(--nav-h);
  overflow: hidden;
  position: relative;
}
.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero-bg-circle {
  position: absolute;
  border-radius: 50%;
  background: var(--blue-10);
}
.hero-bg-circle.c1 {
  width: 600px; height: 600px;
  top: -100px; right: -100px;
  animation: float1 12s ease-in-out infinite;
  will-change: transform;
  backface-visibility: hidden;
}
.hero-bg-circle.c2 {
  width: 300px; height: 300px;
  bottom: 60px; left: -60px;
  background: var(--blue-15);
  animation: float2 9s ease-in-out infinite;
  will-change: transform;
  backface-visibility: hidden;
}
@keyframes float1 {
  0%,100% { transform: translate(0,0); }
  50% { transform: translate(-20px, 30px); }
}
@keyframes float2 {
  0%,100% { transform: translate(0,0); }
  50% { transform: translate(15px, -20px); }
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 60px;
  width: 100%;
  padding: 80px 24px;
}
.hero-content { opacity: 0; animation: fadeUp 0.9s ease 0.2s forwards; }
.hero-kicker {
  font-family: var(--ff-en);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 20px;
}
.hero-title {
  font-size: clamp(32px, 5.5vw, 64px);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 28px;
}
.hero-title em {
  font-style: normal;
  color: var(--blue);
}
.hero-sub {
  font-size: clamp(14px, 1.8vw, 17px);
  color: var(--text-muted);
  max-width: 520px;
  line-height: 1.8;
  margin-bottom: 40px;
  font-weight: 300;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--blue);
  color: var(--white);
  text-decoration: none;
  font-family: var(--ff-ja);
  font-size: 14px;
  font-weight: 500;
  border-radius: 4px;
  transition: background 0.2s, transform 0.15s;
  letter-spacing: 0.04em;
}
.btn:hover { background: #003070; transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  color: var(--blue);
  border: 1.5px solid var(--blue);
}
.btn-outline:hover { background: var(--blue-10); transform: translateY(-1px); }
.hero-svg {
  opacity: 0;
  animation: fadeIn 1.2s ease 0.5s forwards;
  width: clamp(180px, 22vw, 320px);
  flex-shrink: 0;
}
.hero-svg svg path { fill: var(--blue); }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ── Sections common ── */
section {
  padding: 100px 0;
}
section:nth-child(even) { background: var(--bg); }

/* ── About ── */
#about .about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 64px;
  align-items: center;
  margin-top: 56px;
}
.about-avatar {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 8px;
  background: var(--blue-10);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}
.about-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.about-avatar-placeholder {
  width: 64%;
  height: 64%;
  opacity: 0.25;
}
.about-avatar-placeholder path { fill: var(--blue); }
.avatar-label {
  position: absolute;
  bottom: 12px;
  font-family: var(--ff-en);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--blue);
  opacity: 0.5;
}
.about-name {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}
.about-name-en {
  font-family: var(--ff-en);
  font-size: 13px;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  font-weight: 400;
  margin-bottom: 28px;
}
.about-body {
  font-size: 15px;
  color: #444;
  line-height: 1.9;
  font-weight: 300;
}
.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}
.tag {
  font-family: var(--ff-en);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--blue);
  background: var(--blue-10);
  border: 1px solid var(--blue-15);
  padding: 5px 12px;
  border-radius: 3px;
}

/* ── Skills ── */
#skills .skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 56px;
}
.skill-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px 24px;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.skill-card:hover {
  border-color: var(--blue-20);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,66,140,0.08);
}
.skill-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--blue-10);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  font-size: 16px;
}
.skill-name {
  font-family: var(--ff-en);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}
.skill-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 300;
}

/* ── Works ── */
#works .works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 56px;
}
.work-card {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--white);
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}
.work-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(0,0,0,0.08);
}
.work-thumb {
  width: 100%;
  aspect-ratio: 16/9;
  background: var(--blue-10);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.work-thumb-label {
  font-family: var(--ff-en);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--blue);
  opacity: 0.4;
  text-align: center;
  padding: 12px;
}
.work-badge {
  position: absolute;
  top: 12px; right: 12px;
  font-family: var(--ff-en);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 3px;
}
.badge-coming {
  background: rgba(107,114,128,0.12);
  color: var(--text-muted);
}
.badge-live {
  background: rgba(0,66,140,0.1);
  color: var(--blue);
}
.work-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.work-title {
  font-family: var(--ff-en);
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}
.work-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.75;
  flex: 1;
  font-weight: 300;
}
.work-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 20px;
  font-family: var(--ff-en);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--blue);
  text-decoration: none;
  border-bottom: 1px solid var(--blue-20);
  padding-bottom: 1px;
  transition: border-color 0.2s;
  align-self: flex-start;
}
.work-link:hover { border-color: var(--blue); }
.work-link svg { transition: transform 0.2s; }
.work-link:hover svg { transform: translateX(3px); }

/* ── Contact ── */
#contact {
  text-align: center;
}
#contact .container { max-width: 640px; }
.contact-desc {
  font-size: 15px;
  color: var(--text-muted);
  margin-top: 20px;
  margin-bottom: 40px;
  font-weight: 300;
  line-height: 1.9;
}
.contact-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}
.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--ff-en);
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 28px;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 10px 20px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}
.contact-email:hover { border-color: var(--blue-20); color: var(--blue); }
.contact-email svg { color: var(--blue); }

/* ── Contact Platforms ── */
.contact-platforms {
  margin-top: 40px;
}
.contact-platforms-label {
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}
.contact-platforms-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}
.platform-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--ff-ja);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 8px 18px;
  border-radius: 4px;
  transition: border-color 0.2s, color 0.2s;
}
.platform-link:hover {
  border-color: var(--blue-20);
  color: var(--blue);
}

/* ── Footer ── */
footer {
  background: var(--text);
  color: rgba(255,255,255,0.45);
  padding: 32px 24px;
  text-align: center;
  font-family: var(--ff-en);
  font-size: 12px;
  letter-spacing: 0.06em;
}
footer .footer-logo {
  font-weight: 700;
  font-size: 14px;
  color: rgba(255,255,255,0.8);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 8px;
}

/* ── Scroll reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.in { opacity: 1; transform: none; }

/* ── Divider ── */
.section-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 56px;
}
.section-divider::before, .section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  nav { display: none; }
  .hamburger { display: flex; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-svg { display: none; }
  #about .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-avatar { max-width: 240px; margin: 0 auto; }
  section { padding: 72px 0; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 28px; }
  .hero-inner { padding: 60px 20px; }
  .skills-grid { grid-template-columns: 1fr; }
  .works-grid { grid-template-columns: 1fr; }
}
