/* Custom Styles for Stack Game */

/* Typography matching globals.css */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
    sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1 {
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 2.5rem;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 2rem;
}

/* Animations */
@keyframes pushIn {
    0% {
        opacity: 0;
        transform: scale(0.5) translateY(-50px);
    }
    50% {
        transform: scale(1.1) translateY(-10px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes popOut {
    0% {
        opacity: 1;
    }
    100% {
        opacity: 0.25;
    }
}

@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translateY(-10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    0% {
        opacity: 0;
        max-height: 0;
    }
    100% {
        opacity: 1;
        max-height: 500px;
    }
}

@keyframes arrowShow {
    0% {
        opacity: 0;
        transform: translateX(20px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

.push-animation {
    animation: pushIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.pop-animation {
    animation: popOut 0.3s ease-out forwards;
}

.ghost-item {
    opacity: 0.25;
}

.message-show {
    animation: fadeIn 0.3s ease-out;
}

.push-input-show {
    animation: fadeInDown 0.3s ease-out;
    overflow: hidden;
}

.arrow-show {
    animation: arrowShow 0.3s ease-out;
}

.history-item-show {
    animation: fadeIn 0.3s ease-out;
}

/* Hover effects */
button:not(:disabled):hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

button:not(:disabled):active {
    transform: translateY(0);
}

button {
    transition: all 0.2s ease;
}

/* Input focus styles */
input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Scrollbar styling */
#historyLog::-webkit-scrollbar {
    width: 8px;
}

#historyLog::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

#historyLog::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

#historyLog::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    h1 {
        font-size: 1.875rem;
        line-height: 2.25rem;
    }
    
    h2 {
        font-size: 1.25rem;
        line-height: 1.75rem;
    }
    
    #topArrow {
        display: none !important;
    }
}

/* Smooth transitions */
.stack-slot {
    transition: all 0.3s ease;
}

/* Additional utility classes */
.border-gradient {
    border-image: linear-gradient(to right, #3b82f6, #8b5cf6) 1;
}
