@import 'react-awesome-button/dist/styles.css';

@tailwind base;
@tailwind components;
@tailwind utilities;

html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 20px;
}

/* Mobile responsive scrollbar */
@media (max-width: 768px) {
    ::-webkit-scrollbar {
        width: 8px;
    }
}

@media (max-width: 480px) {
    ::-webkit-scrollbar {
        width: 6px;
    }
}

::-webkit-scrollbar-track {
    background-color: transparent;
}

::-webkit-scrollbar-thumb {
    @apply bg-caramel;
    border-radius: 20px;
    border: 6px solid transparent;
    background-clip: content-box;
    transition: background-color 0.3s ease;
}

/* Adjust border for mobile */
@media (max-width: 768px) {
    ::-webkit-scrollbar-thumb {
        border: 2px solid transparent;
        border-radius: 10px;
    }
}

@media (max-width: 480px) {
    ::-webkit-scrollbar-thumb {
        border: 1px solid transparent;
        border-radius: 6px;
    }
}
::-webkit-scrollbar-thumb:hover {
    @apply bg-caramelLight;
}

:root {
    --ease-elastic-3: cubic-bezier(0.68, -0.6, 0.32, 1.6);
    --ease-elastic-4: cubic-bezier(0.68, -0.55, 0.27, 1.55);
    --ease-out-5: cubic-bezier(0.2, 0.8, 0.2, 1);
    --ease-3: cubic-bezier(0.25, 0.1, 0.25, 1);
    --icon-fill: #ea6925;
    --cursor-color: #fff;
}

.dark:root {
    --cursor-color: white;
}

.dark .theme-toggle {
    --icon-fill: white;
}

.sun-and-moon > :is(.moon, .sun, .sun-beams) {
    transform-origin: center;
}

.sun-and-moon > :is(.moon, .sun) {
    fill: var(--icon-fill);
}

.sun-and-moon > .sun-beams {
    stroke: var(--icon-fill);
    stroke-width: 2px;
}

.dark .sun-and-moon > .sun {
    transform: scale(1.75);
}

.dark .sun-and-moon > .sun-beams {
    opacity: 0;
}

.dark .sun-and-moon > .moon > circle {
    transform: translateX(-7px);
}

@supports (cx: 1) {
    .dark .sun-and-moon > .moon > circle {
        cx: 17;
        transform: translateX(0);
    }
}

@media (prefers-reduced-motion: no-preference) {
    .sun-and-moon > .sun {
        transition: transform 0.5s var(--ease-elastic-3);
    }

    .sun-and-moon > .sun-beams {
        transition:
            transform 0.5s var(--ease-elastic-4),
            opacity 0.5s var(--ease-3);
    }

    .sun-and-moon .moon > circle {
        transition: transform 0.25s var(--ease-out-5);
    }

    @supports (cx: 1) {
        .sun-and-moon .moon > circle {
            transition: cx 0.25s var(--ease-out-5);
        }
    }

    .dark .sun-and-moon > .sun {
        transition-timing-function: var(--ease-3);
        transition-duration: 0.25s;
        transform: scale(1.75);
    }

    .dark .sun-and-moon > .sun-beams {
        transition-duration: 0.15s;
        transform: rotateZ(-25deg);
    }

    .dark .sun-and-moon > .moon > circle {
        transition-duration: 0.5s;
        transition-delay: 0.25s;
    }
}

.status-active {
    background-color: #55ff00;
    border-radius: 360px;
}
