/* ========== HERO ========== */
.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: 4rem;
    align-items: center;
    position: relative;
    min-height: 100vh;
    padding-top: 7rem;
}

/* ===== HERO PORTRAIT ===== */
.hero-portrait {
    position: relative;
    z-index: 3;
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    width: 100%;
    max-width: 460px;
    aspect-ratio: 4 / 5;
}

.portrait-frame {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border: 1px solid var(--border-strong);
    clip-path: polygon(
        0 18px, 18px 0,
        calc(100% - 60px) 0, calc(100% - 40px) 18px,
        100% 18px, 100% calc(100% - 18px),
        calc(100% - 18px) 100%, 60px 100%,
        40px calc(100% - 18px), 0 calc(100% - 18px)
    );
    box-shadow:
        0 0 40px rgba(0, 255, 157, 0.18),
        0 30px 80px rgba(0, 0, 0, 0.5);
    background: var(--bg-1);
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.portrait-frame::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 255, 157, 0.05), transparent 40%, rgba(0, 212, 255, 0.05));
    z-index: 2;
    pointer-events: none;
}

.portrait-frame::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(
            to bottom,
            transparent 0,
            transparent 3px,
            rgba(0, 0, 0, 0.18) 4px,
            transparent 5px
        );
    z-index: 3;
    pointer-events: none;
    mix-blend-mode: multiply;
}

.hero-portrait:hover .portrait-frame {
    transform: translateY(-6px) rotateX(2deg) rotateY(-2deg);
}

/* ---- Media stack (rotates between photo, video, office, workspace, homelab) ---- */
.portrait-media {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.portrait-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transform: scale(1.06);
    transition: opacity 1s ease, transform 6s ease-out, filter 0.6s;
    /* heavy cyberpunk filter — looks like a render, not a candid */
    filter: grayscale(100%) contrast(1.35) brightness(0.85) saturate(1.1);
    pointer-events: none;
}

.portrait-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-portrait:hover .portrait-slide.active {
    filter: grayscale(80%) contrast(1.2) brightness(1);
}

/* duotone — green / cyan multiply on top of the grayscale slide */
.portrait-duotone {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(135deg, #00ff9d 0%, #00d4ff 100%);
    mix-blend-mode: multiply;
    opacity: 0.42;
}

/* film noise overlay */
.portrait-noise {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    opacity: 0.08;
    mix-blend-mode: overlay;
    background-image:
        radial-gradient(rgba(255,255,255,0.4) 1px, transparent 1px),
        radial-gradient(rgba(0,0,0,0.4) 1px, transparent 1px);
    background-size: 3px 3px, 5px 5px;
    background-position: 0 0, 1px 1px;
    animation: noiseShift 0.4s steps(4) infinite;
}

@keyframes noiseShift {
    0%   { transform: translate(0, 0); }
    25%  { transform: translate(-1px, 1px); }
    50%  { transform: translate(1px, -1px); }
    75%  { transform: translate(-1px, -1px); }
    100% { transform: translate(0, 0); }
}

/* moving scan line */
.portrait-scan {
    position: absolute;
    inset: 0;
    z-index: 4;
    pointer-events: none;
    overflow: hidden;
}

.portrait-scan::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -10%;
    height: 14%;
    background: linear-gradient(
        to bottom,
        transparent 0,
        rgba(0, 255, 157, 0) 30%,
        rgba(0, 255, 157, 0.22) 60%,
        rgba(0, 255, 157, 0) 90%,
        transparent 100%
    );
    animation: portraitScan 4s linear infinite;
    filter: blur(2px);
}

@keyframes portraitScan {
    0%   { transform: translateY(0); }
    100% { transform: translateY(800%); }
}

/* corner accents */
.portrait-corners .corner {
    position: absolute;
    width: 28px;
    height: 28px;
    border: 2px solid var(--accent);
    z-index: 5;
    box-shadow: 0 0 8px rgba(0, 255, 157, 0.45);
}
.portrait-corners .tl { top: 10px; left: 10px; border-right: none; border-bottom: none; }
.portrait-corners .tr { top: 10px; right: 10px; border-left: none; border-bottom: none; }
.portrait-corners .bl { bottom: 10px; left: 10px; border-right: none; border-top: none; }
.portrait-corners .br { bottom: 10px; right: 10px; border-left: none; border-top: none; }

/* live status badge */
.portrait-badge {
    position: absolute;
    top: 22px;
    right: 22px;
    z-index: 6;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 6px 12px;
    background: rgba(5, 6, 8, 0.85);
    border: 1px solid var(--border-strong);
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--accent);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    backdrop-filter: blur(6px);
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    animation: pulse 2s ease-in-out infinite;
}

/* meta line at bottom */
.portrait-meta {
    position: absolute;
    left: 22px;
    right: 22px;
    bottom: 22px;
    z-index: 6;
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.meta-line {
    color: var(--accent);
    text-shadow: 0 0 6px rgba(0, 255, 157, 0.5);
}
.meta-line.dim { color: var(--text-dim); text-shadow: none; font-size: 0.62rem; }

/* hero-content placement in the grid */
.hero-content {
    grid-column: 1;
    grid-row: 1;
}

/* HUD readouts (top-left) */
.portrait-hud {
    position: absolute;
    top: 22px;
    left: 22px;
    z-index: 6;
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--accent);
    letter-spacing: 1.5px;
    text-shadow: 0 0 6px rgba(0, 255, 157, 0.5);
}

.hud-line {
    padding: 3px 8px;
    background: rgba(5, 6, 8, 0.7);
    border-left: 2px solid var(--accent);
}

/* Slide indicator dots */
.portrait-dots {
    position: absolute;
    right: 22px;
    bottom: 22px;
    z-index: 6;
    display: flex;
    gap: 6px;
}

.portrait-dot {
    width: 18px;
    height: 3px;
    background: rgba(255, 255, 255, 0.18);
    transition: background 0.4s, width 0.4s;
    cursor: pointer;
}

.portrait-dot.active {
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    width: 28px;
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0, 255, 157, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 157, 0.04) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
    pointer-events: none;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
}

.hero-greeting {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--accent);
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
}

.bracket { color: var(--accent-2); }

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 10vw, 7.5rem);
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: -2px;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.hero-title .glitch {
    display: block;
    color: var(--text);
}

.hero-roles {
    font-family: var(--font-mono);
    font-size: clamp(1rem, 2.5vw, 1.5rem);
    color: var(--accent);
    margin-bottom: 1.8rem;
    min-height: 2em;
}

.role-static { margin-right: 0.5rem; color: var(--accent-2); }
.role-caret { color: var(--accent); animation: blink 1s steps(2) infinite; margin-left: 2px; }

.hero-tagline {
    font-size: clamp(1rem, 1.4vw, 1.15rem);
    color: var(--text-dim);
    max-width: 680px;
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 4rem;
}

/* Buttons */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.8rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: all 0.3s;
    overflow: hidden;
}

.btn svg { width: 18px; height: 18px; }

.btn-primary {
    background: var(--accent);
    color: var(--bg-0);
    clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
}

.btn-primary:hover {
    background: var(--accent-2);
    box-shadow: var(--accent-glow);
    transform: translateY(-2px);
}

.btn-ghost {
    color: var(--text);
    border: 1px solid var(--border-strong);
    clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
}

.btn-ghost:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: rgba(0, 255, 157, 0.05);
    transform: translateY(-2px);
}

/* Hero meta counters */
.hero-meta {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 700px;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.meta-num {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    font-weight: 700;
    color: var(--accent);
    line-height: 1;
    text-shadow: 0 0 16px rgba(0, 255, 157, 0.4);
}

.meta-label {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-dim);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: 0.5rem;
    line-height: 1.4;
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 5rem;
    right: var(--pad-x);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-dim);
    letter-spacing: 2px;
    z-index: 3;
}

.scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, transparent, var(--accent), transparent);
    background-size: 100% 200%;
    animation: scrollDown 2s ease-in-out infinite;
}

/* ========== ABOUT ========== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: stretch;
}

.about-card {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 4px;
    position: relative;
    transition: transform 0.3s, border-color 0.3s;
}

.about-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
}

/* Terminal card */
.terminal-card { overflow: hidden; }

.terminal-header {
    display: flex;
    align-items: center;
    padding: 0.7rem 1rem;
    background: rgba(255,255,255,0.03);
    border-bottom: 1px solid var(--border);
    gap: 1rem;
}

.terminal-dots { display: flex; gap: 0.4rem; }
.terminal-dots .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.dot.red    { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green  { background: #27c93f; }

.terminal-title {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-dim);
}

.terminal-body {
    padding: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text);
    line-height: 1.7;
}

.terminal-body .prompt { color: var(--accent); margin-right: 0.4rem; }
.terminal-body .code   {
    color: var(--text);
    margin: 0.5rem 0;
    white-space: pre-wrap;
    font-family: var(--font-mono);
}
.terminal-body .green { color: var(--accent); }
.cursor-blink { color: var(--accent); animation: blink 1s steps(2) infinite; }

/* Bio card */
.bio-card { padding: 2rem; }

.bio-head {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-bottom: 1.4rem;
}

.bio-head-text { flex: 1; min-width: 0; }

.bio-role {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-top: 0.2rem;
}

.bio-role strong { color: var(--accent); font-weight: 500; }

/* Avatar */
.avatar-wrap {
    position: relative;
    width: 84px;
    height: 84px;
    flex-shrink: 0;
}

.avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
    box-shadow: 0 0 18px rgba(0, 255, 157, 0.5);
    filter: grayscale(20%) contrast(1.05);
    transition: filter 0.4s, transform 0.4s;
}

.avatar-wrap:hover .avatar {
    filter: grayscale(0%) contrast(1.1);
    transform: scale(1.04);
}

.avatar-ring {
    position: absolute;
    inset: -8px;
    border: 1px dashed var(--accent);
    border-radius: 50%;
    animation: ringSpinSlow 16s linear infinite;
    opacity: 0.5;
}

.avatar-status {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 14px;
    height: 14px;
    background: var(--accent);
    border: 2px solid var(--bg-0);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes ringSpinSlow {
    to { transform: rotate(360deg); }
}

.inline-link {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px dashed var(--accent);
    transition: color 0.2s, border-color 0.2s;
}

.inline-link:hover {
    color: var(--accent-2);
    border-color: var(--accent-2);
}

.card-title {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--accent);
    margin-bottom: 1rem;
    text-transform: lowercase;
    letter-spacing: 1px;
}

.bio-card p {
    color: var(--text-dim);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.bio-card strong { color: var(--text); font-weight: 600; }

.lang-list {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.lang-list li {
    display: grid;
    grid-template-columns: 110px 1fr 60px;
    gap: 1rem;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.lang { color: var(--text); }
.lang-val { color: var(--accent); text-align: right; }

.lang-bar {
    position: relative;
    height: 4px;
    background: var(--bg-2);
    border-radius: 2px;
    overflow: hidden;
}

.lang-bar::after {
    content: '';
    position: absolute;
    left: 0; top: 0;
    height: 100%;
    width: var(--p, 0);
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    box-shadow: 0 0 8px var(--accent);
    border-radius: 2px;
    animation: barFill 1.2s ease-out;
}

/* ========== ARSENAL ========== */
.arsenal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.2rem;
}

.arsenal-card {
    position: relative;
    background: var(--bg-panel);
    border: 1px solid var(--border);
    padding: 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
    clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 16px 100%, 0 calc(100% - 16px));
    cursor: none;
    overflow: hidden;
}

.arsenal-card::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0,255,157,0.08), transparent);
    transition: left 0.6s;
}

.arsenal-card:hover::before { left: 100%; }

.arsenal-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-strong);
    box-shadow: 0 10px 40px rgba(0, 255, 157, 0.15);
}

.arsenal-card .card-cat {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--accent);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 0.6rem;
}

.arsenal-card h3 {
    font-family: var(--font-display);
    font-size: 1.25rem;
    color: var(--text);
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.arsenal-card p {
    color: var(--text-dim);
    font-size: 0.85rem;
    line-height: 1.6;
}

.arsenal-card .card-tag {
    position: absolute;
    top: 0.8rem;
    right: 1rem;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-faint);
    border: 1px solid var(--border);
    padding: 2px 8px;
    border-radius: 2px;
}

.arsenal-card .card-icon {
    width: 36px;
    height: 36px;
    margin-bottom: 0.8rem;
    color: var(--accent);
    filter: drop-shadow(0 0 6px rgba(0,255,157,0.4));
}

/* ========== FEATURED PROJECT ========== */
.featured-card {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 3rem;
    align-items: center;
    background: var(--bg-panel);
    border: 1px solid var(--border-strong);
    padding: 2.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: relative;
    clip-path: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 24px 100%, 0 calc(100% - 24px));
    box-shadow: 0 20px 60px rgba(0, 255, 157, 0.08);
}

.featured-card::before {
    content: '';
    position: absolute;
    inset: -1px;
    background: linear-gradient(135deg, var(--accent), transparent 40%, var(--accent-2) 100%);
    z-index: -1;
    opacity: 0.4;
    filter: blur(20px);
}

.featured-eyebrow {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 1px;
    margin-bottom: 0.6rem;
}

.featured-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 900;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.featured-tag {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--accent-2);
    margin-bottom: 1.2rem;
}

.featured-desc {
    color: var(--text-dim);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    max-width: 540px;
}

.featured-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1.8rem;
}

.featured-stack li {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    padding: 4px 10px;
    color: var(--accent);
    border: 1px solid var(--border);
    background: rgba(0, 255, 157, 0.05);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.featured-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.featured-visual {
    perspective: 1200px;
}

/* GitHub mock card */
.gh-card {
    background: #0d1117;
    border: 1px solid #30363d;
    border-radius: 6px;
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: #c9d1d9;
    transform: rotateY(-8deg) rotateX(6deg);
    transform-style: preserve-3d;
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow:
        0 20px 60px rgba(0,0,0,0.5),
        0 0 30px rgba(0, 255, 157, 0.2);
}

.gh-card:hover {
    transform: rotateY(-2deg) rotateX(2deg) scale(1.02);
}

.gh-card-head {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.8rem 1rem;
    background: #161b22;
    border-bottom: 1px solid #30363d;
}

.gh-icon { width: 18px; height: 18px; color: #c9d1d9; }

.gh-repo {
    color: #58a6ff;
    font-size: 0.85rem;
}

.gh-card-body { padding: 1rem; }

.gh-mock {
    white-space: pre-wrap;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    line-height: 1.6;
    color: #c9d1d9;
}

.gh-comment { color: #8b949e; font-style: italic; }
.gh-key     { color: var(--accent); }

/* ========== FIELD WORK ========== */
/* Section becomes a stage with its own matrix backdrop */
.field {
    overflow: hidden;
}

.field-matrix {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.55;
    pointer-events: none;
    /* fade out at the very top so the section header stays clean,
       fade out at the bottom so the meta strip is readable */
    -webkit-mask-image: linear-gradient(to bottom,
        transparent 0%,
        black 18%,
        black 78%,
        transparent 100%);
    mask-image: linear-gradient(to bottom,
        transparent 0%,
        black 18%,
        black 78%,
        transparent 100%);
}

/* Make sure all field content sits on top of the matrix canvas */
.field > .section-header,
.field > .section-lead,
.field > .field-card {
    position: relative;
    z-index: 2;
}

/* Centered single-column layout */
.field-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    width: 100%;
}

.field-video {
    width: 100%;
    max-width: 880px;
    perspective: 1400px;
}

.video-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid var(--border-strong);
    background: var(--bg-1);
    transform: perspective(1400px) rotateX(2deg);
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    clip-path: polygon(
        0 16px, 16px 0,
        calc(100% - 60px) 0, calc(100% - 40px) 16px,
        100% 16px, 100% calc(100% - 16px),
        calc(100% - 16px) 100%, 60px 100%,
        40px calc(100% - 16px), 0 calc(100% - 16px)
    );
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.6),
        0 0 60px rgba(0, 255, 157, 0.25),
        0 0 120px rgba(0, 255, 157, 0.15);
}

.field-video:hover .video-frame {
    transform: perspective(1400px) rotateX(0deg) scale(1.015);
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.6),
        0 0 80px rgba(0, 255, 157, 0.35),
        0 0 160px rgba(0, 255, 157, 0.2);
}

.field-vid {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    /* lighter cyberpunk treatment — keep the action visible */
    filter: contrast(1.08) saturate(1.05) brightness(0.95);
    transition: filter 0.5s;
}

.video-frame::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 255, 157, 0.06), transparent 50%, rgba(0, 212, 255, 0.05));
    z-index: 2;
    pointer-events: none;
}

.video-frame::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        to bottom,
        transparent 0,
        transparent 3px,
        rgba(0, 0, 0, 0.18) 4px,
        transparent 5px
    );
    z-index: 3;
    pointer-events: none;
    mix-blend-mode: multiply;
}

/* mute toggle button */
.vid-mute {
    position: absolute;
    bottom: 22px;
    left: 22px;
    z-index: 7;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(5, 6, 8, 0.85);
    border: 1px solid var(--border-strong);
    color: var(--accent);
    cursor: none;
    transition: background 0.3s, color 0.3s, transform 0.3s;
    backdrop-filter: blur(6px);
}

.vid-mute:hover {
    background: var(--accent);
    color: var(--bg-0);
    transform: translateY(-2px);
}

.vid-mute svg {
    width: 18px;
    height: 18px;
}

.vid-mute.unmuted .mute-slash { display: none; }

/* field body — centered under the video */
.field-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 780px;
    margin: 0 auto;
}

.field-body .featured-desc {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.field-body .featured-stack {
    justify-content: center;
}

.field-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 1.8rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    width: 100%;
    max-width: 640px;
}

.field-meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    font-family: var(--font-mono);
    align-items: center;
    text-align: center;
}

.meta-k {
    font-size: 0.65rem;
    color: var(--text-faint);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.meta-v {
    font-size: 0.9rem;
    color: var(--text);
}

.meta-v.accent {
    color: var(--accent);
    text-shadow: 0 0 6px rgba(0, 255, 157, 0.4);
}

/* ========== SKILLS ========== */
.skills-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 1rem;
}

.skill-tab {
    padding: 0.6rem 1.2rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-dim);
    letter-spacing: 1px;
    border: 1px solid transparent;
    transition: all 0.3s;
}

.skill-tab:hover { color: var(--text); }

.skill-tab.active {
    color: var(--bg-0);
    background: var(--accent);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
    perspective: 1200px;
}

.skill-cube {
    position: relative;
    background: var(--bg-panel);
    border: 1px solid var(--border);
    padding: 1.2rem;
    text-align: center;
    transition: transform 0.4s, box-shadow 0.4s, border-color 0.3s;
    transform-style: preserve-3d;
    cursor: none;
}

.skill-cube:hover {
    transform: translateY(-6px) rotateX(8deg) rotateY(-8deg);
    border-color: var(--accent);
    box-shadow:
        0 12px 30px rgba(0, 255, 157, 0.15),
        -8px 8px 0 -1px rgba(0, 255, 157, 0.4);
}

.skill-cube .skill-icon {
    font-size: 2rem;
    margin-bottom: 0.6rem;
    display: inline-block;
    filter: drop-shadow(0 0 12px rgba(0, 255, 157, 0.5));
}

.skill-cube h4 {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--text);
    margin-bottom: 0.3rem;
}

.skill-cube .level {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-dim);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.skill-cube .skill-bar {
    margin-top: 0.6rem;
    height: 3px;
    background: var(--bg-2);
    border-radius: 2px;
    overflow: hidden;
}

.skill-cube .skill-bar::after {
    content: '';
    display: block;
    height: 100%;
    width: var(--p, 50%);
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    box-shadow: 0 0 8px var(--accent);
    animation: barFill 1.2s ease-out;
}

/* ========== EXPERIENCE / TIMELINE (alternating zig-zag) ========== */
.timeline {
    position: relative;
    padding: 1rem 0 2rem;
}

/* center spine */
.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(
        to bottom,
        transparent 0,
        var(--accent) 5%,
        var(--accent) 95%,
        transparent 100%
    );
    box-shadow: 0 0 18px rgba(0, 255, 157, 0.45);
    transform: translateX(-50%);
}

.tl-item {
    position: relative;
    width: 50%;
    padding: 0 3rem 3rem;
    box-sizing: border-box;
}

/* node on the spine */
.tl-item::before {
    content: '';
    position: absolute;
    top: 0.6rem;
    width: 16px;
    height: 16px;
    background: var(--bg-0);
    border: 2px solid var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 14px var(--accent);
    z-index: 2;
}

/* connector line from node to card */
.tl-item::after {
    content: '';
    position: absolute;
    top: 1.2rem;
    width: 2.4rem;
    height: 1px;
    background: linear-gradient(to right, var(--accent), transparent);
    opacity: 0.6;
}

/* LEFT side (odd) */
.tl-item:nth-child(odd) {
    margin-left: 0;
    text-align: right;
}
.tl-item:nth-child(odd)::before { right: -8px; }
.tl-item:nth-child(odd)::after  { right: 0; background: linear-gradient(to left, var(--accent), transparent); }

/* RIGHT side (even) */
.tl-item:nth-child(even) {
    margin-left: 50%;
    text-align: left;
}
.tl-item:nth-child(even)::before { left: -8px; }
.tl-item:nth-child(even)::after  { left: 0; }

/* the card itself */
.tl-card {
    position: relative;
    display: inline-block;
    text-align: left;
    background: var(--bg-panel);
    border: 1px solid var(--border);
    padding: 1.4rem 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 14px 100%, 0 calc(100% - 14px));
    transition: transform 0.35s, border-color 0.3s, box-shadow 0.3s;
    max-width: 100%;
}

.tl-item:hover .tl-card {
    border-color: var(--border-strong);
    transform: translateY(-4px);
    box-shadow: 0 12px 36px rgba(0, 255, 157, 0.14);
}

.tl-item .tl-date {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--accent);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.tl-card h3 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 0.2rem;
    letter-spacing: 0.5px;
    line-height: 1.3;
}

.tl-card .tl-org {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--accent-2);
    margin-bottom: 0.7rem;
}

.tl-card ul {
    margin-top: 0.4rem;
}

.tl-card li {
    color: var(--text-dim);
    padding-left: 1rem;
    position: relative;
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
    line-height: 1.5;
    text-align: left;
}

.tl-card li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--accent);
}

.tl-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.9rem;
    justify-content: flex-start;
}

.tl-tag {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    padding: 3px 8px;
    color: var(--accent);
    border: 1px solid var(--border);
    background: rgba(0, 255, 157, 0.05);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* ========== CONTACT ========== */
.contact-wrap {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 4rem;
    align-items: center;
}

.contact-eyebrow {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent);
    margin-bottom: 0.8rem;
    letter-spacing: 1px;
}

.contact-title {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    color: var(--text);
    margin-bottom: 1.2rem;
    line-height: 1.2;
    letter-spacing: 1px;
}

.contact-text > p {
    color: var(--text-dim);
    max-width: 480px;
    margin-bottom: 2.5rem;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.contact-method {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.4rem;
    background: var(--bg-panel);
    border: 1px solid var(--border);
    font-family: var(--font-mono);
    transition: all 0.3s;
    clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 14px 100%, 0 calc(100% - 14px));
}

.contact-method:hover {
    border-color: var(--accent);
    background: rgba(0, 255, 157, 0.05);
    transform: translateX(6px);
}

.method-label {
    font-size: 0.7rem;
    color: var(--text-faint);
    letter-spacing: 2px;
}

.method-value {
    font-size: 0.9rem;
    color: var(--accent);
}

/* Contact orb (CSS-only 3D rings) */
.contact-orb {
    position: relative;
    aspect-ratio: 1 / 1;
    max-width: 380px;
    margin-left: auto;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.orb-core {
    position: absolute;
    inset: 35%;
    background: radial-gradient(circle at 30% 30%, var(--accent), var(--accent-2) 60%, transparent 100%);
    border-radius: 50%;
    box-shadow:
        0 0 40px var(--accent),
        0 0 80px rgba(0, 255, 157, 0.4),
        inset -10px -10px 30px rgba(0,0,0,0.3);
    animation: orbPulse 3s ease-in-out infinite;
}

.orb-ring {
    position: absolute;
    inset: 0;
    border: 1px solid var(--accent);
    border-radius: 50%;
    opacity: 0.5;
}

.orb-ring.r1 { animation: ringSpin1 8s linear infinite; transform: rotateX(70deg); }
.orb-ring.r2 { animation: ringSpin2 12s linear infinite; transform: rotateY(70deg); border-color: var(--accent-2); }
.orb-ring.r3 { animation: ringSpin3 16s linear infinite; transform: rotateZ(45deg) rotateX(45deg); border-style: dashed; }

/* ========== BOOT SCREEN ========== */
.boot-screen {
    position: fixed;
    inset: 0;
    z-index: 9998;
    background: var(--bg-0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s, visibility 0.6s;
}

.boot-screen.done {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.boot-terminal {
    width: min(700px, 90vw);
    padding: 2rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent);
    background: rgba(0, 255, 157, 0.02);
    border: 1px solid var(--border);
    max-height: 70vh;
    overflow: hidden;
}

#bootLog {
    white-space: pre-wrap;
    line-height: 1.7;
    color: var(--accent);
    font-family: var(--font-mono);
    font-size: 0.85rem;
}
