/* V5 — shared portfolio system. This stylesheet is intentionally loaded last
   so Home, About, Research, and UX case-study pages share one visual language. */
:root {
  --site-content-width: min(1240px, calc(100% - 2rem));
  --site-section-space: clamp(4.5rem, 8vw, 7rem);
  --site-card-radius: 24px;
  --site-portrait-radius: 2rem;
  --site-panel-border: rgba(255, 184, 120, 0.22);
  --site-focus: #ffd29d;
}

.page-shell {
  width: var(--site-content-width);
}

.site-header {
  min-height: 5.45rem;
  border-color: rgba(255, 211, 173, 0.16);
  background: linear-gradient(180deg, rgba(8, 22, 38, 0.9), rgba(13, 20, 43, 0.92));
}

.site-nav {
  gap: clamp(0.75rem, 1.55vw, 1.15rem);
}

.site-nav a {
  white-space: nowrap;
}

.site-nav a:focus-visible {
  border-radius: 0.3rem;
}

.section {
  padding-block: var(--site-section-space);
}

.page-detail {
  background:
    radial-gradient(ellipse at 74% 9%, rgba(255, 184, 120, 0.22), transparent 28%),
    radial-gradient(ellipse at 20% 31%, rgba(167, 139, 250, 0.16), transparent 36%),
    linear-gradient(155deg, #081626 0%, #173257 44%, #303052 73%, #101c35 100%);
}

.page-detail::before {
  opacity: 0.3;
  background:
    linear-gradient(180deg, rgba(255, 246, 234, 0.065), transparent 25%),
    linear-gradient(90deg, rgba(255, 210, 157, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(118, 189, 243, 0.04) 1px, transparent 1px);
}

/* Shared PortraitPanel. The identical image treatment applies to Home + About;
   Home alone adds the compact identity nameplate already in its markup. */
.portrait-panel {
  width: min(100%, 32rem);
  overflow: hidden;
  border-color: rgba(255, 184, 120, 0.36);
  border-radius: var(--site-portrait-radius);
  box-shadow:
    0 30px 74px rgba(8, 14, 30, 0.48),
    0 0 82px rgba(255, 184, 120, 0.2),
    0 0 150px rgba(199, 124, 120, 0.11);
}

.portrait-panel::before {
  background:
    radial-gradient(ellipse at 75% 38%, rgba(255, 210, 157, 0.38), transparent 42%),
    linear-gradient(180deg, transparent 45%, rgba(16, 28, 53, 0.36) 100%);
}

.portrait-panel .poster-image,
.portrait-panel > .poster-image {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 52% 34%;
  transform: scale(1.035) translateZ(16px);
}

.portrait-panel:hover .poster-image {
  transform: scale(1.08) translateZ(24px);
}

.page-home .poster-stack {
  padding-top: 0.75rem;
}

.page-home .poster-frame.portrait-panel {
  width: min(100%, 32rem);
}

.page-home .poster-caption {
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  gap: 0.55rem;
  padding: 0.78rem 0.85rem 0.8rem;
  border-radius: 1.12rem;
}

.page-home .poster-caption .poster-tag { font-size: 0.82rem; }
.page-home .gt-badge-poster { gap: 0.65rem; padding: 0.68rem 0.75rem; border-radius: 0.98rem; }
.page-home .gt-badge-poster .gt-wordmark { max-width: 126px; }
.page-home .gt-badge-poster .gt-copy strong { font-size: 0.88rem; line-height: 1.3; }

/* About: one biography, three concise interests, then one method statement. */
.about-hero {
  align-items: center;
  min-height: 0;
  padding-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.about-hero .detail-copy { max-width: 42rem; }
.about-hero .hero-deck { margin-top: 1.15rem; }
.about-hero .hero-support { margin-top: 1rem; }
.about-portrait { justify-self: end; }

.research-interest-section { padding-top: 1.5rem; }

.research-interest-heading {
  display: grid;
  gap: 0.65rem;
  max-width: 42rem;
  margin-bottom: 1.5rem;
}

.research-interest-heading h2,
.approach-card h2 {
  margin: 0;
  font-family: "Bebas Neue", Impact, sans-serif;
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  letter-spacing: 0.045em;
  line-height: 0.95;
}

.research-interest-heading p { margin: 0; color: var(--muted); line-height: 1.65; }

.interest-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.interest-card,
.approach-card {
  border-color: var(--site-panel-border);
  border-radius: var(--site-card-radius);
  background:
    radial-gradient(circle at top right, rgba(255, 184, 120, 0.1), transparent 38%),
    linear-gradient(145deg, rgba(48, 48, 82, 0.7), rgba(16, 28, 53, 0.92));
}

.interest-card { min-height: 15rem; }

.interest-icon {
  display: grid;
  place-items: center;
  width: 2.55rem;
  height: 2.55rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(255, 210, 157, 0.32);
  border-radius: 0.8rem;
  color: var(--yellow);
  background: rgba(255, 184, 120, 0.09);
  font-size: 1.12rem;
  font-weight: 700;
}

.interest-card h3 { margin-bottom: 0.6rem; }
.interest-card p { margin: 0; }

.approach-card {
  display: grid;
  grid-template-columns: minmax(12rem, 0.42fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
  margin-top: 1rem;
}

.approach-card p { margin: 0; color: var(--muted); line-height: 1.75; }

/* Research is a compact archive heading, deliberately unlike the homepage hero. */
.research-hero {
  display: block;
  min-height: 0;
  padding-top: clamp(3.5rem, 6vw, 5.5rem);
  padding-bottom: clamp(2rem, 4vw, 3.5rem);
}

.research-hero .detail-copy { max-width: 52rem; }
.research-hero h1 { margin: 0.65rem 0 1rem; font-size: clamp(3.6rem, 7vw, 6.6rem); }
.research-hero h1 span { white-space: normal; }
.research-hero .hero-deck { max-width: 45rem; margin: 0; }
.research-hero .button { margin-top: 1.4rem; }
.research-page .detail-grid { padding-top: 1.25rem; }

.page-detail .content-card,
.page-detail .timeline-item {
  border-color: var(--site-panel-border);
  border-radius: var(--site-card-radius);
  background:
    radial-gradient(circle at top right, rgba(255, 184, 120, 0.08), transparent 38%),
    linear-gradient(145deg, rgba(48, 48, 82, 0.68), rgba(16, 28, 53, 0.9) 62%);
}

@media (max-width: 1100px) {
  .about-portrait { justify-self: start; }
  .interest-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .site-header { min-height: 0; }
  .site-nav { gap: 0.75rem; overflow-x: auto; justify-content: flex-start; padding-bottom: 0.2rem; }
  .site-nav a { flex: 0 0 auto; }
  .interest-grid,
  .approach-card { grid-template-columns: 1fr; }
  .approach-card { gap: 1rem; }
}

@media (max-width: 640px) {
  .section { padding-block: 4rem; }
  .portrait-panel,
  .page-home .poster-frame.portrait-panel { width: 100%; }
  .page-home .poster-caption { right: 0.8rem; bottom: 0.8rem; left: 0.8rem; padding: 0.7rem; }
  .page-home .gt-badge-poster { padding: 0.62rem 0.68rem; }
  .interest-grid { grid-template-columns: 1fr; }
}
