#hands-hint {
    position: fixed;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 90;
    font-family: Helvetica, sans-serif;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.55);
    background: rgba(0, 0, 0, 0.35);
    padding: 7px 18px;
    border-radius: 20px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

#hands-hint.visible {
    opacity: 1;
}

#loader {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    background: #000;
}

.loader-spinner {
    width: 44px;
    height: 44px;
    border: 3px solid rgba(255, 255, 255, 0.15);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.loader-text {
    margin: 0;
    color: rgba(255, 255, 255, 0.5);
    font-family: Helvetica, sans-serif;
    font-size: 13px;
    letter-spacing: 0.05em;
}

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

body {
    margin: 0;
    padding: 0;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #000;
}

.container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

#webcam {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1); /* Mirror the webcam feed */
}

#canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: scaleX(-1); /* Mirror the canvas to match webcam */
    pointer-events: none;
}

#three-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

#links-para {
    position: absolute;
    bottom: 5px;
    left: 5px;
    font-family: Helvetica, sans-serif;
    font-size: 16px;
    background-color: rgba(255, 255, 255, 0.5);
    padding: 10px;
}

a {
    color: #0000FF !important;
}

/* ── Info button & popup ────────────────────────────────── */

#info-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 100;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(20, 20, 20, 0.6);
    color: rgba(255, 255, 255, 0.75);
    font-size: 15px;
    font-style: italic;
    font-family: Georgia, serif;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    line-height: 1;
}

#info-btn:hover {
    background: rgba(40, 40, 40, 0.8);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
}

#info-popup {
    position: fixed;
    bottom: 62px;
    right: 20px;
    z-index: 100;
    width: 210px;
    background: rgba(12, 12, 12, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(16px);
    padding: 16px;
    font-family: Helvetica, sans-serif;
    color: #d0d0d0;
    display: none;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

#info-popup.visible {
    display: block;
}

.info-header {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 0;
}

.info-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.info-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
}

.info-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.info-name {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.01em;
}

.info-bio {
    margin: 0;
    font-size: 11px;
    color: #666;
}

.info-links {
    display: flex;
    gap: 6px;
    margin-top: 0;
}

.info-links a {
    color: #7eb8f7 !important;
    font-size: 11px;
    text-decoration: none;
    padding: 3px 10px;
    border: 1px solid rgba(126, 184, 247, 0.25);
    border-radius: 20px;
    transition: background 0.15s, border-color 0.15s;
}

.info-links a:hover {
    background: rgba(126, 184, 247, 0.12);
    border-color: rgba(126, 184, 247, 0.5);
}

.info-divider {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    margin: 12px 0 10px;
}

.gesture-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: #bbb;
}

.gesture-row span:first-child {
    color: #777;
}

.gesture-row:last-child {
    border-bottom: none;
}

