/* 3D Flip Effect Utilities */
.perspective-1000 {
    perspective: 1000px;
}

.preserve-3d {
    transform-style: preserve-3d;
}

.backface-hidden {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.rotate-y-180 {
    transform: rotateY(180deg);
}

.flipped {
    transform: rotateY(180deg);
}

/* Custom Scrollbar for card back */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: transparent;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #e5e7eb;
    border-radius: 4px;
}

.dark .custom-scrollbar::-webkit-scrollbar-thumb {
    background: #374151;
}

/* Focus Mode transitions */
body {
    transition: background-color 0.5s ease;
}

/* Specific Card Colors applied via JS based on category */
.card-color-2xx {
    color: #22c55e;
}

.card-color-3xx {
    color: #3b82f6;
}

.card-color-4xx {
    color: #f59e0b;
}

.card-color-5xx {
    color: #ef4444;
}

.card-color-headers {
    color: #8b5cf6;
}

/* Subtle reveal for flipped state */
.controls-visible {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translateY(0) !important;
}

/* Glowing text on front based on category */
.text-glow-2xx {
    text-shadow: 0 0 40px rgba(34, 197, 94, 0.4);
}

.text-glow-3xx {
    text-shadow: 0 0 40px rgba(59, 130, 246, 0.4);
}

.text-glow-4xx {
    text-shadow: 0 0 40px rgba(245, 158, 11, 0.4);
}

.text-glow-5xx {
    text-shadow: 0 0 40px rgba(239, 68, 68, 0.4);
}

.text-glow-headers {
    text-shadow: 0 0 40px rgba(139, 92, 246, 0.4);
}