:root {
  --bg: #0b0d10;
  --bg-2: #101318;
  --panel: #14181e;
  --panel-2: #1a1f27;
  --line: #242b35;
  --line-2: #313a46;
  --text: #e9ecf1;
  --muted: #8a94a3;
  --accent: #ff6a2b;
  --accent-2: #ffb36b;
  --gd: #7cc4ff;
  --d3: #b892ff;
  --ok: #6fe3a1;
  --radius: 14px;
  --font: "Manrope", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --display: "Unbounded", "Manrope", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --wrap: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: .28;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 80%);
}
body.locked { overflow: hidden; }
[hidden] { display: none !important; }
a { color: inherit; }
img { display: block; max-width: 100%; }
.mono { font-family: var(--mono); font-size: .82em; letter-spacing: -.01em; }
.muted { color: var(--muted); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
@media (max-width: 640px) { .wrap { padding: 0 16px; } }

.topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 24px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-mark {
  display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px;
  background: var(--accent); color: var(--bg); font: 700 13px var(--mono);
}
.logo-name { font: 500 14px var(--mono); color: var(--muted); }
.nav { display: flex; gap: 2px; margin-left: auto; }
.nav a {
  position: relative; text-decoration: none; font-size: 14px; font-weight: 600; color: var(--muted); white-space: nowrap;
  padding: 8px 11px; border-radius: 8px; transition: color .2s, background .2s;
}
.nav a:hover { color: var(--text); background: var(--panel); }
.nav a.active { color: var(--text); background: var(--panel-2); }
.nav a.active::after { content: ""; position: absolute; left: 11px; right: 11px; bottom: 3px; height: 2px; border-radius: 2px; background: var(--accent); }
.topbar-right { display: flex; align-items: center; gap: 10px; }
.lang { display: flex; padding: 3px; gap: 2px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--panel); }
.lang button {
  border: 0; background: transparent; color: var(--muted); cursor: pointer;
  font: 600 12px var(--mono); padding: 5px 8px; border-radius: 6px; transition: color .2s, background .2s;
}
.lang button:hover { color: var(--text); }
.lang button[aria-pressed="true"] { background: var(--accent); color: #140802; }
.progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 60; pointer-events: none; }
.progress span { display: block; height: 100%; width: 0; background: var(--accent); }
@media (max-width: 960px) {
  .topbar { flex-wrap: wrap; padding: 10px 16px 0; gap: 8px 12px; }
  .logo-name { display: none; }
  .nav {
    order: 3; width: calc(100% + 32px); margin: 0 -16px; padding: 4px 12px 8px;
    overflow-x: auto; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 24px), transparent);
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { padding: 6px 10px; font-size: 13px; }
  .topbar-right { margin-left: auto; }
}

.hero {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center;
  padding-top: 88px; padding-bottom: 56px;
}
.id-card { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; }
.id-card .eyebrow { margin: 0; }
.id-name { margin: 0 0 4px; font: 700 18px var(--display); letter-spacing: -.02em; }
.avatar {
  position: relative; flex: none; width: 72px; height: 72px; border-radius: 18px; overflow: hidden;
  display: grid; place-items: center; background: var(--panel-2); border: 2px solid var(--accent);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 14%, transparent);
}
.avatar span { font: 700 20px var(--mono); color: var(--accent); }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 640px) { .avatar { width: 60px; height: 60px; border-radius: 15px; } .id-name { font-size: 16px; } }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 20px; font: 500 13px var(--mono); color: var(--muted); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 20%, transparent); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px color-mix(in srgb, var(--ok) 5%, transparent); } }
h1 {
  font: 800 clamp(38px, 6vw, 72px)/1.02 var(--display);
  letter-spacing: -.035em; margin: 0 0 24px;
}
.accent { color: var(--accent); }
.lead { font-size: 18px; color: #c3cad5; max-width: 560px; margin: 0 0 24px; }
.role-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-bottom: 28px; font-size: 13px; color: var(--muted); }
.chip-label { margin-right: 10px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border-radius: 10px;
  border: 1px solid var(--line-2); background: var(--panel); color: var(--text);
  font: 600 14px var(--font); text-decoration: none; cursor: pointer;
  transition: transform .15s, border-color .2s, background .2s;
}
.btn:hover { border-color: var(--muted); transform: translateY(-1px); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #140802; }
.btn-primary:hover { background: var(--accent-2); border-color: var(--accent-2); }
.btn-sm { padding: 8px 12px; font-size: 13px; }

.hero-code {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 30px 80px -30px #000, 0 0 0 1px #0004 inset;
  overflow: hidden; transform: rotate(1.2deg);
}
.code-head { display: flex; align-items: center; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.code-head span { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.code-head span:first-child { background: var(--accent); }
.code-head em { margin-left: 8px; font: normal 12px var(--mono); color: var(--muted); }
.hero-code pre { margin: 0; padding: 18px 18px 22px; overflow-x: auto; font: 12.5px/1.65 var(--mono); color: #cfd6e0; }
.k { color: #ff8f5c; } .t { color: #7cc4ff; } .s { color: #a5e38b; } .n { color: #e6c07b; } .c { color: #5e6877; font-style: italic; }
.caret { display: inline-block; width: 8px; height: 15px; margin-left: 2px; vertical-align: -2px; background: var(--accent); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; padding-top: 56px; gap: 36px; }
  .hero-code { transform: none; }
}

.summary { margin-top: 8px; }
.summary-card { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 26px 28px 22px; }
.summary-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; }
.summary-head h2 { margin: 0; font-size: 14px; font-weight: 500; color: var(--accent); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.stat { background: var(--bg-2); padding: 18px 20px; }
.stat b { display: block; font: 800 32px/1 var(--display); color: var(--text); margin-bottom: 6px; }
.stat span { font-size: 13px; color: var(--muted); }
.glance { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; margin: 18px 0 0; }
.glance > div { display: grid; grid-template-columns: 170px 1fr; gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--line); }
.glance dt { color: var(--muted); font-size: 12px; padding-top: 2px; }
.glance dd { margin: 0; font-size: 14.5px; }
.glance dd b { color: var(--accent); }
.glance a { color: var(--text); }
.jump { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 18px; }
.jump a { text-decoration: none; font-size: 13px; font-weight: 600; padding: 6px 11px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--bg-2); transition: border-color .2s; }
.jump a:hover { border-color: var(--accent); }
@media (max-width: 900px) { .glance { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .summary-card { padding: 20px 16px; }
  .stats { grid-template-columns: 1fr 1fr; } .stat { padding: 14px; } .stat b { font-size: 26px; }
  .glance > div { grid-template-columns: 1fr; gap: 2px; }
}

.chips { display: flex; gap: 6px; }
.chip { display: inline-grid; place-items: center; min-width: 34px; padding: 3px 7px; border-radius: 6px; font: 700 11px var(--mono); letter-spacing: .04em; border: 1px solid; }
.chip-dev { background: var(--accent); border-color: var(--accent); color: #140802; }
.chip-gd { color: var(--gd); border-color: color-mix(in srgb, var(--gd) 45%, transparent); }
.chip-3d { color: var(--d3); border-color: color-mix(in srgb, var(--d3) 45%, transparent); }

.section { padding-top: 96px; }
.section-head { display: grid; grid-template-columns: auto 1fr; column-gap: 18px; align-items: baseline; margin-bottom: 36px; }
.idx { font: 500 13px var(--mono); color: var(--accent); }
.section-head h2 { margin: 0; font: 700 clamp(28px, 4vw, 44px)/1.1 var(--display); letter-spacing: -.03em; }
.section-head p { grid-column: 2; margin: 12px 0 0; color: var(--muted); max-width: 620px; }

.featured { display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; }
.fcard {
  grid-column: span 3; display: flex; flex-direction: column;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; cursor: pointer; transition: border-color .25s, transform .25s;
  outline: none;
}
.fcard-lg { grid-column: span 6; flex-direction: row; }
.fcard:hover, .fcard:focus-visible { border-color: var(--accent); transform: translateY(-3px); }
.fcard-media { position: relative; aspect-ratio: 460 / 215; background: var(--bg-2); overflow: hidden; }
.fcard-lg .fcard-media { flex: 1.6; aspect-ratio: auto; min-height: 360px; }
.fcard-media img, .fcard-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .35s, transform .6s; }
.fcard-media video { opacity: 0; }
.fcard.playing video { opacity: 1; }
.fcard:hover .fcard-media img { transform: scale(1.04); }
.fcard-status {
  position: absolute; left: 12px; top: 12px; padding: 5px 9px; border-radius: 6px;
  background: #0b0d10cc; backdrop-filter: blur(6px); border: 1px solid #ffffff1a; color: var(--text);
}
.fcard-info { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 6px; }
.fcard-lg .fcard-info { flex: 1; padding: 32px; justify-content: center; }
.fcard-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 6px; }
.fcard h3 { margin: 0; font: 700 20px/1.2 var(--display); letter-spacing: -.02em; }
.fcard-lg h3 { font-size: clamp(24px, 3vw, 36px); }
.fcard-tag { margin: 0; color: #c3cad5; }
.fcard-meta { margin: 6px 0 0; color: var(--muted); }
@media (max-width: 900px) {
  .featured { grid-template-columns: 1fr 1fr; }
  .fcard { grid-column: span 1; }
  .fcard-lg { grid-column: span 2; flex-direction: column; }
  .fcard-lg .fcard-media { min-height: 0; aspect-ratio: 460 / 215; flex: none; }
  .fcard-lg .fcard-info { padding: 20px; }
}
@media (max-width: 600px) {
  .featured { grid-template-columns: 1fr; }
  .fcard, .fcard-lg { grid-column: span 1; }
}

.mobile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.mcard { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; cursor: pointer; transition: border-color .2s, transform .2s; outline: none; }
.mcard:hover, .mcard:focus-visible { border-color: var(--gd); transform: translateY(-3px); }
.mcard-media { aspect-ratio: 4 / 5; background: var(--bg-2); overflow: hidden; }
.mcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.mcard:hover img { transform: scale(1.05); }
.mcard-info { padding: 12px 14px 14px; }
.mcard h3 { margin: 0 0 2px; font-size: 15px; font-weight: 700; line-height: 1.3; }
.mcard p { margin: 0; }
@media (max-width: 480px) { .mobile-grid { grid-template-columns: 1fr 1fr; gap: 10px; } }

.timeline { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line-2); }
.tl-item { position: relative; display: grid; grid-template-columns: 200px 1fr; gap: 24px; padding: 0 0 40px 32px; }
.tl-item::before { content: ""; position: absolute; left: -6px; top: 7px; width: 11px; height: 11px; border-radius: 3px; background: var(--bg); border: 2px solid var(--accent); }
.tl-item:first-child::before { background: var(--accent); }
.tl-when { color: var(--muted); padding-top: 3px; }
.tl-body h3 { margin: 0 0 4px; font-size: 19px; font-weight: 700; }
.tl-body h3 a { text-decoration: none; border-bottom: 1px solid var(--line-2); }
.tl-body h3 a:hover { color: var(--accent); border-color: var(--accent); }
.at { color: var(--accent); font-family: var(--mono); font-weight: 500; }
.tl-body p { margin: 0 0 8px; color: #c3cad5; max-width: 720px; }
.tl-body p.muted { color: var(--muted); }
@media (max-width: 720px) { .tl-item { grid-template-columns: 1fr; gap: 4px; padding-left: 22px; } }

.stack-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.stack-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; }
.stack-card.main { border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); }
.stack-card:last-child h3 { color: var(--muted); }
.stack-card h3 { margin: 0 0 14px; color: var(--accent); font-size: 13px; text-transform: uppercase; letter-spacing: .08em; }
.stack-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.stack-card li { padding: 5px 10px; border-radius: 7px; background: var(--bg-2); border: 1px solid var(--line); font-size: 13.5px; }
@media (max-width: 900px) { .stack-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .stack-grid { grid-template-columns: 1fr; } }

.contact-card {
  position: relative; overflow: hidden;
  background: radial-gradient(120% 140% at 100% 0%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 55%), var(--panel);
  border: 1px solid var(--line); border-radius: 20px; padding: 56px;
}
.contact-card h2 { margin: 0 0 14px; font: 700 clamp(26px, 4vw, 44px)/1.12 var(--display); letter-spacing: -.03em; }
.contact-roles { color: var(--muted); margin: 0 0 28px; max-width: 720px; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin: 44px 0 0; padding-top: 28px; border-top: 1px solid var(--line); }
.facts dt { font: 500 12px var(--mono); color: var(--muted); margin-bottom: 4px; }
.facts dd { margin: 0; font-size: 14px; }
@media (max-width: 900px) { .facts { grid-template-columns: 1fr 1fr; } .contact-card { padding: 32px 22px; } }
@media (max-width: 520px) { .facts { grid-template-columns: 1fr; } }

.id-role { margin: 0 0 6px; font-size: 14.5px; }
.id-role b { color: var(--accent); font-weight: 700; }
.tl-group { margin: 8px 0 18px; font-size: 13px; font-weight: 500; color: var(--accent); }
.timeline + .tl-group { margin-top: 12px; }
.timeline-own .tl-item::before { border-style: dashed; border-color: var(--gd); }
.timeline-own .tl-item:first-child::before { background: var(--bg); }
.tl-note { font-size: 14px; color: var(--muted) !important; border-left: 2px solid var(--line-2); padding-left: 10px; }
.eng-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.eng-card { display: flex; flex-direction: column; gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; cursor: pointer; transition: border-color .2s, transform .2s; outline: none; }
.eng-card:hover, .eng-card:focus-visible { border-color: var(--accent); }
.eng-card.reveal.in:hover { transform: translateY(-3px); }
.eng-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.eng-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent); font-size: 18px; }
.eng-card h3 { margin: 0; font: 700 18px/1.25 var(--display); letter-spacing: -.02em; }
.eng-card p { margin: 0; color: #c3cad5; font-size: 14.5px; flex: 1; }
.eng-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.eng-tags span { font: 500 11.5px var(--mono); padding: 3px 8px; border-radius: 6px; background: var(--bg-2); border: 1px solid var(--line); }
.eng-open { color: var(--accent); font-size: 12px; }
@media (max-width: 900px) { .eng-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .eng-grid { grid-template-columns: 1fr; } }
.metrics { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.metric { display: flex; align-items: baseline; gap: 10px; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); }
.metric b { font: 700 20px var(--display); color: var(--gd); }
.metric span { font-size: 13px; color: var(--muted); }
.contact-card > .idx { display: block; margin-bottom: 14px; }
.to-top {
  position: fixed; right: 20px; bottom: 20px; z-index: 40; display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 12px; text-decoration: none; font-size: 18px;
  background: var(--panel); border: 1px solid var(--line-2); color: var(--text);
  opacity: 0; transform: translateY(10px); pointer-events: none; transition: opacity .25s, transform .25s, border-color .2s;
}
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { border-color: var(--accent); }
html { scroll-padding-top: 76px; }
@media (max-width: 960px) { html { scroll-padding-top: 112px; } }

.footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 40px; padding-bottom: 40px; margin-top: 60px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); }

.modal {
  width: min(1040px, calc(100vw - 32px)); max-height: calc(100vh - 48px);
  padding: 0; border: 1px solid var(--line-2); border-radius: 18px;
  background: var(--bg-2); color: var(--text); overflow-y: auto;
}
.modal::backdrop { background: #05060899; backdrop-filter: blur(6px); }
.modal[open] { animation: pop .25s ease-out; }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.98); } }
.modal-close {
  position: sticky; top: 14px; float: right; margin: 14px 14px 0 0; z-index: 2;
  width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line-2);
  background: var(--panel); color: var(--text); font-size: 15px; cursor: pointer;
}
.modal-close:hover { border-color: var(--accent); }
.modal-body { padding: 32px 36px 40px; }
.m-head h2 { margin: 12px 0 6px; font: 800 clamp(26px, 4vw, 40px)/1.08 var(--display); letter-spacing: -.03em; }
.m-tag { margin: 0 0 24px; color: #c3cad5; font-size: 17px; }
.m-video { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #000; margin-bottom: 28px; border: 1px solid var(--line); }
.m-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.m-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 32px; margin-bottom: 32px; }
.m-about { margin: 0 0 20px; color: #c3cad5; }
.modal-body h4 { margin: 0 0 12px; color: var(--accent); font-weight: 500; font-size: 13px; }
.m-work { margin: 0; padding: 0; list-style: none; }
.m-work li { position: relative; padding: 0 0 10px 22px; }
.m-work li::before { content: "▸"; position: absolute; left: 0; color: var(--accent); }
.m-side { display: flex; flex-direction: column; gap: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 18px; align-self: start; }
.m-side > div:not(.m-tech):not(.m-links) { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); font-size: 14px; }
.m-side b { font-weight: 600; text-align: right; }
.m-tech { display: flex; flex-wrap: wrap; gap: 6px; }
.m-tech span { font: 500 12px var(--mono); padding: 4px 8px; border-radius: 6px; background: var(--bg-2); border: 1px solid var(--line); }
.m-links { display: flex; flex-wrap: wrap; gap: 8px; }
.m-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.g-item { position: relative; padding: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--panel); aspect-ratio: 16 / 10; cursor: zoom-in; }
.g-item img, .g-item video { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.g-item:hover { border-color: var(--accent); }
.g-item:hover img { transform: scale(1.05); }
.g-play { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 26px; text-shadow: 0 2px 12px #000; pointer-events: none; }
.g-vid:hover .g-play { opacity: 0; }
@media (max-width: 760px) {
  .modal { width: 100vw; max-width: 100vw; max-height: 100vh; height: 100vh; border-radius: 0; border: 0; }
  .modal-body { padding: 20px 16px 32px; }
  .m-grid { grid-template-columns: 1fr; gap: 20px; }
  .m-gallery { grid-template-columns: 1fr 1fr; gap: 8px; }
}

.lightbox {
  width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; margin: 0; padding: 0;
  border: 0; background: transparent; color: var(--text); overflow: hidden;
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: #050608f2; }
.lb-stage { width: 100%; height: 100%; display: grid; place-items: center; padding: 56px 72px; }
.lb-stage img, .lb-stage video { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 8px; }
.lb-stage iframe { width: min(1280px, 100%); aspect-ratio: 16 / 9; border: 0; border-radius: 8px; }
.lb-close, .lb-nav { position: absolute; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); cursor: pointer; border-radius: 10px; }
.lb-close { top: 16px; right: 16px; width: 42px; height: 42px; font-size: 16px; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 46px; height: 64px; font-size: 30px; line-height: 1; }
.lb-prev { left: 14px; } .lb-next { right: 14px; }
.lb-close:hover, .lb-nav:hover { border-color: var(--accent); }
.lb-count { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); color: var(--muted); }
@media (max-width: 640px) { .lb-stage { padding: 64px 8px; } .lb-nav { top: auto; bottom: 10px; transform: none; height: 46px; } }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
.fcard.reveal.in:hover, .mcard.reveal.in:hover { transform: translateY(-3px); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 640px) { .hero-code { display: none; } .hero { padding-bottom: 32px; } }
