/* Modèle B "Cards" : plusieurs pages, police sans empattements, grille de cartes, accent indigo.
   Les couleurs sont des variables : le mode sombre ne fait que les redéfinir. */

:root {
  /* Valeurs de secours : build.py injecte les vraies couleurs et polices
     (palette, couleurs personnalisées, mode sombre) depuis content/site.yml. */
  --bg: #fbfaf7;
  --surface: #ffffff;
  --surface-2: #f3f1ec;
  --text: #1c1917;
  --muted: #57534e;
  --line: #e4e0d8;
  --accent: #0f766e;
  --accent-rgb: 15, 118, 110;
  --on-accent: #ffffff;
  --accent2: #b45309;
  --accent2-rgb: 180, 83, 9;
  --shadow: 0 1px 2px rgba(20, 20, 30, 0.05), 0 8px 24px rgba(20, 20, 30, 0.07);
  --shadow-lift: 0 2px 4px rgba(20, 20, 30, 0.05), 0 16px 36px rgba(20, 20, 30, 0.11);
  --font-heading: Georgia, serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: ui-monospace, Consolas, monospace;
  --radius: 18px;
  --wrap: 1160px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--text); font: 400 1rem/1.6 var(--font-body); overflow-wrap: break-word; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-heading); line-height: 1.2; margin: 0; letter-spacing: -0.02em; }
p { margin: 0 0 0.9em; }
ul, ol { padding-left: 1.2em; }
.muted { color: var(--muted); }
.small { font-size: 0.92rem; }
.wrap { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { flex: none; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
main:focus { outline: none; }
main { flex: 1 0 auto; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--accent); color: var(--on-accent); padding: 10px 16px; border-radius: 10px; font-weight: 700; }
.skip-link:focus { top: 12px; }

/* En-tête */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; min-width: 0; }
.brand-mark { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--accent); color: var(--on-accent); font-size: 0.85rem; font-weight: 800; flex: none; }
.brand-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.site-nav a { display: block; padding: 8px 14px; border-radius: 10px; color: var(--muted); font-weight: 600; font-size: 0.94rem; text-decoration: none; }
.site-nav a:hover { color: var(--text); background: var(--surface-2); }
.site-nav a[aria-current="page"] { color: var(--accent); background: rgba(var(--accent-rgb), 0.12); }
.menu-toggle, .theme-toggle { flex: none; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--text); display: grid; place-items: center; cursor: pointer; }
.menu-toggle:hover, .theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
.menu-toggle { display: none; margin-left: auto; order: 2; }
.when-dark { display: none; }
:root[data-theme="dark"] .when-dark { display: inline-flex; }
:root[data-theme="dark"] .when-light { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .when-dark { display: inline-flex; }
  :root:not([data-theme="light"]) .when-light { display: none; }
}

/* Boutons */
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 20px; border-radius: 12px; font-weight: 700; font-size: 0.95rem; text-decoration: none; border: 1px solid transparent; transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 6px 16px rgba(var(--accent-rgb), 0.28); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn-ghost:hover, .btn-icon:hover { border-color: var(--accent); color: var(--accent); }
.btn-icon { width: 46px; padding: 0; background: var(--surface); color: var(--text); border-color: var(--line); }

/* Cartes génériques */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; color: var(--muted); font-size: 0.85rem; margin: 0 0 8px; }
.card-title { font-size: 1.15rem; margin-bottom: 8px; }
.card-title a { color: var(--text); text-decoration: none; }
.card-title a:hover { color: var(--accent); }
.card-text { color: var(--muted); font-size: 0.95rem; margin: 0; }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: auto; padding-top: 16px; }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; }
.card-actions .link-more { margin-right: auto; }
.link-more:hover { text-decoration: underline; }
.link-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 0.88rem; font-weight: 600; color: var(--muted); text-decoration: none; min-height: 32px; }
.link-chip:hover { color: var(--accent); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 14px 0 0; }
.tags li { font-size: 0.8rem; font-weight: 600; padding: 4px 10px; border-radius: 8px; background: var(--surface-2); color: var(--muted); }
.tags-lg li { font-size: 0.9rem; padding: 6px 12px; color: var(--text); }
.pill { display: inline-block; font-size: 0.75rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: rgba(var(--accent-rgb), 0.12); color: var(--accent); white-space: nowrap; }
.pill-academic { color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.pill-personal { color: var(--accent2); background: color-mix(in srgb, var(--accent2) 12%, var(--surface)); }

/* Hero */
.hero { padding: 40px 0 8px; }
.hero-card {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 40px; align-items: center;
  padding: 44px; border-radius: 28px; border: 1px solid var(--line); box-shadow: var(--shadow);
  background:
    radial-gradient(120% 140% at 100% 0%, rgba(var(--accent-rgb), 0.16), transparent 55%),
    var(--surface);
}
.hero-photo { width: 200px; height: 200px; border-radius: 50%; object-fit: cover; border: 6px solid var(--surface); box-shadow: 0 0 0 2px rgba(var(--accent-rgb), 0.4), var(--shadow); }
.hero-location { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 0.92rem; font-weight: 500; margin-bottom: 10px; }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 800; letter-spacing: -0.035em; }
.hero-role { font-size: clamp(1.05rem, 2vw, 1.3rem); font-weight: 600; color: var(--accent); margin: 8px 0 14px; }
.hero-pitch { color: var(--muted); font-size: 1.05rem; max-width: 62ch; }
.hero-pitch strong { color: var(--text); }
.hero-pitch p:last-child { margin: 0; }

/* Blocs */
.page-head { padding: 48px 0 8px; }
.page-head h1 { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 800; letter-spacing: -0.035em; }
.page-lead { color: var(--muted); font-size: 1.1rem; max-width: 62ch; margin-top: 10px; }
.block { padding: 28px 0; }
.block-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 16px; margin-bottom: 18px; }
.block-head h2 { font-size: 1.5rem; font-weight: 800; }
.block-intro { margin-bottom: 16px; }
.card-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }

/* Projets */
.project-card { display: flex; flex-direction: column; overflow: hidden; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.project-card[hidden] { display: none; }
.project-thumb { position: relative; aspect-ratio: 16 / 9; background: var(--surface-2); }
.project-thumb img { width: 100%; height: 100%; object-fit: cover; }
.project-thumb .pill { position: absolute; top: 12px; left: 12px; background: var(--surface); box-shadow: var(--shadow); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.filter { font: inherit; font-size: 0.92rem; font-weight: 700; min-height: 40px; padding: 8px 18px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer; }
.filter:hover { color: var(--text); border-color: var(--accent); }
.filter[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* Expériences */
.exp-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.exp-grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.exp-card { padding: 22px 24px; border-left: 4px solid var(--line); }
.exp-card.is-current { border-left-color: var(--accent); }
.exp-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: start; margin-bottom: 12px; }
.exp-logo { width: 52px; height: 52px; border-radius: 14px; object-fit: contain; background: var(--surface-2); }
.exp-initials { display: grid; place-items: center; font-weight: 800; color: var(--accent); }
.exp-title h3 { font-size: 1.12rem; }
.exp-org { margin: 3px 0 0; font-weight: 600; color: var(--muted); }
.exp-timeline { gap: 22px; }
.prose { max-width: 72ch; }
.prose > :last-child { margin-bottom: 0; }
.prose li { margin-bottom: 0.35em; }
.prose li::marker { color: var(--accent); }
.prose h2 { font-size: 1.35rem; margin: 1.5em 0 0.6em; }
.prose h3 { font-size: 1.15rem; margin: 1.3em 0 0.5em; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0 1.4em; font-size: 0.95rem; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.prose th { background: var(--surface-2); }
.prose code { background: var(--surface-2); padding: 0.1em 0.35em; border-radius: 6px; font-size: 0.9em; }
.prose pre { background: var(--surface-2); padding: 14px; border-radius: 12px; overflow-x: auto; }
.prose img { border-radius: 12px; margin: 1em 0; }
.prose blockquote { margin: 1em 0; padding-left: 16px; border-left: 3px solid var(--accent); color: var(--muted); }

/* À propos */
.about-card { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 32px; padding: 32px; align-items: start; font-size: 1.05rem; }
.about-photo { width: 180px; border-radius: 20px; aspect-ratio: 1; object-fit: cover; }
.skill-grid, .edu-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.skill-card { padding: 22px; }
.skill-card h3 { font-size: 1.05rem; margin-bottom: 4px; }
.skill-bars { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 12px; }
.skill-row { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; font-size: 0.95rem; margin-bottom: 5px; }
.bar { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.edu-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.edu-card { padding: 22px 24px; }
.edu-card h3 { font-size: 1.1rem; }
.edu-school { font-weight: 600; margin: 4px 0 8px; }

/* Contact */
.contact-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.contact-card { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 14px; align-items: center; padding: 20px 22px; height: 100%; color: var(--text); text-decoration: none; }
.contact-card .icon { grid-row: span 2; color: var(--accent); }
a.contact-card:hover { border-color: var(--accent); }
.contact-label { font-size: 0.82rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.contact-value { font-weight: 600; overflow-wrap: anywhere; }
.contact-cv { margin-top: 24px; }
.cta-band { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px; padding: 28px 32px; }
.cta-band > div { flex: 1 1 380px; }
.cta-band h2 { font-size: 1.4rem; font-weight: 800; margin-bottom: 8px; }
.cta-band p { margin: 0; }

/* Page projet */
.project-page { padding: 32px 0 56px; max-width: 880px; }
.back-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; margin-bottom: 18px; }
.project-page-card { overflow: hidden; }
.project-hero { margin: 0; aspect-ratio: 16 / 9; }
.project-hero img { width: 100%; height: 100%; object-fit: cover; }
.project-page-body { padding: 28px 32px 36px; }
.project-page-body h1 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); font-weight: 800; letter-spacing: -0.03em; }

.footer { border-top: 1px solid var(--line); padding: 26px 0; margin-top: 40px; font-size: 0.9rem; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; }
.footer p { margin: 0; }

/* Mobile */
@media (max-width: 820px) {
  .menu-toggle { display: grid; }
  .theme-toggle { order: 3; }
  .site-nav { order: 4; flex-basis: 100%; display: none; margin: 0 0 12px; }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; }
  .site-nav a { padding: 12px 14px; }
  .header-inner { flex-wrap: wrap; }
  .hero-card { grid-template-columns: 1fr; gap: 22px; padding: 28px 22px; }
  .hero-photo { width: 116px; height: 116px; border-width: 4px; }
  .about-card { grid-template-columns: 1fr; padding: 24px 20px; }
  .about-photo { width: 120px; }
}
@media (max-width: 560px) {
  .card-grid, .exp-grid-2, .edu-grid, .skill-grid, .contact-grid { grid-template-columns: 1fr; }
  .exp-card { padding: 18px; }
  .exp-head { grid-template-columns: auto minmax(0, 1fr); }
  .exp-head .pill { grid-column: 2; justify-self: start; }
  .btn { flex: 1 1 auto; }
  .btn-icon { flex: 0 0 46px; }
  .cta-band { padding: 22px 20px; }
  .project-page-body { padding: 22px 20px 28px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .btn:hover, .project-card:hover { transform: none; }
}
@media print {
  .site-header, .filters, .skip-link { display: none; }
}

/* availability badge */
.status { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px; padding: 5px 12px 5px 10px; border-radius: 999px; font-size: 0.88rem; font-weight: 600; color: #166534; background: rgba(22, 163, 74, 0.1); border: 1px solid rgba(22, 163, 74, 0.25); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.2); }
:root[data-theme="dark"] .status { color: #86efac; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .status { color: #86efac; } }

/* === shine layer === */
/* Soft coloured halos behind the page, like a light source above the content */
body {
  background:
    radial-gradient(900px 520px at 12% -8%, rgba(var(--accent-rgb), 0.16), transparent 60%),
    radial-gradient(760px 480px at 100% 0%, rgba(var(--accent2-rgb), 0.12), transparent 62%),
    var(--bg);
  background-attachment: fixed;
}

/* Hero: a glowing corner */
.hero-card { position: relative; isolation: isolate; }
.hero-card::before {
  content: ""; position: absolute; inset: -40px -10% auto auto; width: 520px; height: 420px; z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(var(--accent-rgb), 0.22), rgba(var(--accent2-rgb), 0.10) 55%, transparent);
  filter: blur(8px);
}
/* Photo: luminous ring */
.hero-photo img, .about-photo img { box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.25), 0 18px 50px -12px rgba(var(--accent-rgb), 0.45) !important; }
/* Cards: lift, accent border and a light sheen that sweeps across on hover */
.project-card, .exp-card, .skill-card, .edu-card, .contact-card, .about-card { position: relative; overflow: hidden; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.project-card:hover, .exp-card:hover, .skill-card:hover, .edu-card:hover, .contact-card:hover, .about-card:hover, .project-card:focus-within, .exp-card:focus-within, .skill-card:focus-within, .edu-card:focus-within, .contact-card:focus-within, .about-card:focus-within { transform: translateY(-4px); box-shadow: var(--shadow-lift), 0 12px 40px -18px rgba(var(--accent-rgb), 0.55); border-color: rgba(var(--accent-rgb), 0.45); }
.project-card::after, .exp-card::after, .skill-card::after, .edu-card::after, .contact-card::after, .about-card::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 45%; height: 100%; pointer-events: none;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,0.28) 45%, rgba(255,255,255,0.08) 60%, transparent);
  transform: skewX(-18deg); opacity: 0;
}
.project-card:hover::after, .exp-card:hover::after, .skill-card:hover::after, .edu-card:hover::after, .contact-card:hover::after, .about-card:hover::after { animation: sheen .9s ease forwards; }
@keyframes sheen { from { left: -60%; opacity: 1; } to { left: 130%; opacity: 1; } }
.project-thumb { overflow: hidden; }
.project-thumb img { transition: transform .45s ease; }
.project-card:hover .project-thumb img, .exp-card:hover .project-thumb img, .skill-card:hover .project-thumb img, .edu-card:hover .project-thumb img, .contact-card:hover .project-thumb img, .about-card:hover .project-thumb img { transform: scale(1.05); }
/* Primary button: glow and the same sheen */
.btn-primary { position: relative; overflow: hidden; box-shadow: 0 8px 22px -8px rgba(var(--accent-rgb), 0.65); transition: transform .2s ease, box-shadow .2s ease; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 30px -8px rgba(var(--accent-rgb), 0.75); }
.btn-primary::after {
  content: ""; position: absolute; top: 0; left: -70%; width: 50%; height: 100%; pointer-events: none;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,0.45), transparent); transform: skewX(-18deg);
}
.btn-primary:hover::after { animation: sheen .8s ease forwards; }
/* Headline name: subtle gradient ink */
h1.shine-text { background: linear-gradient(100deg, var(--text) 15%, rgb(var(--accent-rgb)) 62%, rgb(var(--accent2-rgb)) 100%); -webkit-background-clip: text; background-clip: text; color: transparent !important; -webkit-text-fill-color: transparent; padding-bottom: .06em; width: fit-content; max-width: 100%; }
@media (prefers-reduced-motion: reduce) {
  .project-card:hover::after, .exp-card:hover::after, .skill-card:hover::after, .edu-card:hover::after, .contact-card:hover::after, .about-card:hover::after, .btn-primary:hover::after { animation: none; }
  .project-card:hover, .exp-card:hover, .skill-card:hover, .edu-card:hover, .contact-card:hover, .about-card:hover, .project-card:focus-within, .exp-card:focus-within, .skill-card:focus-within, .edu-card:focus-within, .contact-card:focus-within, .about-card:focus-within, .btn-primary:hover { transform: none; }
  .project-card:hover .project-thumb img, .exp-card:hover .project-thumb img, .skill-card:hover .project-thumb img, .edu-card:hover .project-thumb img, .contact-card:hover .project-thumb img, .about-card:hover .project-thumb img { transform: none; }
}

/* === frame layer (framed shell + gradient panels) === */
/* Page: a deeper tone around a framed shell, like a desk under a sheet of paper */
:root { --page: color-mix(in srgb, var(--bg) 90%, var(--text) 10%); --panel-a: var(--surface); --panel-b: color-mix(in srgb, var(--surface) 55%, var(--bg)); }
:root[data-theme="dark"] { --page: color-mix(in srgb, var(--bg) 55%, #000); --panel-b: color-mix(in srgb, var(--surface) 45%, var(--bg)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --page: color-mix(in srgb, var(--bg) 55%, #000); --panel-b: color-mix(in srgb, var(--surface) 45%, var(--bg)); } }
body {
  background:
    radial-gradient(1000px 600px at 8% -10%, rgba(var(--accent-rgb), 0.14), transparent 60%),
    radial-gradient(800px 520px at 100% 0%, rgba(var(--accent2-rgb), 0.10), transparent 62%),
    var(--page);
  background-attachment: fixed;
}
.shell {
  width: min(100% - 32px, 1400px); margin: 16px auto; border-radius: 28px;
  border: 1px solid color-mix(in srgb, var(--line) 80%, rgb(var(--accent-rgb)) 20%);
  background:
    radial-gradient(circle at 0% 0%, rgba(var(--accent-rgb), 0.10), transparent 30%),
    linear-gradient(130deg, color-mix(in srgb, var(--surface) 90%, rgb(var(--accent-rgb)) 10%), var(--bg) 55%);
  box-shadow: 0 40px 90px -50px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
/* Panels: vertical gradient with a coloured glow in the top-left corner */
.card, .hero-card {
  background:
    radial-gradient(circle at top left, rgba(var(--accent-rgb), 0.12), transparent 42%),
    linear-gradient(180deg, var(--panel-a), var(--panel-b));
  border-color: color-mix(in srgb, var(--line) 85%, rgb(var(--accent-rgb)) 15%);
}
.shell > .site-header { border-radius: 28px 28px 0 0; background: color-mix(in srgb, var(--surface) 80%, transparent); }
.shell > .footer { border-radius: 0 0 28px 28px; }
.hero-card { background: radial-gradient(circle at top left, rgba(var(--accent-rgb), 0.22), transparent 34%), linear-gradient(180deg, var(--panel-a), var(--panel-b)) !important; }
@media (max-width: 760px) {
  .shell { width: 100%; margin: 0; border-radius: 0; border: 0; box-shadow: none; }
}

/* === polish layer (panels for skills, education, contact) === */
.contact-card .icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: rgba(var(--accent-rgb), 0.12); box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.18), 0 8px 20px -10px rgba(var(--accent-rgb), 0.6); }
.bar span { background: linear-gradient(90deg, rgb(var(--accent-rgb)), color-mix(in srgb, rgb(var(--accent-rgb)) 60%, #fff)); box-shadow: 0 0 10px rgba(var(--accent-rgb), 0.5); }

/* keep decorative glows from widening the page on phones */
html, body { overflow-x: clip; }

.menu-toggle .when-open { display: none; }
.menu-toggle[aria-expanded="true"] .when-open { display: inline-flex; }
.menu-toggle[aria-expanded="true"] .when-closed { display: none; }
.menu-toggle span { display: inline-flex; }
