
/* ── Override app layout for scrollable document ──────────────── */
html,
body {
height: auto;
overflow: auto;
}
body {
display: block;
background: #0d0b08;
}

/* ── Smooth scrolling for anchor links ───────────────────────────── */
html {
  scroll-behavior: smooth;
}
section[id],
h2[id],
h3[id] {
  scroll-margin-top: 64px;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* ── Page shell ───────────────────────────────────────────────── */
.about-header {
position: sticky;
top: 0;
z-index: 100;
background: rgba(13, 11, 8, 0.96);
backdrop-filter: blur(8px);
-webkit-backdrop-filter: blur(8px);
border-bottom: 1px solid var(--border);
padding: 0 24px;
height: 48px;
display: flex;
align-items: center;
gap: 20px;
}

.about-header-title {
font-size: 13px;
font-weight: 600;
color: var(--text-bright);
letter-spacing: 0.06em;
text-transform: uppercase;
text-decoration: none;
white-space: nowrap;
}
.about-header-title:hover {
color: var(--gold);
}

.about-header-sep {
color: var(--border);
font-size: 18px;
font-weight: 300;
line-height: 1;
}

.about-header-page {
font-size: 12px;
color: var(--text-muted);
letter-spacing: 0.06em;
text-transform: uppercase;
}

.about-header-back {
margin-left: auto;
font-size: 11px;
color: var(--text-muted);
text-decoration: none;
letter-spacing: 0.05em;
text-transform: uppercase;
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 4px 10px;
transition:
    color var(--transition),
    border-color var(--transition);
}
.about-header-back:hover {
color: var(--gold);
border-color: var(--gold);
}

/* ── Content wrapper ──────────────────────────────────────────── */
.about-body {
max-width: 780px;
margin: 0 auto;
padding: 0 24px 80px;
}

/* ── Hero ─────────────────────────────────────────────────────── */
.about-hero {
padding: 60px 0 48px;
border-bottom: 1px solid var(--border);
margin-bottom: 56px;
}

.about-hero-label {
font-size: 10px;
letter-spacing: 0.12em;
text-transform: uppercase;
color: var(--text-muted);
margin-bottom: 16px;
}

.about-hero-title {
font-size: 36px;
font-weight: 700;
color: var(--gold);
letter-spacing: 0.04em;
line-height: 1.15;
margin: 0 0 12px;
}

.about-hero-tagline {
font-size: 16px;
color: var(--text);
font-weight: 500;
margin: 0 0 28px;
}

.about-hero-sub-tagline {
  font-size: 14px;
  color: var(--text-muted);
  font-style: italic;
  line-height: 1.5;
  margin: -14px 0 28px;
}

.about-hero-intro {
font-size: 15px;
color: var(--text);
line-height: 1.7;
margin: 0;
max-width: 680px;
}

/* ── Table of Contents ────────────────────────────────────────── */
.page-toc {
  margin: 0 0 56px;
  padding: 0 0 32px;
  border-bottom: 1px solid var(--border);
}
.page-toc p {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 14px;
}
.page-toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── Back to top link styling ─────────────────────────────────── */
.back-to-top {
  /* margin-bottom: 20px; */
  text-align: right;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.back-to-top a {
  color: var(--gold);
  text-decoration: none;
}
.back-to-top a:hover {
  text-decoration: underline;
}

/* ── Section structure ────────────────────────────────────────── */
.about-section {
margin-bottom: 64px;
}

.about-section + .about-section {
padding-top: 0;
}

h2 {
font-size: 11px;
font-weight: 600;
letter-spacing: 0.1em;
text-transform: uppercase;
color: var(--gold);
margin: 0 0 20px;
padding-bottom: 8px;
border-bottom: 1px solid var(--border);
}

h3 {
font-size: 14px;
font-weight: 600;
color: var(--text-bright);
margin: 28px 0 10px;
letter-spacing: 0.02em;
}

p {
font-size: 14px;
color: var(--text);
line-height: 1.75;
margin: 0 0 16px;
}

p:last-child {
margin-bottom: 0;
}

strong {
color: var(--text-bright);
font-weight: 600;
}

a {
color: var(--gold);
text-decoration: none;
}
a:hover {
text-decoration: underline;
}

/* ── Journey table ────────────────────────────────────────────── */
.journey-table {
width: 100%;
border-collapse: collapse;
font-size: 13px;
margin: 20px 0 24px;
}

.journey-table th {
text-align: left;
font-size: 10px;
font-weight: 600;
letter-spacing: 0.08em;
text-transform: uppercase;
color: var(--text-muted);
padding: 0 12px 10px 0;
border-bottom: 1px solid var(--border);
}

.journey-table td {
padding: 10px 12px 10px 0;
color: var(--text);
border-bottom: 1px solid rgba(42, 37, 32, 0.5);
vertical-align: top;
}

.journey-table tr:last-child td {
border-bottom: none;
}

.journey-table td.char-frodo {
color: var(--frodo);
font-weight: 600;
}
.journey-table td.char-aragorn {
color: var(--aragorn);
font-weight: 600;
}
.journey-table td.char-bilbo {
color: var(--bilbo);
font-weight: 600;
}

.journey-table td.num {
color: var(--text-muted);
font-variant-numeric: tabular-nums;
}

/* ── Stat cards ───────────────────────────────────────────────── */
.stat-row {
display: flex;
flex-wrap: wrap;
gap: 12px;
margin: 20px 0 24px;
}

.stat-card {
background: rgba(255, 255, 255, 0.03);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 14px 18px;
flex: 1;
min-width: 120px;
}

.stat-card-value {
font-size: 24px;
font-weight: 700;
color: var(--text-bright);
line-height: 1;
margin-bottom: 4px;
font-variant-numeric: tabular-nums;
}

.stat-card-label {
font-size: 10px;
color: var(--text-muted);
letter-spacing: 0.07em;
text-transform: uppercase;
}

/* ── Data flow diagram ────────────────────────────────────────── */
.data-flow {
background: rgba(255, 255, 255, 0.02);
border: 1px solid var(--border);
border-radius: var(--radius);
padding: 20px 24px;
margin: 20px 0 24px;
font-size: 12px;
font-family: "Consolas", "SF Mono", monospace;
color: var(--text-muted);
line-height: 1.8;
overflow-x: auto;
}

.data-flow .file {
color: var(--frodo);
}
.data-flow .arrow {
color: var(--aragorn);
}
.data-flow .note {
color: var(--text-muted);
font-style: italic;
}
.data-flow .generated {
color: var(--bilbo);
}

/* ── Calendar table ───────────────────────────────────────────── */
.shire-calendar {
width: 100%;
border-collapse: collapse;
font-size: 12px;
margin: 16px 0 20px;
}

.shire-calendar th {
text-align: left;
font-size: 10px;
letter-spacing: 0.06em;
text-transform: uppercase;
color: var(--text-muted);
padding: 0 16px 8px 0;
border-bottom: 1px solid var(--border);
}

.shire-calendar td {
padding: 7px 16px 7px 0;
border-bottom: 1px solid rgba(42, 37, 32, 0.4);
color: var(--text);
font-variant-numeric: tabular-nums;
}

.shire-calendar tr:last-child td {
border-bottom: none;
}
.shire-calendar .special {
color: var(--gold);
}

/* ── Callout box ──────────────────────────────────────────────── */
.callout {
border-left: 3px solid var(--border);
padding: 12px 16px;
margin: 20px 0;
background: rgba(255, 255, 255, 0.02);
border-radius: 0 var(--radius) var(--radius) 0;
}

.callout p {
font-size: 13px;
color: var(--text-muted);
margin: 0;
font-style: italic;
}

.callout.note {
border-left-color: var(--gold);
}
.callout.note p {
color: var(--text);
font-style: normal;
}

/* ── Image figures ────────────────────────────────────────────── */
figure {
margin: 28px 0;
}

figure img {
width: 100%;
height: auto;
display: block;
border-radius: var(--radius);
border: 1px solid var(--border);
}

figcaption {
font-size: 11px;
color: var(--text-muted);
margin-top: 8px;
line-height: 1.5;
font-style: italic;
}

.figure-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
margin: 28px 0;
}

.figure-row figure {
margin: 0;
}

/* ── Certificate gallery ──────────────────────────────────────── */
.cert-row {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 12px;
margin: 24px 0;
}

.cert-item img {
width: 100%;
height: auto;
display: block;
border-radius: var(--radius);
border: 1px solid var(--border);
}

.cert-item figcaption {
font-size: 11px;
color: var(--text-muted);
text-align: center;
margin-top: 6px;
font-style: italic;
}

/* ── Skills progression ───────────────────────────────────────── */
.progression {
display: flex;
flex-direction: column;
gap: 0;
margin: 20px 0 24px;
}

.prog-step {
display: flex;
align-items: flex-start;
gap: 16px;
padding: 12px 0;
border-bottom: 1px solid rgba(42, 37, 32, 0.5);
}

.prog-step:last-child {
border-bottom: none;
}

.prog-label {
font-size: 11px;
font-weight: 600;
letter-spacing: 0.06em;
text-transform: uppercase;
color: var(--gold);
min-width: 160px;
padding-top: 1px;
}

.prog-desc {
font-size: 13px;
color: var(--text-muted);
line-height: 1.6;
}

/* ── Attribution list ─────────────────────────────────────────── */
.attr-list {
display: flex;
flex-direction: column;
gap: 16px;
margin: 20px 0;
}

.attr-item {
display: grid;
grid-template-columns: 160px 1fr;
gap: 12px;
font-size: 13px;
}

.attr-source {
color: var(--text-bright);
font-weight: 600;
padding-top: 1px;
}

.attr-desc {
color: var(--text-muted);
line-height: 1.6;
}

.attr-desc a {
color: var(--gold);
}

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 640px) {
.about-body {
    padding: 0 16px 60px;
}
.about-header {
    gap: 2px;
}
.about-hero {
    padding: 40px 0 36px;
}
.about-hero-title {
    font-size: 26px;
}
.figure-row {
    grid-template-columns: 1fr;
}
.cert-row {
    grid-template-columns: 1fr 1fr;
}
.attr-item {
    grid-template-columns: 1fr;
    gap: 4px;
}
.attr-source {
    font-size: 12px;
}
.prog-label {
    min-width: 130px;
    font-size: 10px;
}
.stat-card-value {
    font-size: 20px;
}
}

/* ── Code styling ─────────────────────────────────────────────── */
.about-body code {
font-family:
    ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", monospace;
font-size: 0.9em;
padding: 0.1em 0.3em;
border-radius: 3px;
background: rgba(255, 255, 255, 0.05);
color: var(--gold);
}

/* ── Technical deep-dive links ───────────────────────────────────── */
.eda-link {
display: flex;
align-items: center;
justify-content: space-between;
gap: 20px;
margin: 24px 0;
padding: 16px 18px;
background: rgba(255, 255, 255, 0.02);
border: 1px solid var(--border);
border-radius: var(--radius);
transition:
    border-color var(--transition),
    background var(--transition);
}
.eda-link:hover {
border-color: rgba(255, 255, 255, 0.18);
background: rgba(255, 255, 255, 0.035);
}
.eda-link-content {
display: flex;
flex-direction: column;
gap: 3px;
min-width: 0;
}
.eda-link-label {
font-size: 9px;
font-weight: 600;
letter-spacing: 0.1em;
text-transform: uppercase;
color: var(--gold);
}
.eda-link-content strong {
font-size: 13px;
font-weight: 600;
color: var(--text-bright);
}
.eda-link-desc {
font-size: 11px;
line-height: 1.5;
color: var(--text-muted);
}
.eda-link-action {
flex-shrink: 0;
font-size: 10px;
font-weight: 600;
letter-spacing: 0.07em;
text-transform: uppercase;
color: var(--gold);
white-space: nowrap;
text-decoration: none;
}
.eda-link-action:hover {
text-decoration: underline;
}
@media (max-width: 640px) {
.eda-link {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
}
}

/* ── Technical deep dives ─────────────────────────────────────────── */
.deep-dive-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 12px;
margin: 20px 0 24px;
}
.deep-dive-card {
display: flex;
flex-direction: column;
min-height: 190px;
padding: 18px;
background: rgba(255, 255, 255, 0.02);
border: 1px solid var(--border);
border-radius: var(--radius);
text-decoration: none;
transition:
    border-color var(--transition),
    background var(--transition),
    transform var(--transition);
}
.deep-dive-card:hover {
text-decoration: none;
border-color: rgba(255, 255, 255, 0.18);
background: rgba(255, 255, 255, 0.035);
transform: translateY(-1px);
}
.deep-dive-number {
font-size: 9px;
font-weight: 600;
letter-spacing: 0.1em;
color: var(--gold);
margin-bottom: 14px;
}
.deep-dive-title {
font-size: 15px;
font-weight: 600;
color: var(--text-bright);
margin-bottom: 8px;
}
.deep-dive-desc {
font-size: 12px;
line-height: 1.6;
color: var(--text-muted);
}
.deep-dive-arrow {
margin-top: auto;
padding-top: 18px;
font-size: 10px;
font-weight: 600;
letter-spacing: 0.07em;
text-transform: uppercase;
color: var(--gold);
}
.deep-dive-card:hover .deep-dive-arrow {
text-decoration: underline;
}
@media (max-width: 640px) {
.deep-dive-grid {
    grid-template-columns: 1fr;
}
.deep-dive-card {
    min-height: 0;
}
}

/* ── Standalone scrollable About page (fix sticky header) ── */
html {
  height: auto;
  overflow-x: clip;
  overflow-y: visible;
}
body {
  height: auto;
  overflow-x: clip;
  overflow-y: visible;
}
.about-header {
  position: sticky;
  top: 0;
  z-index: 100;
}