/* ============================================================
   Jan Tommy Zonneveld — portfolio
   Dark, sleek, tech — with friendly creatures watching you.
   ============================================================ */

:root {
    --bg: #07090f;
    --bg-2: #0c111c;
    --surface: rgba(255, 255, 255, 0.04);
    --border: rgba(255, 255, 255, 0.09);
    --text: #e6edf6;
    --text-dim: #93a0b4;
    --accent: #22d3ee;       /* cyan */
    --accent-2: #a3e635;     /* lime */
    --accent-3: #818cf8;     /* indigo */
    --glow: rgba(34, 211, 238, 0.35);
    --radius: 18px;
    --font: 'Space Grotesk', system-ui, sans-serif;
    --mono: 'JetBrains Mono', ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background:
        radial-gradient(1200px 800px at 80% -10%, rgba(129, 140, 248, 0.10), transparent 60%),
        radial-gradient(900px 700px at -10% 30%, rgba(34, 211, 238, 0.07), transparent 60%),
        var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

.mono { font-family: var(--mono); }
.accent { color: var(--accent); }
.center { text-align: center; margin-top: 3rem; }

::selection { background: var(--accent); color: #04222a; }

/* ---------- background canvas + cursor glow ---------- */
#particles {
    position: fixed;
    inset: 0;
    z-index: -2;
}

.cursor-glow {
    position: fixed;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.07), transparent 65%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: -1;
    transition: opacity 0.4s;
}

/* ---------- typography ---------- */
h1, h2, h3 { line-height: 1.15; font-weight: 700; }

.gradient-text {
    background: linear-gradient(100deg, var(--accent), var(--accent-2));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* ---------- nav ---------- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.1rem 2.5rem;
    z-index: 100;
    transition: background 0.3s, box-shadow 0.3s, padding 0.3s;
}

.nav.scrolled {
    background: rgba(7, 9, 15, 0.78);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 1px 0 var(--border);
    padding: 0.7rem 2.5rem;
}

.nav-logo {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-link {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    transition: color 0.25s;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    transition: width 0.3s;
}

.nav-link:hover, .nav-link.active { color: var(--text); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.nav-burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}
.nav-burger span {
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- layout ---------- */
.section {
    max-width: 1180px;
    margin: 0 auto;
    padding: 7rem 2.5rem 3rem;
}

.section-head { margin-bottom: 3rem; }

.section-tag {
    color: var(--accent);
    font-size: 0.85rem;
    letter-spacing: 1px;
    display: inline-block;
    margin-bottom: 0.6rem;
    opacity: 0.85;
}

.section-head h2 {
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    display: flex;
    align-items: center;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.section-sub {
    color: var(--text-dim);
    max-width: 640px;
    margin-top: 0.9rem;
}
.section-sub em { color: var(--accent-2); font-style: normal; font-size: 0.9em; }

/* ---------- hero ---------- */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: 8rem;
    position: relative;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 4rem;
    align-items: center;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: 999px;
    padding: 0.4rem 1rem;
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-bottom: 1.6rem;
}

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

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.4); opacity: 0.6; }
}

.hero-title {
    font-size: clamp(2.6rem, 6vw, 4.4rem);
    letter-spacing: -1.5px;
    margin-bottom: 1.4rem;
}

.hero-sub {
    color: var(--text-dim);
    font-size: 1.08rem;
    max-width: 540px;
    margin-bottom: 2rem;
}

.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.8rem; }

.btn {
    display: inline-block;
    padding: 0.85rem 1.7rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    font-family: var(--font);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn-primary {
    background: linear-gradient(100deg, var(--accent), #38bdf8);
    color: #04222a;
    box-shadow: 0 8px 30px -8px var(--glow);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 38px -8px var(--glow); }

.btn-ghost {
    border-color: var(--border);
    color: var(--text);
    background: var(--surface);
}
.btn-ghost:hover { border-color: var(--accent); transform: translateY(-2px); }

.btn-block { width: 100%; text-align: center; }

.hero-stats { display: flex; gap: 2.6rem; flex-wrap: wrap; }

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    display: block;
}
.stat-number::after { content: '+'; color: var(--accent-2); }

.stat-label { color: var(--text-dim); font-size: 0.85rem; }

/* ---------- hero visual / terminal ---------- */
.hero-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.terminal {
    width: 100%;
    max-width: 460px;
    background: rgba(10, 14, 22, 0.92);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(34, 211, 238, 0.05);
}

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

.t-dot { width: 11px; height: 11px; border-radius: 50%; }
.t-dot.red { background: #ff5f57; }
.t-dot.yellow { background: #febc2e; }
.t-dot.green { background: #28c840; }

.terminal-title { margin-left: auto; margin-right: auto; font-size: 0.75rem; color: var(--text-dim); }

.terminal-body {
    padding: 1.1rem 1.2rem 1.4rem;
    font-size: 0.8rem;
    min-height: 215px;
    color: #b7c5d8;
    white-space: pre-wrap;
}

.terminal-body .t-prompt { color: var(--accent-2); }
.terminal-body .t-ok { color: var(--accent); }
.terminal-body .t-warn { color: #fbbf24; }

.t-cursor {
    display: inline-block;
    width: 8px;
    height: 14px;
    background: var(--accent);
    vertical-align: -2px;
    animation: blinkCursor 0.9s steps(1) infinite;
}
@keyframes blinkCursor { 50% { opacity: 0; } }

/* ---------- mascot robot ---------- */
.mascot {
    position: relative;
    cursor: pointer;
    margin-bottom: 1.4rem;
    user-select: none;
    -webkit-user-select: none;
    animation: hover-float 4s ease-in-out infinite;
    z-index: 5;
}

@keyframes hover-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.mascot.bounce { animation: mascot-bounce 0.55s; }
@keyframes mascot-bounce {
    0% { transform: scale(1); }
    35% { transform: scale(1.12, 0.85); }
    60% { transform: scale(0.92, 1.1); }
    100% { transform: scale(1); }
}

.antenna {
    width: 3px;
    height: 26px;
    background: linear-gradient(#475569, #64748b);
    margin: 0 auto;
    position: relative;
    transform-origin: bottom;
    animation: antenna-wobble 3.5s ease-in-out infinite;
}
@keyframes antenna-wobble {
    0%, 100% { transform: rotate(-6deg); }
    50% { transform: rotate(8deg); }
}

.antenna-ball {
    position: absolute;
    top: -9px;
    left: 50%;
    transform: translateX(-50%);
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--accent-2);
    box-shadow: 0 0 14px var(--accent-2);
    animation: pulse 1.6s infinite;
}

.bot-head {
    width: 120px;
    height: 88px;
    background: linear-gradient(145deg, #1c2638, #11192a);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    padding-top: 10px;
    box-shadow: inset 0 2px 8px rgba(255, 255, 255, 0.06), 0 16px 35px -16px rgba(0, 0, 0, 0.8);
    position: relative;
}

.bot-mouth {
    flex-basis: 100%;
    width: 34px;
    height: 7px;
    margin: -4px auto 0;
    border-radius: 0 0 10px 10px;
    background: var(--accent);
    box-shadow: 0 0 10px var(--glow);
    transition: height 0.2s, border-radius 0.2s, width 0.2s;
}
.bot-mouth.happy { height: 14px; width: 40px; border-radius: 0 0 20px 20px; }

.bot-body {
    width: 88px;
    height: 50px;
    margin: 6px auto 0;
    background: linear-gradient(145deg, #1a2438, #0f1626);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bot-lights { display: flex; gap: 9px; }

.bot-light {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    animation: light-cycle 1.8s infinite;
}
.bot-light.l1 { background: var(--accent); animation-delay: 0s; }
.bot-light.l2 { background: var(--accent-2); animation-delay: 0.3s; }
.bot-light.l3 { background: var(--accent-3); animation-delay: 0.6s; }

@keyframes light-cycle {
    0%, 100% { opacity: 0.25; }
    50% { opacity: 1; box-shadow: 0 0 8px currentColor; }
}

.bot-shadow {
    width: 90px;
    height: 12px;
    margin: 14px auto 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    filter: blur(4px);
    animation: shadow-pulse 4s ease-in-out infinite;
}
@keyframes shadow-pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(0.82); opacity: 0.3; }
}

.speech {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) scale(0.7);
    background: #e6edf6;
    color: #0b1020;
    font-weight: 600;
    font-size: 0.82rem;
    padding: 0.55rem 0.9rem;
    border-radius: 12px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s, transform 0.25s;
    z-index: 10;
}
.speech::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 7px solid transparent;
    border-top-color: #e6edf6;
}
.speech.show { opacity: 1; transform: translateX(-50%) scale(1); }

/* ---------- eyes (shared by all creatures) ---------- */
.eye, .g-eye {
    width: 26px;
    height: 26px;
    background: #f8fafc;
    border-radius: 50%;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 -3px 6px rgba(0, 0, 0, 0.18);
    flex: none;
}

.g-eye.sm { width: 16px; height: 16px; }

.pupil {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 42%;
    height: 42%;
    background: #0b1020;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.08s linear;
}

.eye.blink, .g-eye.blink { animation: do-blink 0.18s; }
@keyframes do-blink {
    0%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.08); }
}

/* googly pair in headings */
.googly {
    display: inline-flex;
    gap: 4px;
    vertical-align: middle;
    animation: googly-bob 3s ease-in-out infinite;
}
@keyframes googly-bob {
    0%, 100% { transform: translateY(0) rotate(-3deg); }
    50% { transform: translateY(-5px) rotate(3deg); }
}

/* ---------- scroll hint ---------- */
.scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.8rem;
    transition: color 0.25s;
}
.scroll-hint:hover { color: var(--accent); }
.scroll-arrow { display: inline-block; animation: arrow-bounce 1.6s infinite; }
@keyframes arrow-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

/* ---------- about ---------- */
.about-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3rem;
    align-items: start;
}

.about-text p { color: var(--text-dim); margin-bottom: 1.2rem; }
.about-text strong { color: var(--text); }

.about-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    backdrop-filter: blur(8px);
}

.blob-buddy {
    position: absolute;
    top: -34px;
    right: 26px;
    width: 74px;
    height: 44px;
    background: linear-gradient(145deg, var(--accent-3), #5b63d3);
    border-radius: 40px 40px 6px 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 -6px 20px -8px rgba(129, 140, 248, 0.6);
    animation: buddy-peek 6s ease-in-out infinite;
}
@keyframes buddy-peek {
    0%, 100% { transform: translateY(12px); }
    15%, 85% { transform: translateY(0); }
}
.blob-buddy .g-eye { width: 20px; height: 20px; }

.info-list { font-size: 0.86rem; }
.info-list div {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border);
}
.info-list div:last-of-type { margin-bottom: 1.4rem; }
.info-list dt { color: var(--text-dim); }
.info-list dt::before { content: '> '; color: var(--accent-2); }
.info-list dd { text-align: right; }
.info-list a { color: var(--accent); text-decoration: none; }
.info-list a:hover { text-decoration: underline; }
.status-ok { color: var(--accent-2); }

/* ---------- projects ---------- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.6rem;
}

.project-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.8rem;
    overflow: hidden;
    transform-style: preserve-3d;
    transition: border-color 0.3s, box-shadow 0.3s;
    --mx: 50%;
    --my: 50%;
}

.project-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(420px circle at var(--mx) var(--my), rgba(34, 211, 238, 0.10), transparent 45%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.project-card:hover { border-color: rgba(34, 211, 238, 0.4); box-shadow: 0 22px 50px -25px var(--glow); }
.project-card:hover::before { opacity: 1; }

.card-eyes {
    position: absolute;
    top: 1.1rem;
    right: 1.1rem;
    display: flex;
    gap: 3px;
}

.project-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: linear-gradient(145deg, rgba(34, 211, 238, 0.18), rgba(163, 230, 53, 0.12));
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 1.1rem;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-bottom: 0.85rem;
    font-size: 0.7rem;
}
.project-tags span {
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    padding: 0.18rem 0.6rem;
    border-radius: 999px;
    color: var(--text-dim);
}

.project-card h3 { font-size: 1.25rem; margin-bottom: 0.6rem; }
.project-card p { color: var(--text-dim); font-size: 0.93rem; margin-bottom: 1.2rem; }

.project-links { display: flex; gap: 1.3rem; font-size: 0.82rem; }
.project-links a { color: var(--accent); text-decoration: none; }
.project-links a:hover { color: var(--accent-2); }
.project-links .demo-link {
    color: var(--accent-2);
    border: 1px solid rgba(163, 230, 53, 0.4);
    border-radius: 8px;
    padding: 0.15rem 0.6rem;
}
.project-links .demo-link:hover { color: #04222a; background: var(--accent-2); }

/* ---------- lab: terraform demo ---------- */
.inline-link { color: var(--accent); text-decoration: none; }
.inline-link:hover { text-decoration: underline; }

.lab-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.lab-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1rem;
}

.lab-btn {
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font-family: var(--mono);
    font-size: 0.78rem;
    padding: 0.55rem 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: border-color 0.2s, transform 0.2s, opacity 0.2s, box-shadow 0.2s;
}
.lab-btn::before { content: '$ '; color: var(--accent-2); }
.lab-btn:hover:not(:disabled) { border-color: var(--accent); transform: translateY(-2px); }
.lab-btn.apply { border-color: rgba(163, 230, 53, 0.5); }
.lab-btn.apply:hover:not(:disabled) { border-color: var(--accent-2); box-shadow: 0 6px 20px -8px rgba(163, 230, 53, 0.5); }
.lab-btn.danger { border-color: rgba(244, 63, 94, 0.4); }
.lab-btn.danger:hover:not(:disabled) { border-color: #f43f5e; box-shadow: 0 6px 20px -8px rgba(244, 63, 94, 0.5); }
.lab-btn:disabled { opacity: 0.4; cursor: wait; }

.lab-terminal { max-width: none; }
.lab-terminal .terminal-body {
    min-height: 280px;
    max-height: 280px;
    overflow-y: auto;
}
.terminal-body .t-err { color: #f87171; }
.terminal-body .t-add { color: var(--accent-2); }

.diagram {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.4rem;
}

.rg {
    border: 1.5px dashed rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    padding: 1.1rem;
    transition: border-color 0.4s, background 0.4s;
}
.rg.alive {
    border-color: rgba(34, 211, 238, 0.55);
    background: rgba(34, 211, 238, 0.04);
}

.rg-label {
    display: block;
    font-size: 0.72rem;
    color: var(--text-dim);
    margin-bottom: 0.9rem;
}
.rg.alive .rg-label { color: var(--accent); }

.nodes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

.node {
    border: 1.5px dashed var(--border);
    border-radius: 12px;
    padding: 0.9rem 0.8rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    text-align: center;
    opacity: 0.38;
    transition: opacity 0.4s, border-color 0.4s, box-shadow 0.4s, background 0.4s;
    position: relative;
}

.node-ico { font-size: 1.4rem; }
.node-eyes { display: flex; gap: 3px; height: 1.6rem; align-items: center; }
.node-name { font-weight: 600; font-size: 0.88rem; }
.node-type { font-size: 0.6rem; color: var(--text-dim); word-break: break-all; }

.node.planned {
    opacity: 0.8;
    border-color: rgba(163, 230, 53, 0.6);
}
.node.planned::after {
    content: '+';
    position: absolute;
    top: 6px;
    right: 9px;
    color: var(--accent-2);
    font-family: var(--mono);
    font-weight: 700;
}

.node.alive {
    opacity: 1;
    border-style: solid;
    border-color: rgba(34, 211, 238, 0.6);
    background: rgba(34, 211, 238, 0.05);
    box-shadow: 0 8px 24px -10px var(--glow);
    animation: node-pop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes node-pop {
    0% { transform: scale(0.85); }
    60% { transform: scale(1.06); }
    100% { transform: scale(1); }
}

.diagram-status {
    margin-top: 1rem;
    font-size: 0.72rem;
    color: var(--text-dim);
    text-align: center;
}
.diagram-status.ok { color: var(--accent-2); }

.lab-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 1.4rem;
}
.lab-features span {
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: 999px;
    padding: 0.35rem 0.9rem;
    font-size: 0.72rem;
    color: var(--text-dim);
    transition: border-color 0.25s, color 0.25s;
}
.lab-features span:hover { border-color: var(--accent-2); color: var(--text); }

/* ---------- certifications ---------- */
.cert-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 2rem;
}

.cert-filters button {
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-dim);
    font-family: var(--mono);
    font-size: 0.78rem;
    padding: 0.45rem 1rem;
    border-radius: 999px;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.cert-filters button:hover { border-color: var(--accent); color: var(--text); }
.cert-filters button.active {
    border-color: var(--accent);
    color: #04222a;
    background: linear-gradient(100deg, var(--accent), #38bdf8);
    font-weight: 700;
}

.certs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.1rem;
}

.cert-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.2rem 1.3rem;
    transition: transform 0.25s, border-color 0.25s, opacity 0.3s;
}
.cert-card:hover { transform: translateY(-4px); border-color: rgba(34, 211, 238, 0.45); }
.cert-card[data-cat="ai"] { border-left: 3px solid var(--accent-2); }
.cert-card.filtered-out { display: none; }

.cert-badge {
    display: inline-block;
    font-size: 0.6rem;
    letter-spacing: 1px;
    color: var(--accent);
    border: 1px solid rgba(34, 211, 238, 0.35);
    border-radius: 6px;
    padding: 0.1rem 0.45rem;
    margin-bottom: 0.6rem;
}
.cert-card[data-cat="ai"] .cert-badge { color: var(--accent-2); border-color: rgba(163, 230, 53, 0.4); }

.cert-card h3 { font-size: 0.95rem; margin-bottom: 0.35rem; line-height: 1.35; }
.cert-issuer { color: var(--text-dim); font-size: 0.8rem; }

/* ---------- skills ---------- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.6rem;
}

.skill-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.8rem;
    transition: transform 0.3s, border-color 0.3s;
}
.skill-card:hover { transform: translateY(-6px); border-color: rgba(163, 230, 53, 0.35); }

.skill-head { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 1.4rem; }
.skill-emoji { font-size: 1.5rem; }
.skill-head h3 { font-size: 1.05rem; }

.skill-bar { margin-bottom: 1rem; }
.skill-name { font-size: 0.85rem; color: var(--text-dim); display: block; margin-bottom: 0.35rem; }

.bar {
    height: 7px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.07);
    overflow: hidden;
}

.fill {
    height: 100%;
    width: 0;
    border-radius: 99px;
    background: linear-gradient(90deg, var(--accent), var(--accent-2));
    box-shadow: 0 0 12px var(--glow);
    transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.skill-card.visible .fill { width: var(--w); }

/* ---------- contact ---------- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
}

.contact-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 1.6rem;
}

.contact-ico {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex: none;
}

.c-label { display: block; color: var(--accent); font-size: 0.72rem; margin-bottom: 0.1rem; }
.contact-item a { color: var(--text); text-decoration: none; }
.contact-item a:hover { color: var(--accent); }

.socials { display: flex; gap: 0.8rem; margin-top: 2rem; }

.social-btn {
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    padding: 0.6rem 1.2rem;
    border-radius: 12px;
    text-decoration: none;
    font-size: 0.83rem;
    transition: border-color 0.25s, transform 0.25s;
}
.social-btn:hover { border-color: var(--accent); transform: translateY(-2px); }

.contact-cta {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.6rem 2.2rem;
    text-align: center;
    position: relative;
}

.cta-eyes {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-bottom: 1.2rem;
}

.cta-line {
    color: var(--accent-2);
    font-size: 0.78rem;
    margin-bottom: 1rem;
    word-break: break-all;
}

.contact-cta > p:not(.cta-line) {
    color: var(--text-dim);
    max-width: 380px;
    margin: 0 auto 1.8rem;
}

.btn-big { font-size: 1.05rem; padding: 1rem 2.4rem; }

/* ---------- peeker creature ---------- */
.peeker {
    position: fixed;
    bottom: 0;
    right: 7vw;
    z-index: 90;
    transform: translateY(105%);
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
}
.peeker.up { transform: translateY(30%); }
.peeker.hiding { transform: translateY(105%); transition: transform 0.25s ease-in; }

.peeker-body {
    width: 96px;
    height: 80px;
    background: linear-gradient(160deg, #2dd4bf, #0d9488);
    border-radius: 48px 48px 0 0;
    display: flex;
    justify-content: center;
    gap: 10px;
    padding-top: 20px;
    box-shadow: 0 -8px 30px -10px rgba(45, 212, 191, 0.5);
}

.peeker-hand {
    position: absolute;
    top: 58px;
    width: 16px;
    height: 16px;
    border-radius: 50% 50% 0 0;
    background: #2dd4bf;
}
.peeker-hand.h1 { left: -10px; }
.peeker-hand.h2 { right: -10px; }

/* ---------- footer + walker ---------- */
.footer {
    position: relative;
    border-top: 1px solid var(--border);
    margin-top: 5rem;
    padding: 3.5rem 2rem 2.5rem;
    text-align: center;
    overflow: hidden;
}

.footer-inner p { color: var(--text-dim); margin-top: 0.6rem; font-size: 0.92rem; }
.footer-quote { color: var(--accent) !important; font-size: 0.82rem !important; }
.footer-copy { font-size: 0.78rem !important; }

.walker {
    position: absolute;
    top: -1px;
    left: 0;
    animation: walk-across 22s linear infinite;
    pointer-events: none;
}

@keyframes walk-across {
    0% { left: -60px; transform: scaleX(1); }
    49% { left: calc(100% + 10px); transform: scaleX(1); }
    50% { left: calc(100% + 10px); transform: scaleX(-1); }
    99% { left: -60px; transform: scaleX(-1); }
    100% { left: -60px; transform: scaleX(1); }
}

.walker-body {
    width: 44px;
    height: 30px;
    background: linear-gradient(160deg, #f472b6, #db2777);
    border-radius: 22px 22px 8px 8px;
    display: flex;
    justify-content: center;
    gap: 4px;
    padding-top: 6px;
    animation: walker-bob 0.4s ease-in-out infinite;
}
@keyframes walker-bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

.walker-leg {
    position: absolute;
    top: 28px;
    width: 5px;
    height: 10px;
    border-radius: 3px;
    background: #db2777;
}
.walker-leg.leg1 { left: 9px; animation: step 0.4s ease-in-out infinite; }
.walker-leg.leg2 { right: 9px; animation: step 0.4s ease-in-out infinite reverse; }
@keyframes step {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* ---------- reveal on scroll ---------- */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ---------- party mode (Konami) ---------- */
body.party {
    animation: party-hue 3s linear infinite;
}
@keyframes party-hue {
    to { filter: hue-rotate(360deg); }
}

.confetti-creature {
    position: fixed;
    top: -60px;
    font-size: 28px;
    z-index: 999;
    pointer-events: none;
    animation: confetti-fall linear forwards;
}
@keyframes confetti-fall {
    to { transform: translateY(110vh) rotate(720deg); }
}

/* ---------- responsive ---------- */
@media (max-width: 960px) {
    .hero-grid { grid-template-columns: 1fr; gap: 3rem; }
    .hero-visual { order: -1; }
    .about-grid, .contact-grid, .lab-grid { grid-template-columns: 1fr; }
    .projects-grid { grid-template-columns: 1fr; }
    .skills-grid { grid-template-columns: 1fr; }
    .certs-grid { grid-template-columns: 1fr 1fr; }
    .hero { padding-top: 9rem; }
}

@media (max-width: 720px) {
    .nav { padding: 1rem 1.4rem; }
    .nav.scrolled { padding: 0.8rem 1.4rem; }
    .section { padding: 5rem 1.4rem 2rem; }
    .nav-burger { display: flex; }
    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: min(75vw, 300px);
        background: rgba(10, 14, 22, 0.97);
        backdrop-filter: blur(16px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2.2rem;
        transform: translateX(100%);
        transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
        z-index: 99;
    }
    .nav-links.open { transform: translateX(0); }
    .peeker { right: 4vw; }
    .certs-grid { grid-template-columns: 1fr; }
    .nodes { grid-template-columns: 1fr 1fr; }
    .scroll-hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
}
