* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
    height: 100%;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
    background: #05060a;
    color: #fff;
}

#bg-canvas,
#bg-image,
#bg-video,
#bg-youtube {
    position: fixed;
    inset: 0;
    z-index: 0;
    transition: opacity 0.8s ease;
}

#bg-canvas,
#bg-image,
#bg-youtube { display: none; }

#bg-image {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

#bg-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
    pointer-events: none;
}

#bg-youtube { overflow: hidden; }
#bg-youtube iframe {
    position: absolute;
    top: 50%; left: 50%;
    width: 100vw; height: 56.25vw;
    min-height: 100vh; min-width: 177.77vh;
    transform: translate(-50%, -50%);
    pointer-events: none;
    border: 0;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: rgba(0, 0, 0, var(--video-overlay, 0));
    transition: background 0.4s ease;
}

@media (hover: hover) and (pointer: fine) {
    * { cursor: none !important; }

    .cursor-dot, .cursor-ring {
        position: fixed;
        top: 0; left: 0;
        pointer-events: none;
        z-index: 9999;
        border-radius: 50%;
        transform: translate(-50%, -50%);
    }
    .cursor-dot {
        width: 6px; height: 6px;
        background: #fff;
        box-shadow: 0 0 10px #fff;
    }
    .cursor-ring {
        width: 34px; height: 34px;
        border: 1.5px solid rgba(255,255,255,0.6);
        transition: width .2s ease, height .2s ease, border-color .2s;
    }
    .cursor-ring.hover {
        width: 56px; height: 56px;
        border-color: #00ff88;
    }
}
@media (hover: none) {
    .cursor-dot, .cursor-ring { display: none; }
}

.card {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transform-style: preserve-3d;
    will-change: transform;
    z-index: 1;
    text-align: center;
    padding: 40px 26px 22px;
    width: 360px;
    max-width: 92vw;
    max-height: 92vh;
    overflow-y: auto;
    background: rgba(15, 17, 25, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 22px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    opacity: 0;
    transition: opacity 0.9s ease, transform 0.15s ease-out;
}

.card.visible {
    opacity: 1;
}

.avatar-wrap {
    width: 110px; height: 110px;
    margin: 0 auto 16px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(135deg, #6a5cff, #00d4ff, #ff3d9a);
    animation: spinGlow 6s linear infinite;
}
@keyframes spinGlow {
    0%   { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}
.avatar {
    width: 100%; height: 100%;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    background: #111;
}

.name {
    font-size: 26px;
    font-weight: 800;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.bio {
    font-size: 14px;
    color: #c9cee0;
    margin-bottom: 22px;
    min-height: 20px;
    font-family: 'JetBrains Mono', monospace;
}
.bio::after {
    content: "▌";
    animation: blink 1s steps(1) infinite;
    margin-left: 2px;
    color: #00ff88;
}
.bio.done::after { display: none; }
@keyframes blink { 50% { opacity: 0; } }

.links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    overflow: hidden;
    transition: transform 0.25s ease,
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.btn .icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease;
}
.btn .icon svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.btn .label { flex: 1; text-align: left; }

.btn:hover {
    transform: translateY(-2px) scale(1.02);
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.btn:hover .icon { transform: scale(1.15); }

.btn[data-brand="discord"]:hover   { box-shadow: 0 0 24px rgba(88,101,242,0.6); border-color:#5865F2; }
.btn[data-brand="instagram"]:hover { box-shadow: 0 0 24px rgba(225,48,108,0.6); border-color:#E1306C; }
.btn[data-brand="tiktok"]:hover    { box-shadow: 0 0 24px rgba(255,0,80,0.5);  border-color:#ff0050; }
.btn[data-brand="youtube"]:hover   { box-shadow: 0 0 24px rgba(255,0,0,0.6);   border-color:#FF0000; }
.btn[data-brand="github"]:hover    { box-shadow: 0 0 24px rgba(255,255,255,0.3); border-color:#fff; }
.btn[data-brand="twitter"]:hover   { box-shadow: 0 0 24px rgba(29,161,242,0.6); border-color:#1DA1F2; }
.btn[data-brand="twitch"]:hover    { box-shadow: 0 0 24px rgba(145,70,255,0.6); border-color:#9146FF; }
.btn[data-brand="spotify"]:hover   { box-shadow: 0 0 24px rgba(30,215,96,0.6);  border-color:#1DB954; }
.btn[data-brand="steam"]:hover     { box-shadow: 0 0 24px rgba(102,192,244,0.6);border-color:#66c0f4; }
.btn[data-brand="telegram"]:hover  { box-shadow: 0 0 24px rgba(34,158,217,0.6); border-color:#229ED9; }
.btn[data-brand="email"]:hover     { box-shadow: 0 0 24px rgba(255,180,0,0.6);  border-color:#ffb400; }
.btn[data-brand="website"]:hover   { box-shadow: 0 0 24px rgba(0,255,136,0.5);  border-color:#00ff88; }

.bottom-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 14px;
    border-top: 1px solid rgba(255,255,255,0.07);
    font-size: 12px;
    color: #8f96ab;
}
.music-btn {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: 0.2s;
}
.music-btn:hover { background: rgba(255,255,255,0.15); }

.music-btn svg {
  width: 16px;
  height: 16px;
  fill: #fff;
  transition: opacity 0.2s;
}
.music-btn.muted svg { opacity: 0.35; }

.visits {
  font-family: 'JetBrains Mono', monospace;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.visits svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  opacity: 0.75;
}

#intro {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: #05060a;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: none;
    transition: opacity 0.9s ease, visibility 0.9s ease;
    animation: introFadeIn 1s ease both;
}
#intro.hidden {
    animation: introFadeOut 0.7s cubic-bezier(0.4, 0.0, 0.2, 1) forwards;
    pointer-events: none;
}

@keyframes introFadeOut {
    0% {
        opacity: 1;
        transform: scale(1);
        filter: blur(0);
    }
    100% {
        opacity: 0;
        transform: scale(1.08);
        filter: blur(8px);
    }
}

@keyframes introFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.intro-content {
    animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse {
    0%, 100% { transform: scale(1);     opacity: 0.85; }
    50%      { transform: scale(1.05);  opacity: 1;    }
}

.intro-title {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: 2px;
    color: #fff;
    margin-bottom: 10px;
    text-shadow: 0 0 30px rgba(0, 255, 136, 0.4);
}

.intro-sub {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    color: #6a5cff;
    letter-spacing: 4px;
    text-transform: uppercase;
}

.intro-title::after {
    content: " ▸";
    animation: blinkArrow 1s steps(2) infinite;
    color: #00ff88;
}
@keyframes blinkArrow {
    50% { opacity: 0; }
}

.ripple {
    position: fixed;
    border-radius: 50%;
    background: radial-gradient(circle,
    rgba(0, 255, 136, 0.55) 0%,
    rgba(106, 92, 255, 0.35) 40%,
    transparent 70%);
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%) scale(0);
    animation: rippleAnim 0.7s ease-out forwards;
}
@keyframes rippleAnim {
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0;
    }
}

.card {
    transform-style: preserve-3d;
    will-change: transform;
    transition: transform 0.15s ease-out,
    opacity 0.9s ease;
}
.card.visible {
    opacity: 1;
}

/* ============================================================
   DISCORD PRESENCE WIDGET
============================================================ */
#discord-activity {
  margin-bottom: 16px;
}

.dc-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(88, 101, 242, 0.12);
  border: 1px solid rgba(88, 101, 242, 0.25);
  text-align: left;
  transition: 0.25s;
}

.dc-card.dc-spotify {
  background: rgba(30, 215, 96, 0.12);
  border-color: rgba(30, 215, 96, 0.3);
}

.dc-card.dc-idle {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.08);
}

.dc-cover {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

.dc-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
  min-width: 0;
}

.dc-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #5865F2;
}
.dc-spotify .dc-label { color: #1DB954; }
.dc-idle .dc-label { color: #8f96ab; }

.dc-label svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

.dc-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dc-sub {
  font-size: 12px;
  color: #b0b6c8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
