/* --- 1. Base Resets --- */
*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, sans-serif;
    /* Force Light/Orange Background */
    background-color: #fff7ed; 
    color: #1f2937;
    line-height: 1.5;
}

/* --- 2. Scrollbars (Orange Themed) --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fff7ed;
}
::-webkit-scrollbar-thumb {
    background: #fdba74; /* Light Orange */
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #f97316; /* Orange 500 */
}

/* --- 3. Layout Utilities --- */
.min-h-screen { min-height: 100vh; }
.w-full { width: 100%; }
.h-full { height: 100%; }
.max-w-5xl { max-width: 64rem; }
.max-w-md { max-width: 28rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Spacing */
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }

/* Flexbox */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.flex-1 { flex: 1 1 0%; }
.flex-wrap { flex-wrap: wrap; }

/* Grid */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Visibility */
.hidden { display: none; }
.block { display: block; }

/* Positioning */
.fixed { position: fixed; }
.absolute { position: absolute; }
.relative { position: relative; }
.sticky { position: sticky; }
.top-0 { top: 0; }
.bottom-0 { bottom: 0; }
.bottom-6 { bottom: 1.5rem; }
.right-6 { right: 1.5rem; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.z-10 { z-index: 10; }
.z-30 { z-index: 30; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

/* --- 4. Styling & Colors (FORCING ORANGE THEME) --- */

/* App Backgrounds - Mapping Dark/Gray classes to Light/Orange */
.bg-gray-50, .bg-gray-950 { 
    background-color: #fff7ed; /* Orange-50 */
}

/* Card Backgrounds */
.bg-white, .bg-gray-900 { 
    background-color: #ffffff; 
    border: 1px solid #fed7aa; /* Orange-200 border */
    color: #1f2937;
}

/* Header Background */
.bg-white\/80, .bg-gray-900\/50 {
    background-color: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid #fed7aa;
}
.backdrop-blur-md { backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }

/* Primary Colors (Orange/Yellow) */
/* This maps both the new orange classes AND the old blue classes to Orange */
.bg-orange-500, .bg-blue-600 { 
    background-color: #f97316; /* Orange-500 */
    color: white;
}
.bg-orange-50 { background-color: #fff7ed; }

/* Gradients */
.bg-gradient-to-br { 
    background-image: linear-gradient(to bottom right, #f97316, #eab308); /* Orange to Yellow */
    color: white;
}

/* Text Colors */
.text-gray-900, .text-gray-200, .text-white { color: #111827; } /* Make default text dark */
.text-gray-500, .text-gray-400 { color: #6b7280; }
.text-white { color: #111827; } /* Force white text to be dark on light backgrounds */

/* Exceptions for text inside buttons/cards with dark backgrounds */
.bg-orange-500 .text-white, 
.bg-blue-600 .text-white,
.bg-gradient-to-br .text-white,
button .text-white {
    color: #ffffff !important;
}

/* Accents */
.text-orange-500, .text-blue-500 { color: #f97316; }
.text-orange-600 { color: #ea580c; }
.text-red-500, .text-red-400 { color: #ef4444; }
.text-green-500, .text-green-400 { color: #16a34a; }
.text-yellow-500, .text-yellow-400 { color: #ca8a04; }

/* Text Styles */
.font-bold { font-weight: 700; }
.font-medium { font-weight: 500; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.uppercase { text-transform: uppercase; }
.tracking-wider { letter-spacing: 0.05em; }
.text-center { text-align: center; }
.text-right { text-align: right; }

/* Borders & Radius */
.border { border-width: 1px; border-style: solid; }
.border-b { border-bottom-width: 1px; border-bottom-style: solid; }
.border-t { border-top-width: 1px; border-top-style: solid; }
.border-gray-200, .border-gray-800, .border-gray-700 { border-color: #fed7aa; /* Orange-200 */ }

.rounded-xl { border-radius: 0.75rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-full { border-radius: 9999px; }

/* Shadows */
.shadow-sm, .shadow-lg { box-shadow: 0 4px 6px -1px rgba(249, 115, 22, 0.1), 0 2px 4px -1px rgba(249, 115, 22, 0.06); }

/* --- 5. Inputs & Buttons --- */
button { cursor: pointer; border: none; outline: none; font-family: inherit; }
button:active { transform: scale(0.95); }

input, select {
    width: 100%;
    outline: none;
    background: #fff;
    border: 1px solid #fed7aa;
    color: #111827;
    font-family: inherit;
}
input:focus, select:focus {
    border-color: #f97316;
    box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.2);
}

/* Fix for icons */
svg { display: inline-block; vertical-align: middle; }

/* Modals */
/* Note: The \ escapes the brackets [ ] */
.max-h-\[90vh\] { max-height: 90vh; }
.overflow-y-auto { overflow-y: auto; }
.bg-black\/50, .bg-black\/80 { background-color: rgba(0, 0, 0, 0.5); }


/* --- 6. Responsive & States (The "Weird" Escaping) --- */
/* NOTE: These backslashes \ are NOT errors. 
   They allow us to use the exact class names from the JS code.
   If cPanel shows red lines here, ignore them. 
*/

.hover\:bg-orange-600:hover, .hover\:bg-blue-500:hover { background-color: #ea580c; }
.hover\:bg-gray-50:hover, .hover\:bg-gray-800:hover { background-color: #fff7ed; border-color: #fdba74; }
.hover\:text-red-500:hover, .hover\:text-red-400:hover { color: #ef4444; }

@media (min-width: 768px) {
    .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .md\:col-span-2 { grid-column: span 2 / span 2; }
    
    .md\:flex { display: flex; }
    .md\:block { display: block; }
    .md\:hidden { display: none; }
    
    .md\:pb-0 { padding-bottom: 0; }
    .md\:w-1\/4 { width: 25%; }
    .md\:flex-row { flex-direction: row; }
}