/* Natural Order - MTG Trading Platform Styles */

/* Logo text styles */
.logo-text {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.2;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.logo-natural {
    color: #1a4d2e;
}

.logo-order {
    background: linear-gradient(
        to bottom,
        #e2c68e 0%,
        #b58d3e 50%,
        #8d6e2f 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

/* Base styles */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

.font-display {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Radio card selection styles */
.radio-card input:checked + div,
.checkbox-card input:checked + div {
    border-color: #16a34a;
    background-color: rgba(22, 163, 74, 0.1);
    box-shadow: 0 0 0 1px #16a34a;
}

.radio-card input:focus + div,
.checkbox-card input:focus + div {
    outline: 2px solid #22c55e;
    outline-offset: 2px;
}

/* Checkbox card disabled state (max selections reached) */
.checkbox-card.disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* Form input focus states */
input[type="email"]:focus {
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
}

/* Button hover effects */
button {
    transition: all 0.2s ease;
}

button:active {
    transform: scale(0.98);
}

/* Progress bar animation */
#progress-bar {
    transition: width 0.4s ease-out;
}

/* Form step transitions */
.form-step {
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Success message animation */
#success-message:not(.hidden) {
    animation: successPop 0.5s ease-out;
}

@keyframes successPop {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Hero section */
header {
    position: relative;
}

/* Card hover effects */
.bg-mtg-dark\/50:hover {
    transform: translateY(-2px);
    transition: transform 0.2s ease;
}

/* Mobile-first responsive adjustments */
@media (max-width: 640px) {
    .font-display {
        letter-spacing: -0.02em;
    }

    /* Stack radio cards on very small screens */
    .grid-cols-3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Accessibility: Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* Focus visible for keyboard navigation */
:focus-visible {
    outline: 2px solid #22c55e;
    outline-offset: 2px;
}

/* Custom scrollbar for webkit browsers */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0d0d0d;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #16a34a;
}

/* Loading state for submit button */
.loading {
    position: relative;
    color: transparent !important;
}

.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Error shake animation */
.shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    60% { transform: translateX(-10px); }
    80% { transform: translateX(10px); }
}
