/* ==========================================================================
   pages.css — shared building blocks for the inner pages
   (about / projects / skills / contact). Page-specific tweaks live in each
   page's own stylesheet.
   ========================================================================== */

/* Re-skin legacy full-viewport snap sections used across inner pages */
.snap-section { min-height: 0; }
section[id] { scroll-margin-top: calc(var(--nav-h) + 30px); }

/* ---- Page hero (compact) ---------------------------------------------- */
.page-hero { padding: clamp(24px, 4vw, 40px) var(--gutter) 0; }
.page-hero__panel {
  position: relative;
  max-width: var(--maxw);
  margin-inline: auto;
  border-radius: var(--r-lg);
  background: var(--hero-grad);
  color: var(--on-dark);
  padding: clamp(30px, 5vw, 64px);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  isolation: isolate;
}
.page-hero__panel::before {
  content: "";
  position: absolute;
  width: 55%; height: 120%;
  right: -8%; top: -30%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 62%);
  z-index: -1;
}
.page-hero__eyebrow { color: var(--cyan-400); }
.page-hero h1,
.page-hero__title {
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  text-transform: uppercase;
  color: var(--on-dark);
  margin: 14px 0 18px;
}
.page-hero__lead { font-size: var(--fs-lead); color: var(--on-dark-muted); max-width: 54ch; }

/* Reusable blue panel */
.panel-blue {
  background: var(--hero-grad-soft);
  color: var(--on-dark);
  border-radius: var(--r-lg);
  padding: clamp(26px, 4vw, 52px);
  box-shadow: var(--shadow-lg);
}

/* ---- Fact cards -------------------------------------------------------- */
.fact-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
}
.fact-card {
  background: var(--surface);
  border: 1px solid var(--card-border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fact-card__label {
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.fact-card__value { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; color: var(--text); }
.fact-card__value.accent { color: var(--blue-700); }

/* ---- Horizontal progress bars (hobbies / skills) ---------------------- */
.hbar { margin-bottom: 18px; }
.hbar__top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}
.hbar__name { font-weight: 600; color: var(--text); }
.hbar__val {
  font-family: var(--font-label);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--blue-700);
}
.hbar__track {
  height: 12px;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  border: 1px solid var(--card-border);
  overflow: hidden;
}
.hbar__fill {
  height: 100%;
  border-radius: var(--r-pill);
  background: var(--cta-grad);
  width: 0;
  transition: width 1s cubic-bezier(0.22, 1, 0.36, 1);
}
.hbar.is-visible .hbar__fill,
.reveal.is-visible .hbar__fill { width: var(--val, 0%); }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .hbar__fill { width: var(--val, 0%); }
  }
}

/* ---- Generic surface card grid ---------------------------------------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.s-card {
  background: var(--surface);
  border: 1px solid var(--card-border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  padding: 26px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.s-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.s-card__icon {
  width: 46px; height: 46px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--sky-100);
  font-size: 1.4rem;
  margin-bottom: 14px;
}
:root[data-theme="dark"] .s-card__icon { background: var(--surface-2); }
.s-card h3 { margin-bottom: 10px; font-size: 1.2rem; }
.s-card p { color: var(--text-muted); }

/* ---- Fact / fun list chips -------------------------------------------- */
.chip-list { display: flex; flex-wrap: wrap; gap: 12px; }
.chip-list li {
  background: var(--surface);
  border: 1px solid var(--card-border);
  border-radius: var(--r-pill);
  padding: 10px 18px;
  box-shadow: var(--shadow-sm);
  color: var(--text);
  font-size: 0.95rem;
}

/* ---- Contact ---------------------------------------------------------- */
.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.75fr);
  gap: clamp(20px, 3vw, 36px);
  align-items: start;
}
.contact-methods { display: flex; flex-direction: column; gap: 14px; }
.method-card {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 14px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--card-border);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  padding: 18px 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.method-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--blue-500); }
.method-card__icon {
  grid-row: 1 / 3;
  width: 46px; height: 46px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--sky-100);
  font-size: 1.3rem;
}
:root[data-theme="dark"] .method-card__icon { background: var(--surface-2); }
.method-card__icon img { width: 24px; height: 24px; }
:root[data-theme="dark"] .method-card__icon img { filter: brightness(0) invert(1); }
.method-card__label {
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.method-card__value { font-weight: 600; color: var(--text); word-break: break-word; }
.method-note {
  background: var(--surface-2);
  border: 1px solid var(--card-border);
  border-radius: var(--r-md);
  padding: 18px 20px;
}
.method-note p { color: var(--text-muted); font-size: 0.92rem; margin-top: 12px; }
@media (max-width: 900px) {
  .contact-layout { grid-template-columns: 1fr; }
}

/* ---- Two-column media/text -------------------------------------------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
}
.split__media img {
  width: 100%;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--card-border);
  object-fit: cover;
}
@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; }
}
