/* ========================================
   UTILITIES (Floating buttons, cursor)
   ======================================== */

/* Fixed utilities container */
.utilities {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 70;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* WhatsApp button */
.whatsapp-btn {
    width: 4rem;
    height: 4rem;
    background: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.3);
    transition: transform 0.3s;
    position: relative;
}

.whatsapp-btn:hover {
    transform: scale(1.1);
}

.whatsapp-btn svg {
    width: 32px;
    height: 32px;
}

.whatsapp-btn__tooltip {
    position: absolute;
    left: 5rem;
    background: black;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.whatsapp-btn:hover .whatsapp-btn__tooltip {
    opacity: 1;
}

.whatsapp-btn__tooltip::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -0.5rem;
    transform: translateY(-50%);
    border: 8px solid transparent;
    border-right-color: black;
    border-left-width: 0;
}

/* Theme switcher */
.theme-btn {
    width: 4rem;
    height: 4rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.5s;
    overflow: hidden;
    position: relative;
}

.dark .theme-btn {
    background: black;
    border-color: rgba(255, 255, 255, 0.1);
}

.theme-btn:hover {
    transform: scale(1.1);
}

.theme-btn svg {
    width: 28px;
    height: 28px;
    color: var(--primary-orange);
    fill: var(--primary-orange);
    position: absolute;
    transition: all 0.5s;
}

.theme-btn__moon {
    opacity: 0;
    transform: rotate(180deg) translateY(40px);
}

.theme-btn__sun {
    opacity: 1;
    transform: rotate(0) translateY(0);
}

.dark .theme-btn__moon {
    opacity: 1;
    transform: rotate(0) translateY(0);
}

.dark .theme-btn__sun {
    opacity: 0;
    transform: rotate(-180deg) translateY(-40px);
}

/* Back to top */
.back-to-top {
    width: 4rem;
    height: 4rem;
    background: white;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    opacity: 0;
    transform: scale(0) translateY(20px);
    pointer-events: none;
}

.dark .back-to-top {
    background: black;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.back-to-top.visible {
    opacity: 1;
    transform: scale(1) translateY(0);
    pointer-events: all;
}

.back-to-top:hover {
    background: black;
    color: white;
}

.dark .back-to-top:hover {
    background: var(--primary-orange);
    color: black;
}

.back-to-top svg {
    width: 28px;
    height: 28px;
}

/* Custom Cursor */
.custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 2rem;
    height: 2rem;
    border: 2px solid var(--primary-orange);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, background-color 0.3s;
    will-change: transform;
    display: none;
}

@media (pointer: fine) {
    .custom-cursor {
        display: block;
    }
}

.custom-cursor.hovered {
    width: 4rem;
    height: 4rem;
    background: rgba(124, 179, 66, 0.2);
}

.custom-cursor-dot {
    position: fixed;
    top: 0;
    left: 0;
    width: 0.375rem;
    height: 0.375rem;
    background: var(--primary-orange);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    will-change: transform;
    display: none;
}

@media (pointer: fine) {
    .custom-cursor-dot {
        display: block;
    }
}

/* Mobile heading adjustments */
@media (max-width: 480px) {
    h1 {
        font-size: 2rem !important;
    }

    h2 {
        font-size: 1.75rem !important;
    }

    h3 {
        font-size: 1.5rem !important;
    }

    .section-title {
        font-size: 1.75rem !important;
    }
}

@media (max-width: 360px) {
    h1 {
        font-size: 1.75rem !important;
    }

    h2 {
        font-size: 1.5rem !important;
    }

    .hero__title {
        font-size: 1.75rem !important;
    }
}