/* cursor.css — dot cursor system (see js/v2/cursor.js) */

html.has-dot-cursor,
html.has-dot-cursor * {
    cursor: none !important;
}

.dot-cursor {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 5000;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #000;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease, width 0.2s ease, height 0.2s ease;
}

.dot-cursor.is-visible { opacity: 1; }

/* Interact: ring around the dot */
.dot-cursor::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 1.5px solid #000;
    border-radius: 50%;
    box-sizing: border-box;
    opacity: 0;
    transform: scale(0.4);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.dot-cursor[data-state="interact"]::before {
    opacity: 1;
    transform: scale(1);
}

/* New tab / close: the dot grows to hold a glyph */
.dot-cursor[data-state="newtab"],
.dot-cursor[data-state="close"] {
    width: 15px;
    height: 15px;
}

.dot-cursor__icon {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: #fff;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.dot-cursor[data-state="newtab"] .dot-cursor__icon--newtab,
.dot-cursor[data-state="close"]  .dot-cursor__icon--close {
    opacity: 1;
    transition-delay: 0.08s; /* glyph appears once the dot has mostly grown */
}

/* Pan hint: four arrowheads around the cursor, pulsing one after another clockwise */
.dot-cursor__pan {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    fill: none;
    stroke: #000;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.dot-cursor.has-pan-hint .dot-cursor__pan {
    opacity: 1;
    transform: scale(1);
}

.dot-cursor__pan path {
    opacity: 0.2;
    animation: pan-hint-pulse 0.8s ease-in-out infinite;
}

.dot-cursor__pan path:nth-child(2) { animation-delay: 0.2s; }
.dot-cursor__pan path:nth-child(3) { animation-delay: 0.4s; }
.dot-cursor__pan path:nth-child(4) { animation-delay: 0.6s; }

@keyframes pan-hint-pulse {
    0%, 100% { opacity: 0.2; }
    35%      { opacity: 1; }
}
