/* ==========================================
   CSS Variables
   ========================================== */
:root {
  --bg: #1a1a1a;
  --bg-card: #222222;
  --fg: #f0f0f0;
  --fg-muted: #999999;
  --primary: #50b478;
  --border: #333333;
  --font-mono: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', sans-serif;
  --max-width: 960px;
  --px: 24px;
  --header-h: 56px;
}

@media (min-width: 768px) {
  :root { --px: 48px; }
}

@media (min-width: 1024px) {
  :root { --px: 96px; }
}

/* ==========================================
   Reset & Base
   ========================================== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: var(--header-h);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: opacity 0.2s;
}

a:hover {
  opacity: 0.8;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ==========================================
   Site Header / Navigation
   ========================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(26, 26, 26, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  padding: 0 var(--px);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--fg);
  text-decoration: none;
}

.header-brand:hover {
  opacity: 0.8;
  text-decoration: none;
}

.header-brand .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.header-brand span {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.header-nav {
  display: none;
  align-items: center;
  gap: 28px;
}

@media (min-width: 640px) {
  .header-nav { display: flex; }
}

.header-nav a {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-muted);
  text-decoration: none;
  transition: color 0.2s;
  padding: 4px 0;
}

.header-nav a:hover {
  color: var(--fg);
  text-decoration: none;
  opacity: 1;
}

.header-nav a.active {
  color: var(--primary);
}

/* Hamburger */
.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 4px;
}

@media (min-width: 640px) {
  .nav-toggle { display: none; }
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 1px;
  background: var(--fg-muted);
  transition: transform 0.2s, opacity 0.2s;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  top: var(--header-h);
  left: 0;
  right: 0;
  background: rgba(26, 26, 26, 0.98);
  border-bottom: 1px solid var(--border);
  padding: 20px var(--px);
  z-index: 99;
  flex-direction: column;
  gap: 0;
}

.mobile-nav.open { display: flex; }

.mobile-nav a {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-muted);
  text-decoration: none;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  transition: color 0.2s;
}

.mobile-nav a:last-child { border-bottom: none; }

.mobile-nav a.active { color: var(--primary); }

.mobile-nav a:hover {
  color: var(--fg);
  text-decoration: none;
  opacity: 1;
}

/* ==========================================
   Section Base
   ========================================== */
section {
  padding: 96px var(--px);
  border-top: 1px solid var(--border);
}

section:first-of-type {
  border-top: none;
}

.section-inner {
  max-width: var(--max-width);
}

/* ==========================================
   Section Header
   ========================================== */
.section-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 48px;
}

.section-header .num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
}

.section-header .sep {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
}

.section-header h2 {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--fg);
}

.section-header .subtitle {
  font-size: 12px;
  color: var(--fg-muted);
}

.section-header .subtitle::before {
  content: '—';
  margin-right: 8px;
}

/* ==========================================
   Page Hero (inner pages)
   ========================================== */
.page-hero {
  padding: 56px var(--px) 48px;
  border-bottom: 1px solid var(--border);
}

.page-hero-inner {
  max-width: var(--max-width);
}

.page-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.page-label .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.page-hero h1 {
  font-size: 22px;
  font-weight: 400;
  line-height: 1.5;
  margin-bottom: 12px;
}

@media (min-width: 768px) {
  .page-hero h1 { font-size: 30px; }
}

.page-hero .page-desc {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.9;
  max-width: 640px;
}

/* ==========================================
   HERO (index only)
   ========================================== */
.hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px var(--px);
  overflow: hidden;
}

.hero canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.8;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
}

.hero-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 32px;
}

.hero-label .dot {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.hero-label span {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.hero h1 {
  font-size: 24px;
  font-weight: 400;
  line-height: 1.6;
  margin-bottom: 24px;
}

.hero h1 .accent { color: var(--primary); }

.hero .sub {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--fg-muted);
  margin-bottom: 48px;
}

.hero .badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  background: rgba(34, 34, 34, 0.8);
  backdrop-filter: blur(8px);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.badge .dot.active { background: var(--primary); }
.badge .dot.info   { background: var(--fg-muted); }

@media (min-width: 768px) {
  .hero h1 { font-size: 36px; }
}

@media (min-width: 1024px) {
  .hero h1 { font-size: 48px; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

/* ==========================================
   INDEX: Page Navigation Cards
   ========================================== */
.page-nav-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 480px) {
  .page-nav-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .page-nav-grid { grid-template-columns: repeat(3, 1fr); }
}

.page-nav-card {
  display: block;
  padding: 24px 24px 52px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--fg);
  text-decoration: none;
  position: relative;
  transition: border-color 0.2s;
}

.page-nav-card:hover {
  border-color: var(--primary);
  text-decoration: none;
  opacity: 1;
}

.page-nav-card .pnc-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--primary);
  margin-bottom: 16px;
}

.page-nav-card .pnc-title {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg);
  margin-bottom: 10px;
}

.page-nav-card .pnc-desc {
  font-size: 12px;
  color: var(--fg-muted);
  line-height: 1.8;
}

.page-nav-card .pnc-arrow {
  position: absolute;
  bottom: 20px;
  right: 24px;
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--fg-muted);
  transition: color 0.2s, transform 0.2s;
}

.page-nav-card:hover .pnc-arrow {
  color: var(--primary);
  transform: translateX(4px);
}

/* ==========================================
   PROFILE / ABOUT TEXT
   ========================================== */
.profile p,
.about-text p {
  font-size: 14px;
  line-height: 1.9;
  color: var(--fg-muted);
  margin-bottom: 20px;
}

.profile p:last-child,
.about-text p:last-child {
  margin-bottom: 0;
}

.profile .highlight { color: var(--primary); }

/* Philosophy block */
.philosophy-block {
  padding: 24px;
  border-left: 2px solid var(--primary);
  background: rgba(80, 180, 120, 0.03);
}

.philosophy-block p {
  font-size: 14px;
  line-height: 1.9;
  color: var(--fg-muted);
}

/* ==========================================
   CAREER Timeline
   ========================================== */
.timeline {
  display: flex;
  flex-direction: column;
}

.timeline-item {
  display: flex;
  gap: 24px;
}

.timeline-track {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--fg-muted);
  margin-top: 6px;
  flex-shrink: 0;
}

.timeline-dot.active { background: var(--primary); }

.timeline-line {
  width: 1px;
  flex: 1;
  background: var(--border);
  margin-top: 8px;
}

.timeline-content { padding-bottom: 32px; }

.timeline-item:last-child .timeline-content { padding-bottom: 0; }

.timeline-year {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.timeline-year.active { color: var(--primary); }

.timeline-desc {
  font-size: 14px;
  line-height: 1.8;
  margin-top: 8px;
}

/* ==========================================
   WORK STYLE
   ========================================== */
.workstyle-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.workstyle-card {
  padding: 16px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.workstyle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.workstyle-label .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.workstyle-label span {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.workstyle-body .title {
  font-size: 14px;
  margin-bottom: 4px;
}

.workstyle-body p {
  font-size: 12px;
  line-height: 1.8;
  color: var(--fg-muted);
}

/* ==========================================
   SERVICES
   ========================================== */
.service-blocks {
  display: flex;
  flex-direction: column;
}

.service-block {
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
}

.service-block:first-child { padding-top: 0; }
.service-block:last-child { border-bottom: none; padding-bottom: 0; }

.service-block-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.service-block-header .svc-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 4px;
}

.service-block-header h3 {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
}

.svc-body {
  padding-left: 32px;
}

.svc-body p {
  font-size: 13px;
  line-height: 1.9;
  color: var(--fg-muted);
  margin-bottom: 16px;
}

.svc-body p:last-child { margin-bottom: 0; }

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

.service-tag {
  padding: 4px 10px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Basis / rationale block */
.basis-block {
  padding: 24px;
  border: 1px solid var(--primary);
  background: rgba(80, 180, 120, 0.04);
}

.basis-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.basis-label .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.basis-block p {
  font-size: 13px;
  line-height: 1.9;
  color: var(--fg-muted);
}

/* ==========================================
   WORKS
   ========================================== */
.works-categories {
  display: flex;
  flex-direction: column;
  gap: 64px;
}

.works-cat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.works-cat-header .cat-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--primary);
}

.works-cat-header .cat-name {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg);
  font-weight: 400;
}

.works-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 480px) {
  .works-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .works-grid { grid-template-columns: repeat(3, 1fr); }
}

.work-card {
  border: 1px solid var(--border);
  background: var(--bg-card);
  overflow: hidden;
}

.work-card-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.work-card-body {
  padding: 16px;
}

.work-card-body .work-title {
  font-size: 13px;
  font-weight: 400;
  margin-bottom: 8px;
}

.work-card-body p {
  font-size: 11px;
  color: var(--fg-muted);
  line-height: 1.8;
}

/* Photo grid */
.photo-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 640px) {
  .photo-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 960px) {
  .photo-grid { grid-template-columns: repeat(4, 1fr); }
}

.photo-card {
  border: 1px solid var(--border);
  background: var(--bg-card);
  overflow: hidden;
}

.photo-card-thumb {
  width: 100%;
  aspect-ratio: 3 / 4;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Video grid */
.video-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .video-grid { grid-template-columns: repeat(2, 1fr); }
}

.video-wrap {
  border: 1px solid var(--border);
  background: var(--bg-card);
  overflow: hidden;
}

.video-embed {
  position: relative;
  padding-top: 56.25%;
  background: #111;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.video-info {
  padding: 16px;
}

.video-info .video-title {
  font-size: 13px;
  margin-bottom: 4px;
}

.video-info p {
  font-size: 11px;
  color: var(--fg-muted);
}

/* ==========================================
   VOICE
   ========================================== */
.voice-stats {
  display: flex;
  margin-bottom: 48px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  flex-wrap: wrap;
}

.voice-stat {
  flex: 1;
  min-width: 120px;
  padding: 24px;
  border-right: 1px solid var(--border);
}

.voice-stat:last-child { border-right: none; }

@media (max-width: 479px) {
  .voice-stat { border-right: none; border-bottom: 1px solid var(--border); }
  .voice-stat:last-child { border-bottom: none; }
}

.voice-stat .stat-num {
  font-family: var(--font-mono);
  font-size: 28px;
  color: var(--primary);
  line-height: 1.2;
}

.voice-stat .stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 6px;
}

.voice-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .voice-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .voice-grid { grid-template-columns: repeat(3, 1fr); }
}

.voice-card {
  padding: 24px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  display: flex;
  flex-direction: column;
}

.voice-quote-mark {
  font-family: Georgia, serif;
  font-size: 32px;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 12px;
}

.voice-card .voice-text {
  font-size: 13px;
  line-height: 1.9;
  color: var(--fg);
  flex: 1;
  margin-bottom: 20px;
}

.voice-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.voice-meta .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.voice-meta .meta-text {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ==========================================
   CONTACT
   ========================================== */
.contact-box {
  padding: 24px 32px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  margin-bottom: 40px;
}

.contact-box p {
  font-size: 14px;
  color: var(--fg-muted);
  margin-bottom: 24px;
}

.contact-email {
  display: flex;
  align-items: center;
  gap: 12px;
}

.contact-email .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.contact-email a { font-size: 16px; }

.form-section-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.form-section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.contact-form-wrap {
  width: 100%;
}

.contact-form-wrap iframe {
  width: 100%;
  min-height: 640px;
  border: 1px solid var(--border);
  display: block;
  background: transparent;
  color-scheme: dark;
}

/* ==========================================
   DISABLED NAV LINK
   ========================================== */
.nav-link-disabled {
  pointer-events: none;
  cursor: default;
  opacity: 0.35;
}

.page-nav-card--disabled {
  pointer-events: none;
  cursor: default;
  opacity: 0.4;
  border-color: var(--border) !important;
}

.page-nav-card--disabled .pnc-coming {
  display: inline-block;
  margin-top: 12px;
  padding: 3px 8px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-muted);
}

/* ==========================================
   FOOTER
   ========================================== */
footer {
  padding: 48px var(--px);
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: var(--max-width);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (min-width: 768px) {
  .footer-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-brand .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--fg-muted);
}

.footer-brand span {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.footer-nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-nav a {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-decoration: none;
}

.footer-nav a:hover {
  color: var(--fg);
  text-decoration: none;
  opacity: 1;
}

.footer-copy {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-muted);
}
