/* Global Styles for Dofus Gadgets */

/* Base body styles */
body {
    font-family: 'Inter', sans-serif;
    /* Clean gradient fallback if video fails */
    background: linear-gradient(135deg, #111827 0%, #0d1f22 100%);
    background-color: #111827;
    /* bg-gray-900 fallback */
    color: #e2e8f0;
    /* Light text */
    min-height: 100vh;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Flex centering for main layout if needed, though pages override this often */
    display: flex;
    justify-content: center;
    /* Center horizontally */
    align-items: center;
    /* Center vertically - mostly for landing page */
    flex-direction: column;
    /* Ensure vertical stacking */
}

/* Background video styles */
.video-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -2;
}

.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    /* Dark overlay */
    z-index: -1;
}

/* Card background */
.card-bg {
    background-color: rgba(31, 41, 55, 0.85);
    /* bg-gray-800 with opacity */
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Custom Scrollbar for Chrome/Safari/Edge */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #1f2937;
    /* bg-gray-800 */
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: #0d9488;
    /* teal-600 */
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0f766e;
    /* teal-700 */
}

/* Message Box Styles (Success, Error, Info) */
.message-box {
    padding: 1rem;
    margin-top: 1.5rem;
    border-radius: 0.5rem;
    font-weight: 500;
    display: none;
    /* Hidden by default */
}

.message-box.block {
    display: block;
}

.message-box.error {
    background-color: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border-left: 4px solid #ef4444;
}

.message-box.info {
    background-color: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border-left: 4px solid #3b82f6;
}

.message-box.success {
    background-color: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border-left: 4px solid #10b981;
}

/* Common Loader */
.loader {
    width: 20px;
    height: 20px;
    border: 3px solid #4b5563;
    border-bottom-color: #14b8a6;
    border-radius: 50%;
    display: inline-block;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
}

@keyframes rotation {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Logo Styles for Tool Header */
.tool-logo-container {
    position: relative;
    width: 64px;
    height: 64px;
    display: inline-block;
    vertical-align: middle;
    /* Align with text */
    margin-right: 12px;
}

.tool-logo-egg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    object-fit: contain;
    z-index: 5;
    /* Egg behind */
}

.tool-logo-gear {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 140%;
    height: 140%;
    object-fit: contain;
    z-index: 10;
    /* Gear on top */
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    /* Nice pop effect */
}

/* Spin on link hover */
a:hover .tool-logo-gear {
    transform: translate(-50%, -50%) rotate(180deg);
}