/* ===================================================================
 * Henry Imoh — modern theme
 * =================================================================== */

:root {
  --bg: #0a0e1a;
  --bg-alt: #0e1730;
  --card: #131d3633;
  --card-solid: #131d36;
  --border: rgba(120, 150, 215, 0.14);
  --text: #e6eaf2;
  --muted: #8b97af;
  --accent: #5e84e0;
  --accent-2: #8aa8f0;
  --grad: linear-gradient(115deg, #5478d8, #8aa8f0);
  --font-head: "Space Grotesk", sans-serif;
  --font-body: "Inter", sans-serif;
  --radius: 16px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 1.06rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a { color: var(--accent); text-decoration: none; transition: color 0.25s ease; }
a:hover { color: var(--accent-2); }

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

::selection { background: var(--accent); color: #0a0e1a; }

.container { width: min(1140px, 92%); margin-inline: auto; }

section { padding: 6.5rem 0; position: relative; }

/* eyebrow + section headings */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}
.eyebrow::before {
  content: "";
  width: 2.2rem;
  height: 2px;
  background: var(--grad);
  border-radius: 2px;
}
.section-head { max-width: 640px; margin-bottom: 3.5rem; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.7rem); margin-bottom: 0.8rem; }
.section-head p { font-size: 1.1rem; }

/* gradient text helper */
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ===================================================================
 * buttons
 * =================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.9rem 2rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
  background: transparent;
}
.btn:hover { transform: translateY(-3px); border-color: var(--accent); color: var(--text); }
.btn-primary {
  background: var(--grad);
  border: none;
  color: #0a0e1a;
}
.btn-primary:hover {
  box-shadow: 0 12px 32px rgba(94, 132, 224, 0.35);
  color: #0a0e1a;
}

/* ===================================================================
 * header / nav
 * =================================================================== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background 0.35s ease, border-color 0.35s ease, backdrop-filter 0.35s ease;
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(10, 14, 26, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-color: var(--border);
}
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4.5rem;
}
.brand {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--text);
  letter-spacing: 0.04em;
}
.brand span { color: var(--accent); }
.nav-links {
  display: flex;
  gap: 2.2rem;
  list-style: none;
}
.nav-links a {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--grad);
  border-radius: 2px;
  transition: width 0.3s ease;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 2.4rem;
  height: 2.4rem;
  cursor: pointer;
  position: relative;
  z-index: 110;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: "";
  display: block;
  position: absolute;
  width: 24px;
  height: 2px;
  background: var(--text);
  left: 50%;
  transform: translateX(-50%);
  transition: all 0.3s ease;
}
.nav-toggle span { top: 50%; }
.nav-toggle span::before { top: -8px; }
.nav-toggle span::after { top: 8px; }
body.nav-open .nav-toggle span { background: transparent; }
body.nav-open .nav-toggle span::before { top: 0; transform: translateX(-50%) rotate(45deg); }
body.nav-open .nav-toggle span::after { top: 0; transform: translateX(-50%) rotate(-45deg); }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    inset: 0;
    background: rgba(10, 14, 26, 0.96);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    font-size: 1.3rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }
  body.nav-open .nav-links { opacity: 1; pointer-events: auto; }
  .nav-links a { font-size: 1.25rem; }
}

/* ===================================================================
 * hero
 * =================================================================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  text-align: center;
  padding: 7rem 0 4rem;
  overflow: hidden;
  background: radial-gradient(ellipse at 50% 30%, #15233f 0%, var(--bg) 70%);
}
/* WebGL molten-light canvas */
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
}
/* scrim: darkens for legibility + faint tech grid + bottom fade */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(to bottom, transparent 68%, var(--bg)),
    linear-gradient(rgba(210, 222, 240, 0.03) 1px, transparent 1px) 0 0 / 100% 66px,
    linear-gradient(90deg, rgba(210, 222, 240, 0.03) 1px, transparent 1px) 0 0 / 66px 100%,
    radial-gradient(ellipse at 50% 46%, rgba(10, 14, 26, 0.28) 0%, rgba(10, 14, 26, 0.55) 80%);
}

.hero-inner { position: relative; z-index: 2; width: 100%; }
.hero-inner > * { animation: heroUp 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; }
.hero-inner > *:nth-child(2) { animation-delay: 0.1s; }
.hero-inner > *:nth-child(3) { animation-delay: 0.2s; }
.hero-inner > *:nth-child(4) { animation-delay: 0.3s; }
.hero-inner > *:nth-child(5) { animation-delay: 0.4s; }
@keyframes heroUp {
  from { opacity: 0; transform: translateY(28px); }
  to { opacity: 1; transform: none; }
}

.hero-greeting {
  font-family: var(--font-head);
  color: var(--accent-2);
  font-size: clamp(1rem, 2.2vw, 1.35rem);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  min-height: 2rem;
}
.hero-greeting .cursor { animation: blink 0.9s step-end infinite; color: var(--accent); }
@keyframes blink { 50% { opacity: 0; } }

.hero h1 {
  font-size: clamp(3.4rem, 12vw, 8.5rem);
  font-weight: 700;
  margin: 0.4rem 0 0.6rem;
  letter-spacing: -0.03em;
  line-height: 0.95;
}
.hero h1 .grad-text {
  filter: drop-shadow(0 6px 40px rgba(94, 132, 224, 0.45));
}
.hero-tagline {
  max-width: 540px;
  margin: 0 auto 2rem;
  font-size: clamp(1rem, 2vw, 1.18rem);
  color: var(--text);
  opacity: 0.85;
}
.hero-roles {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.4rem 0.9rem;
  margin-bottom: 2.4rem;
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero-roles span { color: var(--text); }
.hero-roles .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.hero-cta { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }

/* vertical social rail */
.hero-social {
  position: absolute;
  left: 2.4rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  z-index: 3;
  list-style: none;
}
.hero-social::after {
  content: "";
  width: 1px;
  height: 5rem;
  margin: 0.4rem auto 0;
  background: linear-gradient(var(--border), transparent);
}
.hero-social a, .footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--muted);
  background: rgba(10, 14, 26, 0.4);
  backdrop-filter: blur(4px);
  transition: all 0.25s ease;
}
.hero-social a:hover, .footer-social a:hover {
  color: var(--text);
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(94, 132, 224, 0.3);
}
.icon { width: 1.1rem; height: 1.1rem; fill: currentColor; }

/* scroll cue */
.hero-scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-head);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero-scroll span {
  width: 24px;
  height: 38px;
  border: 2px solid var(--border);
  border-radius: 999px;
  position: relative;
}
.hero-scroll span::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 7px;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  border-radius: 999px;
  background: var(--accent);
  animation: scrollDot 1.6s ease-in-out infinite;
}
.hero-scroll:hover { color: var(--text); }
@keyframes scrollDot {
  0% { opacity: 0; transform: translateY(0); }
  35% { opacity: 1; }
  70% { opacity: 0; transform: translateY(12px); }
  100% { opacity: 0; }
}

@media (max-width: 820px) {
  .hero-social {
    flex-direction: row;
    left: 0;
    right: 0;
    top: auto;
    bottom: 4.5rem;
    transform: none;
    justify-content: center;
  }
  .hero-social::after { display: none; }
  .hero-scroll { display: none; }
}

/* ===================================================================
 * about
 * =================================================================== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
.about-card {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.2rem;
  position: relative;
  overflow: hidden;
}
.about-card::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -30%;
  width: 70%;
  height: 80%;
  background: radial-gradient(circle, rgba(94, 132, 224, 0.16), transparent 70%);
  pointer-events: none;
}
.about-intro { display: flex; gap: 1.4rem; align-items: center; margin-bottom: 1.6rem; }
.avatar { position: relative; width: 104px; height: 104px; flex-shrink: 0; }
.avatar::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, var(--accent), var(--accent-2), var(--accent));
  animation: spin 6s linear infinite;
}
.avatar img {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--card-solid);
}
@keyframes spin { to { transform: rotate(360deg); } }
.about-intro h3 { font-size: 1.4rem; margin-bottom: 0.2rem; }
.about-intro p { font-size: 0.92rem; color: var(--accent); font-family: var(--font-head); letter-spacing: 0.04em; }

.info-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
  margin-top: 2rem;
}
.info-list li {
  background: rgba(210, 222, 240, 0.025);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.9rem 1rem;
}
.info-list li:last-child { grid-column: 1 / -1; }
.info-list strong {
  display: block;
  font-family: var(--font-head);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.2rem;
}
.info-list span { color: var(--text); font-size: 0.95rem; }

/* tech marquee */
.tech-marquee {
  margin: 4.5rem 0 0;
  padding: 1.3rem 0;
  border-block: 1px solid var(--border);
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.tech-track {
  display: flex;
  gap: 3.2rem;
  width: max-content;
  animation: marquee 30s linear infinite;
}
.tech-marquee:hover .tech-track { animation-play-state: paused; }
.tech-track span {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.25s ease;
}
.tech-track span:hover { color: var(--accent); }
@keyframes marquee { to { transform: translateX(-50%); } }

.skills { list-style: none; display: grid; gap: 1.6rem; }
.skills li { font-size: 0.92rem; }
.skill-top {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.skill-top em { font-style: normal; color: var(--accent); }
.bar {
  height: 7px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 999px;
  overflow: hidden;
}
.bar i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: var(--grad);
  transition: width 1.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.about-cta { margin-top: 3.5rem; display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }

/* collapsible skills */
.skills .more-skill { display: none; }
.skills.show-all .more-skill { display: block; }
.skills-toggle {
  margin-top: 1.8rem;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  padding: 0.65rem 1.5rem;
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.25s ease, color 0.25s ease;
}
.skills-toggle::after {
  content: "↓";
  font-size: 0.9rem;
  transition: transform 0.3s ease;
}
.skills.show-all ~ .skills-toggle::after { transform: rotate(180deg); }
.skills-toggle:hover { border-color: var(--accent); color: var(--accent); }

/* ===================================================================
 * timeline (resume)
 * =================================================================== */
.timeline { position: relative; max-width: 800px; margin-inline: auto; }
.timeline::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent), var(--accent-2), transparent);
  opacity: 0.4;
}
.timeline-item { position: relative; padding: 0 0 2.8rem 3rem; }
.timeline-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
  box-shadow: 0 0 14px rgba(94, 132, 224, 0.5);
}
.timeline-item h3 { font-size: 1.25rem; }
.timeline-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
  align-items: baseline;
  margin: 0.2rem 0 0.9rem;
}
.timeline-meta strong { color: var(--accent); font-family: var(--font-head); font-weight: 600; }
.timeline-meta time { font-size: 0.85rem; letter-spacing: 0.05em; }
.timeline-item ul { list-style: none; display: grid; gap: 0.5rem; }
.timeline-item ul li { padding-left: 1.2rem; position: relative; font-size: 0.97rem; }
.timeline-item ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--grad);
}
.resume-block + .resume-block { margin-top: 4.5rem; }
.resume-block > h2 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 2.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ===================================================================
 * services
 * =================================================================== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}
.service-card {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.2rem 1.8rem;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}
.service-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--grad);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}
.service-card:hover { transform: translateY(-8px); border-color: rgba(94, 132, 224, 0.4); box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4); }
.service-card:hover::before { transform: scaleX(1); }
.service-card .glyph {
  font-size: 1.6rem;
  width: 3.4rem;
  height: 3.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(94, 132, 224, 0.12);
  margin-bottom: 1.4rem;
}
.service-card h3 { font-size: 1.2rem; margin-bottom: 0.7rem; }
.service-card p { font-size: 0.95rem; }

/* ===================================================================
 * stats
 * =================================================================== */
.stats-band {
  border-block: 1px solid var(--border);
  background: var(--bg-alt);
  padding: 4rem 0;
}
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 2rem;
  text-align: center;
}
.stat strong {
  display: block;
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat span {
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* ===================================================================
 * portfolio cards
 * =================================================================== */
.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
  margin-bottom: 3rem;
}
.filters button {
  font-family: var(--font-head);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.5rem 1.4rem;
  cursor: pointer;
  transition: all 0.25s ease;
}
.filters button:hover { color: var(--text); border-color: var(--accent); }
.filters button.active {
  background: var(--grad);
  border-color: transparent;
  color: #0a0e1a;
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.6rem;
}
.work-card {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}
.work-card.hidden { display: none; }
.work-card:hover {
  transform: translateY(-8px);
  border-color: rgba(94, 132, 224, 0.45);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45);
}
.work-thumb { aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-alt); }
.work-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.work-card:hover .work-thumb img { transform: scale(1.07); }
.work-body { padding: 1.3rem 1.4rem 1.5rem; }
.work-body h3 { font-size: 1.08rem; margin-bottom: 0.35rem; }
.work-tag {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ===================================================================
 * modal / lightbox
 * =================================================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal.open { opacity: 1; pointer-events: auto; }
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(6, 9, 18, 0.88);
  backdrop-filter: blur(8px);
}
.modal-card {
  position: relative;
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-width: 680px;
  width: 100%;
  max-height: 90svh;
  overflow-y: auto;
  transform: translateY(24px) scale(0.97);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.modal.open .modal-card { transform: none; }
.modal-card img { width: 100%; }
.modal-body { padding: 1.8rem; }
.modal-body h3 { font-size: 1.35rem; margin-bottom: 0.7rem; }
.modal-cat {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 1rem 0 1.4rem;
}
.modal-close {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: none;
  background: rgba(10, 14, 26, 0.7);
  color: var(--text);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition: background 0.25s ease;
}
.modal-close:hover { background: var(--accent); color: #0a0e1a; }

/* ===================================================================
 * gallery (photography)
 * =================================================================== */
.gallery-grid {
  columns: 3 300px;
  column-gap: 1.4rem;
}
.gallery-item {
  break-inside: avoid;
  margin-bottom: 1.4rem;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  border: 1px solid var(--border);
}
.gallery-item img { transition: transform 0.6s ease; width: 100%; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 2.4rem 1.2rem 1rem;
  background: linear-gradient(transparent, rgba(6, 9, 18, 0.92));
  color: var(--text);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.35s ease;
}
.gallery-item:hover figcaption { opacity: 1; transform: none; }

/* ===================================================================
 * contact
 * =================================================================== */
.contact-wrap { max-width: 720px; margin-inline: auto; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.form-grid .full { grid-column: 1 / -1; }
.contact-wrap input, .contact-wrap textarea {
  width: 100%;
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.2rem;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.97rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.contact-wrap input:focus, .contact-wrap textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(94, 132, 224, 0.15);
}
.contact-wrap textarea { min-height: 11rem; resize: vertical; }
.contact-wrap .btn { margin-top: 1.4rem; }

.contact-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.4rem;
  margin-top: 4rem;
  text-align: center;
}
.contact-info > div {
  background: var(--card-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.8rem 1.4rem;
}
.contact-info h4 {
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}
.contact-info p, .contact-info a { font-size: 0.95rem; color: var(--muted); display: block; }
.contact-info a:hover { color: var(--text); }

/* ===================================================================
 * footer
 * =================================================================== */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.8rem 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.footer-social { display: flex; gap: 0.9rem; list-style: none; }
.site-footer p { font-size: 0.88rem; }

#to-top {
  position: fixed;
  right: 1.6rem;
  bottom: 1.6rem;
  width: 2.9rem;
  height: 2.9rem;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--card-solid);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 90;
}
#to-top.show { opacity: 1; pointer-events: auto; }
#to-top:hover { border-color: var(--accent); transform: translateY(-3px); }

/* ===================================================================
 * page hero (subpages)
 * =================================================================== */
.page-hero {
  padding: 10rem 0 4rem;
  text-align: center;
  overflow: hidden;
  position: relative;
  background: radial-gradient(ellipse at 50% -10%, rgba(94, 132, 224, 0.18), transparent 55%), var(--bg);
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(210, 222, 240, 0.025) 1px, transparent 1px) 0 0 / 100% 60px,
    linear-gradient(90deg, rgba(210, 222, 240, 0.025) 1px, transparent 1px) 0 0 / 60px 100%;
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000, transparent 70%);
  mask-image: radial-gradient(ellipse at 50% 0%, #000, transparent 70%);
}
.page-hero > * { position: relative; z-index: 1; }
.page-hero h1 { font-size: clamp(2.4rem, 6vw, 4rem); margin-bottom: 1rem; }
.page-hero p { max-width: 560px; margin-inline: auto; font-size: 1.1rem; }

/* ===================================================================
 * reveal animations
 * =================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--d, 0s);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

/* ===================================================================
 * responsive
 * =================================================================== */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 3rem; }
}
@media (max-width: 600px) {
  section { padding: 4.5rem 0; }
  .form-grid { grid-template-columns: 1fr; }
  .about-intro { flex-direction: column; align-items: center; text-align: center; }
  .info-list { grid-template-columns: 1fr; }
  .info-list li:last-child { grid-column: auto; }
  .footer-inner { justify-content: center; text-align: center; }
}
