/* =====================================================
   YOLANDA SABUCO — Portfolio Website
   Design: Academic, Clean, Professional
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400;1,600&family=Caveat:wght@400;500;600&family=Noto+Sans:ital,wght@0,300;0,400;0,500;0,700;1,400&family=JetBrains+Mono:wght@400;500&display=swap');

/* === VARIABLES === */
:root {
  --bg: #f7f6f2;
  --surface: #ffffff;
  --surface-2: #eeece8;
  --border: rgba(0,0,0,0.09);
  --text: #1a1a1a;
  --text-secondary: #5a5a5a;
  --text-muted: #8a8a8a;
  --accent: #8a5c1a;
  --accent-hover: #7a4f14;
  --accent-warm: #8a5c1a;
  --accent-warm-hover: #7a4f14;
  --accent-warm-light: rgba(138,92,26,0.08);
  --accent-light: rgba(138,92,26,0.08);
  --tag-bg: rgba(0,0,0,0.05);
  --tag-text: #666666;

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Noto Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;

  --banner-height: 36px;
  --nav-height: 64px;
  --max-width: 1100px;
  --max-narrow: 760px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.10);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.14);

  --transition: 200ms ease;
  --transition-slow: 400ms ease;

  /* aliases for ported components */
  --a1: var(--accent);
  --a2: #34d399;
  --a3: var(--accent-warm);
  --muted: var(--text-secondary);
  --fh: var(--font-serif);
  --r: var(--radius-lg);
  --ease: cubic-bezier(.4,0,.2,1);
}

/* === SCROLLBAR === */
::-webkit-scrollbar { width: 3px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 2px; }

/* === RESET === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 2rem;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  display: grid;
  grid-template-columns: 300px 1fr;
  grid-template-rows: 1fr;
  min-height: 100vh;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-warm); }
ul, ol { list-style: none; }

/* === TYPOGRAPHY === */
h1, h2, h3, h4, h5 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
}
h1 { font-size: clamp(3rem, 6vw, 4.8rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -0.015em; }
h3 { font-size: clamp(1.5rem, 2.5vw, 2rem); }
h4 { font-size: 1.2rem; }
p { margin-bottom: 1em; }
p:last-child { margin-bottom: 0; }

code {
  font-family: var(--font-mono);
  font-size: 0.87em;
  background: var(--surface-2);
  padding: 0.15em 0.4em;
  border-radius: var(--radius-sm);
  color: #34d399;
}

pre {
  font-family: var(--font-mono);
  background: #0d1117;
  color: #e6edf3;
  padding: 1.5rem;
  border-radius: var(--radius-md);
  overflow-x: auto;
  font-size: 0.875rem;
  line-height: 1.65;
  margin: 1.5rem 0;
  border: 1px solid #30363d;
}
pre code { background: none; color: inherit; padding: 0; font-size: inherit; }

/* === LAYOUT === */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }
.container--narrow { max-width: var(--max-narrow); }

section { padding: 4.5rem 0; }

.section-label {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 0.92rem;
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--accent-warm);
  margin-bottom: 0.5rem;
}

.section-title { margin-bottom: 2.5rem; }
.section-title h2 { margin-bottom: 0.5rem; }
.section-title p { color: var(--text-secondary); max-width: 580px; }

.divider {
  width: 36px; height: 1px;
  background: var(--accent-warm);
  opacity: 0.4;
  margin: 0.5rem 0 1.75rem;
}

/* === BUTTONS === */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.6rem 1.35rem;
  border-radius: var(--radius-md);
  font-size: 0.88rem; font-weight: 500; font-family: var(--font-sans);
  cursor: pointer; border: 2px solid transparent;
  transition: all var(--transition);
  text-decoration: none; white-space: nowrap;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-hover); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--warm { background: var(--accent-warm); color: #fff; }
.btn--warm:hover { background: var(--accent-warm-hover); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--outline { background: transparent; color: var(--accent); border-color: var(--border); }
.btn--outline:hover { border-color: var(--accent); background: var(--accent-light); color: var(--accent); }

/* === SIDEBAR === */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  scrollbar-width: none;
  z-index: 10;
}
.sidebar::-webkit-scrollbar { display: none; }

.sidebar__inner {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 2.5rem 1.75rem;
  min-height: 100%;
}

.sidebar__photo {
  width: 145px;
  height: 158px;
  object-fit: cover;
  object-position: center top;
  display: block;
  margin-bottom: 0.5rem;
  border-radius: 60% 40% 55% 45% / 50% 55% 45% 60%;
}

.sidebar__status {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  color: #22c55e;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.sidebar__status::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  animation: pulse-green 2s ease-in-out infinite;
}

.sidebar__name {
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 2vw, 2rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--text);
}

.sidebar__role {
  font-size: 0.75rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.sidebar__stats {
  display: flex;
  gap: 1.5rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.sidebar__stat-val {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}
.sidebar__stat-lbl {
  display: block;
  font-size: 0.62rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  line-height: 1.3;
}

.sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.sidebar__nav-link {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 0.42rem 0.65rem;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
  text-decoration: none;
  display: block;
}
.sidebar__nav-link:hover,
.sidebar__nav-link.active {
  color: var(--accent);
  background: var(--accent-light);
}

.sidebar__social {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}
.sidebar__social a {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  transition: all var(--transition);
  flex-shrink: 0;
}
.sidebar__social a:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light);
}

.sidebar__cta {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.btn--sm {
  padding: 0.45rem 1rem;
  font-size: 0.8rem;
}

.sidebar__impressum {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}
.sidebar__impressum a {
  font-size: 0.72rem;
  color: var(--text-muted);
}
.sidebar__impressum a:hover { color: var(--accent); }

/* Mobile toggle button (hidden on desktop) */
.sidebar__mobile-toggle {
  display: none;
  position: fixed;
  top: 1rem; left: 1rem;
  z-index: 200;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.55rem;
  box-shadow: var(--shadow-sm);
}
.sidebar__mobile-toggle span {
  display: block; width: 20px; height: 2px;
  background: var(--text);
  transition: all var(--transition);
}

/* === MAIN CONTENT === */
.main-content {
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  z-index: 1;
}

/* === ANIMATED BACKGROUND CANVAS === */
#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* === INTRO SECTION === */
.intro-section {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  align-items: center;
  padding: 5rem 3.5rem 4rem;
  border-bottom: 1px solid var(--border);
}

/* AI Prompt card */
.intro-section__text {
  background: #111110;
  border: 1px solid rgba(200,150,60,0.25);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 12px 48px rgba(0,0,0,0.28);
}

.intro-prompt-bar {
  display: flex; align-items: center; gap: 0.45rem;
  padding: 0.7rem 1.1rem;
  background: #1c1c1e;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.intro-prompt-dot {
  width: 12px; height: 12px; border-radius: 50%; flex-shrink: 0;
}
.intro-prompt-dot--red    { background: #ff5f57; }
.intro-prompt-dot--yellow { background: #ffbd2e; }
.intro-prompt-dot--green  { background: #28c840; }
.intro-prompt-label {
  margin-left: 0.5rem;
  font-family: var(--font-mono); font-size: 0.7rem;
  color: rgba(255,255,255,0.3); letter-spacing: 0.04em;
}

.intro-prompt-body { padding: 1.6rem 1.8rem; }

.intro-section__text p {
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: rgba(242,230,200,0.88);
  line-height: 1.9;
  margin-bottom: 1rem;
  padding-left: 1.6rem;
  position: relative;
}
.intro-section__text p:last-child { margin-bottom: 0; }
.intro-section__text strong { color: var(--accent); font-weight: 700; }

.intro-prompt-caret {
  position: absolute; left: 0;
  color: var(--accent); font-weight: 700;
  font-size: 1rem; line-height: 1.9;
}

.intro-prompt-cursor {
  color: var(--accent);
  animation: blink-cursor 1s step-end infinite;
  margin-left: 2px;
}
@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

.intro-section__video {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.intro-video-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
}

.intro-video-label {
  font-family: 'Caveat', cursive;
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--text-secondary);
  line-height: 1.3;
  text-align: right;
  transform: rotate(-6deg);
  margin-right: 0.5rem;
  flex-shrink: 0;
}

.intro-video-circle {
  width: 210px;
  height: 210px;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px rgba(138,92,26,0.25), var(--shadow-md);
}

.intro-video-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
  display: block;
}
.intro-video-circle:hover .intro-video-thumb { transform: scale(1.05); }

.intro-video-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.28);
  border: none;
  cursor: pointer;
  transition: background 200ms;
  border-radius: 50%;
}
.intro-video-circle:hover .intro-video-play { background: rgba(0,0,0,0.45); }
.intro-video-play svg {
  width: 52px; height: 52px;
  color: #ffffff;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
  margin-left: 4px;
}

.intro-video-circle iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

@media (max-width: 960px) {
  .intro-section {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .intro-section__video { justify-content: center; }
  .intro-video-wrap {
    flex-direction: column-reverse;
    align-items: center;
    gap: 0.75rem;
  }
  .intro-video-label {
    font-size: 1rem;
    text-align: center;
    transform: rotate(-3deg);
    margin-right: 0;
  }
  .intro-video-circle { width: 180px; height: 180px; }
}

/* === HOBBIES SECTION === */
.hobbies-section {
  padding: 4.5rem 3.5rem;
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.hobbies-inner {
  width: 100%;
}

.hobbies-inner .section-label {
  display: block;
  margin-bottom: 1.6rem;
}

.hobbies-carousel {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.hobbies-viewport {
  flex: 1;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.hobbies-track {
  display: flex;
  gap: 0.75rem;
  transition: transform 0.52s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.hobbies-slide {
  flex: 0 0 calc(33.333% - 0.5rem);
  position: relative;
  height: 240px;
  border-radius: var(--radius);
  overflow: hidden;
}

.hobbies-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.45s ease;
}

.hobbies-slide:hover img { transform: scale(1.06); }

.hobbies-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.8rem 0.9rem 0.6rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.72));
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  text-transform: uppercase;
  color: #fff;
}

.hobbies-label__title {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1;
}

.hobbies-label__sub {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.07em;
  color: rgba(255,255,255,0.75);
  line-height: 1.2;
}

.hobbies-btn {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid rgba(0,0,0,0.22);
  background: #fff;
  color: rgba(0,0,0,0.55);
  font-size: 1.25rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.hobbies-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: #fff;
}

.hobbies-btn:disabled {
  opacity: 0.25;
  cursor: default;
}

@media (max-width: 768px) {
  .hobbies-section { padding: 3.5rem 1.5rem; }
  .hobbies-slide   { height: 180px; }
}

@media (max-width: 768px) {
  .intro-section { padding: 3.5rem 1.5rem 2.5rem; }
}

/* === BLOG CTA BUTTON === */
.blog-cta-wrap {
  position: relative;
  height: 0;
  z-index: 10;
  display: flex;
  justify-content: center;
}

.blog-cta-btn {
  position: absolute;
  top: 0;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 1.4rem 0.6rem 1rem;
  background: #111110;
  color: rgba(242,230,200,0.9);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 100px;
  border: 1px solid rgba(196,134,42,0.45);
  box-shadow: 0 0 0 4px rgba(138,92,26,0.08), 0 4px 20px rgba(0,0,0,0.25);
  text-decoration: none;
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.25s;
}

.blog-cta-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(196,134,42,0.12) 50%, transparent 100%);
  transform: translateX(-100%);
  transition: transform 0.55s ease;
}

.blog-cta-btn:hover::before {
  transform: translateX(100%);
}

.blog-cta-btn:hover {
  border-color: rgba(196,134,42,0.8);
  box-shadow: 0 0 0 4px rgba(138,92,26,0.12), 0 6px 28px rgba(0,0,0,0.3);
  transform: translateY(calc(-50% - 2px));
  color: rgba(242,230,200,1);
}

.blog-cta-btn:active {
  transform: translateY(-50%);
}

.blog-cta-btn__icon {
  width: 14px;
  height: 14px;
  color: var(--accent);
  flex-shrink: 0;
}

.blog-cta-btn__text {
  position: relative;
}

.blog-cta-btn__pip {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  animation: pip-pulse 2s ease-in-out infinite;
}

@keyframes pip-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.7); }
}

/* === AI BANNER === */
.ai-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--banner-height);
  display: flex; align-items: center; justify-content: center; gap: .6rem;
  font-size: .72rem; font-family: var(--font-sans); letter-spacing: .06em;
  text-transform: uppercase; color: rgba(255,255,255,0.88);
  background: linear-gradient(90deg, #7c3aed, #a855f7, #ec4899, #f59e0b, #a855f7, #7c3aed);
  background-size: 300% 100%;
  animation: bannerShift 6s linear infinite;
  overflow: hidden;
}
.ai-banner::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.12) 50%, transparent 100%);
  animation: bannerShimmer 2.4s ease-in-out infinite;
}
.ai-banner__sparkle {
  font-size: .8rem; opacity: .85;
  animation: sparkle 2s ease-in-out infinite alternate;
}
.ai-banner__text strong { font-weight: 700; letter-spacing: .03em; }

@keyframes bannerShift {
  0%   { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}
@keyframes bannerShimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
@keyframes sparkle {
  from { transform: scale(1)   rotate(0deg);   opacity: .7; }
  to   { transform: scale(1.3) rotate(20deg);  opacity: 1; }
}

/* Offset nav + hero when banner is present */
.has-banner .nav           { top: var(--banner-height); }
.has-banner .nav__mobile-menu { top: calc(var(--banner-height) + var(--nav-height)); }
.has-banner .hero          { padding-top: calc(var(--banner-height) + var(--nav-height) + 4.5rem); }
html:has(body.has-banner)  { scroll-padding-top: calc(var(--banner-height) + var(--nav-height)); }

/* === NAVIGATION === */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-height);
  background: rgba(12,12,12,0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.nav.scrolled { border-color: var(--border); box-shadow: var(--shadow-sm); }

.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem;
}

.nav__logo {
  display: flex; align-items: center; gap: 0.7rem;
  font-family: var(--font-serif); font-size: 1.1rem; font-weight: 600;
  color: #f2f2f2;
}
.nav__logo img { height: 34px; width: auto; mix-blend-mode: screen; }

.nav__links { display: flex; align-items: center; gap: 0.15rem; }

.nav__link {
  font-size: 0.82rem; font-weight: 500; color: #a8a8a8;
  padding: 0.35rem 0.65rem; border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}
.nav__link:hover, .nav__link.active { color: #c8963c; background: rgba(200,150,60,0.12); }

.nav__social { display: flex; align-items: center; gap: 0.3rem; margin-left: 0.5rem; }
.nav__social a {
  display: flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent); color: var(--bg);
  transition: background var(--transition), transform var(--transition);
}
.nav__social a:hover { background: var(--accent-hover); transform: scale(1.08); color: var(--bg); }

.nav__hamburger {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; padding: 0.4rem; background: none; border: none;
}
.nav__hamburger span { display: block; width: 22px; height: 2px; background: #f2f2f2; transition: all var(--transition); }

.nav__mobile-menu {
  display: none;
  position: fixed; top: var(--nav-height); left: 0; right: 0;
  background: var(--bg); border-bottom: 1px solid var(--border);
  padding: 1rem 1.5rem; flex-direction: column; gap: 0.25rem;
  box-shadow: var(--shadow-md); z-index: 99;
}
.nav__mobile-menu.open { display: flex; }
.nav__mobile-link {
  padding: 0.6rem 0.75rem; color: var(--text); border-radius: var(--radius-sm);
  font-size: 0.95rem; font-weight: 500; transition: background var(--transition);
}
.nav__mobile-link:hover { background: var(--surface); color: var(--accent); }

/* === HERO === */
.hero {
  padding-top: calc(var(--nav-height) + 4.5rem);
  padding-bottom: 5rem;
  min-height: 92vh;
  display: flex; align-items: center;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 4rem; align-items: center;
}

.hero__open-to-work {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: rgba(34,197,94,0.1); border: 1px solid rgba(34,197,94,0.4);
  color: #22c55e; padding: 0.3rem 0.85rem; border-radius: 100px;
  font-size: 0.78rem; font-weight: 600; margin-bottom: 0.6rem;
  letter-spacing: 0.03em;
}
.hero__open-to-work::before {
  content: ''; width: 6px; height: 6px;
  background: #22c55e; border-radius: 50%;
  animation: pulse-green 2s ease-in-out infinite;
}
@keyframes pulse-green {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.hero__badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--accent-warm-light); border: 1px solid rgba(245,158,11,0.35);
  color: var(--accent-warm); padding: 0.3rem 0.85rem; border-radius: 100px;
  font-size: 0.78rem; font-weight: 600; margin-bottom: 1.25rem;
  letter-spacing: 0.03em;
}
.hero__badge::before {
  content: ''; width: 6px; height: 6px;
  background: var(--accent-warm); border-radius: 50%;
}

.hero__name { font-size: clamp(3.6rem, 7.5vw, 5.8rem); line-height: 1.02; margin-bottom: 0.4rem; letter-spacing: -0.025em; }
.hero__name .accent { color: var(--accent); }

.hero__title {
  font-family: var(--font-serif); font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: var(--text-secondary); font-weight: 400; font-style: italic;
  margin-bottom: 1.5rem;
}

.hero__bio {
  font-size: 1rem; color: var(--text-secondary);
  line-height: 1.75; max-width: 500px; margin-bottom: 1.75rem;
}

.hero__stats { display: flex; gap: 2.5rem; margin-bottom: 2rem; }
.hero__stat-value { font-family: var(--font-serif); font-size: 2.2rem; font-weight: 700; color: var(--accent); line-height: 1; }
.hero__stat-label { font-size: 0.72rem; color: var(--text-muted); margin-top: 0.2rem; }

.hero__cta { display: flex; flex-wrap: wrap; gap: 0.75rem; }



.expertise-intro {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2.5rem;
  align-items: center;
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}
.expertise-intro__photo { flex-shrink: 0; }
.expertise-portrait {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius-lg);
  filter: brightness(0.92) contrast(1.05);
}
.expertise-intro__bio p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}
.expertise-intro__bio p:last-child { margin-bottom: 0; }
.expertise-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2.5rem;
  align-items: start;
}
.expertise-photo {
  position: sticky;
  top: calc(var(--nav-height) + 2rem);
}
.expertise-portrait {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius-lg);
  filter: brightness(0.92) contrast(1.05);
}

.expertise-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  align-items: stretch;
}

.hero__deco {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-shrink: 0;
  overflow: hidden;
}
.hero__deco-text {
  font-family: var(--font-serif);
  font-size: clamp(4.5rem, 9vw, 7.5rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: rgba(138, 92, 26, 0.10);
  text-align: right;
  user-select: none;
  pointer-events: none;
}

.hero__img-wrapper { position: relative; }
.hero__img {
  width: 100%; aspect-ratio: 4/5; object-fit: cover;
  border-radius: var(--radius-lg);
  object-position: center top;
  filter: brightness(0.88) contrast(1.08) saturate(0.92);
  mask-image: radial-gradient(ellipse 78% 88% at 50% 38%, black 48%, transparent 86%);
  -webkit-mask-image: radial-gradient(ellipse 78% 88% at 50% 38%, black 48%, transparent 86%);
}
.hero__img-card {
  position: absolute; bottom: 1.5rem; left: -1.5rem;
  background: var(--bg); border-radius: var(--radius-md);
  padding: 0.8rem 1.1rem; box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}
.hero__img-card-val { font-family: var(--font-serif); font-size: 1.4rem; font-weight: 700; color: var(--accent-warm); line-height: 1; }
.hero__img-card-lbl { font-size: 0.68rem; color: var(--text-muted); margin-top: 0.2rem; }

/* === EXPERTISE === */
.expertise-section {
  background: var(--surface);
  position: relative;
  overflow: hidden;
}
.expertise-section::before {
  content: '';
  position: absolute;
  right: -6%;
  top: 50%;
  transform: translateY(-50%);
  width: 520px;
  height: 520px;
  background: url('../images/logo.png') center / contain no-repeat;
  opacity: 0.07;
  pointer-events: none;
  mix-blend-mode: screen;
}
.expertise-section .container {
  max-width: 1340px;
}

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.expertise-card {
  display: flex; flex-direction: column;
  background: #ffffff;
  border: none;
  border-radius: 20px;
  padding: 2.25rem 2rem 2rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 28px rgba(0,0,0,0.08), 0 1px 4px rgba(0,0,0,0.04);
  transition: transform 300ms ease, box-shadow 300ms ease;
}
/* Decorative glowing circle bottom-right */
.expertise-card::before {
  content: '';
  position: absolute;
  bottom: -55px; right: -55px;
  width: 170px; height: 170px;
  border-radius: 50%;
  pointer-events: none;
  transition: transform 300ms ease;
}
/* Solid color per card */
.expertise-cards .expertise-card:nth-child(1) { background: #c6f0de; }
.expertise-cards .expertise-card:nth-child(2) { background: #f5dfa0; }
.expertise-cards .expertise-card:nth-child(3) { background: #f8c4cb; }
.expertise-cards .expertise-card:nth-child(4) { background: #bfd5f7; }
.expertise-cards .expertise-card:nth-child(1)::before { background: none; }
.expertise-cards .expertise-card:nth-child(2)::before { background: none; }
.expertise-cards .expertise-card:nth-child(3)::before { background: none; }
.expertise-cards .expertise-card:nth-child(4)::before { background: none; }
.expertise-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 64px rgba(0,0,0,0.13), 0 4px 16px rgba(0,0,0,0.06);
}
.expertise-card:hover::before { transform: scale(1.15); }

.expertise-card__icon {
  width: auto; height: auto;
  background: none;
  border-radius: 0;
  display: flex; align-items: center;
  margin-bottom: 1.5rem;
}
.expertise-card__icon svg { width: 38px; height: 38px; }
.expertise-card__icon--blue  { color: #3b82f6; }
.expertise-card__icon--green { color: #22a371; }
.expertise-card__icon--amber { color: var(--accent-warm); }
.expertise-card__icon--rose  { color: #d94f6f; }

.expertise-card__title {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}
.expertise-cards .expertise-card:nth-child(1) .expertise-card__title { color: #1a9e6e; }
.expertise-cards .expertise-card:nth-child(2) .expertise-card__title { color: var(--accent-warm); }
.expertise-cards .expertise-card:nth-child(3) .expertise-card__title { color: #d94f6f; }
.expertise-cards .expertise-card:nth-child(4) .expertise-card__title { color: #2563eb; }
.expertise-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}
.expertise-card__text {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.75;
  margin-top: 0.75rem;
}

/* === EXPERIENCE TIMELINE === */
.exp-timeline {
  max-width: 780px;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}
.exp-timeline::before { display: none; }

.t-item {
  background: #ffffff;
  border-radius: 16px;
  padding: 1.6rem 1.75rem;
  position: relative;
  border-left: 3px solid var(--accent);
  box-shadow: 0 2px 14px rgba(0,0,0,0.05), 0 1px 3px rgba(0,0,0,0.03);
  transition: transform 250ms ease, box-shadow 250ms ease;
}
.t-item:last-child { padding-bottom: 1.6rem; }
.t-item::before { display: none; }
.t-item:hover {
  transform: translateX(6px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.09);
}

.exp-timeline .t-item:nth-child(1) { border-left-color: #22a371; }
.exp-timeline .t-item:nth-child(2) { border-left-color: var(--accent-warm); }
.exp-timeline .t-item:nth-child(3) { border-left-color: #d94f6f; }
.exp-timeline .t-item:nth-child(4) { border-left-color: #3b82f6; }
.exp-timeline .t-item:nth-child(5) { border-left-color: #22a371; }
.exp-timeline .t-item:nth-child(6) { border-left-color: var(--accent-warm); }
.exp-timeline .t-item:nth-child(7) { border-left-color: #d94f6f; }
.exp-timeline .t-item:nth-child(8) { border-left-color: #3b82f6; }

.t-date {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}
.t-company {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.2rem;
  line-height: 1.15;
}
.t-role {
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.7rem;
  letter-spacing: 0.01em;
}
.t-desc { color: var(--text-secondary); font-size: 0.875rem; line-height: 1.72; }

/* === SKILLS — Technical Arsenal === */
.sec-label {
  font-size: .72rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--accent);
  font-family: var(--font-serif); margin-bottom: .65rem;
}
.sec-sub {
  color: var(--text-secondary); max-width: 560px;
  line-height: 1.8; margin-bottom: 3.5rem;
}
/* === SKILLS GRID === */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
@media (max-width: 900px) { .skills-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .skills-grid { grid-template-columns: 1fr; } }

.skill-card {
  background: var(--bg);
  border: 1px solid rgba(200,150,60,0.18);
  border-radius: 12px;
  padding: 1.4rem 1.4rem 1.2rem;
  display: flex; flex-direction: column; gap: .75rem;
  transition: border-color 300ms ease, box-shadow 300ms ease, transform 300ms ease;
  position: relative; overflow: hidden;
}
.skill-card::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at top left, rgba(200,150,60,0.07) 0%, transparent 65%);
  pointer-events: none;
}
.skill-card:hover {
  border-color: rgba(200,150,60,0.55);
  box-shadow: 0 0 22px rgba(200,150,60,0.15), 0 4px 24px rgba(0,0,0,0.35);
  transform: translateY(-3px);
}

.skill-card__icon {
  font-size: 1.5rem; line-height: 1;
}
.skill-card__title {
  font-size: .95rem; font-weight: 700;
  color: var(--accent); letter-spacing: .01em;
  font-family: var(--font-sans); margin: 0;
}
.skill-card__tags {
  display: flex; flex-wrap: wrap; gap: .4rem;
}
.stag {
  font-size: .75rem; font-family: var(--font-sans);
  background: rgba(200,150,60,0.10);
  color: var(--text-secondary);
  border: 1px solid rgba(200,150,60,0.22);
  border-radius: 999px;
  padding: .2rem .65rem;
  white-space: nowrap;
  transition: background 200ms ease, color 200ms ease, border-color 200ms ease;
}
.skill-card:hover .stag {
  background: rgba(200,150,60,0.18);
  color: var(--text);
  border-color: rgba(200,150,60,0.45);
}

/* === REVEAL ANIMATION (.r / .show) === */
.r { opacity: 0; transform: translateY(22px); transition: opacity 600ms var(--ease), transform 600ms var(--ease); }
.r.show { opacity: 1; transform: translateY(0); }
.r.d1 { transition-delay: 80ms; }
.r.d2 { transition-delay: 160ms; }
.r.d3 { transition-delay: 240ms; }
.r.d4 { transition-delay: 320ms; }

/* === SKILLS BENTO === */
.skills-bento {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.skills-domain {
  border-radius: 16px;
  padding: 1.5rem 1.6rem 1.4rem;
  border: 1.5px solid transparent;
}

.skills-domain--health { background: #d4f5e9; border-color: #9de5c8; }
.skills-domain--code   { background: #d6e8fd; border-color: #a4c8f8; }
.skills-domain--infra  { background: #e8e2fd; border-color: #c4b2f8; }

.skills-domain__header {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.skills-domain__icon { font-size: 1rem; line-height: 1; }

.skills-domain__name {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.skills-domain--health .skills-domain__name { color: #065f46; }
.skills-domain--code   .skills-domain__name { color: #1e3a8a; }
.skills-domain--infra  .skills-domain__name { color: #4c1d95; }

.skills-domain__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.skills-domain__grid--wide {
  grid-template-columns: repeat(6, 1fr);
}

.skill-bcard {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  backdrop-filter: blur(4px);
  transition: background 200ms ease, transform 200ms ease;
}

.skill-bcard:hover { background: rgba(255,255,255,0.92); transform: translateY(-2px); }

.skill-bcard__title {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.55rem;
  line-height: 1.2;
}

.skill-bcard__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

/* Domain-coloured tags */
.skills-domain--health .stag {
  background: rgba(16,185,129,0.15);
  border-color: rgba(16,185,129,0.35);
  color: #065f46;
}
.skills-domain--code .stag {
  background: rgba(59,130,246,0.15);
  border-color: rgba(59,130,246,0.35);
  color: #1e3a8a;
}
.skills-domain--infra .stag {
  background: rgba(139,92,246,0.15);
  border-color: rgba(139,92,246,0.35);
  color: #4c1d95;
}

@media (max-width: 900px) {
  .skills-domain__grid { grid-template-columns: repeat(2, 1fr); }
  .skills-domain__grid--wide { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 560px) {
  .skills-domain__grid,
  .skills-domain__grid--wide { grid-template-columns: repeat(2, 1fr); }
  .skills-domain { padding: 1.1rem 1rem; }
  .stag { white-space: normal; word-break: break-word; font-size: 0.7rem; }
}

/* === PROJECTS === */
.projects__grid {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
}

.project-card {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1.8rem 2.2rem;
  background: #ffffff;
  border: none;
  border-bottom: 1px solid var(--border);
  border-left: 6px solid transparent;
  text-decoration: none;
  color: inherit;
  transition: background 220ms var(--ease), border-left-color 220ms var(--ease), transform 220ms var(--ease);
  position: relative;
}
.project-card:last-child { border-bottom: none; }

/* Accent color per row */
.projects__grid .project-card:nth-child(1) { border-left-color: #10b981; }
.projects__grid .project-card:nth-child(2) { border-left-color: #c8963c; }
.projects__grid .project-card:nth-child(3) { border-left-color: #f43f5e; }
.projects__grid .project-card:nth-child(4) { border-left-color: #3b82f6; }
.projects__grid .project-card:nth-child(5) { border-left-color: #8b5cf6; }
.projects__grid .project-card:nth-child(6) { border-left-color: #0d9488; }

/* Hover: tinted background + slight indent */
.projects__grid .project-card:nth-child(1):hover { background: #f0fdf9; }
.projects__grid .project-card:nth-child(2):hover { background: #fef9ee; }
.projects__grid .project-card:nth-child(3):hover { background: #fff1f2; }
.projects__grid .project-card:nth-child(4):hover { background: #eff6ff; }
.projects__grid .project-card:nth-child(5):hover { background: #f5f3ff; }
.projects__grid .project-card:nth-child(6):hover { background: #f0fdfa; }

.project-card:hover { transform: translateX(4px); }

/* Number */
.project-card__num {
  font-family: var(--font-serif);
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1;
  min-width: 3rem;
  flex-shrink: 0;
  letter-spacing: -0.04em;
  transition: opacity 220ms;
}
.projects__grid .project-card:nth-child(1) .project-card__num { color: #10b981; }
.projects__grid .project-card:nth-child(2) .project-card__num { color: #c8963c; }
.projects__grid .project-card:nth-child(3) .project-card__num { color: #f43f5e; }
.projects__grid .project-card:nth-child(4) .project-card__num { color: #3b82f6; }
.projects__grid .project-card:nth-child(5) .project-card__num { color: #8b5cf6; }
.projects__grid .project-card:nth-child(6) .project-card__num { color: #0d9488; }

/* Body */
.project-card__body { flex: 1; min-width: 0; }
.project-card__title {
  font-family: var(--font-serif);
  font-size: 1.18rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  line-height: 1.35;
  color: var(--text);
}
.project-card__desc {
  font-size: 0.83rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  line-height: 1.65;
}
.project-card__tags { display: flex; flex-wrap: wrap; gap: 0.35rem; }

/* Arrow */
.project-card__arrow {
  font-size: 1.5rem;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 220ms var(--ease), color 220ms;
  margin-left: 1rem;
  line-height: 1;
}
.project-card:hover .project-card__arrow { transform: translate(4px, -4px); color: var(--text-secondary); }

.tag {
  background: var(--tag-bg); color: var(--tag-text);
  padding: 0.18rem 0.55rem; border-radius: 100px;
  font-size: 0.7rem; font-weight: 500;
}

/* === EDUCATION === */
.education__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
@media (max-width: 700px) { .education__grid { grid-template-columns: 1fr; } }

.education-card {
  border-radius: 16px;
  padding: 1.8rem 1.7rem 1.6rem;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; gap: 0;
  border: none;
  transition: transform 250ms ease, box-shadow 250ms ease;
}
.education-card:hover { transform: translateY(-5px); box-shadow: 0 12px 40px rgba(0,0,0,0.12); }

.education-card--1 { background: #c6f0de; }
.education-card--2 { background: #f5dfa0; }
.education-card--3 { background: #f8c4cb; }


.education-badge {
  display: inline-block;
  padding: 0.22rem 0.75rem; border-radius: 999px;
  font-size: 0.68rem; font-weight: 800;
  align-self: flex-start; margin-bottom: 1rem;
  font-family: var(--font-sans);
}
.education-card--1 .education-badge { background: rgba(6,95,70,0.18);  color: #065f46; }
.education-card--2 .education-badge { background: rgba(120,53,15,0.18); color: #78350f; }
.education-card--3 .education-badge { background: rgba(159,18,57,0.18); color: #9f1239; }

.education-card__degree {
  font-family: var(--font-serif); font-weight: 700; font-size: 1.25rem;
  line-height: 1.3; color: var(--text); margin-bottom: 0.5rem;
}
.education-card__school {
  font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 0.4rem; line-height: 1.45;
}
.education-card__badge-row {
  display: flex; align-items: center; gap: 0.6rem; margin-bottom: 1rem;
}
.education-card__badge-row .education-badge { margin-bottom: 0; }
.education-card__note {
  font-size: 0.78rem; color: var(--text-muted); font-style: italic;
}

.certs-grid { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.cert-badge {
  display: flex; align-items: center; gap: 0.6rem;
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 0.6rem 0.95rem; font-size: 0.82rem; transition: all var(--transition);
}
.cert-badge:hover { border-color: var(--accent-warm); background: var(--accent-warm-light); }
.cert-badge__icon { font-size: 1.1rem; }
.cert-badge__issuer { font-size: 0.7rem; color: var(--text-muted); }

/* === PUBLICATIONS === */
.publications { background: var(--surface); }
.publications__list { display: flex; flex-direction: column; gap: 1rem; }
.pub-item {
  display: flex; gap: 1.1rem; align-items: flex-start;
  padding: 1.15rem 1.25rem; background: var(--bg);
  border-radius: var(--radius-md); border: 1px solid var(--border);
  transition: all var(--transition);
  text-decoration: none; color: inherit;
}
.pub-item:hover { border-color: var(--accent); background: var(--accent-light); }
.pub-item__year { flex-shrink: 0; font-family: var(--font-serif); font-size: 0.82rem; color: var(--accent-warm); font-weight: 600; min-width: 40px; padding-top: 0.15rem; }
.pub-item__type {
  display: inline-block; background: var(--tag-bg); color: var(--tag-text);
  padding: 0.12rem 0.5rem; border-radius: 100px; font-size: 0.68rem; font-weight: 600;
  margin-bottom: 0.3rem;
}
.pub-item__title { font-weight: 600; font-size: 0.92rem; margin-bottom: 0.2rem; color: var(--text); }
.pub-item__venue { font-size: 0.8rem; color: var(--text-muted); font-style: italic; }

/* === BLOG === */
/* Blog index: transparent background so particles show */
.blog-cards-section { background: transparent; position: relative; z-index: 1; }

.filter-row { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: 2.5rem; }
.filter-btn {
  padding: .45rem 1.15rem; border-radius: 100px;
  border: 2px solid transparent;
  font-family: var(--font-sans); font-size: .78rem; font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer; transition: all 180ms ease;
}
/* Default (inactive) */
.filter-btn[data-filter="all"]               { background: #f5dfa0; color: #78350f; border-color: #e8c96a; }
.filter-btn[data-filter="conferences"]       { background: #d4f5e9; color: #065f46; border-color: #9de5c8; }
.filter-btn[data-filter="interoperability"]  { background: #d6e8fd; color: #1e3a8a; border-color: #a4c8f8; }
.filter-btn[data-filter="security"]          { background: #e8e2fd; color: #4c1d95; border-color: #c4b2f8; }
.filter-btn[data-filter="personal"]          { background: #f8c4cb; color: #9f1239; border-color: #f4a3ac; }
/* Active: darker fill, white text */
.filter-btn[data-filter="all"].active               { background: #c8963c; color: #fff; border-color: #c8963c; }
.filter-btn[data-filter="conferences"].active       { background: #10b981; color: #fff; border-color: #10b981; }
.filter-btn[data-filter="interoperability"].active  { background: #2563eb; color: #fff; border-color: #2563eb; }
.filter-btn[data-filter="security"].active          { background: #8b5cf6; color: #fff; border-color: #8b5cf6; }
.filter-btn[data-filter="personal"].active          { background: #f43f5e; color: #fff; border-color: #f43f5e; }
/* Hover */
.filter-btn[data-filter="all"]:hover               { background: #f0cb6a; }
.filter-btn[data-filter="conferences"]:hover       { background: #b8eeda; }
.filter-btn[data-filter="interoperability"]:hover  { background: #bdd9fc; }
.filter-btn[data-filter="security"]:hover          { background: #d8d0fc; }
.filter-btn[data-filter="personal"]:hover          { background: #f5aab5; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.blog-card {
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-lg); overflow: hidden; cursor: pointer;
  transition: transform 300ms var(--ease), border-color 300ms var(--ease), box-shadow 300ms var(--ease);
  text-decoration: none; color: inherit; display: flex; flex-direction: column;
}
.blog-card:hover { transform: translateY(-5px); border-color: rgba(200,150,60,.25); box-shadow: 0 20px 56px rgba(0,0,0,.45); }
.blog-card[hidden] { display: none; }
.blog-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; transition: transform 400ms var(--ease); }
.blog-card:hover .blog-img { transform: scale(1.04); }
.blog-img-wrap { overflow: hidden; flex-shrink: 0; }
.blog-body { padding: 1.5rem; display: flex; flex-direction: column; flex: 1; }
.blog-meta { display: flex; align-items: center; gap: .6rem; margin-bottom: .85rem; }
.cat-pill {
  padding: .28rem .8rem; border-radius: 100px;
  font-size: .72rem; font-weight: 800;
  font-family: var(--font-sans); letter-spacing: 0.04em;
  border: 1.5px solid transparent;
}
.cat-interoperability { background: #d6e8fd; border-color: #a4c8f8; color: #1e3a8a; }
.cat-conferences      { background: #d4f5e9; border-color: #9de5c8; color: #065f46; }
.cat-security         { background: #e8e2fd; border-color: #c4b2f8; color: #4c1d95; }
.cat-personal         { background: #f8c4cb; border-color: #f4a3ac; color: #9f1239; }
.blog-date { font-size: .75rem; color: var(--text-secondary); font-family: var(--font-serif); }
.blog-title { font-family: var(--font-serif); font-weight: 700; font-size: 1.08rem; line-height: 1.4; margin-bottom: auto; }
.blog-read {
  display: inline-flex; align-items: center; gap: .35rem; margin-top: 1.25rem;
  font-family: var(--font-serif); font-size: .78rem; font-weight: 700;
  color: var(--accent); text-decoration: none; transition: gap 200ms;
}
.blog-card:hover .blog-read { gap: .55rem; }
.blog-read svg { width: 13px; height: 13px; }

/* === FSH TUTORIAL CALLOUT === */
.tut-callout {
  position: relative;
  overflow: hidden;
  padding: 6rem 0;
  background: linear-gradient(135deg, #8a6020 0%, #c8963c 45%, #b5832f 100%);
}
.tut-callout__sphere {
  position: absolute;
  right: -5%;
  top: 50%;
  transform: translateY(-50%);
  width: 600px;
  height: 600px;
  background: url('../images/logo.png') center / contain no-repeat;
  opacity: 0.18;
  mix-blend-mode: screen;
  pointer-events: none;
}
.tut-callout__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4rem;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.tut-callout__content { flex: 1; min-width: 280px; }
.tut-callout__label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  margin-bottom: 1rem;
}
.tut-callout__title {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.05;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}
.tut-callout__desc {
  font-size: 1rem;
  color: rgba(255,255,255,0.78);
  line-height: 1.75;
  max-width: 500px;
  margin-bottom: 2rem;
}
.tut-callout__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: #1a1a1a;
  color: #ffffff;
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius-md);
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 200ms, transform 200ms, box-shadow 200ms;
  box-shadow: 0 4px 18px rgba(0,0,0,0.35);
}
.tut-callout__cta:hover {
  background: #000;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0,0,0,0.5);
}
.tut-callout__stats {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.tut-callout__stat {
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.6rem;
  min-width: 180px;
  backdrop-filter: blur(8px);
  transition: background 200ms, border-color 200ms;
}
.tut-callout__stat:hover {
  background: rgba(0,0,0,0.35);
  border-color: rgba(255,255,255,0.28);
}
.tut-callout__stat-val {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
  margin-bottom: 0.3rem;
}
.tut-callout__stat-lbl {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.03em;
}

/* === FSH CALLOUT (homepage banner) === */
.fsh-callout {
  background: var(--surface);
  position: relative;
  overflow: hidden;
  padding: 5.5rem 0;
}
.fsh-callout::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 90% at 0% 50%, rgba(200,150,60,0.13) 0%, transparent 65%),
    radial-gradient(ellipse 50% 60% at 100% 30%, rgba(200,150,60,0.07) 0%, transparent 60%);
  pointer-events: none;
}
.fsh-callout__inner {
  display: flex;
  align-items: center;
  gap: 3.5rem;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.fsh-callout__content {
  flex: 1;
  min-width: 280px;
}
.fsh-callout__eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.fsh-callout__title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 700;
  color: var(--text);
  line-height: 1.1;
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}
.fsh-callout__title span { color: var(--accent); }
.fsh-callout__desc {
  color: var(--text-secondary);
  max-width: 460px;
  margin-bottom: 1.75rem;
  line-height: 1.75;
  font-size: 0.97rem;
}
.fsh-callout__badges {
  display: flex;
  gap: 0.875rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}
.fsh-callout__badge {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.7rem 1.1rem;
  min-width: 80px;
  text-align: center;
  transition: border-color var(--transition);
}
.fsh-callout__badge:hover { border-color: var(--accent); }
.fsh-callout__badge-val {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}
.fsh-callout__badge-lbl {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  letter-spacing: 0.02em;
}
/* code editor window */
.fsh-callout__window {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
  background: #0d1117;
  border: 1px solid #30363d;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow:
    var(--shadow-lg),
    0 0 0 1px rgba(200,150,60,0.15),
    0 0 50px rgba(200,150,60,0.08);
}
.fsh-window-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.625rem 1rem;
  background: #161b22;
  border-bottom: 1px solid #30363d;
}
.fsh-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  flex-shrink: 0;
}
.fsh-dot--r { background: #ff5f57; }
.fsh-dot--y { background: #febc2e; }
.fsh-dot--g { background: #28c840; }
.fsh-window-bar__name {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #8b949e;
  margin-left: 0.5rem;
}
.fsh-window-body {
  margin: 0;
  padding: 1.25rem 1.5rem;
  background: #0d1117;
  border: none;
  border-radius: 0;
  font-size: 0.8rem;
  line-height: 1.75;
  overflow-x: auto;
}
/* FSH syntax tokens */
.fsh-kw   { color: #ff7b72; }
.fsh-val  { color: #79c0ff; }
.fsh-id   { color: #d2a8ff; }
.fsh-str  { color: #a5d6ff; }
.fsh-card { color: #f2cc60; }
.fsh-flag { color: #c8963c; }
.fsh-bullet { color: #8b949e; }
.fsh-url  { color: #79c0ff; }

/* === CONTACT === */
.contact { background: var(--surface); }
.contact__inner { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.contact__desc { color: var(--text-secondary); margin-bottom: 2rem; font-size: 0.97rem; }
.contact__links { display: flex; flex-direction: column; gap: 0.65rem; }
.contact__link {
  display: flex; align-items: center; gap: 0.85rem;
  padding: 0.8rem 1rem; background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius-md); color: var(--text); transition: all var(--transition);
}
.contact__link:hover { border-color: var(--accent); background: var(--accent-light); color: var(--accent); transform: translateX(4px); }
.contact__link-icon {
  width: 36px; height: 36px; background: var(--accent-warm-light);
  border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0;
}
.contact__link-label { font-size: 0.7rem; color: var(--text-muted); margin-bottom: 0.1rem; }
.contact__link-text { font-size: 0.88rem; }

/* === FOOTER === */
.footer { background: var(--surface); color: var(--text-secondary); padding: 2rem 0 1.5rem; border-top: 1px solid var(--border); }
.footer__inner { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 2.5rem; margin-bottom: 2.5rem; }
.footer__logo { font-family: var(--font-serif); font-size: 1.15rem; color: white; margin-bottom: 0.3rem; font-weight: 600; }
.footer__tagline { font-size: 0.78rem; color: rgba(255,255,255,0.4); max-width: 320px; line-height: 1.5; }
.footer__socials { display: flex; gap: 1rem; margin-top: 1.1rem; }
.footer__social-link {
  color: rgba(255,255,255,0.35); transition: color var(--transition);
  display: flex; align-items: center;
}
.footer__social-link:hover { color: var(--accent); }
.footer__links { display: flex; flex-direction: column; gap: 0.6rem; align-items: flex-end; }
.footer__link { color: rgba(255,255,255,0.45); font-size: 0.82rem; transition: color var(--transition); }
.footer__link:hover { color: white; }
.footer__copyright { text-align: center; font-size: 0.73rem; color: var(--text-muted); padding-top: 0; }

/* === BACK TO TOP === */
.back-to-top {
  position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 50;
  width: 40px; height: 40px; background: var(--accent); color: white;
  border: none; border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md); opacity: 0; transform: translateY(10px);
  pointer-events: none; transition: all var(--transition);
}
.back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { background: var(--accent-warm); transform: translateY(-2px); }

/* === REVEAL ANIMATIONS === */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }
.reveal-d4 { transition-delay: 0.4s; }

/* =====================================================
   BLOG PAGES
   ===================================================== */
/* === BLOG POST — full-width override for body grid === */
.blog-hero,
.post-body,
body > .footer {
  grid-column: 1 / -1;
}

/* Nav: light style on all blog pages */
body:has(.blog-hero) .nav,
body:has(.blog-cards-section) .nav {
  background: rgba(247,246,242,0.96);
  border-bottom: 1px solid var(--border);
}
body:has(.blog-hero) .nav__link,
body:has(.blog-cards-section) .nav__link { color: var(--text-secondary); }
body:has(.blog-hero) .nav__link:hover,
body:has(.blog-hero) .nav__link.active,
body:has(.blog-cards-section) .nav__link:hover,
body:has(.blog-cards-section) .nav__link.active { color: var(--accent); background: var(--accent-light); }
body:has(.blog-hero) .nav__social a,
body:has(.blog-cards-section) .nav__social a { background: var(--accent); color: #fff; }
body:has(.blog-hero) .nav__social a:hover,
body:has(.blog-cards-section) .nav__social a:hover { background: var(--accent-hover); }
body:has(.blog-hero) .nav__hamburger span,
body:has(.blog-cards-section) .nav__hamburger span { background: var(--text); }

.blog-hero {
  padding-top: calc(var(--nav-height) + 3.5rem);
  padding-bottom: 3rem;
  background: var(--surface);
  border-bottom: 3px solid var(--accent);
}

.post-back {
  font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--text-muted);
  display: inline-flex; align-items: center; gap: 0.35rem;
  margin-bottom: 1.5rem; text-decoration: none;
  transition: color 200ms, gap 200ms;
}
.post-back:hover { color: var(--accent); gap: 0.55rem; }

.post-cat {
  display: inline-flex; align-items: center;
  font-size: 0.68rem; font-weight: 800;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: 0.28rem 0.85rem; border-radius: 999px;
  margin-bottom: 1.1rem;
  background: rgba(138,92,26,0.15); color: #78350f;
  border: 1.5px solid rgba(138,92,26,0.3);
}
/* Category colour overrides */
.post-cat[data-cat="conferences"]    { background: #d4f5e9; color: #065f46; border-color: #9de5c8; }
.post-cat[data-cat="interoperability"]{ background: #d6e8fd; color: #1e3a8a; border-color: #a4c8f8; }
.post-cat[data-cat="personal"]       { background: #f8c4cb; color: #9f1239; border-color: #f4a3ac; }
.post-cat[data-cat="security"]       { background: #e8e2fd; color: #4c1d95; border-color: #c4b2f8; }

.post-title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.15; margin-bottom: 1.25rem;
  max-width: 820px; font-family: var(--font-serif);
  font-weight: 700; letter-spacing: -0.01em;
}
.post-meta { display: flex; flex-wrap: wrap; gap: 1rem; font-size: 0.83rem; color: var(--text-muted); align-items: center; }
.post-meta-item { display: flex; align-items: center; gap: 0.3rem; }

.post-img {
  width: 100%; max-height: 480px; object-fit: cover;
  border-radius: var(--radius-lg); margin: 2rem 0;
  box-shadow: 0 8px 40px rgba(0,0,0,0.12);
}

.post-body { padding: 2.5rem 0 5rem; }
.post-body__inner { max-width: 720px; margin: 0 auto; padding: 0 1.5rem; }
.post-body__inner h2 {
  font-size: 1.6rem; font-family: var(--font-serif); font-weight: 700;
  margin: 2.5rem 0 0.8rem; padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent);
}
.post-body__inner h3 { font-size: 1.25rem; color: var(--accent); margin: 1.75rem 0 0.5rem; }
.post-body__inner h4 { font-size: 1.05rem; margin: 1.25rem 0 0.4rem; }
.post-body__inner p { color: var(--text-secondary); line-height: 1.85; margin-bottom: 1.25rem; font-size: 1.01rem; }
.post-body__inner ul, .post-body__inner ol { padding-left: 0; margin-bottom: 1.4rem; color: var(--text-secondary); list-style: none; }
.post-body__inner li {
  margin-bottom: 0.9rem; line-height: 1.75; font-size: 1.01rem;
  padding-left: 1.4rem; position: relative;
}
.post-body__inner ul li::before {
  content: '';
  position: absolute; left: 0; top: 0.65em;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
}
.post-body__inner ol { counter-reset: li; }
.post-body__inner ol li { counter-increment: li; }
.post-body__inner ol li::before {
  content: counter(li);
  position: absolute; left: 0; top: 0.05em;
  font-size: 0.75rem; font-weight: 800;
  color: var(--accent); font-family: var(--font-sans);
}
.post-body__inner blockquote {
  margin: 2rem 0; padding: 1.25rem 1.6rem;
  border-left: 5px solid var(--accent);
  background: #fef9ee; border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  font-style: italic; color: var(--text); font-size: 1.05rem; line-height: 1.7;
}
.post-body__inner a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.post-body__inner img { border-radius: var(--radius-md); margin: 1.5rem 0; box-shadow: var(--shadow-md); }

.ref-box {
  background: #fef9ee; border: 1.5px solid rgba(138,92,26,0.25);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 1rem 1.3rem; margin: 1.4rem 0; font-size: 0.875rem; color: var(--text-secondary);
}
.ref-box cite { font-style: normal; font-weight: 600; color: var(--text); }

.author-box {
  background: var(--bg); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem; display: flex; gap: 1.2rem;
  align-items: flex-start; margin-top: 3rem;
}
.author-box__avatar { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; flex-shrink: 0; object-position: top; }
.author-box__name { font-weight: 700; margin-bottom: 0.2rem; font-family: var(--font-serif); font-size: 1.05rem; }
.author-box__desc { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 0.65rem; line-height: 1.6; }
.author-box__links { display: flex; gap: 0.7rem; }
.author-box__links a { font-size: 0.8rem; color: var(--text-muted); }
.author-box__links a:hover { color: var(--accent); }

.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2.5rem; padding-top: 2.5rem; border-top: 2px solid var(--border); }
.post-nav__item {
  padding: 1.1rem 1.25rem; background: var(--surface);
  border: 1.5px solid var(--border); border-radius: var(--radius-lg);
  transition: all 220ms var(--ease); border-left: 5px solid var(--accent);
}
.post-nav__item:hover { border-color: var(--accent); background: #fef9ee; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.post-nav__item--next { border-left: 1.5px solid var(--border); border-right: 5px solid var(--accent); text-align: right; }
.post-nav__item--next:hover { border-color: var(--accent); }
.post-nav__lbl { font-size: 0.68rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 0.3rem; }
.post-nav__title { font-family: var(--font-serif); font-size: 0.95rem; color: var(--text); line-height: 1.4; }

/* === BLOG LISTING PAGE === */
.blog-index-hero { padding-top: calc(var(--nav-height) + 3rem); padding-bottom: 2rem; background: var(--surface); border-bottom: 1px solid var(--border); }

.blog-index-header {
  padding-top: calc(var(--nav-height) + 4rem);
  padding-bottom: 2rem;
  padding-left: 2rem;
  padding-right: 1.5rem;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  min-height: 100vh;
  position: relative;
  z-index: 1;
}
.blog-filter { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-bottom: 2.5rem; }
.blog-filter__btn {
  padding: 0.38rem 0.95rem; border-radius: 100px; font-size: 0.8rem; font-weight: 500;
  background: var(--surface); color: var(--text-secondary); border: 1px solid var(--border);
  cursor: pointer; transition: all var(--transition);
}
.blog-filter__btn:hover { border-color: var(--accent); color: var(--accent); }
.blog-filter__btn.active { background: var(--accent); color: white; border-color: var(--accent); }

/* =====================================================
   FSH TUTORIAL — CARD NAVIGATION
   ===================================================== */
.tut-page { padding: calc(var(--nav-height) + 2.5rem) 0 5rem; }

.tut-header { text-align: center; max-width: 700px; margin: 0 auto 3rem; padding: 0 1.5rem; }
.tut-header__cover { width: 100%; max-height: 300px; object-fit: contain; border-radius: var(--radius-lg); margin-bottom: 2rem; }
.tut-header__title { font-size: clamp(1.6rem, 3.5vw, 2.3rem); margin-bottom: 0.6rem; }
.tut-header__meta { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 1.5rem; }
.tut-header__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.75rem; }

.tut-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 1.25rem;
  padding: 0 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.tut-card {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 1.5rem 1.5rem 1.25rem;
  cursor: pointer; transition: all var(--transition);
  display: flex; flex-direction: column; gap: 0.5rem;
  position: relative; overflow: hidden;
  text-align: left;
}
.tut-card::before {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-warm));
  transform: scaleX(0); transform-origin: left; transition: transform var(--transition);
}
.tut-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); border-color: var(--accent); }
.tut-card:hover::before { transform: scaleX(1); }
.tut-card--highlight { background: var(--accent); border-color: var(--accent); color: white; }
.tut-card--highlight::before { display: none; }
.tut-card--highlight:hover { background: var(--accent-hover); }
.tut-card--highlight .tut-card__num, .tut-card--highlight .tut-card__desc { color: rgba(255,255,255,0.75); }
.tut-card--highlight .tut-card__title { color: white; }

.tut-card__icon { font-size: 1.75rem; }
.tut-card__num { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-warm); }
.tut-card__title { font-family: var(--font-serif); font-size: 1.15rem; font-weight: 600; line-height: 1.25; color: #ffffff; }
.tut-card__desc { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; flex: 1; }
.tut-card__arrow { align-self: flex-end; font-size: 0.9rem; color: var(--accent-warm); margin-top: 0.5rem; }
.tut-card--highlight .tut-card__arrow { color: var(--accent-warm); }

/* Section view */
.tut-section-view { display: none; max-width: 760px; margin: 0 auto; padding: 0 1.5rem; }
.tut-section-view.active { display: block; animation: fadeIn 0.3s ease; }

.tut-back {
  display: inline-flex; align-items: center; gap: 0.4rem;
  font-size: 0.82rem; color: var(--text-muted); cursor: pointer;
  padding: 0.4rem 0.8rem; border: 1px solid var(--border); border-radius: 100px;
  background: var(--surface); transition: all var(--transition); margin-bottom: 2rem;
  font-family: var(--font-sans);
}
.tut-back:hover { color: var(--accent); border-color: var(--accent); background: var(--accent-light); }

.tut-section-view h2 { font-size: 1.7rem; margin-bottom: 0.5rem; }
.tut-section-view h3 { font-size: 1.2rem; color: var(--accent); margin: 1.5rem 0 0.5rem; }
.tut-section-view h4 { font-size: 0.95rem; font-weight: 600; margin: 1.2rem 0 0.35rem; }
.tut-section-view p { color: var(--text-secondary); line-height: 1.78; margin-bottom: 1.1rem; }
.tut-section-view ul, .tut-section-view ol { padding-left: 1.5rem; margin-bottom: 1rem; color: var(--text-secondary); }
.tut-section-view ul { list-style: disc; }
.tut-section-view ol { list-style: decimal; }
.tut-section-view li { margin-bottom: 0.4rem; line-height: 1.65; }
.tut-section-view a { text-decoration: underline; text-underline-offset: 3px; }
.tut-section-view blockquote {
  font-style: italic; color: var(--accent); border-left: 3px solid var(--accent-warm);
  padding-left: 1.2rem; margin: 1.25rem 0;
}

.tut-section-img { width: 100%; border-radius: var(--radius-md); margin: 1.25rem 0; box-shadow: var(--shadow-md); border: 1px solid var(--border); }
.tut-section-img-caption { text-align: center; font-size: 0.78rem; color: var(--text-muted); margin-top: -0.75rem; margin-bottom: 1.25rem; font-style: italic; }

.tut-nav {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--border);
  flex-wrap: wrap; gap: 1rem;
}
.tut-nav__btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.55rem 1rem; border-radius: var(--radius-md);
  border: 1px solid var(--border); background: var(--surface);
  font-size: 0.82rem; font-weight: 500; cursor: pointer;
  transition: all var(--transition); font-family: var(--font-sans); color: var(--text);
}
.tut-nav__btn:hover { border-color: var(--accent); background: var(--accent-light); color: var(--accent); }
.tut-nav__btn--primary { background: var(--accent); color: white; border-color: var(--accent); }
.tut-nav__btn--primary:hover { background: var(--accent-hover); color: white; }

/* Exercise sub-cards */
.ex-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; margin: 1.5rem 0; }
.ex-card {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 1.25rem; cursor: pointer; transition: all var(--transition);
}
.ex-card:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.ex-card__num { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-warm); margin-bottom: 0.3rem; }
.ex-card__title { font-family: var(--font-serif); font-size: 0.98rem; }

/* FSH TUTORIAL — OLD LAYOUT (kept for backward compat if needed) === */
.tut-layout {
  display: grid; grid-template-columns: 260px 1fr; gap: 3rem;
  max-width: var(--max-width); margin: 0 auto;
  padding: calc(var(--nav-height) + 2.5rem) 1.5rem 5rem;
}

.tut-toc {
  position: sticky; top: calc(var(--nav-height) + 1.5rem);
  height: fit-content; max-height: calc(100vh - var(--nav-height) - 3rem);
  overflow-y: auto;
}
.tut-toc__title { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 0.65rem; }
.tut-toc__list { list-style: none; padding: 0; }
.tut-toc__item { margin-bottom: 0.2rem; }
.tut-toc__link {
  display: block; padding: 0.28rem 0.6rem; font-size: 0.8rem;
  color: var(--text-secondary); border-left: 2px solid var(--border);
  transition: all var(--transition);
}
.tut-toc__link:hover, .tut-toc__link.active { color: var(--accent); border-left-color: var(--accent); background: var(--accent-light); }
.tut-toc__link--sub { padding-left: 1.2rem; font-size: 0.76rem; }

.tut-content h2 {
  font-size: 1.75rem; border-bottom: 2px solid var(--border);
  padding-bottom: 0.45rem; margin: 2.5rem 0 1rem;
}
.tut-content h2:first-child { margin-top: 0; }
.tut-content h3 { font-size: 1.25rem; color: var(--accent); margin: 1.75rem 0 0.55rem; }
.tut-content h4 { font-size: 1rem; margin: 1.2rem 0 0.4rem; }
.tut-content p { color: var(--text-secondary); line-height: 1.78; margin-bottom: 1.1rem; }
.tut-content ul, .tut-content ol { padding-left: 1.5rem; margin-bottom: 1rem; color: var(--text-secondary); }
.tut-content ul { list-style: disc; }
.tut-content ol { list-style: decimal; }
.tut-content li { margin-bottom: 0.4rem; line-height: 1.65; }
.tut-content a { text-decoration: underline; text-underline-offset: 3px; }

.exercise {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); margin: 2rem 0; overflow: hidden;
}
.exercise__header {
  background: var(--accent); color: white; padding: 0.9rem 1.4rem;
  display: flex; align-items: center; gap: 0.7rem;
}
.exercise__num {
  background: var(--accent-warm); color: white; width: 26px; height: 26px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 0.82rem; font-weight: 700; flex-shrink: 0;
}
.exercise__title { font-family: var(--font-sans); font-size: 0.92rem; font-weight: 600; }
.exercise__body { padding: 1.4rem; }
.exercise__body p { font-size: 0.88rem; color: var(--text-secondary); margin-bottom: 0.7rem; }
.exercise__body h4 { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin: 0.9rem 0 0.35rem; }

.code-wrap { position: relative; margin: 0.75rem 0; }
.code-copy {
  position: absolute; top: 0.5rem; right: 0.5rem;
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.7); padding: 0.22rem 0.55rem;
  border-radius: var(--radius-sm); font-size: 0.68rem; cursor: pointer;
  transition: all var(--transition); font-family: var(--font-sans);
}
.code-copy:hover { background: rgba(255,255,255,0.2); color: white; }

.sol-links { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-top: 0.7rem; }
.sol-link {
  display: inline-flex; align-items: center; gap: 0.3rem;
  background: var(--accent-warm-light); color: var(--accent-warm); border: 1px solid rgba(245,158,11,0.35);
  padding: 0.28rem 0.65rem; border-radius: 100px; font-size: 0.75rem; font-weight: 500;
  transition: all var(--transition);
}
.sol-link:hover { background: var(--accent-warm); color: white; border-color: var(--accent-warm); }

.info-box {
  background: var(--accent-light); border: 1px solid rgba(200,150,60,0.4);
  border-radius: var(--radius-md); padding: 0.9rem 1.15rem;
  margin: 1rem 0; font-size: 0.875rem; color: var(--accent);
}
.info-box strong { display: block; margin-bottom: 0.2rem; }

.concepts {
  background: var(--accent-warm-light); border: 1px solid rgba(245,158,11,0.35);
  border-radius: var(--radius-md); padding: 0.9rem 1.15rem; margin: 0.75rem 0;
}
.concepts h4 { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-warm); margin-bottom: 0.45rem; }
.concepts li { font-size: 0.83rem; color: rgba(245,158,11,0.85); padding: 0.18rem 0; display: flex; align-items: center; gap: 0.45rem; list-style: none; }
.concepts li::before { content: '✓'; color: var(--accent-warm); font-weight: 700; }

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 1100px) {
  body { grid-template-columns: 260px 1fr; }
}

@media (max-width: 960px) {
  .hero__inner { grid-template-columns: 1fr; text-align: center; }
  .hero__img-wrapper { order: -1; max-width: 260px; margin: 0 auto; }
  .hero__bio, .hero__cta, .hero__stats { justify-content: center; }
  .hero__bio { margin: 0 auto 1.75rem; }
  .hero__deco { display: none; }
  .contact__inner { grid-template-columns: 1fr; }
  .tut-layout { grid-template-columns: 1fr; }
  .tut-toc { display: none; }
  .expertise-grid { grid-template-columns: repeat(2, 1fr); }
  .expertise-layout { grid-template-columns: 160px 1fr; gap: 1.75rem; }
}

@media (max-width: 768px) {
  body { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }

  .sidebar {
    position: fixed;
    top: 0; left: 0;
    width: 280px;
    height: 100vh;
    transform: translateX(-100%);
    transition: transform 300ms ease;
    z-index: 150;
    box-shadow: var(--shadow-lg);
  }
  .sidebar.open { transform: translateX(0); }

  .sidebar__mobile-toggle { display: flex; }

  .main-content { grid-column: 1; padding-top: 0; }

  .content-intro { padding: 4rem 1.5rem 2.5rem; }
  .content-intro__text { font-size: clamp(1.6rem, 6vw, 2.2rem); }

  /* Intro section */
  .intro-section { padding: 2.5rem 1.25rem 2rem; }
  .intro-prompt-body { padding: 1.2rem 1.2rem; }
  .intro-section__text p { font-size: 0.84rem; }

  /* Blog CTA */
  .blog-cta-btn { font-size: 0.65rem; padding: 0.5rem 1rem 0.5rem 0.8rem; gap: 0.5rem; }

  /* Hobbies */
  .hobbies-section { padding: 3rem 1.25rem; }
  .hobbies-slide   { height: 200px; }

  /* Expertise cards */
  .expertise-card  { padding: 1.1rem 1rem; }
  .expertise-section .container { padding: 0 1.25rem; }

  /* Section titles */
  .section-label { font-size: 0.7rem; }
}

@media (max-width: 480px) {
  .expertise-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  :root { --space-section: 3.5rem; }
  section { padding: 3.5rem 0; }
  .nav__links, .nav__social { display: none; }
  .nav__hamburger { display: flex; }
  .blog-grid { grid-template-columns: 1fr; }
  .project-card { gap: 1rem; padding: 1.3rem 1.2rem; }
  .project-card__num { font-size: 2.2rem; min-width: 2.2rem; }
  .project-card__arrow { font-size: 1.1rem; margin-left: 0.5rem; }
  .post-nav { grid-template-columns: 1fr; }
  .footer__inner { flex-direction: column; gap: 1.5rem; }
  /* Who I Am — mobile: stack photo above cards */
  .expertise-layout { grid-template-columns: 1fr; }
  .expertise-photo { position: static; max-width: 200px; margin: 0 auto 1.5rem; }
  .expertise-portrait { aspect-ratio: 1/1; object-position: center 20%; }
  .expertise-cards { grid-template-columns: 1fr; }
  .expertise-cards .expertise-card:nth-child(even) { margin-top: 0; }
}

@media (max-width: 480px) {
  .hero__stats { flex-direction: column; align-items: center; gap: 1rem; }
  .hero__cta { flex-direction: column; align-items: center; }
  .tut-layout { padding-left: 1rem; padding-right: 1rem; }
  .expertise-grid { grid-template-columns: 1fr; }
  .expertise-photo { max-width: 160px; }
  .expertise-cards { grid-template-columns: 1fr; }

  /* Intro section */
  .intro-section { padding: 2rem 1rem 1.75rem; gap: 1.75rem; }
  .intro-section__text p { font-size: 0.8rem; line-height: 1.75; }

  /* Hobbies */
  .hobbies-section { padding: 2.5rem 1rem; }
  .hobbies-slide   { height: 220px; border-radius: 8px; }
  .hobbies-btn     { width: 28px; height: 28px; font-size: 1.1rem; }

  /* Blog CTA */
  .blog-cta-btn { font-size: 0.62rem; letter-spacing: 0.07em; padding: 0.45rem 0.9rem 0.45rem 0.7rem; }
}
