@property --a { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
:root {
  --bg: #04050c; --fg: #f4f4f5; --muted: #c4c4cc; --dim: #8b8b96;
  --accent: #5eead4; --accent2: #a78bfa; --accent3: #f0abfc;
  --glass: rgb(12 14 30 / 0.55); --line: rgb(255 255 255 / 0.1);
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { background: var(--bg); }
body { margin: 0; color: var(--fg); font: 18px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
main { width: 100%; max-width: 612px; margin: 0 auto; padding: 8px 16px 48px; }

/* Hero: a plain photo + name without WebGL, the 3D desk with it. */
.stage { position: relative; padding: 72px 16px 32px; }
.hero { text-align: center; }
.photo-wrap { position: relative; isolation: isolate; width: 176px; height: 176px; margin: 0 auto 32px; border-radius: 40px; }
.photo-wrap::before, .photo-wrap::after {
  content: ""; position: absolute; inset: -3px; border-radius: 43px; z-index: -1;
  background: conic-gradient(from var(--a), var(--accent), var(--accent2), var(--accent3), var(--accent));
  animation: spin 6s linear infinite;
}
.photo-wrap::after { inset: -10px; filter: blur(28px); opacity: 0.55; }
.photo { display: block; width: 100%; height: 100%; border-radius: 37px; object-fit: cover; border: 3px solid var(--bg); }
h1 {
  font-size: clamp(2.6rem, 9vw, 4rem); line-height: 1.05; margin: 0 0 18px; letter-spacing: -0.035em;
  background: linear-gradient(110deg, #fff 20%, var(--accent) 40%, var(--accent2) 55%, var(--accent3) 65%, #fff 80%);
  background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shimmer 9s linear infinite;
}
.role { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 0; }
.role span {
  font: 500 12px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase;
  padding: 9px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--accent);
  background: rgb(255 255 255 / 0.04); backdrop-filter: blur(8px);
}
.hint, .tip, .panel, .toast { display: none; }

.has-3d .stage {
  height: 100vh; height: 100svh; padding: 0; overflow: hidden;
  background: radial-gradient(ellipse 75% 65% at 50% 62%, #1d1a3d 0%, #0b0c1c 48%, var(--bg) 82%);
}
.has-3d .stage > canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; outline: none; }
.has-3d .stage > canvas:active { cursor: grabbing; }
.has-3d .hero { position: absolute; top: clamp(20px, 5vh, 48px); left: 16px; right: 16px; z-index: 2; pointer-events: none; }
.has-3d .photo-wrap { display: none; }
.has-3d .hero { transition: opacity 0.4s; }
.stage.focused .hero { opacity: 0; }
.stage.focused .hint { visibility: hidden; }
.has-3d h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); margin-bottom: 14px; filter: drop-shadow(0 4px 30px rgb(94 234 212 / 0.25)); }
.has-3d .hint {
  display: block; position: absolute; left: 16px; right: 16px; bottom: 24px; z-index: 2; pointer-events: none; text-align: center;
  font: 500 12px/1.6 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim);
  animation: breathe 3s ease-in-out infinite;
}
.has-3d .hint::after { content: "\2193  scroll for more"; display: block; opacity: 0.7; }
.has-3d .tip {
  display: block; position: absolute; z-index: 3; pointer-events: none; white-space: nowrap;
  padding: 6px 11px; border-radius: 9px; background: rgb(10 12 24 / 0.85); border: 1px solid var(--line);
  font-size: 13px; font-weight: 600; color: var(--fg); opacity: 0; transform: translate(-50%, -150%); transition: opacity 0.15s;
}
.has-3d .tip.show { opacity: 1; }
.has-3d .panel {
  display: block; position: absolute; z-index: 4; top: 50%; right: 24px; width: min(420px, calc(100% - 32px));
  max-height: calc(100% - 48px); overflow: auto; padding: 18px 20px 6px;
  background: rgb(10 12 26 / 0.72); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 30px 80px -20px rgb(0 0 0 / 0.7);
  opacity: 0; transform: translate(24px, -50%); transition: opacity 0.4s, transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.has-3d .panel[hidden] { display: none; }
.has-3d .panel.open { opacity: 1; transform: translate(0, -50%); }
.panel h2 { margin-top: 6px; }
.panel-close {
  position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--line); background: rgb(255 255 255 / 0.06); color: var(--fg); font-size: 15px; line-height: 1;
}
.panel-close:hover { border-color: var(--accent); }
.has-3d .toast {
  display: block; position: absolute; z-index: 4; left: 50%; bottom: 84px; transform: translate(-50%, 10px); pointer-events: none;
  padding: 10px 16px; border-radius: 999px; background: rgb(10 12 24 / 0.85); border: 1px solid var(--line);
  font-size: 14px; opacity: 0; transition: 0.3s; white-space: nowrap;
}
.has-3d .toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 700px) {
  .has-3d .panel { top: auto; bottom: 16px; right: 16px; left: 16px; width: auto; max-height: 62%; transform: translateY(24px); }
  .has-3d .panel.open { transform: none; }
}
@media (pointer: coarse) { .has-3d .stage { height: 84vh; height: 84svh; } }

h2 {
  font: 600 12px/1 var(--mono); text-transform: uppercase; letter-spacing: 0.18em;
  margin: 44px 0 14px; color: var(--dim); display: flex; align-items: center; gap: 12px;
}
h2::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line), transparent); }
p { margin: 0 0 16px; color: var(--muted); }
.intro strong { color: var(--fg); font-weight: 600; }
a { color: var(--accent); }

.card {
  position: relative; overflow: hidden; display: block; background: var(--glass);
  backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid var(--line); border-radius: 18px; padding: 18px; margin: 0 0 12px;
  color: inherit; text-decoration: none; transition: transform 0.25s ease-out, border-color 0.2s;
  box-shadow: 0 20px 50px -20px rgb(0 0 0 / 0.6);
}
.card::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgb(94 234 212 / 0.14), transparent 45%);
}
.card:hover { border-color: rgb(94 234 212 / 0.4); }
.card:hover::after { opacity: 1; }
.card-head { display: flex; align-items: center; gap: 12px; }
.card-head img, .card-head .mark { width: 42px; height: 42px; border-radius: 11px; flex: none; }
.card-head .avatar { border-radius: 50%; }
.card-title { font-weight: 600; line-height: 1.3; }
.card-sub { font-size: 14px; color: var(--dim); }
.card p { font-size: 16px; margin: 12px 0 0; }
.repos { list-style: none; margin: 14px 0 0; padding: 0; border-top: 1px solid var(--line); }
.repos li { padding: 10px 0 0; font-size: 15px; }
.repos a { font-weight: 600; text-decoration: none; }
.repos p { font-size: 14px; margin: 2px 0 0; }
.meta { font-size: 13px; color: var(--dim); margin-left: 6px; }
.follow {
  margin-left: auto; font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap;
  padding: 7px 12px; border-radius: 999px; border: 1px solid rgb(94 234 212 / 0.35); background: rgb(94 234 212 / 0.08);
}
.follow:hover { background: rgb(94 234 212 / 0.18); }
.promo { margin: 32px 0 0; padding: 22px; border-color: rgb(94 234 212 / 0.35);
  background: linear-gradient(135deg, rgb(94 234 212 / 0.12), rgb(167 139 250 / 0.1)), var(--glass); }
.promo .card-title { font-size: 21px; }
.promo .ad { display: block; margin-bottom: 6px; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dim); }
.promo .cta {
  display: inline-block; margin-top: 16px; padding: 10px 18px; border-radius: 999px;
  background: var(--accent); color: #04120f; font-weight: 700; font-size: 15px; transition: transform 0.2s;
}
.promo:hover .cta { transform: translateX(3px); }
.promo small { display: block; margin-top: 12px; font-size: 12px; color: var(--dim); }
footer { margin-top: 56px; font-size: 13px; color: var(--dim); text-align: center; }
footer a { color: inherit; }

.rise { animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) backwards; animation-delay: calc(0.3s + var(--i) * 0.09s); }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }
@keyframes spin { to { --a: 360deg; } }
@keyframes shimmer { to { background-position: -250% 0; } }
@keyframes breathe { 50% { opacity: 0.45; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
}
.d0 { --i: 0; }
.d1 { --i: 1; }
.d2 { --i: 2; }
.d3 { --i: 3; }
.d4 { --i: 4; }
.d5 { --i: 5; }
.d6 { --i: 6; }
.d7 { --i: 7; }
