/* CV site: premium, compact, full-width layout. Markup generated by admin/lib/render.php.
   Light by default, dark via [data-theme="dark"] or the system setting. */
:root {
    --bg: #f5f5f7; --bg-2: #ebebf0; --card: #ffffff; --card-2: #f5f5f7; --ink: #1d1d1f; --ink-2: #424245; --muted: #6e6e73; --faint: #86868b;
    --line: rgba(0, 0, 0, .08); --fill: rgba(120, 120, 128, .12); --fill-2: rgba(120, 120, 128, .07);
    --blue: #0071e3; --blue-ink: #0066cc; --blue-soft: rgba(0, 113, 227, .1); --green: #1f9d48; --green-soft: rgba(52, 199, 89, .14);
    --accent: linear-gradient(120deg, #0a84ff 0%, #5e5ce6 55%, #bf5af2 100%);
    --glass: rgba(255, 255, 255, .72);
    --shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 10px 30px -14px rgba(0, 0, 0, .14);
    --shadow-lift: 0 2px 6px rgba(0, 0, 0, .05), 0 24px 50px -20px rgba(0, 0, 0, .28);
    --r: 22px; --r-sm: 14px;
    --ease: cubic-bezier(.16, 1, .3, 1); --spring: cubic-bezier(.34, 1.56, .64, 1);
    --font: Inter, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
    --display: Inter, -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
    color-scheme: light;
}
:root[data-theme="dark"] {
    --bg: #000; --bg-2: #0d0d0f; --card: #161618; --card-2: #1f1f22; --ink: #f5f5f7; --ink-2: #d2d2d7; --muted: #a1a1a6; --faint: #7c7c82;
    --line: rgba(255, 255, 255, .09); --fill: rgba(120, 120, 128, .26); --fill-2: rgba(120, 120, 128, .14);
    --blue: #0a84ff; --blue-ink: #4aa3ff; --blue-soft: rgba(10, 132, 255, .18); --green: #30d158; --green-soft: rgba(48, 209, 88, .16);
    --glass: rgba(22, 22, 24, .72);
    --shadow: 0 0 0 .5px rgba(255, 255, 255, .07);
    --shadow-lift: 0 0 0 .5px rgba(255, 255, 255, .12), 0 24px 50px -20px rgba(0, 0, 0, .8);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.55 var(--font); letter-spacing: -.011em; overflow-x: clip; }
body::before { content: ""; position: fixed; inset: -20% -10% auto; height: 70vh; z-index: -1; pointer-events: none; background: radial-gradient(50% 60% at 20% 20%, rgba(10, 132, 255, .12), transparent 70%), radial-gradient(40% 50% at 85% 10%, rgba(191, 90, 242, .1), transparent 70%); }
img { max-width: 100%; display: block; }
a { color: var(--blue-ink); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { margin: 0; font-family: var(--display); letter-spacing: -.022em; color: var(--ink); }
ul, ol { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }
strong { font-weight: 600; color: var(--ink); }
::selection { background: rgba(0, 113, 227, .22); }
:focus-visible { outline: 3px solid rgba(0, 113, 227, .5); outline-offset: 2px; border-radius: 6px; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; padding: 8px 14px; border-radius: 10px; background: var(--ink); color: var(--bg); }
.skip:focus { top: 12px; }
.eyebrow { margin-bottom: 8px; color: var(--faint); font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border: 0; border-radius: 999px; font: 600 14px var(--font); letter-spacing: -.01em; cursor: pointer; white-space: nowrap; transition: transform .25s var(--spring), filter .2s, background-color .2s, box-shadow .25s; text-decoration: none !important; }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 8px 20px -10px rgba(0, 113, 227, .8); }
.btn-primary:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-secondary { background: var(--fill); color: var(--ink); }
.btn-secondary:hover { background: var(--fill-2); transform: translateY(-1px); }
.btn:active { transform: scale(.96); }
.btn-sm { height: 32px; padding: 0 13px; font-size: 12.5px; }
.icon-btn { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--ink); cursor: pointer; transition: background-color .2s, transform .25s var(--spring); }
.icon-btn:hover { background: var(--fill); }
.icon-btn:active { transform: scale(.9); }

/* ---------- Top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: var(--glass); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: .5px solid var(--line); }
.topbar-inner { display: flex; align-items: center; gap: 20px; max-width: 1480px; height: 56px; margin: 0 auto; padding: 0 24px; }
.brand { display: inline-flex; cursor: pointer; border-radius: 999px; padding: 3px 10px 3px 3px; margin-left: -3px; transition: background-color .2s; align-items: center; gap: 10px; color: var(--ink); font: 650 16px var(--display); letter-spacing: -.02em; text-decoration: none !important; }
.brand img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 .5px var(--line); }
.topnav { position: relative; display: flex; gap: 2px; margin: 0 auto; padding: 3px; border-radius: 999px; background: var(--fill-2); }
.topnav a { position: relative; z-index: 1; padding: 6px 13px; border-radius: 999px; color: var(--muted); font-size: 13px; font-weight: 500; text-decoration: none !important; transition: color .25s; white-space: nowrap; }
.topnav a:hover, .topnav a.is-active { color: var(--ink); }
.topnav-pill { position: absolute; top: 3px; bottom: 3px; left: 0; width: 0; border-radius: 999px; background: var(--card); box-shadow: 0 1px 3px rgba(0, 0, 0, .1), 0 0 0 .5px var(--line); opacity: 0; transition: left .45s var(--spring), width .45s var(--spring), opacity .3s; }
.topnav-pill.is-on { opacity: 1; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.lang { display: inline-grid; grid-auto-flow: column; padding: 2px; border-radius: 9px; background: var(--fill); font-size: 12px; font-weight: 600; }
.lang > * { padding: 4px 10px; border-radius: 7px; color: var(--ink); text-decoration: none !important; }
.lang span { background: var(--card); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.lang a { opacity: .6; }
.lang a:hover { opacity: 1; }
.progress { position: absolute; left: 0; bottom: -.5px; height: 2px; width: 100%; transform-origin: left; transform: scaleX(var(--p, 0)); background: var(--accent); }

/* ---------- Layout ---------- */
.layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 20px; max-width: 1480px; margin: 0 auto; padding: 20px 24px 40px; align-items: start; }
.content { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.panel { position: relative; padding: 28px 30px; border-radius: var(--r); background: var(--card); box-shadow: var(--shadow); }
.sec-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.sec-head h2 { font-size: 24px; font-weight: 700; }
.lead { color: var(--ink-2); font-size: 16px; line-height: 1.65; }
.duo { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 20px; }

/* ---------- Profile ---------- */
.profile { position: sticky; top: var(--profile-top, 76px); }
.profile-card { display: flex; flex-direction: column; padding: 26px 24px 24px; border-radius: 26px; background: var(--card); box-shadow: var(--shadow); }
.profile-card::-webkit-scrollbar { display: none; }
.profile-card > * { flex-shrink: 0; }
.avatar { position: relative; width: 112px; height: 112px; margin-bottom: 16px; }
.avatar::before { content: ""; position: absolute; inset: -4px; border-radius: 50%; background: conic-gradient(from 0deg, #0a84ff, #5e5ce6, #bf5af2, #ff375f, #ff9f0a, #0a84ff); animation: spin 8s linear infinite; }
.avatar::after { content: ""; position: absolute; inset: -1px; border-radius: 50%; background: var(--card); }
.avatar img { position: relative; z-index: 1; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.avatar-status { position: absolute; z-index: 2; right: 6px; bottom: 6px; width: 18px; height: 18px; border-radius: 50%; background: #34c759; box-shadow: 0 0 0 3px var(--card); }
.avatar-status::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #34c759; animation: ping 2s var(--ease) infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes ping { 0% { transform: scale(1); opacity: .6; } 100% { transform: scale(2.4); opacity: 0; } }
.kicker { font-size: 13px; font-weight: 650; background: linear-gradient(90deg, #ff6a00, #ee0979 55%, #8e2de2); -webkit-background-clip: text; background-clip: text; color: transparent; }
.name { margin-top: 4px; font-size: 30px; line-height: 1.08; font-weight: 800; letter-spacing: -.03em; }
.role { margin-top: 6px; color: var(--ink); font-size: 15px; font-weight: 600; }
.pitch { margin-top: 10px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.available { display: flex; align-items: center; gap: 8px; margin-top: 16px; padding: 9px 12px; border-radius: 12px; background: var(--green-soft); color: var(--green); font-size: 13px; }
.available strong { color: var(--green); }
.available span:last-child { color: var(--ink-2); }
.available .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 0 currentColor; animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(52, 199, 89, .5); } 70% { box-shadow: 0 0 0 8px rgba(52, 199, 89, 0); } 100% { box-shadow: 0 0 0 0 rgba(52, 199, 89, 0); } }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.stat { padding: 10px 8px; border-radius: 12px; background: var(--card-2); text-align: center; }
.stat strong { display: block; font: 800 22px/1.1 var(--display); letter-spacing: -.03em; background: var(--accent); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.stat span { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; line-height: 1.25; }
.facts { display: grid; gap: 6px; margin-top: 14px; color: var(--ink-2); font-size: 13px; }
.facts li { display: flex; gap: 9px; align-items: baseline; }
.facts i { width: 14px; color: var(--faint); text-align: center; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.chip { padding: 4px 10px; border-radius: 999px; background: var(--fill-2); box-shadow: inset 0 0 0 .5px var(--line); color: var(--ink-2); font-size: 12px; font-weight: 500; }
.profile-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; }
.profile-actions .btn { padding: 0 10px; font-size: 13px; }
.contact-links { display: grid; margin-top: 16px; border-radius: 14px; background: var(--card-2); overflow: hidden; }
.contact-links a { display: flex; align-items: center; gap: 11px; padding: 10px 12px; color: var(--ink); font-size: 13px; text-decoration: none !important; transition: background-color .2s; }
.contact-links a + a { border-top: .5px solid var(--line); }
.contact-links a:hover { background: var(--fill-2); }
.contact-links i { display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 8px; background: var(--blue); color: #fff; font-size: 12px; }
.contact-links span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.expertise { margin-top: 16px; }
.expertise span { display: block; padding: 7px 0; border-top: .5px solid var(--line); color: var(--ink-2); font-size: 13px; }
.expertise .eyebrow + span { border-top: 0; padding-top: 0; }

/* ---------- Experience timeline ---------- */
.timeline { position: relative; display: grid; gap: 14px; padding-left: 26px; }
.timeline-line { position: absolute; left: 6px; top: 8px; bottom: 8px; width: 2px; border-radius: 2px; background: var(--fill); overflow: hidden; }
.timeline-line span { position: absolute; inset: 0; transform-origin: top; transform: scaleY(var(--tl, 0)); background: var(--accent); }
.xp { position: relative; padding: 20px 22px; border-radius: var(--r-sm); background: var(--card-2); transition: transform .45s var(--ease), box-shadow .45s var(--ease), background-color .3s; }
.xp:hover { transform: translateX(3px); background: var(--card); box-shadow: var(--shadow-lift); }
.xp-dot { position: absolute; left: -26px; top: 26px; width: 14px; height: 14px; border-radius: 50%; background: var(--card); box-shadow: 0 0 0 2px var(--faint); }
.xp-dot.is-current { background: #34c759; box-shadow: 0 0 0 4px var(--green-soft); }
.xp-head { display: flex; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.xp-head h3 { font-size: 19px; font-weight: 750; }
.xp-role { margin-top: 2px; color: var(--blue-ink); font-size: 14px; font-weight: 600; }
.xp-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.pill { padding: 3px 10px; border-radius: 999px; background: var(--fill); color: var(--ink-2); font-size: 12px; font-weight: 600; white-space: nowrap; }
.pill.is-current { background: var(--green-soft); color: var(--green); }
.xp-loc { color: var(--faint); font-size: 12px; }
.xp-body { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 22px; margin-top: 14px; }
.xp-text h4 { margin: 14px 0 6px; color: var(--faint); font-family: var(--font); font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.xp-text h4:first-child { margin-top: 0; }
.xp-text li { position: relative; padding-left: 16px; margin-bottom: 5px; color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.xp-text li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 5px; height: 5px; border-radius: 50%; background: var(--blue); opacity: .6; }
.xp-tech ul { display: grid; gap: 1px; border-radius: 12px; overflow: hidden; background: var(--line); }
.xp-tech li { display: flex; gap: 10px; padding: 8px 10px; background: var(--card); font-size: 12.5px; line-height: 1.35; }
.xp:hover .xp-tech li { background: var(--card-2); }
.xp-tech i { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 6px; background: var(--blue-soft); color: var(--blue-ink); font-size: 10.5px; }
.xp-tech strong { display: block; font-weight: 600; }
.xp-tech span { display: block; color: var(--muted); }

/* ---------- Skills (masonry) ---------- */
.skills { columns: 3 260px; column-gap: 14px; }
.skill { break-inside: avoid; margin-bottom: 14px; padding: 16px 18px; border-radius: var(--r-sm); background: var(--card-2); transition: transform .4s var(--ease), box-shadow .4s var(--ease), background-color .3s; }
.skill:hover { transform: translateY(-3px); background: var(--card); box-shadow: var(--shadow-lift); }
.skill h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; font-size: 15px; font-weight: 700; line-height: 1.3; }
.skill-icon { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(160deg, #5ac8fa, #0a84ff); color: #fff; font-size: 12.5px; transition: transform .45s var(--spring); }
.skill:hover .skill-icon { transform: rotate(-8deg) scale(1.08); }
.skill li { position: relative; padding-left: 14px; margin-bottom: 4px; color: var(--ink-2); font-size: 13px; line-height: 1.45; }
.skill li::before { content: ""; position: absolute; left: 1px; top: .6em; width: 4px; height: 4px; border-radius: 50%; background: var(--faint); }

/* ---------- Certifications & education ---------- */
.certs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.certs li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--card-2); color: var(--ink-2); font-size: 13px; line-height: 1.35; transition: transform .3s var(--ease), background-color .3s; }
.certs li:hover { transform: translateY(-2px); background: var(--fill-2); }
.certs i { flex: none; color: #30d158; font-size: 16px; }
.edu { display: grid; gap: 10px; }
.edu li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; padding: 14px; border-radius: 12px; background: var(--card-2); }
.edu-years { display: inline-block !important; margin: 4px 0 2px; padding: 2px 9px; border-radius: 999px; background: rgba(137, 68, 171, .12); color: #8944ab !important; font-size: 11.5px !important; font-weight: 700; font-variant-numeric: tabular-nums; }
:root[data-theme="dark"] .edu-years { color: #da8fff; }
.edu strong { display: block; font-size: 15px; }
.edu span { display: block; margin-top: 2px; color: var(--muted); font-size: 13px; line-height: 1.4; }

/* ---------- Testimonials slider ---------- */
.slider-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 28px) / 3); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; padding: 2px; margin: -2px; }
.slider-track::-webkit-scrollbar { display: none; }
.quote { position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 16px; margin: 0; padding: 20px; border-radius: var(--r-sm); background: var(--card-2); scroll-snap-align: start; transition: transform .4s var(--ease), box-shadow .4s var(--ease), background-color .3s; }
.quote:hover { transform: translateY(-3px); background: var(--card); box-shadow: var(--shadow-lift); }
.quote-mark { position: absolute; right: 18px; top: 16px; color: var(--blue); opacity: .15; font-size: 28px; }
.quote blockquote { margin: 0; color: var(--ink-2); font-size: 14px; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 8; -webkit-box-orient: vertical; overflow: hidden; }
.quote.is-open blockquote { -webkit-line-clamp: unset; }
.quote-who { display: flex; align-items: center; gap: 11px; }
.quote-who img, .quote-initial { flex: none; width: 44px; height: 44px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--card); }
.quote-initial { display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 700; }
.quote-who strong { display: block; font-size: 14px; }
.quote-who span { display: block; color: var(--muted); font-size: 12px; line-height: 1.35; }
.quote-link { color: inherit; text-decoration: none !important; }
.quote-link:hover strong { color: var(--blue-ink); }
.slider-controls { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 16px; }
.slider-controls .icon-btn { background: var(--fill-2); }
.slider-dots { display: flex; gap: 6px; }
.slider-dots button { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 999px; background: var(--ink); opacity: .2; cursor: pointer; transition: width .35s var(--ease), opacity .3s; }
.slider-dots button.is-on { width: 22px; opacity: .75; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.4fr); gap: 26px; }
.contact-intro { display: flex; flex-direction: column; gap: 8px; }
.contact-intro .lead { margin-bottom: 8px; }
.contact-row { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px; background: var(--card-2); color: var(--ink); font-size: 14px; text-decoration: none !important; transition: transform .3s var(--ease), background-color .2s; }
.contact-row:hover { transform: translateX(3px); background: var(--fill-2); }
.contact-row i { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--blue); color: #fff; font-size: 13px; }
.contact-form { display: grid; gap: 12px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fld { display: grid; gap: 6px; }
.fld span { color: var(--muted); font-size: 12.5px; font-weight: 600; }
.fld input, .fld textarea { width: 100%; padding: 11px 14px; border: 0; border-radius: 12px; background: var(--card-2); box-shadow: inset 0 0 0 .5px var(--line); color: var(--ink); font: 14px/1.5 var(--font); outline: 0; transition: box-shadow .2s, background-color .2s; }
.fld textarea { resize: vertical; min-height: 120px; }
.fld input:focus, .fld textarea:focus { background: var(--card); box-shadow: inset 0 0 0 1px var(--blue), 0 0 0 4px var(--blue-soft); }
.fld.is-invalid input, .fld.is-invalid textarea { box-shadow: inset 0 0 0 1px #ff3b30, 0 0 0 4px rgba(255, 59, 48, .12); }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.form-foot small { color: var(--faint); font-size: 12px; }
.form-status { min-height: 1.2em; font-size: 13.5px; font-weight: 600; }
.form-status.is-ok { color: var(--green); }
.form-status.is-error { color: #ff3b30; }
.contact-form.is-sending button[type="submit"] { opacity: .6; pointer-events: none; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Footer ---------- */
.footer { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 6px 6px 0; color: var(--faint); font-size: 12.5px; }
.footer strong { color: var(--muted); }
.footer a { color: var(--muted); }

/* ---------- Motion ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0ms); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
    .layout { grid-template-columns: 310px minmax(0, 1fr); }
    .slider-track { grid-auto-columns: calc((100% - 14px) / 2); }
    .xp-body { grid-template-columns: minmax(0, 1fr) 240px; }
}
@media (max-width: 1100px) {
    .topnav { display: none; }
    .topbar-inner { justify-content: space-between; }
    .duo { grid-template-columns: 1fr; }
}
@media (max-width: 920px) {
    .layout { grid-template-columns: 1fr; padding: 14px 14px 30px; gap: 14px; }
    .content { gap: 14px; }
    .profile { position: static; }
    .profile-card { max-height: none; align-items: center; text-align: center; }
    .facts li { justify-content: center; }
    .chips { justify-content: center; }
    .expertise { width: 100%; text-align: left; }
    .contact-links { width: 100%; text-align: left; }
    .profile-actions, .stats, .available { width: 100%; }
    .available { justify-content: center; }
    .xp-body { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    body { font-size: 14.5px; }
    .topbar-inner { padding: 0 14px; gap: 10px; }
    .brand span, .topbar-actions .btn span { display: none; }
    .topbar-actions .btn { width: 32px; padding: 0; }
    .panel { padding: 22px 18px; border-radius: 20px; }
    .sec-head h2 { font-size: 21px; }
    .certs, .form-row { grid-template-columns: 1fr; }
    .slider-track { grid-auto-columns: 88%; }
    .timeline { padding-left: 20px; }
    .xp { padding: 16px; }
    .xp-dot { left: -20px; }
    .timeline-line { left: 3px; }
    .xp-meta { align-items: flex-start; }
    .edu li { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
    .reveal { opacity: 1; transform: none; }
}
@media print {
    .topbar, .slider-controls, .contact-form, .profile-actions { display: none !important; }
    .layout { display: block; }
    .panel, .profile-card { box-shadow: none; break-inside: avoid; }
    .reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- Icons (Phosphor) ---------- */
[class^="ph"], [class*=" ph-"] { line-height: 1; }
.btn i, .icon-btn i { font-size: 16px; }
.contact-links i, .contact-row i { font-size: 15px; }
.xp-tech i { font-size: 13px; }
.skill-icon i { font-size: 16px; }
.certs i { font-size: 18px; }
.facts i { font-size: 15px; }

/* ---------- Cut-out photo on a gradient disc ---------- */
.avatar.is-cutout { width: 124px; height: 124px; margin-top: 10px; }
.avatar.is-cutout::after { display: none; }
.avatar.is-cutout::before { z-index: 0; }
.avatar-bg { position: absolute; inset: 0; z-index: 0; border-radius: 50%; background: radial-gradient(circle at 30% 25%, #ffffff 0%, rgba(255, 255, 255, 0) 45%), linear-gradient(150deg, #cfe3ff 0%, #b9c4ff 45%, #e2c8ff 100%); }
:root[data-theme="dark"] .avatar-bg { background: radial-gradient(circle at 30% 25%, rgba(255, 255, 255, .18) 0%, rgba(255, 255, 255, 0) 45%), linear-gradient(150deg, #1d3a66 0%, #2c2f6e 50%, #4a2a6a 100%); }
/* The photo is taller than the disc: the head rises above it, the shoulders are clipped to the circle. */
.avatar.is-cutout img { position: absolute; z-index: 1; left: 0; bottom: 0; width: 100%; height: 118%; border-radius: 0; object-fit: cover; object-position: center top; clip-path: inset(-20% 0 0 0 round 0 0 62px 62px); }
.avatar:not(.is-cutout) .avatar-bg { display: none; }

/* ---------- Logos (companies, schools, projects) ---------- */
.xp-head { align-items: flex-start; }
.xp-title { flex: 1; min-width: 0; }
.xp-logo, .edu-logo, .project-logo, .cert-logo { display: grid; place-items: center; flex: none; overflow: hidden; background: #fff; box-shadow: 0 0 0 .5px var(--line), 0 4px 10px -6px rgba(0, 0, 0, .25); }
.xp-logo { width: 46px; height: 46px; border-radius: 12px; }
.edu-logo { width: 44px; height: 44px; border-radius: 11px; }
.cert-logo { width: 30px; height: 30px; border-radius: 8px; }
.cert-logo.has-img img { padding: 3px; }
.certs li > i { width: 30px; justify-content: center; }
.project-logo { width: 52px; height: 52px; border-radius: 14px; }
.has-img img { width: 100%; height: 100%; object-fit: contain; padding: 5px; }
.is-mono { background: linear-gradient(150deg, hsl(var(--h) 85% 62%), hsl(calc(var(--h) + 30) 75% 46%)); color: #fff; font: 800 15px var(--display); letter-spacing: -.02em; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 6px 14px -8px hsl(var(--h) 80% 40%); }
:root[data-theme="dark"] .has-img { background: #f5f5f7; }
.xp-head { display: flex; gap: 14px; }

/* ---------- Projects ---------- */
.projects { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.project { display: flex; gap: 14px; padding: 16px; border-radius: var(--r-sm); background: var(--card-2); color: var(--ink); text-decoration: none !important; transition: transform .4s var(--ease), box-shadow .4s var(--ease), background-color .3s; }
.project:hover { transform: translateY(-3px); background: var(--card); box-shadow: var(--shadow-lift); }
.project h3 { display: flex; align-items: center; gap: 6px; font-size: 16px; font-weight: 700; }
.project-go { color: var(--blue-ink); font-size: 14px; transition: transform .35s var(--spring); }
.project:hover .project-go { transform: translate(2px, -2px); }
.project p { margin-top: 4px; color: var(--muted); font-size: 13.5px; line-height: 1.5; }
.project-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.project-tags span { padding: 2px 9px; border-radius: 999px; background: var(--fill-2); color: var(--ink-2); font-size: 11.5px; font-weight: 600; }
@media (max-width: 640px) { .xp-head { flex-wrap: wrap; } .xp-logo { width: 40px; height: 40px; } }

/* Duotone icons are drawn with two stacked layers (::before + ::after): boxes around them must use flex, not grid. */
.contact-links i, .contact-row i, .xp-tech i, .skill-icon, .icon-btn, .xp-logo, .edu-logo, .project-logo, .cert-logo { display: inline-flex !important; align-items: center; justify-content: center; }

/* Download menu (CV 1 page / 2 pages / full), a <details> element so it works without JavaScript. */
.dl { position: relative; }
.dl > summary { list-style: none; }
.dl > summary::-webkit-details-marker { display: none; }
.dl-caret { font-size: .85em; opacity: .8; transition: transform .3s var(--ease); }
.dl[open] .dl-caret { transform: rotate(180deg); }
.dl-menu { position: absolute; z-index: 60; top: calc(100% + 8px); right: 0; width: 264px; padding: 6px; border-radius: 18px; background: var(--card); box-shadow: 0 0 0 .5px var(--line), 0 24px 50px -16px rgba(0, 0, 0, .35); transform-origin: top right; animation: dl-in .32s var(--spring); }
.dl-profile .dl-menu { left: 0; right: auto; transform-origin: top left; }
.dl-menu a { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 12px; color: var(--ink); text-decoration: none; transition: background-color .2s; }
.dl-menu a:hover, .dl-menu a:focus-visible { background: var(--fill); outline: none; }
.dl-icon { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--blue-soft); color: var(--blue); font-size: 18px; }
.dl-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.dl-text strong { font-size: 13.5px; font-weight: 600; }
.dl-text small { color: var(--muted); font-size: 12px; }
.dl-menu a.is-recommended .dl-icon { background: var(--blue); color: #fff; }
.dl-menu a.is-recommended small { color: var(--blue-ink); font-weight: 600; }
@keyframes dl-in { from { opacity: 0; transform: translateY(-6px) scale(.96); } to { opacity: 1; transform: none; } }
.profile-actions .dl > summary { width: 100%; }
@media (max-width: 640px) {
    .topbar-actions .dl-caret { display: none; }
    .dl-menu { position: fixed; top: 60px; left: 14px; right: 14px; width: auto; }
}
@media print { .dl-menu { display: none; } }

/* Brand menu (back to top, admin) */
.brand:hover, .dl-brand[open] > .brand { background: var(--fill); }
.brand .dl-caret { color: var(--muted); font-size: 12px; }
.dl-brand .dl-menu { left: 0; right: auto; width: 250px; transform-origin: top left; }

/* ---------- Technologies bar (marquee) ---------- */
.stack { overflow: hidden; padding-left: 0; padding-right: 0; }
.stack-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 0 30px; margin-bottom: 16px; }
.stack-head h2 { font-size: 24px; font-weight: 700; }
.stack-head p { margin: 0; color: var(--muted); font-size: 13.5px; }
.marquee { display: flex; gap: 12px; padding: 6px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); }
.marquee + .marquee { margin-top: 6px; }
.marquee-track { display: flex; flex: none; gap: 12px; margin: 0; padding: 0; list-style: none; animation: marquee calc(var(--n, 12) * 3.2s) linear infinite; }
.marquee.is-reverse .marquee-track { animation-direction: reverse; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(calc(-100% - 12px)); } }
.tech { display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px 8px 8px; border-radius: 999px; background: var(--card-2); box-shadow: inset 0 0 0 .5px var(--line); white-space: nowrap; font-size: 14px; font-weight: 600; color: var(--ink); transition: transform .3s var(--spring), background-color .2s; }
.tech:hover { transform: translateY(-2px) scale(1.04); background: var(--fill-2); }
.tech-logo { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 34px; height: 34px; border-radius: 50%; overflow: hidden; background: #fff; box-shadow: 0 0 0 .5px var(--line), 0 3px 8px -5px rgba(0, 0, 0, .3); }
.tech-logo.has-img img { padding: 6px; }
.tech-logo.is-mono { font-size: 12px; }
@media (max-width: 640px) { .stack-head { padding: 0 18px; } .stack-head h2 { font-size: 21px; } .tech { font-size: 13px; } }
@media (prefers-reduced-motion: reduce) {
    .marquee { -webkit-mask-image: none; mask-image: none; padding: 0 30px; }
    .marquee-track { flex-wrap: wrap; flex: 1; animation: none; }
    .marquee-track[aria-hidden="true"] { display: none; }
}
@media print { .stack { display: none; } }
.duo.is-single { grid-template-columns: 1fr; }

/* Contact: security code */
.captcha { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: end; }
.captcha input { text-transform: uppercase; letter-spacing: .3em; font-weight: 600; }
.captcha input::placeholder { text-transform: none; letter-spacing: normal; font-weight: 400; }
.captcha-img { display: flex; align-items: center; gap: 6px; }
.captcha-img img { width: 160px; height: 51px; border-radius: 10px; background: #f4f6fa; box-shadow: inset 0 0 0 .5px var(--line); }
@media (max-width: 640px) { .captcha { grid-template-columns: 1fr; } }

/* ---------- Languages ---------- */
.langs { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.lang-item { padding: 14px 16px; border-radius: 14px; background: var(--card-2); transition: transform .3s var(--ease); }
.lang-item:hover { transform: translateY(-2px); }
.lang-top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.lang-top strong { font-size: 15px; }
.lang-top span { color: var(--muted); font-size: 12.5px; }
.lang-bar { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.lang-bar i { height: 6px; border-radius: 3px; background: var(--fill); }
.lang-bar i.on { background: var(--accent); }

/* Phones: experience header = logo + title on one line, dates and place underneath (no overlap) */
@media (max-width: 640px) {
    .xp-head { flex-wrap: wrap; gap: 10px 12px; }
    .xp-title { flex: 1 1 calc(100% - 56px); }
    .xp-meta { flex: 1 1 100%; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
}

/* Languages in the profile card */
.side-langs { margin-top: 16px; }
.side-langs ul { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; }
.side-lang-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 5px; }
.side-lang-top strong { font-size: 13.5px; font-weight: 600; }
.side-lang-top span { color: var(--muted); font-size: 12px; }
.side-langs .lang-bar { gap: 3px; }
.side-langs .lang-bar i { height: 5px; }
@media (max-width: 920px) { .side-langs { width: 100%; text-align: left; } }

/* Experience: "Technologies utilisées" below the missions, as a grid of cards */
.xp-body, .xp-body { grid-template-columns: minmax(0, 1fr); gap: 16px; }
.xp-tech { padding-top: 14px; border-top: .5px solid var(--line); }
.xp-tech ul { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; border-radius: 0; overflow: visible; background: none; }
.xp-tech li { align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--card); box-shadow: inset 0 0 0 .5px var(--line); transition: transform .3s var(--ease), box-shadow .2s; }
.xp:hover .xp-tech li { background: var(--card); }
.xp-tech li:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 .5px var(--line), var(--shadow); }
:root[data-theme="dark"] .xp-tech li { background: var(--card-2); }
@media (max-width: 640px) { .xp-tech ul { grid-template-columns: 1fr 1fr; } .xp-tech span { font-size: 11.5px; } }
@media (max-width: 420px) { .xp-tech ul { grid-template-columns: 1fr; } }

/* Experience technologies: compact pills (icon · name · details), wrapping on one or two lines */
.xp-tech { padding-top: 12px; }
.xp-tech .eyebrow { margin-bottom: 8px; }
.xp-tech ul { display: flex; flex-wrap: wrap; gap: 6px; }
.xp-tech li { display: inline-flex; align-items: center; gap: 7px; max-width: 100%; padding: 4px 11px 4px 4px; border-radius: 999px; background: var(--card); box-shadow: inset 0 0 0 .5px var(--line), 0 1px 2px rgba(0, 0, 0, .04); font-size: 12px; line-height: 1.3; }
.xp-tech li:hover { transform: translateY(-1px); box-shadow: inset 0 0 0 .5px var(--line), 0 6px 14px -8px rgba(0, 0, 0, .25); }
.xp-tech li > i { width: 22px; height: 22px; border-radius: 50%; font-size: 12px !important; }
.xp-tech li > div { display: flex; align-items: baseline; gap: 5px; min-width: 0; }
.xp-tech strong { display: inline; font-size: 12px; font-weight: 600; white-space: nowrap; }
.xp-tech span { display: inline; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.xp-tech span::before { content: "·"; margin-right: 5px; color: var(--faint); }
:root[data-theme="dark"] .xp-tech li { background: var(--card-2); }
@media (max-width: 640px) { .xp-tech ul { display: flex; } .xp-tech span { display: none; } }
