/* ============================================
   style.css — Particle Physics Researcher Site
   TODO: カラーやフォントは好みに合わせて調整
   ============================================ */

/* --- Google Fonts (Inter + EB Garamond) --- */
@import url('https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400;0,600;1,400&family=Inter:wght@300;400;500;600&display=swap');

/* ─── CSS Variables ─────────────────────── */
:root {
  --bg-primary:    #f0f4ff;
  --bg-secondary:  #e6ecf8;
  --bg-card:       #ffffff;
  --bg-card-hover: #f5f8ff;
  --border:        #c8d4ee;

  --cyan:    #0066cc;
  --cyan-dim: #004fa3;
  --gold:    #b07800;
  --accent:  var(--cyan);

  --text-primary:   #0d1a3a;
  --text-secondary: #3a4a6b;
  --text-muted:     #7a8aaa;

  --font-serif:  'EB Garamond', Georgia, serif;
  --font-sans:   'Inter', system-ui, sans-serif;

  --radius:  8px;
  --radius-lg: 16px;
  --shadow:  0 4px 24px rgba(0, 30, 80, 0.12);
  --shadow-card: 0 2px 12px rgba(0, 102, 204, 0.1);

  --nav-height: 64px;
  --max-width:  1100px;
}

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

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

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--cyan-dim); }

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.25;
  color: var(--text-primary);
}

ul { list-style: none; }

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

.section { padding: 80px 0; }

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 8px;
  color: var(--text-primary);
}

.section-title span { color: var(--accent); }

.section-subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 48px;
}

.divider {
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  margin: 16px 0 40px;
  border-radius: 2px;
}

/* ─── Navigation ────────────────────────── */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: rgba(240, 244, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  display: flex;
  align-items: center;
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.5px;
}

.nav-logo:hover { color: var(--accent); }

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  letter-spacing: 0.3px;
  position: relative;
  transition: color 0.2s;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  transform: scaleX(1);
}

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

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: all 0.3s;
}

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

/* Mobile nav */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0; right: 0;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  padding: 24px;
  flex-direction: column;
  gap: 20px;
  z-index: 99;
}

.nav-mobile.open { display: flex; }
.nav-mobile a { font-size: 1rem; color: var(--text-secondary); font-weight: 500; }
.nav-mobile a:hover, .nav-mobile a.active { color: var(--accent); }

/* ─── Page wrapper ───────────────────────── */
.page-content {
  padding-top: var(--nav-height);
  min-height: 100vh;
}

/* ─── Hero (index) ──────────────────────── */
.hero {
  min-height: calc(100vh - var(--nav-height));
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

/* Background decoration */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 70% 40%, rgba(0, 102, 204, 0.07) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 20% 70%, rgba(176, 120, 0, 0.05) 0%, transparent 60%);
  pointer-events: none;
}

/* Dot grid */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(0,60,150,0.08) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 0%, transparent 100%);
}

.hero-content { position: relative; z-index: 2; }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--accent);
}

.hero-name {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 1.1;
  margin-bottom: 12px;
  background: linear-gradient(135deg, #0d1a3a 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-affiliation {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  font-family: var(--font-sans);
  font-weight: 300;
}

.hero-affiliation strong { color: var(--text-primary); font-weight: 500; }

.hero-tagline {
  font-family: var(--font-serif);
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-style: italic;
  color: var(--text-secondary);
  max-width: 560px;
  margin-bottom: 40px;
  line-height: 1.5;
}

.hero-tagline em { color: var(--gold); font-style: normal; }

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ─── Buttons ────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  font-family: var(--font-sans);
  transition: all 0.25s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--cyan-dim);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 102, 204, 0.3);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
}

.btn-gold {
  background: var(--gold);
  color: var(--bg-primary);
}

.btn-gold:hover {
  background: #d4a820;
  color: var(--bg-primary);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(240, 192, 64, 0.3);
}

/* ─── Cards ─────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.25s;
  box-shadow: var(--shadow-card);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(0, 102, 204, 0.3);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0, 102, 204, 0.12);
}

/* ─── Grid layouts ──────────────────────── */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

/* ─── Highlight cards (index) ──────────── */
.highlight-card .card-tag {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.highlight-card .card-title {
  font-size: 1.05rem;
  margin-bottom: 10px;
  font-family: var(--font-serif);
  font-size: 1.15rem;
}

.highlight-card .card-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 16px;
}

.highlight-card .card-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ─── Page header banner ────────────────── */
.page-banner {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  border-bottom: 1px solid var(--border);
  padding: 64px 0 48px;
  position: relative;
  overflow: hidden;
}

.page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 50% 80% at 90% 50%, rgba(0, 102, 204, 0.05) 0%, transparent 70%);
}

.page-banner-inner { position: relative; z-index: 2; }

.page-banner-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.page-banner h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  margin-bottom: 12px;
}

.page-banner p {
  color: var(--text-secondary);
  max-width: 540px;
  font-size: 1rem;
}

/* ─── Research page ─────────────────────── */
.research-theme {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-bottom: 64px;
}

.theme-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: all 0.25s;
}

.theme-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.theme-card:hover {
  border-color: rgba(0, 102, 204, 0.3);
  transform: translateY(-2px);
}

.theme-card .theme-number {
  font-size: 3rem;
  font-family: var(--font-serif);
  color: rgba(0, 102, 204, 0.12);
  font-weight: 600;
  line-height: 1;
  margin-bottom: 12px;
}

.theme-card h3 {
  font-size: 1.2rem;
  margin-bottom: 12px;
  color: var(--accent);
}

.theme-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Paper list */
.paper-list { display: flex; flex-direction: column; gap: 16px; }

.paper-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  transition: all 0.2s;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: start;
}

.paper-item:hover {
  border-color: rgba(0, 102, 204, 0.3);
  background: var(--bg-card-hover);
}

.paper-year {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  background: rgba(0, 102, 204, 0.1);
  padding: 4px 10px;
  border-radius: 4px;
  white-space: nowrap;
  height: fit-content;
}

.paper-body {}

.paper-title {
  font-family: var(--font-serif);
  font-size: 1rem;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.paper-authors {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.paper-journal {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
}

.paper-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
}

.paper-link {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  white-space: nowrap;
  transition: all 0.2s;
}

.paper-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.paper-link.arxiv { border-color: rgba(0, 102, 204, 0.3); color: var(--accent); }

/* ─── CV page ───────────────────────────── */
.cv-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 48px;
  align-items: start;
}

/* Timeline */
.timeline { position: relative; padding-left: 24px; }

.timeline::before {
  content: '';
  position: absolute;
  left: 0; top: 8px; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}

.timeline-item {
  position: relative;
  padding-bottom: 36px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -28px;
  top: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px rgba(0, 102, 204, 0.35);
}

.timeline-year {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.timeline-title {
  font-size: 1rem;
  font-family: var(--font-serif);
  margin-bottom: 4px;
}

.timeline-place {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* CV Personal Data */
.cv-personal {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.cv-personal-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0;
  border-bottom: 1px solid var(--border);
}

.cv-personal-row:last-child {
  border-bottom: none;
}

.cv-personal-row dt {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  padding: 10px 16px;
  display: flex;
  align-items: center;
}

.cv-personal-row dd {
  font-size: 0.88rem;
  color: var(--text-primary);
  padding: 10px 16px;
  background: var(--bg-card);
  display: flex;
  align-items: center;
  line-height: 1.5;
}

.cv-personal-row dd a {
  color: var(--accent);
}

@media (max-width: 640px) {
  .cv-personal-row {
    grid-template-columns: 1fr;
  }
  .cv-personal-row dt {
    border-bottom: 1px solid var(--border);
    padding-bottom: 6px;
  }
}

/* CV sidebar */
.cv-sidebar-section {
  margin-bottom: 36px;
}

.cv-sidebar-section h3 {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.cv-award-item {
  margin-bottom: 16px;
}

.cv-award-year {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.cv-award-name {
  font-size: 0.9rem;
  color: var(--text-primary);
}

.cv-award-org {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* Talk filter tabs */
.talk-filter {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.talk-filter-btn {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  padding: 6px 18px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: all 0.2s;
}

.talk-filter-btn:hover {
  border-color: rgba(0, 102, 204, 0.4);
  color: var(--accent);
}

.talk-filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* Year filter (All タブ選択時のみ表示) */
.talk-year-filter {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: -10px;
  margin-bottom: 20px;
  padding-left: 4px;
}

.talk-year-filter.hidden { display: none; }

.talk-year-btn {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: all 0.2s;
}

.talk-year-btn:hover {
  border-color: rgba(0, 102, 204, 0.4);
  color: var(--accent);
}

.talk-year-btn.active {
  background: rgba(0, 102, 204, 0.1);
  border-color: rgba(0, 102, 204, 0.4);
  color: var(--accent);
  font-weight: 600;
}

/* Talk list */
.talk-list { display: flex; flex-direction: column; gap: 12px; }

.talk-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  border-left: 3px solid var(--border);
  transition: border-color 0.2s;
}

.talk-item[data-category~="seminar"]    { border-left-color: var(--accent); }
.talk-item[data-category~="invited"]   { border-left-color: var(--gold); }
.talk-item[data-category~="short-talk"] { border-left-color: #0a9e6b; }
.talk-item[data-category~="poster"]    { border-left-color: #8b68e8; }

.talk-item[data-hidden="true"] { display: none; }

.talk-title {
  font-size: 0.9rem;
  margin-bottom: 6px;
}

.talk-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* カテゴリバッジ */
.talk-badge {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
}

.talk-badge--seminar {
  background: rgba(0, 102, 204, 0.1);
  color: var(--accent);
  border: 1px solid rgba(0, 102, 204, 0.25);
}

.talk-badge--short-talk {
  background: rgba(10, 158, 107, 0.1);
  color: #0a9e6b;
  border: 1px solid rgba(10, 158, 107, 0.3);
}

.talk-badge--poster {
  background: rgba(139, 104, 232, 0.1);
  color: #8b68e8;
  border: 1px solid rgba(139, 104, 232, 0.3);
}

.talk-badge--invited {
  background: rgba(176, 120, 0, 0.1);
  color: var(--gold);
  border: 1px solid rgba(176, 120, 0, 0.35);
}

/* ─── Blog page ─────────────────────────── */
.blog-grid { display: flex; flex-direction: column; gap: 24px; }

.blog-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  transition: all 0.25s;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: start;
}

.blog-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(0, 102, 204, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0, 102, 204, 0.1);
}

.blog-card-left {}

.blog-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.blog-tag {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.8px;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(0, 102, 204, 0.08);
  border: 1px solid rgba(0, 102, 204, 0.2);
  color: var(--accent);
}

.blog-tag.tag-cosmology { background: rgba(176, 120, 0, 0.08); border-color: rgba(176, 120, 0, 0.3); color: var(--gold); }
.blog-tag.tag-numerical { background: rgba(100, 60, 200, 0.08); border-color: rgba(100, 60, 200, 0.3); color: #6040c0; }
.blog-tag.tag-theory    { background: rgba(0, 102, 204, 0.08);  border-color: rgba(0, 102, 204, 0.25);  color: var(--accent); }

.blog-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin-bottom: 10px;
  transition: color 0.2s;
}

.blog-card:hover .blog-title { color: var(--accent); }

.blog-excerpt {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.blog-card-right {
  text-align: right;
  min-width: 100px;
}

.blog-date {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.blog-read-time {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ─── Footer ────────────────────────────── */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
  margin-top: 80px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: start;
  margin-bottom: 32px;
}

.footer-name {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin-bottom: 6px;
}

.footer-affiliation {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.footer-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.footer-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.2s;
}

.footer-link:hover {
  color: var(--accent);
  border-color: rgba(0, 102, 204, 0.4);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ─── Utilities ─────────────────────────── */
.text-accent   { color: var(--accent); }
.text-gold     { color: var(--gold); }
.text-muted    { color: var(--text-muted); }
.text-secondary{ color: var(--text-secondary); }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-32 { margin-top: 32px; }
.mb-8  { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-32 { margin-bottom: 32px; }

/* ─── Banner / Hero photo ───────────────── */
/*
 * 使い方: <section class="hero"> または <div class="page-banner"> の
 * 直下の子として <div class="banner-photo" style="background-image:url('YOUR_PHOTO.jpg')"></div>
 * を追加してください。画像がなければ単に空白になります。
 */
.banner-photo {
  position: absolute;
  inset: 0;           /* 全面背景として使用 */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
}

/* 半透明ティント + ブラーで文字を読みやすくする */
.banner-photo::after {
  content: '';
  position: absolute;
  inset: 0;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 1;
}

.hero .banner-photo::after {
  background: rgba(240, 244, 255, 0.55);
}

.page-banner .banner-photo::after {
  background: rgba(230, 236, 248, 0.55);
}

/* 左配置バリアント */
.banner-photo--left {
  left: 0;
  right: auto;
  width: 70%;  /* 写真 70% : テキスト 30% */
}

.hero .banner-photo--left::after {
  background: linear-gradient(
    to left,
    #f0f4ff 0%,
    rgba(240, 244, 255, 0.97) 28%,
    rgba(240, 244, 255, 0.65) 52%,
    transparent 78%
  );
}

.page-banner .banner-photo--left::after {
  background: linear-gradient(
    to left,
    #e6ecf8 0%,
    rgba(230, 236, 248, 0.97) 28%,
    rgba(230, 236, 248, 0.65) 52%,
    transparent 78%
  );
}

/* 写真が左にある場合、テキストを右30%に寄せる */
.hero--photo-left .hero-content {
  margin-left: auto;
  max-width: 30%;
}

.page-banner--photo-left .page-banner-inner {
  margin-left: auto;
  max-width: 30%;
}

/* モバイル：写真を表示しつつ、オーバーレイを少し濃くして文字を読みやすくする */
@media (max-width: 640px) {
  .hero .banner-photo::after {
    background: rgba(240, 244, 255, 0.68);
  }
  .page-banner .banner-photo::after {
    background: rgba(230, 236, 248, 0.68);
  }
  .hero--photo-left .hero-content { max-width: 100%; margin-left: 0; }
  .page-banner--photo-left .page-banner-inner { max-width: 100%; margin-left: 0; }
}

/* ─── MathJax overrides ─────────────────── */
.MathJax { color: var(--text-primary) !important; }

/* ─── Responsive ────────────────────────── */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .research-theme { grid-template-columns: 1fr; }
  .cv-layout { grid-template-columns: 1fr; }
  .paper-item { grid-template-columns: 1fr; }
  .paper-links { flex-direction: row; align-items: flex-start; }
}

@media (max-width: 640px) {
  :root { --nav-height: 56px; }
  .section { padding: 56px 0; }
  .container { padding: 0 16px; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .hero { min-height: calc(100svh - var(--nav-height)); }
  .hero-cta { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
  .blog-card { grid-template-columns: 1fr; }
  .blog-card-right { text-align: left; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-links { flex-wrap: wrap; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .page-banner { padding: 48px 0 36px; }
}
