/* ============================================
   RUBI Shared App Utilities
   ============================================
   Common Tailwind-like utility classes used across all RUBI apps.
   Import this file in app.css or after rubi-shared.css
*/

/* ============================================
   Base Styles
   ============================================
   Global styles for all RUBI apps
*/

html, body {
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Remove outline from headings */
h1, h2, h3, h4, h5, h6 {
    outline: none;
}

h1:focus, h2:focus, h3:focus, h4:focus, h5:focus, h6:focus {
    outline: none;
}

/* Selection color - uses theme variable */
::selection {
    background-color: rgba(var(--theme-500-rgb, 244, 63, 94), 0.3);
    color: white;
}

/* ============================================
   Scrollbar Styling
   ============================================ */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #16161d;
}

::-webkit-scrollbar-thumb {
    background: #3f3f46;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #52525b;
}

/* Hide scrollbar utility (for horizontal scroll areas) */
.scrollbar-hide {
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;     /* Firefox */
}
.scrollbar-hide::-webkit-scrollbar {
    display: none;             /* Chrome, Safari, Opera */
}

/* Thin scrollbar utility (for horizontal nav areas) */
.scrollbar-thin {
    scrollbar-width: thin;     /* Firefox */
}
.scrollbar-thin::-webkit-scrollbar {
    height: 4px;               /* Chrome, Safari */
    width: 4px;
}
.scrollbar-thumb-slate-600::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 2px;
}
.scrollbar-track-transparent::-webkit-scrollbar-track {
    background: transparent;
}

/* ============================================
   Blazor-Specific Styles
   ============================================ */

/* Form Validation States */
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #22c55e;
}

.invalid {
    outline: 1px solid #ef4444;
}

.validation-message {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Blazor Error UI */
#blazor-error-ui {
    display: none;
}

#blazor-error-ui.show {
    display: block;
}

/* Blazor Error Boundary */
.blazor-error-boundary {
    background: linear-gradient(135deg, #991b1b, #7f1d1d);
    padding: 1rem 1rem 1rem 3.5rem;
    color: white;
    border-radius: 0.5rem;
    position: relative;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fbbf24'%3E%3Cpath d='M12 2L1 21h22L12 2zm0 3.99L19.53 19H4.47L12 5.99zM11 16v2h2v-2h-2zm0-6v4h2v-4h-2z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 1rem center;
    background-size: 1.5rem;
}

.blazor-error-boundary::after {
    content: "An error has occurred.";
}

/* ============================================
   Form Controls
   ============================================ */

/* Form Control Focus - uses theme variable */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(var(--theme-500-rgb, 244, 63, 94), 0.3);
    border-color: var(--theme-500, #f43f5e);
}

/* ============================================
   Sidebar Toggle Button
   ============================================
   Uses theme variables for colors
*/

.sidebar-toggle-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    border: none;
    background: transparent;
    color: var(--theme-400, #fb7185);
    cursor: pointer;
    transition: all 0.2s;
}

.sidebar-toggle-btn:hover {
    background-color: rgba(var(--theme-500-rgb, 244, 63, 94), 0.1);
    color: var(--theme-300, #fda4af);
}

.sidebar-toggle-btn i {
    font-size: 1rem;
}

/* ============================================
   Print Styles
   ============================================ */

@media print {
    .sidebar,
    header,
    .no-print {
        display: none !important;
    }
    main {
        margin-left: 0 !important;
    }
}

/* ============================================
   Mobile Responsive
   ============================================ */

@media (max-width: 768px) {
    .sidebar-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 35;
    }
}

/* ============================================
   Layout & Display
   ============================================ */
.block { display: block; }
.inline-block { display: inline-block; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.grid { display: grid; }
.hidden { display: none; }

/* Flex Direction */
.flex-row { flex-direction: row; }
.flex-col { flex-direction: column; }

/* Flex Wrap */
.flex-wrap { flex-wrap: wrap; }
.flex-nowrap { flex-wrap: nowrap; }

/* Flex Grow/Shrink */
.flex-1 { flex: 1 1 0%; }
.flex-auto { flex: 1 1 auto; }
.flex-none { flex: none; }
.flex-shrink-0 { flex-shrink: 0; }
.flex-grow { flex-grow: 1; }
.flex-grow-0 { flex-grow: 0; }

/* Space Between Children */
.space-x-1 > * + * { margin-left: 0.25rem; }
.space-x-2 > * + * { margin-left: 0.5rem; }
.space-x-3 > * + * { margin-left: 0.75rem; }
.space-x-4 > * + * { margin-left: 1rem; }
.space-x-6 > * + * { margin-left: 1.5rem; }

.space-y-1 > * + * { margin-top: 0.25rem; }
.space-y-1\.5 > * + * { margin-top: 0.375rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }

/* Arbitrary values for stress test dashboard */
.min-w-\[300px\] { min-width: 300px; }
.text-\[10px\] { font-size: 10px; line-height: 14px; }
.max-h-28 { max-height: 7rem; }

/* Align Items */
.items-start { align-items: flex-start; }
.items-center { align-items: center; }
.items-end { align-items: flex-end; }
.items-stretch { align-items: stretch; }

/* Justify Content */
.justify-start { justify-content: flex-start; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }

/* Gap */
.gap-1 { gap: 0.25rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-5 { gap: 1.25rem; }
.gap-6 { gap: 1.5rem; }

/* ============================================
   Grid
   ============================================ */
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ============================================
   Spacing - Margin
   ============================================ */
.m-0 { margin: 0; }
.m-1 { margin: 0.25rem; }
.m-2 { margin: 0.5rem; }
.m-4 { margin: 1rem; }

.mx-2 { margin-left: 0.5rem; margin-right: 0.5rem; }
.mx-4 { margin-left: 1rem; margin-right: 1rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

.my-2 { margin-top: 0.5rem; margin-bottom: 0.5rem; }
.my-4 { margin-top: 1rem; margin-bottom: 1rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-5 { margin-top: 1.25rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-5 { margin-bottom: 1.25rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }
.mb-20 { margin-bottom: 5rem; }
.mb-24 { margin-bottom: 6rem; }
.mb-32 { margin-bottom: 8rem; }

.ml-1 { margin-left: 0.25rem; }
.ml-2 { margin-left: 0.5rem; }
.ml-16 { margin-left: 4rem; }
.ml-60 { margin-left: 15rem; }
.ml-auto { margin-left: auto; }

.mr-1 { margin-right: 0.25rem; }
.mr-2 { margin-right: 0.5rem; }
.mr-3 { margin-right: 0.75rem; }

/* Additional margin */
.ml-4 { margin-left: 1rem; }
.my-3 { margin-top: 0.75rem; margin-bottom: 0.75rem; }

/* ============================================
   Spacing - Padding
   ============================================ */
.p-0 { padding: 0; }
.p-1 { padding: 0.25rem; }
.p-2 { padding: 0.5rem; }
.p-3 { padding: 0.75rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.p-10 { padding: 2.5rem; }

.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-5 { padding-left: 1.25rem; padding-right: 1.25rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.px-10 { padding-left: 2.5rem; padding-right: 2.5rem; }
.px-12 { padding-left: 3rem; padding-right: 3rem; }
.px-16 { padding-left: 4rem; padding-right: 4rem; }

.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-5 { padding-top: 1.25rem; padding-bottom: 1.25rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }

.pt-0 { padding-top: 0; }
.pt-1 { padding-top: 0.25rem; }
.pt-2 { padding-top: 0.5rem; }
.pt-3 { padding-top: 0.75rem; }
.pt-4 { padding-top: 1rem; }
.pt-5 { padding-top: 1.25rem; }
.pt-6 { padding-top: 1.5rem; }
.pt-8 { padding-top: 2rem; }
.pt-10 { padding-top: 2.5rem; }
.pt-12 { padding-top: 3rem; }
.pt-16 { padding-top: 4rem; }
.pt-20 { padding-top: 5rem; }
.pt-24 { padding-top: 6rem; }
.pt-32 { padding-top: 8rem; }

.pb-0 { padding-bottom: 0; }
.pb-1 { padding-bottom: 0.25rem; }
.pb-2 { padding-bottom: 0.5rem; }
.pb-3 { padding-bottom: 0.75rem; }
.pb-4 { padding-bottom: 1rem; }
.pb-5 { padding-bottom: 1.25rem; }
.pb-6 { padding-bottom: 1.5rem; }
.pb-8 { padding-bottom: 2rem; }
.pb-10 { padding-bottom: 2.5rem; }
.pb-12 { padding-bottom: 3rem; }
.pb-16 { padding-bottom: 4rem; }
.pb-20 { padding-bottom: 5rem; }      /* 80px - for bottom nav */
.pb-24 { padding-bottom: 6rem; }      /* 96px */
.pb-32 { padding-bottom: 8rem; }      /* 128px - for bottom nav + safe area */

.pl-0 { padding-left: 0; }
.pl-1 { padding-left: 0.25rem; }
.pl-2 { padding-left: 0.5rem; }
.pl-3 { padding-left: 0.75rem; }
.pl-4 { padding-left: 1rem; }

.pr-0 { padding-right: 0; }
.pr-1 { padding-right: 0.25rem; }
.pr-2 { padding-right: 0.5rem; }
.pr-3 { padding-right: 0.75rem; }
.pr-4 { padding-right: 1rem; }

/* ============================================
   Width & Height
   ============================================ */
.w-full { width: 100%; }
.w-auto { width: auto; }
.w-1\.5 { width: 0.375rem; min-width: 0.375rem; }
.w-2 { width: 0.5rem; min-width: 0.5rem; }
.w-8 { width: 2rem; }
.w-10 { width: 2.5rem; }
.w-20 { width: 5rem; }
.w-24 { width: 6rem; }
.w-28 { width: 7rem; }
.w-12 { width: 3rem; }
.w-16 { width: 4rem; }
.w-24 { width: 6rem; }
.w-40 { width: 10rem; }
.w-60 { width: 15rem; }
.w-fit { width: fit-content; }

.h-6 { height: 1.5rem; }
.h-12 { height: 3rem; }
.h-16 { height: 4rem; }
.h-20 { height: 5rem; }
.h-24 { height: 6rem; }
.h-32 { height: 8rem; }
.h-40 { height: 10rem; }
.h-full { height: 100%; }
.h-auto { height: auto; }
.h-1\.5 { height: 0.375rem; min-height: 0.375rem; }
.h-2 { height: 0.5rem; min-height: 0.5rem; }
.h-8 { height: 2rem; }
.h-10 { height: 2.5rem; }
.h-px { height: 1px; }

.min-h-screen { min-height: 100vh; }
.h-screen { height: 100vh; }
.max-h-\[90vh\] { max-height: 90vh; }
.max-w-md { max-width: 28rem; }
.max-w-lg { max-width: 32rem; }
.max-w-xl { max-width: 36rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-5xl { max-width: 64rem; }
.max-w-6xl { max-width: 72rem; }

.w-6 { width: 1.5rem; }
.w-32 { width: 8rem; }
.w-36 { width: 9rem; }
.w-48 { width: 12rem; }
.w-56 { width: 14rem; }
.w-64 { width: 16rem; }
.w-72 { width: 18rem; }
.w-80 { width: 20rem; }
.w-96 { width: 24rem; }

/* ============================================
   Typography
   ============================================ */
.text-\[10px\] { font-size: 10px; line-height: 1rem; }
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.text-5xl { font-size: 3rem; line-height: 1; }

.leading-relaxed { line-height: 1.625; }
.leading-tight { line-height: 1.25; }

.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

.tracking-wider { letter-spacing: 0.05em; }

.whitespace-nowrap { white-space: nowrap; }
.break-words { word-wrap: break-word; overflow-wrap: break-word; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Line Clamp - Multi-line text truncation */
.line-clamp-1 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
}
.line-clamp-2 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}
.line-clamp-3 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

/* ============================================
   Text Colors
   ============================================ */
.text-white { color: #ffffff; }
.text-white\/80 { color: rgba(255, 255, 255, 0.8); }
.text-white\/70 { color: rgba(255, 255, 255, 0.7); }
.text-white\/60 { color: rgba(255, 255, 255, 0.6); }
.text-black { color: #000000; }

.text-gray-100 { color: #f3f4f6; }
.text-gray-200 { color: #e5e7eb; }
.text-gray-300 { color: #d1d5db; }
.text-gray-400 { color: #9ca3af; }
.text-gray-500 { color: #6b7280; }
.text-gray-600 { color: #4b5563; }

.text-green-400 { color: #4ade80; }
.text-green-500 { color: #22c55e; }
.text-blue-400 { color: #60a5fa; }
.text-blue-500 { color: #3b82f6; }
.text-red-400 { color: #f87171; }
.text-red-500 { color: #ef4444; }
.text-yellow-400 { color: #facc15; }
.text-yellow-500 { color: #eab308; }
.text-amber-400 { color: #fbbf24; }
.text-rose-400 { color: #fb7185; }
.text-rose-500 { color: #f43f5e; }
.text-purple-400 { color: #c084fc; }

/* Gradient Text */
.text-transparent { color: transparent; }
.bg-clip-text { -webkit-background-clip: text; background-clip: text; }

/* ============================================
   Background Colors
   ============================================ */
.bg-transparent { background-color: transparent; }
.bg-white { background-color: #ffffff; }
.bg-black { background-color: #000000; }

/* Semi-transparent backgrounds */
.bg-white\/5 { background-color: rgba(255, 255, 255, 0.05); }
.bg-white\/10 { background-color: rgba(255, 255, 255, 0.1); }
.bg-white\/20 { background-color: rgba(255, 255, 255, 0.2); }

/* Solid backgrounds */
.bg-gray-500 { background-color: #6b7280; }
.bg-gray-600 { background-color: #4b5563; }
.bg-green-500 { background-color: #22c55e; }
.bg-green-600 { background-color: #16a34a; }
.bg-blue-500 { background-color: #3b82f6; }
.bg-blue-600 { background-color: #2563eb; }
.bg-red-500 { background-color: #ef4444; }
.bg-red-600 { background-color: #dc2626; }
.bg-yellow-500 { background-color: #eab308; }
.bg-yellow-600 { background-color: #ca8a04; }
.bg-amber-600 { background-color: #d97706; }
.bg-rose-600 { background-color: #e11d48; }
.bg-purple-600 { background-color: #9333ea; }
.bg-teal-600 { background-color: #0d9488; }
.bg-cyan-600 { background-color: #0891b2; }
.bg-orange-600 { background-color: #ea580c; }
.bg-indigo-600 { background-color: #4f46e5; }
.bg-pink-600 { background-color: #db2777; }

/* Dark theme backgrounds */
.bg-dark-base { background-color: #0f0f14; }
.bg-dark-surface { background-color: #16161d; }
.bg-dark-base\/95 { background-color: rgba(15, 15, 20, 0.95); }
.bg-dark-surface\/80 { background-color: rgba(22, 22, 29, 0.8); }
.bg-dark-surface\/90 { background-color: rgba(22, 22, 29, 0.9); }
.bg-dark-elevated { background-color: #1c1c26; }
.bg-dark-card { background-color: #1e1e28; }
.bg-dark-hover { background-color: #252530; }
.bg-dark-active { background-color: #2d2d3a; }

/* Semi-transparent colored backgrounds */
.bg-green-500\/10 { background-color: rgba(34, 197, 94, 0.1); }
.bg-green-500\/20 { background-color: rgba(34, 197, 94, 0.2); }
.bg-blue-500\/10 { background-color: rgba(59, 130, 246, 0.1); }
.bg-blue-500\/20 { background-color: rgba(59, 130, 246, 0.2); }
.bg-red-500\/10 { background-color: rgba(239, 68, 68, 0.1); }
.bg-red-500\/20 { background-color: rgba(239, 68, 68, 0.2); }
.bg-yellow-500\/5 { background-color: rgba(234, 179, 8, 0.05); }
.bg-yellow-500\/10 { background-color: rgba(234, 179, 8, 0.1); }
.bg-yellow-500\/20 { background-color: rgba(234, 179, 8, 0.2); }
.bg-amber-500\/20 { background-color: rgba(245, 158, 11, 0.2); }
.bg-rose-500\/20 { background-color: rgba(244, 63, 94, 0.2); }
.bg-purple-500\/20 { background-color: rgba(168, 85, 247, 0.2); }
.bg-gray-500\/10 { background-color: rgba(107, 114, 128, 0.1); }
.bg-gray-500\/20 { background-color: rgba(107, 114, 128, 0.2); }
.bg-petrol-500\/20 { background-color: rgba(20, 184, 166, 0.2); }

/* Gradients */
.bg-gradient-to-r { background-image: linear-gradient(to right, var(--tw-gradient-stops)); }
.bg-gradient-to-l { background-image: linear-gradient(to left, var(--tw-gradient-stops)); }
.bg-gradient-to-t { background-image: linear-gradient(to top, var(--tw-gradient-stops)); }
.bg-gradient-to-b { background-image: linear-gradient(to bottom, var(--tw-gradient-stops)); }
.bg-gradient-to-br { background-image: linear-gradient(to bottom right, var(--tw-gradient-stops)); }
.bg-gradient-to-bl { background-image: linear-gradient(to bottom left, var(--tw-gradient-stops)); }
.bg-gradient-to-tr { background-image: linear-gradient(to top right, var(--tw-gradient-stops)); }
.bg-gradient-to-tl { background-image: linear-gradient(to top left, var(--tw-gradient-stops)); }

/* Gradient from colors - Dark theme (shared) */
.from-dark-base { --tw-gradient-from: #0f0f14; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-dark-surface { --tw-gradient-from: #16161d; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-dark-elevated { --tw-gradient-from: #1c1c26; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }

/* Gradient from theme colors (using CSS variables) */
.from-theme-950 { --tw-gradient-from: var(--theme-950); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }

/* Gradient from colors - Standard Tailwind colors (semantic use) */
.from-blue-500 { --tw-gradient-from: #3b82f6; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-blue-600 { --tw-gradient-from: #2563eb; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-blue-950 { --tw-gradient-from: #172554; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-purple-500 { --tw-gradient-from: #a855f7; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-purple-600 { --tw-gradient-from: #9333ea; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-green-500 { --tw-gradient-from: #22c55e; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-green-600 { --tw-gradient-from: #16a34a; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-green-950 { --tw-gradient-from: #052e16; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-amber-500 { --tw-gradient-from: #f59e0b; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-amber-600 { --tw-gradient-from: #d97706; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-amber-950 { --tw-gradient-from: #451a03; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-rose-500 { --tw-gradient-from: #f43f5e; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-rose-600 { --tw-gradient-from: #e11d48; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-rose-950 { --tw-gradient-from: #4c0519; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-yellow-500 { --tw-gradient-from: #eab308; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-sky-400 { --tw-gradient-from: #38bdf8; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-sky-500 { --tw-gradient-from: #0ea5e9; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-sky-600 { --tw-gradient-from: #0284c7; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-cyan-400 { --tw-gradient-from: #22d3ee; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-cyan-500 { --tw-gradient-from: #06b6d4; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-cyan-600 { --tw-gradient-from: #0891b2; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-teal-500 { --tw-gradient-from: #14b8a6; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-teal-600 { --tw-gradient-from: #0d9488; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-orange-500 { --tw-gradient-from: #f97316; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-orange-600 { --tw-gradient-from: #ea580c; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.from-amber-400 { --tw-gradient-from: #fbbf24; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }

/* Gradient to colors - Standard Tailwind colors */
.to-blue-500 { --tw-gradient-to: #3b82f6; }
.to-blue-600 { --tw-gradient-to: #2563eb; }
.to-purple-500 { --tw-gradient-to: #a855f7; }
.to-purple-600 { --tw-gradient-to: #9333ea; }
.to-green-500 { --tw-gradient-to: #22c55e; }
.to-green-600 { --tw-gradient-to: #16a34a; }
.to-amber-500 { --tw-gradient-to: #f59e0b; }
.to-amber-600 { --tw-gradient-to: #d97706; }
.to-rose-500 { --tw-gradient-to: #f43f5e; }
.to-rose-600 { --tw-gradient-to: #e11d48; }
.to-yellow-500 { --tw-gradient-to: #eab308; }
.to-sky-500 { --tw-gradient-to: #0ea5e9; }
.to-sky-600 { --tw-gradient-to: #0284c7; }
.to-cyan-500 { --tw-gradient-to: #06b6d4; }
.to-cyan-600 { --tw-gradient-to: #0891b2; }
.to-teal-500 { --tw-gradient-to: #14b8a6; }
.to-teal-600 { --tw-gradient-to: #0d9488; }
.to-orange-500 { --tw-gradient-to: #f97316; }
.to-orange-600 { --tw-gradient-to: #ea580c; }

/* Gradient via colors */
.via-dark-surface { --tw-gradient-stops: var(--tw-gradient-from), #16161d, var(--tw-gradient-to, transparent); }
.via-dark-base { --tw-gradient-stops: var(--tw-gradient-from), #0f0f14, var(--tw-gradient-to, transparent); }

/* Gradient to colors */
.to-dark-base { --tw-gradient-to: #0f0f14; }
.to-dark-surface { --tw-gradient-to: #16161d; }
.to-dark-card { --tw-gradient-to: #1e1e28; }
.to-transparent { --tw-gradient-to: transparent; }

/* ============================================
   Borders
   ============================================ */
.border { border-width: 1px; border-style: solid; }
.border-0 { border-width: 0; }
.border-none { border: none; }
.border-2 { border-width: 2px; border-style: solid; }
.border-3 { border-width: 3px; border-style: solid; }
.border-4 { border-width: 4px; border-style: solid; }
.border-t { border-top-width: 1px; border-top-style: solid; }
.border-b { border-bottom-width: 1px; border-bottom-style: solid; }
.border-l { border-left-width: 1px; border-left-style: solid; }
.border-r { border-right-width: 1px; border-right-style: solid; }
.border-r-2 { border-right-width: 2px; border-right-style: solid; }
.border-l-4 { border-left-width: 4px; border-left-style: solid; }

/* Border styles */
.border-solid { border-style: solid; }
.border-dashed { border-style: dashed; }
.border-dotted { border-style: dotted; }

.border-transparent { border-color: transparent; }
.border-t-transparent { border-top-color: transparent; }
.border-white\/5 { border-color: rgba(255, 255, 255, 0.05); }
.border-white\/10 { border-color: rgba(255, 255, 255, 0.1); }
.border-white\/20 { border-color: rgba(255, 255, 255, 0.2); }
.border-white\/30 { border-color: rgba(255, 255, 255, 0.3); }

.border-gray-500\/30 { border-color: rgba(107, 114, 128, 0.3); }
.border-green-500\/10 { border-color: rgba(34, 197, 94, 0.1); }
.border-green-500\/20 { border-color: rgba(34, 197, 94, 0.2); }
.border-green-500\/30 { border-color: rgba(34, 197, 94, 0.3); }
.border-blue-500\/10 { border-color: rgba(59, 130, 246, 0.1); }
.border-blue-500\/20 { border-color: rgba(59, 130, 246, 0.2); }
.border-blue-500\/30 { border-color: rgba(59, 130, 246, 0.3); }
.border-yellow-500\/20 { border-color: rgba(234, 179, 8, 0.2); }
.border-yellow-500\/30 { border-color: rgba(234, 179, 8, 0.3); }
.border-rose-500\/30 { border-color: rgba(244, 63, 94, 0.3); }
.border-red-500\/30 { border-color: rgba(239, 68, 68, 0.3); }
.border-amber-500 { border-color: #f59e0b; }
.border-amber-500\/30 { border-color: rgba(245, 158, 11, 0.3); }

/* Border top colors (for spinners) */
.border-t-rose-500 { border-top-color: #f43f5e; }
.border-t-green-500 { border-top-color: #22c55e; }
.border-t-blue-500 { border-top-color: #3b82f6; }

/* Border color - dark theme */
.border-dark-elevated { border-color: #1c1c26; }
.border-dark-surface { border-color: #16161d; }

.rounded { border-radius: 0.25rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-3xl { border-radius: 1.5rem; }
.rounded-full { border-radius: 9999px; }

/* Partial border radius */
.rounded-t-2xl { border-top-left-radius: 1rem; border-top-right-radius: 1rem; }
.rounded-b-2xl { border-bottom-left-radius: 1rem; border-bottom-right-radius: 1rem; }

/* ============================================
   Effects & Transitions
   ============================================ */
.shadow { box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1); }
.shadow-lg { box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }
.shadow-2xl { box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25); }

/* Glow Shadows - Standard Tailwind colors */
.shadow-glow-rose { box-shadow: 0 0 20px rgba(244, 63, 94, 0.3); }
.shadow-glow-rose-lg { box-shadow: 0 0 30px rgba(244, 63, 94, 0.5); }
.shadow-glow-green { box-shadow: 0 0 20px rgba(34, 197, 94, 0.3); }
.shadow-glow-blue { box-shadow: 0 0 20px rgba(59, 130, 246, 0.3); }
.shadow-glow-amber { box-shadow: 0 0 20px rgba(217, 119, 6, 0.3); }
.shadow-glow-purple { box-shadow: 0 0 20px rgba(147, 51, 234, 0.3); }

/* Hover glow shadows */
.hover\:shadow-glow-rose:hover { box-shadow: 0 0 20px rgba(244, 63, 94, 0.3); }
.hover\:shadow-glow-rose-lg:hover { box-shadow: 0 0 30px rgba(244, 63, 94, 0.5); }

/* Group hover utilities (parent has .group class) */
.group:hover .group-hover\:shadow-glow-rose { box-shadow: 0 0 20px rgba(244, 63, 94, 0.3); }
.group:hover .group-hover\:text-rose-400 { color: #fb7185; }
.group:hover .group-hover\:text-blue-400 { color: #60a5fa; }
.group:hover .group-hover\:text-purple-400 { color: #c084fc; }
.group:hover .group-hover\:text-green-400 { color: #4ade80; }
.group:hover .group-hover\:text-white { color: #ffffff; }

/* Drop Shadow */
.drop-shadow { filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1)); }
.drop-shadow-lg { filter: drop-shadow(0 10px 8px rgba(0, 0, 0, 0.04)); }
.drop-shadow-\[0_0_8px_rgba\(244\,63\,94\,0\.5\)\] { filter: drop-shadow(0 0 8px rgba(244, 63, 94, 0.5)); }
.drop-shadow-\[0_0_20px_rgba\(244\,63\,94\,0\.5\)\] { filter: drop-shadow(0 0 20px rgba(244, 63, 94, 0.5)); }
.drop-shadow-\[0_0_8px_rgba\(34\,197\,94\,0\.5\)\] { filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.5)); }
.drop-shadow-\[0_0_8px_rgba\(59\,130\,246\,0\.5\)\] { filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.5)); }

/* Backdrop Blur */
.backdrop-blur-sm { backdrop-filter: blur(4px); }
.backdrop-blur { backdrop-filter: blur(8px); }
.backdrop-blur-md { backdrop-filter: blur(12px); }
.backdrop-blur-lg { backdrop-filter: blur(16px); }

.opacity-50 { opacity: 0.5; }
.opacity-60 { opacity: 0.6; }
.opacity-75 { opacity: 0.75; }

.transition { transition: all 150ms ease; }
.transition-colors {
    transition-property: color, background-color, border-color;
    transition-timing-function: ease;
    transition-duration: 150ms;
}
.transition-all {
    transition-property: all;
    transition-timing-function: ease;
    transition-duration: 150ms;
}

/* Transition Duration */
.duration-150 { transition-duration: 150ms; }
.duration-200 { transition-duration: 200ms; }
.duration-300 { transition-duration: 300ms; }
.duration-500 { transition-duration: 500ms; }

/* Transition Timing */
.ease-linear { transition-timing-function: linear; }
.ease-in { transition-timing-function: cubic-bezier(0.4, 0, 1, 1); }
.ease-out { transition-timing-function: cubic-bezier(0, 0, 0.2, 1); }
.ease-in-out { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); }

/* ============================================
   Cursor & Interaction
   ============================================ */
.cursor-pointer { cursor: pointer; }
.cursor-not-allowed { cursor: not-allowed; }
.pointer-events-none { pointer-events: none; }

/* ============================================
   Overflow
   ============================================ */
.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }

/* ============================================
   Max Height (for scrollable containers)
   ============================================ */
.max-h-\[300px\] { max-height: 300px; }
.max-h-\[400px\] { max-height: 400px; }
.max-h-\[500px\] { max-height: 500px; }
.max-h-\[600px\] { max-height: 600px; }
.max-h-96 { max-height: 24rem; /* 384px */ }

/* ============================================
   Object Fit & Images
   ============================================ */
.object-cover { object-fit: cover; }
.object-contain { object-fit: contain; }
.object-fill { object-fit: fill; }
.object-center { object-position: center; }

/* ============================================
   Form & Input Utilities
   ============================================ */
.resize-none { resize: none; }
.resize { resize: both; }
.outline-none { outline: none; }
.ring-2 { --tw-ring-offset-shadow: 0 0 #0000; --tw-ring-shadow: 0 0 0 2px var(--tw-ring-color); box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); }
.ring-amber-500\/50 { --tw-ring-color: rgba(245, 158, 11, 0.5); }
.ring-rose-500\/50 { --tw-ring-color: rgba(244, 63, 94, 0.5); }
.ring-blue-500\/50 { --tw-ring-color: rgba(59, 130, 246, 0.5); }
.ring-green-500\/50 { --tw-ring-color: rgba(34, 197, 94, 0.5); }

/* Focus ring utilities */
.focus\:outline-none:focus { outline: none; }
.focus\:ring-2:focus { --tw-ring-offset-shadow: 0 0 #0000; --tw-ring-shadow: 0 0 0 2px var(--tw-ring-color); box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); }
.focus\:ring-amber-500\/50:focus { --tw-ring-color: rgba(245, 158, 11, 0.5); }
.focus\:border-amber-500:focus { border-color: #f59e0b; }

/* ============================================
   Position
   ============================================ */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }

.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.top-0 { top: 0; }
.top-10 { top: 2.5rem; }
.right-0 { right: 0; }
.bottom-0 { bottom: 0; }
.left-0 { left: 0; }

/* Negative positioning */
.-top-2 { top: -0.5rem; }
.-right-2 { right: -0.5rem; }
.-translate-y-1 { transform: translateY(-0.25rem); }

/* ============================================
   Z-Index
   ============================================ */
.z-10 { z-index: 10; }
.z-20 { z-index: 20; }
.z-30 { z-index: 30; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

/* ============================================
   Hover States
   ============================================ */
.hover\:bg-white\/5:hover { background-color: rgba(255, 255, 255, 0.05); }
.hover\:bg-white\/10:hover { background-color: rgba(255, 255, 255, 0.1); }

/* Hover text colors */
.hover\:text-white:hover { color: #ffffff; }
.hover\:text-gray-300:hover { color: #d1d5db; }
.hover\:bg-green-700:hover { background-color: #15803d; }
.hover\:bg-blue-700:hover { background-color: #1d4ed8; }

/* Hover gradient utilities - Standard Tailwind colors */
.hover\:from-rose-500:hover { --tw-gradient-from: #f43f5e; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:to-rose-400:hover { --tw-gradient-to: #fb7185; }
.hover\:from-rose-400:hover { --tw-gradient-from: #fb7185; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:to-rose-600:hover { --tw-gradient-to: #e11d48; }
.hover\:from-amber-400:hover { --tw-gradient-from: #fbbf24; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:from-amber-500:hover { --tw-gradient-from: #f59e0b; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:to-amber-500:hover { --tw-gradient-to: #f59e0b; }
.hover\:to-amber-600:hover { --tw-gradient-to: #d97706; }
.hover\:from-purple-500:hover { --tw-gradient-from: #a855f7; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:to-purple-500:hover { --tw-gradient-to: #a855f7; }

/* More hover states */
.hover\:bg-dark-hover:hover { background-color: #252530; }
.hover\:bg-dark-elevated:hover { background-color: #1c1c26; }
.hover\:bg-red-500\/20:hover { background-color: rgba(239, 68, 68, 0.2); }
.hover\:bg-red-600:hover { background-color: #dc2626; }
.hover\:border-amber-500\/50:hover { border-color: rgba(245, 158, 11, 0.5); }
.hover\:text-amber-400:hover { color: #fbbf24; }

/* Hover border colors */
.hover\:border-rose-500\/30:hover { border-color: rgba(244, 63, 94, 0.3); }
.hover\:border-blue-500\/30:hover { border-color: rgba(59, 130, 246, 0.3); }
.hover\:border-purple-500\/30:hover { border-color: rgba(168, 85, 247, 0.3); }
.hover\:border-green-500\/30:hover { border-color: rgba(34, 197, 94, 0.3); }
.hover\:border-gray-600:hover { border-color: #4b5563; }

/* Hover text colors */
.hover\:text-rose-400:hover { color: #fb7185; }
.hover\:text-blue-400:hover { color: #60a5fa; }
.hover\:text-purple-400:hover { color: #c084fc; }
.hover\:text-green-400:hover { color: #4ade80; }

/* ============================================
   Disabled States
   ============================================ */
.disabled\:opacity-50:disabled { opacity: 0.5; }
.disabled\:cursor-not-allowed:disabled { cursor: not-allowed; }

/* ============================================
   Responsive Breakpoints (sm: 640px+)
   ============================================ */
@media (min-width: 640px) {
    .sm\:flex { display: flex; }
    .sm\:hidden { display: none; }
    .sm\:block { display: block; }
    .sm\:flex-row { flex-direction: row; }
    .sm\:items-center { align-items: center; }
    .sm\:items-start { align-items: flex-start; }
    .sm\:justify-between { justify-content: space-between; }
}

/* ============================================
   Responsive Breakpoints (md: 768px+)
   ============================================ */
@media (min-width: 768px) {
    .md\:flex { display: flex; }
    .md\:hidden { display: none; }
    .md\:block { display: block; }
    .md\:grid { display: grid; }

    .md\:flex-row { flex-direction: row; }
    .md\:flex-col { flex-direction: column; }

    .md\:items-start { align-items: flex-start; }
    .md\:items-center { align-items: center; }
    .md\:items-end { align-items: flex-end; }

    .md\:justify-start { justify-content: flex-start; }
    .md\:justify-center { justify-content: center; }
    .md\:justify-end { justify-content: flex-end; }
    .md\:justify-between { justify-content: space-between; }

    .md\:gap-2 { gap: 0.5rem; }
    .md\:gap-3 { gap: 0.75rem; }
    .md\:gap-4 { gap: 1rem; }
    .md\:gap-6 { gap: 1.5rem; }

    .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

    .md\:text-left { text-align: left; }
    .md\:text-center { text-align: center; }

    /* Responsive text sizes */
    .md\:text-xs { font-size: 0.75rem; line-height: 1rem; }
    .md\:text-sm { font-size: 0.875rem; line-height: 1.25rem; }
    .md\:text-base { font-size: 1rem; line-height: 1.5rem; }
    .md\:text-lg { font-size: 1.125rem; line-height: 1.75rem; }
    .md\:text-xl { font-size: 1.25rem; line-height: 1.75rem; }
    .md\:text-2xl { font-size: 1.5rem; line-height: 2rem; }
    .md\:text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
    .md\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
    .md\:text-5xl { font-size: 3rem; line-height: 1; }

    .md\:col-span-2 { grid-column: span 2 / span 2; }

    /* Responsive padding */
    .md\:p-4 { padding: 1rem; }
    .md\:p-5 { padding: 1.25rem; }
    .md\:p-6 { padding: 1.5rem; }
    .md\:p-8 { padding: 2rem; }
    .md\:px-4 { padding-left: 1rem; padding-right: 1rem; }
    .md\:px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
    .md\:py-4 { padding-top: 1rem; padding-bottom: 1rem; }
    .md\:py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
    .md\:py-8 { padding-top: 2rem; padding-bottom: 2rem; }
    .md\:pt-4 { padding-top: 1rem; }
    .md\:pt-6 { padding-top: 1.5rem; }
    .md\:pt-8 { padding-top: 2rem; }
    .md\:pt-12 { padding-top: 3rem; }
    .md\:pt-16 { padding-top: 4rem; }
    .md\:pt-20 { padding-top: 5rem; }
    .md\:pt-24 { padding-top: 6rem; }
    .md\:pt-32 { padding-top: 8rem; }
    .md\:pb-4 { padding-bottom: 1rem; }
    .md\:pb-6 { padding-bottom: 1.5rem; }

    /* Responsive margins */
    .md\:mb-3 { margin-bottom: 0.75rem; }
    .md\:mb-4 { margin-bottom: 1rem; }
    .md\:mb-6 { margin-bottom: 1.5rem; }
    .md\:mb-8 { margin-bottom: 2rem; }
    .md\:mb-12 { margin-bottom: 3rem; }
    .md\:mr-2 { margin-right: 0.5rem; }
}

/* ============================================
   Responsive Breakpoints (lg: 1024px+)
   ============================================ */
@media (min-width: 1024px) {
    .lg\:flex { display: flex; }
    .lg\:hidden { display: none; }
    .lg\:block { display: block; }
    .lg\:grid { display: grid; }

    .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

    .lg\:gap-2 { gap: 0.5rem; }
    .lg\:gap-3 { gap: 0.75rem; }
    .lg\:gap-6 { gap: 1.5rem; }
    .lg\:gap-8 { gap: 2rem; }

    .lg\:p-3 { padding: 0.75rem; }
    .lg\:p-4 { padding: 1rem; }
    .lg\:px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
    .lg\:py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
    .lg\:px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }

    .lg\:w-56 { width: 14rem; }
    .lg\:w-64 { width: 16rem; }
    .lg\:w-80 { width: 20rem; }

    .lg\:text-xs { font-size: 0.75rem; line-height: 1rem; }
    .lg\:text-sm { font-size: 0.875rem; line-height: 1.25rem; }
    .lg\:text-base { font-size: 1rem; line-height: 1.5rem; }

    .lg\:space-y-3 > * + * { margin-top: 0.75rem; }
}

/* ============================================
   Responsive Breakpoints (xl: 1280px+)
   ============================================ */
@media (min-width: 1280px) {
    .xl\:flex { display: flex; }
    .xl\:hidden { display: none; }
    .xl\:block { display: block; }
    .xl\:grid { display: grid; }

    .xl\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .xl\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .xl\:grid-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }

    .xl\:gap-3 { gap: 0.75rem; }
    .xl\:gap-5 { gap: 1.25rem; }
    .xl\:gap-6 { gap: 1.5rem; }
    .xl\:gap-8 { gap: 2rem; }

    .xl\:p-4 { padding: 1rem; }
    .xl\:p-5 { padding: 1.25rem; }
    .xl\:px-4 { padding-left: 1rem; padding-right: 1rem; }
    .xl\:py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
    .xl\:px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }

    .xl\:w-64 { width: 16rem; }
    .xl\:w-72 { width: 18rem; }
    .xl\:w-80 { width: 20rem; }
    .xl\:w-96 { width: 24rem; }

    .xl\:text-sm { font-size: 0.875rem; line-height: 1.25rem; }
    .xl\:text-base { font-size: 1rem; line-height: 1.5rem; }
    .xl\:text-lg { font-size: 1.125rem; line-height: 1.75rem; }
    .xl\:text-xl { font-size: 1.25rem; line-height: 1.75rem; }
    .xl\:text-2xl { font-size: 1.5rem; line-height: 2rem; }

    .xl\:space-y-3 > * + * { margin-top: 0.75rem; }
    .xl\:space-y-5 > * + * { margin-top: 1.25rem; }

    .xl\:mb-3 { margin-bottom: 0.75rem; }
    .xl\:mb-4 { margin-bottom: 1rem; }
    .xl\:mb-5 { margin-bottom: 1.25rem; }
    .xl\:mr-2 { margin-right: 0.5rem; }
    .xl\:ml-20 { margin-left: 5rem; }
    .xl\:pl-3 { padding-left: 0.75rem; }
    .xl\:mt-4 { margin-top: 1rem; }
    .xl\:py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
    .xl\:py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
    .xl\:py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
    .xl\:py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
    .xl\:py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }

    .xl\:max-h-36 { max-height: 9rem; }

    .xl\:inline { display: inline; }
}

/* ============================================
   Responsive Breakpoints (2xl: 1536px+)
   ============================================ */
@media (min-width: 1536px) {
    .2xl\:w-72 { width: 18rem; }
    .2xl\:w-96 { width: 24rem; }
    .\32xl\:w-72 { width: 18rem; }
    .\32xl\:w-96 { width: 24rem; }
}

/* ============================================
   Animations
   ============================================ */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.animate-spin { animation: spin 1s linear infinite; }
.animate-pulse { animation: pulse 2s ease-in-out infinite; }

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}
.animate-slide-up { animation: slideUp 0.3s ease-out forwards; }

/* ============================================
   Ring/Focus utilities
   ============================================ */
.ring-2 { box-shadow: 0 0 0 2px; }
.ring-white\/50 { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5); }

/* ============================================
   Divide utilities for tables/lists
   ============================================ */
.divide-y > * + * { border-top-width: 1px; border-top-style: solid; }
.divide-white\/5 > * + * { border-color: rgba(255, 255, 255, 0.05); }

/* ============================================
   Common Component Styles
   ============================================ */

/* Status Dot */
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}
.status-dot.online {
    background-color: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
}
.status-dot.warning { background-color: #facc15; }
.status-dot.offline { background-color: #6b7280; }
.status-dot.error { background-color: #ef4444; }

/* Consensus Status Animations */
.consensus-spin {
    animation: consensus-spin 1.5s linear infinite;
}

@keyframes consensus-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Pending Transactions Popover */
.pending-tx-container {
    position: relative;
}

.pending-tx-container:hover .pending-tx-popover {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.pending-tx-popover {
    transform: translateY(-8px);
    pointer-events: none;
}

/* Hover bridge - invisible area that maintains hover when moving from trigger to popover */
.pending-tx-popover::before {
    content: '';
    position: absolute;
    top: -12px;  /* Extends up to cover the gap (mt-2 = 8px + buffer) */
    left: 0;
    right: 0;
    height: 12px;
}

/* Stat Card */
.stat-card {
    background: linear-gradient(135deg, rgba(31, 42, 42, 0.8), rgba(17, 24, 24, 0.6));
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    padding: 1.25rem;
    transition: all 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.stat-card.primary { border-left: 3px solid #3b82f6; }
.stat-card.success { border-left: 3px solid #22c55e; }
.stat-card.warning { border-left: 3px solid #f59e0b; }
.stat-card.info { border-left: 3px solid #06b6d4; }

/* Dark Card */
.card-dark {
    background-color: #1f2a2a;
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    transition: all 0.2s ease;
}

.card-dark:hover {
    border-color: rgba(var(--theme-500-rgb, 59, 130, 246), 0.3);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

/* ============================================
   Bootstrap Dark Theme Overrides
   ============================================
   Core Bootstrap components styled for dark theme.
   Uses CSS variables for theme-aware coloring.
*/

/* Cards */
.card {
    background-color: var(--bg-card, #161b22);
    border: 1px solid var(--border-color, #30363d);
    border-radius: 0.75rem;
    color: var(--text-primary, #e6edf3);
}

.card-header {
    background-color: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid var(--border-color, #30363d);
    color: var(--text-primary, #e6edf3);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
}

.card-body {
    padding: 1rem;
    color: var(--text-primary, #e6edf3);
}

.card-footer {
    background-color: rgba(0, 0, 0, 0.1);
    border-top: 1px solid var(--border-color, #30363d);
    padding: 0.75rem 1rem;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary, #e6edf3);
}

/* Tables */
.table {
    --bs-table-bg: transparent;
    --bs-table-color: var(--text-primary, #e6edf3);
    color: var(--text-primary, #e6edf3);
    width: 100%;
    border-collapse: collapse;
}

.table th {
    color: var(--text-secondary, #9ca3af) !important;
    border-bottom: 1px solid var(--border-color, #30363d);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
}

.table td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0.75rem 1rem;
    vertical-align: middle;
}

.table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.table-sm th, .table-sm td {
    padding: 0.5rem;
}

.table-responsive {
    overflow-x: auto;
}

/* Form Controls */
.form-control, .form-select {
    width: 100%;
    background-color: var(--bg-card, #1c1c26);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    color: var(--text-primary, #e5e7eb);
    border-radius: 0.5rem;
    padding: 0.625rem 0.875rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus, .form-select:focus {
    outline: none;
    border-color: var(--theme-500, #3b82f6);
    box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 59, 130, 246), 0.25);
}

.form-control::placeholder {
    color: var(--text-muted, #6b7280);
}

.form-label {
    display: block;
    color: var(--text-secondary, #d1d5db);
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

/* Date picker calendar icon - visible on dark theme */
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="datetime-local"]::-webkit-calendar-picker-indicator {
    filter: invert(1);
    cursor: pointer;
    opacity: 0.7;
}

input[type="date"]::-webkit-calendar-picker-indicator:hover,
input[type="datetime-local"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    text-decoration: none;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--theme-500, #3b82f6);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background-color: var(--theme-600, #2563eb);
    box-shadow: 0 0 12px rgba(var(--theme-500-rgb, 59, 130, 246), 0.4);
}

.btn-secondary {
    background-color: var(--bg-card, #1f2a2a);
    color: var(--text-primary, #e5e7eb);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
}

.btn-secondary:hover:not(:disabled) {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
}

.btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #4ade80 0%, #22c55e 100%);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, #f87171 0%, #ef4444 100%);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.btn-warning:hover:not(:disabled) {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.btn-outline-primary {
    color: var(--theme-500, #3b82f6);
    border: 1px solid var(--theme-500, #3b82f6);
    background-color: transparent;
}

.btn-outline-primary:hover:not(:disabled) {
    background-color: var(--theme-500, #3b82f6);
    color: white;
}

.btn-outline-success {
    color: #22c55e;
    border: 1px solid #22c55e;
    background-color: transparent;
}

.btn-outline-success:hover:not(:disabled) {
    background-color: #22c55e;
    color: white;
}

.btn-outline-danger {
    color: #ef4444;
    border: 1px solid #ef4444;
    background-color: transparent;
}

.btn-outline-danger:hover:not(:disabled) {
    background-color: #ef4444;
    color: white;
}

/* Dropdowns */
.dropdown-menu {
    background-color: var(--bg-card, #161b22);
    border: 1px solid var(--border-color, #30363d);
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.dropdown-item {
    color: var(--text-primary, #e6edf3);
    padding: 0.5rem 1rem;
    transition: background-color 0.15s;
}

.dropdown-item:hover, .dropdown-item:focus {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.dropdown-header {
    color: var(--text-secondary, #8b949e);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.dropdown-divider {
    border-top: 1px solid var(--border-color, #30363d);
}

/* Alerts */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.alert-success {
    background-color: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #22c55e;
}

.alert-warning {
    background-color: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.alert-danger {
    background-color: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.alert-info {
    background-color: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

.alert-dismissible {
    padding-right: 2.5rem;
    position: relative;
}

.alert .btn-close {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: currentColor;
    cursor: pointer;
    opacity: 0.7;
}

.alert .btn-close:hover {
    opacity: 1;
}

/* Spinner */
.spinner-border {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    vertical-align: -0.125em;
    border: 0.25em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.15em;
}

@keyframes spinner-border {
    to { transform: rotate(360deg); }
}

/* ============================================
   Node Dashboard Components
   ============================================
   Common components for Sentinel/Permanent node dashboards.
*/

/* Stat Grid - for dashboard stat cards */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary, #9ca3af);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
    word-break: break-word;
    hyphens: auto;
}

.stat-value {
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary, #e6edf3);
}

.stat-value.success { color: #22c55e; }
.stat-value.error { color: #ef4444; }
.stat-value.warning { color: #f59e0b; }
.stat-value.info { color: #3b82f6; }

/* Metrics Grid - for admin dashboards */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.metric-card {
    background: var(--bg-card, #1e1e28);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    padding: 1.25rem;
    transition: all 0.2s ease;
}

.metric-card:hover {
    border-color: var(--theme-500, #8b5cf6);
    box-shadow: 0 0 20px rgba(var(--theme-500-rgb, 139, 92, 246), 0.3);
}

.metric-card .metric-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.metric-card .metric-icon.success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
}

.metric-card .metric-icon.warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.metric-card .metric-icon.info {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.metric-card .metric-icon.admin {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    color: white;
}

.metric-card .metric-value {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.25rem;
}

.metric-card .metric-label {
    font-size: 0.875rem;
    color: var(--text-secondary, #9ca3af);
}

/* Log Viewer - for node dashboards */
.log-viewer {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.8rem;
    background-color: #0a0f0f;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
    border-radius: 0.75rem;
    padding: 1rem;
    overflow-x: auto;
    max-height: 600px;
    overflow-y: auto;
}

.log-container {
    background-color: #0a0f0f;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    overflow: hidden;
}

.log-entry {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.8125rem;
    line-height: 1.5;
    padding: 0.25rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.log-entry:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.log-timestamp {
    color: var(--text-muted, #6e7681);
    margin-right: 1rem;
}

/* Log level colors */
.log-level-info, .log-entry.info { color: #60a5fa; }
.log-level-success, .log-entry.success { color: #4ade80; }
.log-level-warn, .log-level-warning, .log-entry.warning { color: #fbbf24; }
.log-level-error, .log-entry.error { color: #f87171; }
.log-level-debug { color: var(--text-secondary, #8b949e); }
.log-entry.consensus { color: #a78bfa; }

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
}

.modal-content {
    background: var(--bg-card, #1e1e28);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
}

/* Pulse animation for status indicators */
@keyframes pulse-green {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-dot.online {
    animation: pulse-green 2s infinite;
}

/* Badges */
.badge-success {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.badge-warning {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: rgba(234, 179, 8, 0.2);
    color: #facc15;
}

.badge-danger {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.badge-info {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 9999px;
    background-color: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

/* Navigation Badges - Used in sidebar navigation for counts/status
   Default color uses theme variable for automatic app theming */
.nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.25rem;
    height: 1.25rem;
    padding: 0 0.375rem;
    font-size: 0.65rem;
    font-weight: 600;
    border-radius: 9999px;
    background-color: color-mix(in srgb, var(--theme-500) 20%, transparent);
    color: var(--theme-500);
    margin-left: 0.25rem;
}

.nav-badge-success {
    background-color: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.nav-badge-danger {
    background-color: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.nav-badge-warning {
    background-color: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.nav-badge-info {
    background-color: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

/* Category Badge - Base class for referendum topic categories
   Colors are overridden by each theme */
.category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    /* Default colors - overridden by themes */
    background-color: rgba(99, 102, 241, 0.15);
    color: var(--theme-400, #a5b4fc);
    border-color: rgba(99, 102, 241, 0.25);
}

.category-badge:hover {
    transform: scale(1.02);
}

.category-badge i {
    font-size: 0.7rem;
}

.category-badge-subscribed {
    /* Default subscribed state - overridden by themes */
    background-color: rgba(99, 102, 241, 0.25);
    color: var(--theme-300, #c7d2fe);
    border-color: rgba(99, 102, 241, 0.4);
}

/* Spin Animation Helper */
.spin {
    animation: spin 1s linear infinite;
}

/* ============================================
   Navigation Link Styles (Themed)
   ============================================
   Each app uses a theme-specific nav-link class for
   consistent spacing, hover effects, and active states
   with a colored left border glow.
*/

/* ============================================
   Sidebar Navigation Links
   ============================================
   Generic nav-link that uses CSS theme variables.
   Colors automatically adapt based on which theme
   file is loaded (sentinel, permanent, merchant, etc.)
*/

/* Admin sidebar navigation container */
.admin-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.5rem;
}

.nav-link {
    position: relative;
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    color: rgba(156, 163, 175, 1); /* gray-400 */
    transition: all 0.2s ease;
    text-decoration: none;
}

/* Animated accent border */
.nav-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 0;
    background: linear-gradient(180deg, var(--theme-500), var(--theme-400));
    border-radius: 0 4px 4px 0;
    transition: height 0.2s ease;
}

.nav-link i {
    width: 1.5rem;
    text-align: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
    margin-right: 0.325rem;
}

.nav-link span {
    white-space: nowrap;
}

.nav-link:hover {
    background: linear-gradient(90deg, rgba(var(--theme-500-rgb), 0.1), transparent);
    color: rgba(255, 255, 255, 1);
}

.nav-link:hover i {
    color: var(--theme-500);
    text-shadow: 0 0 12px rgba(var(--theme-500-rgb), 0.5);
}

.nav-link:hover::before {
    height: 60%;
}

.nav-link.active {
    background: linear-gradient(90deg, rgba(var(--theme-500-rgb), 0.2), rgba(var(--theme-500-rgb), 0.05));
    color: var(--theme-400);
}

.nav-link.active::before {
    height: 70%;
    box-shadow: 0 0 8px rgba(var(--theme-500-rgb), 0.4);
}

.nav-link.active i {
    color: var(--theme-500);
    text-shadow: 0 0 15px rgba(var(--theme-500-rgb), 0.6);
}

/* ============================================
   Tab Navigation (Bootstrap nav-tabs override)
   ============================================
   Dark theme tabs using CSS variables
*/

.nav-tabs {
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
}

.nav-tabs .nav-link {
    color: rgba(156, 163, 175, 1);
    font-weight: 500;
    border: none;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    padding: 0.75rem 1.5rem;
    background: transparent;
}

.nav-tabs .nav-link:hover {
    color: var(--theme-400);
    border-bottom-color: var(--theme-500);
    background-color: rgba(var(--theme-500-rgb), 0.05);
}

.nav-tabs .nav-link.active {
    color: var(--theme-400);
    background-color: transparent;
    border-bottom-color: var(--theme-500);
    font-weight: 600;
}

/* ============================================
   Generic Theme Utilities (use CSS variables)
   ============================================
   These use --theme-* variables set by each theme file.
   Apps should use these instead of hardcoded color classes.
*/

/* Theme text colors */
.text-theme-100 { color: var(--theme-100); }
.text-theme-200 { color: var(--theme-200); }
.text-theme-300 { color: var(--theme-300); }
.text-theme-400 { color: var(--theme-400); }
.text-theme-500 { color: var(--theme-500); }
.text-theme-600 { color: var(--theme-600); }
.text-theme-700 { color: var(--theme-700); }
.text-theme-100\/70 { color: rgba(var(--theme-100-rgb, 254, 243, 199), 0.7); }
.text-theme-200\/80 { color: rgba(var(--theme-200-rgb, 253, 230, 138), 0.8); }
.text-theme-400\/60 { color: rgba(var(--theme-400-rgb, 251, 191, 36), 0.6); }

/* Theme background colors */
.bg-theme-500 { background-color: var(--theme-500); }
.bg-theme-600 { background-color: var(--theme-600); }
.bg-theme-700 { background-color: var(--theme-700); }
.bg-theme-800 { background-color: var(--theme-800); }
.bg-theme-900 { background-color: var(--theme-900); }
.bg-theme-500\/5 { background-color: rgba(var(--theme-500-rgb), 0.05); }
.bg-theme-500\/10 { background-color: rgba(var(--theme-500-rgb), 0.1); }
.bg-theme-500\/20 { background-color: rgba(var(--theme-500-rgb), 0.2); }
.bg-theme-500\/30 { background-color: rgba(var(--theme-500-rgb), 0.3); }
.bg-theme-600\/10 { background-color: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.1); }
.bg-theme-600\/20 { background-color: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.2); }
.bg-theme-600\/30 { background-color: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.3); }
.bg-theme-900\/20 { background-color: rgba(var(--theme-900-rgb, 30, 27, 75), 0.2); }
.bg-theme-900\/30 { background-color: rgba(var(--theme-900-rgb, 30, 27, 75), 0.3); }
.bg-theme-900\/50 { background-color: rgba(var(--theme-900-rgb, 30, 27, 75), 0.5); }

/* Theme border colors */
.border-theme-500 { border-color: var(--theme-500); }
.border-theme-500\/20 { border-color: rgba(var(--theme-500-rgb), 0.2); }
.border-theme-500\/30 { border-color: rgba(var(--theme-500-rgb), 0.3); }
.border-theme-500\/40 { border-color: rgba(var(--theme-500-rgb), 0.4); }
.border-theme-500\/50 { border-color: rgba(var(--theme-500-rgb), 0.5); }
.border-theme-600 { border-color: var(--theme-600); }

/* Theme ring colors */
.ring-theme-500\/50 { --tw-ring-color: rgba(var(--theme-500-rgb), 0.5); }
.focus\:ring-theme-500\/50:focus { --tw-ring-color: rgba(var(--theme-500-rgb), 0.5); }
.focus\:border-theme-500:focus { border-color: var(--theme-500); }

/* Theme gradients */
.from-theme-400 {
    --tw-gradient-from: var(--theme-400);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-500 {
    --tw-gradient-from: var(--theme-500);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-600 {
    --tw-gradient-from: var(--theme-600) var(--tw-gradient-from-position);
    --tw-gradient-to: transparent var(--tw-gradient-to-position);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);
}
.via-theme-700 {
    --tw-gradient-to: transparent var(--tw-gradient-to-position);
    --tw-gradient-stops: var(--tw-gradient-from), var(--theme-700) var(--tw-gradient-via-position), var(--tw-gradient-to);
}
.to-theme-500 {
    --tw-gradient-to: var(--theme-500) var(--tw-gradient-to-position);
}
.to-theme-600 {
    --tw-gradient-to: var(--theme-600) var(--tw-gradient-to-position);
}
.to-theme-800 {
    --tw-gradient-to: var(--theme-800) var(--tw-gradient-to-position);
}
.to-theme-900 {
    --tw-gradient-to: var(--theme-900) var(--tw-gradient-to-position);
}

/* Gradient from with opacity */
.from-theme-500\/10 {
    --tw-gradient-from: rgba(var(--theme-500-rgb), 0.1);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-600\/10 {
    --tw-gradient-from: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.1);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-600\/20 {
    --tw-gradient-from: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.2);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-800\/50 {
    --tw-gradient-from: rgba(var(--theme-800-rgb, var(--theme-900-rgb, 30, 27, 75)), 0.5);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.from-theme-900\/50 {
    --tw-gradient-from: rgba(var(--theme-900-rgb, 30, 27, 75), 0.5);
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent);
}
.to-theme-500\/10 {
    --tw-gradient-to: rgba(var(--theme-500-rgb), 0.1);
}
.to-theme-600\/10 {
    --tw-gradient-to: rgba(var(--theme-600-rgb, var(--theme-500-rgb)), 0.1);
}
.to-theme-800\/50 {
    --tw-gradient-to: rgba(var(--theme-800-rgb, var(--theme-900-rgb, 30, 27, 75)), 0.5);
}

/* Theme hover states */
.hover\:bg-theme-500:hover { background-color: var(--theme-500); }
.hover\:bg-theme-600:hover { background-color: var(--theme-600); }
.hover\:bg-theme-700:hover { background-color: var(--theme-700); }
.hover\:border-theme-500:hover { border-color: var(--theme-500); }
.hover\:border-theme-500\/30:hover { border-color: rgba(var(--theme-500-rgb), 0.3); }
.hover\:border-theme-500\/50:hover { border-color: rgba(var(--theme-500-rgb), 0.5); }
.hover\:text-theme-400:hover { color: var(--theme-400); }
.hover\:text-theme-300:hover { color: var(--theme-300); }
.hover\:from-theme-400:hover { --tw-gradient-from: var(--theme-400); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:from-theme-500:hover { --tw-gradient-from: var(--theme-500); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, transparent); }
.hover\:to-theme-500:hover { --tw-gradient-to: var(--theme-500); }
.hover\:to-theme-600:hover { --tw-gradient-to: var(--theme-600); }

/* Theme peer-checked states */
.peer-checked\:bg-theme-600:is(.peer:checked ~ *) { background-color: var(--theme-600); }

/* Theme shadow colors */
.shadow-theme-500\/25 { --tw-shadow-color: rgba(var(--theme-500-rgb), 0.25); box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color); }
.shadow-theme-500\/20 { --tw-shadow-color: rgba(var(--theme-500-rgb), 0.2); box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color); }

/* Section divider text colors - standard Tailwind colors for semantic use */
.text-green-400\/60 { color: rgba(74, 222, 128, 0.6); }
.text-blue-400\/60 { color: rgba(96, 165, 250, 0.6); }
.text-amber-400\/60 { color: rgba(251, 191, 36, 0.6); }
.text-purple-400\/60 { color: rgba(192, 132, 252, 0.6); }

/* Additional margin utilities */
.ml-3 { margin-left: 0.75rem; }
.mx-3 { margin-left: 0.75rem; margin-right: 0.75rem; }

/* py-2.5 for nav links */
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }

/* Logout button hover states */
.hover\:text-red-300:hover { color: #fca5a5; }
.hover\:bg-red-500\/10:hover { background-color: rgba(239, 68, 68, 0.1); }

/* ============================================
   Login Page Styles (Floating Card)
   ============================================
   Used by all apps for consistent login experience.
   Accent colors come from theme CSS variables.
*/

.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: linear-gradient(135deg, var(--theme-gradient-start, #4c1d4d) 0%, #0f0f14 50%, #16161d 100%);
}

.login-card {
    background: #1e1e28;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 2.5rem;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

/* Mobile responsive login */
@media (max-width: 480px) {
    .login-container {
        padding: 1rem;
        align-items: flex-start;
        padding-top: 2rem;
    }

    .login-card {
        padding: 1.5rem;
        border-radius: 0.75rem;
    }

    .login-logo {
        width: 64px;
        height: 64px;
        margin-bottom: 1rem;
    }

    .login-title {
        font-size: 1.25rem;
    }
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
}

.login-logo img {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 20px var(--theme-glow, rgba(244, 63, 94, 0.3)));
}

.login-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.login-subtitle {
    color: #9ca3af;
    font-size: 0.875rem;
}

/* Login Form Controls */
.login-form-group {
    margin-bottom: 1.25rem;
}

.login-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #d1d5db;
    margin-bottom: 0.5rem;
}

.login-label i {
    color: var(--theme-accent, #f43f5e);
    margin-right: 0.375rem;
}

.login-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: #1c1c26;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    color: #ffffff;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.login-input::placeholder {
    color: #6b7280;
}

.login-input:focus {
    outline: none;
    border-color: var(--theme-accent, #f43f5e);
    box-shadow: 0 0 0 3px var(--theme-glow, rgba(244, 63, 94, 0.2));
}

/* Custom File Input (styled file picker) */
.file-input-wrapper {
    position: relative;
}

.file-input-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.file-input-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: #1c1c26;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    overflow: hidden;
}

.file-input-label:hover {
    border-color: var(--theme-accent-50, rgba(244, 63, 94, 0.5));
    background: #252530;
}

.file-input-label:hover .file-input-button {
    filter: brightness(1.1);
}

.file-input-hidden:focus + .file-input-label {
    border-color: var(--theme-accent, #f43f5e);
    box-shadow: 0 0 0 3px var(--theme-glow, rgba(244, 63, 94, 0.2));
}

.file-input-text {
    flex: 1;
    padding: 0.75rem 1rem;
    color: #9ca3af;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-input-text i {
    flex-shrink: 0;
    margin-right: 0.5rem;
}

/* When file is selected, change text color */
.file-input-label.has-file .file-input-text {
    color: #e5e7eb;
}

.file-input-button {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, var(--theme-accent, #f43f5e) 0%, var(--theme-accent-dark, #e11d48) 100%);
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.2s ease;
    white-space: nowrap;
}

/* Custom Search Input (file-picker style) */
.search-input-wrapper {
    display: flex;
    align-items: stretch;
    background: #1c1c26;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    overflow: hidden;
    transition: all 0.2s ease;
    width: 14rem;
}

.search-input-wrapper:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: #252530;
}

.search-input-wrapper:focus-within {
    border-color: var(--theme-accent, #f43f5e);
    box-shadow: 0 0 0 3px var(--theme-glow, rgba(244, 63, 94, 0.2));
}

.search-input-field {
    flex: 1;
    background: transparent;
    border: none;
    padding: 0.5rem 0.75rem;
    color: #e5e7eb;
    font-size: 0.875rem;
    outline: none;
    min-width: 0;
}

.search-input-field::placeholder {
    color: #6b7280;
}

.search-input-clear {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0.5rem;
    color: #6b7280;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.search-input-clear:hover {
    color: #d1d5db;
}

.search-input-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    color: white;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    transition: filter 0.2s ease;
    /* Match parent's right-side border radius */
    border-radius: 0 calc(0.5rem - 1px) calc(0.5rem - 1px) 0;
}

.search-input-wrapper:hover .search-input-button {
    filter: brightness(1.1);
}

/* Login Button */
.login-btn {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: linear-gradient(135deg, var(--theme-accent, #f43f5e) 0%, var(--theme-accent-dark, #e11d48) 100%);
    color: white;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px var(--theme-glow, rgba(244, 63, 94, 0.3));
}

.login-btn:hover:not(:disabled) {
    filter: brightness(1.1);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--theme-glow, rgba(244, 63, 94, 0.4));
}

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Login Alert Messages */
.login-alert {
    padding: 0.875rem 1rem;
    border-radius: 0.75rem;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.875rem;
}

.login-alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.login-alert-error i {
    color: #f87171;
    margin-top: 0.125rem;
}

.login-alert-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #86efac;
}

.login-alert-success i {
    color: #4ade80;
    margin-top: 0.125rem;
}

/* Login Footer */
.login-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.login-footer-text {
    color: #6b7280;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.login-footer-text i {
    color: #22c55e;
}

.login-help {
    margin-top: 1.5rem;
    text-align: center;
}

.login-help-text {
    color: #6b7280;
    font-size: 0.875rem;
}

.login-help-link {
    color: var(--theme-accent, #f43f5e);
    text-decoration: none;
    margin-left: 0.25rem;
}

.login-help-link:hover {
    color: var(--theme-accent-light, #fb7185);
    text-decoration: underline;
}

/* Loading Spinner for Login */
.login-spinner {
    width: 1.25rem;
    height: 1.25rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ============================================
   App Loading Screen (WASM Startup)
   ============================================ */

/* Fixed-width loading card container - Glassmorphic style */
.loading-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    width: 360px;              /* Fixed width - accommodates longer app names */
    min-width: 360px;          /* Prevent shrinking */
    max-width: 360px;          /* Prevent growing */
    box-sizing: border-box;    /* Include padding in width calculation */
    padding: 3rem 2rem;
    /* Glassmorphic background - semi-transparent with blur */
    background: linear-gradient(135deg,
        rgba(22, 22, 29, 0.7),
        rgba(28, 28, 38, 0.6));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow:
        0 25px 50px -12px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Spinner indicator container */
.loading-indicator {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
}

/* Glow effect behind spinner - uses CSS variable for theme color */
.loading-indicator::before {
    content: '';
    position: absolute;
    inset: -12px;
    border-radius: 50%;
    background: var(--loading-glow, rgba(244, 63, 94, 0.15));
    filter: blur(15px);
    animation: loading-pulse 2s ease-in-out infinite;
}

/* Double spinner - outer ring */
.loading-spinner-double {
    width: 72px;
    height: 72px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--loading-color, #f43f5e);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    position: relative;
}

/* Double spinner - inner ring */
.loading-spinner-double::after {
    content: '';
    position: absolute;
    inset: 4px;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: var(--loading-color-secondary, rgba(251, 113, 133, 0.6));
    animation: spin 1.2s linear infinite reverse;
}

/* Center icon in spinner */
.loading-icon {
    position: absolute;
    font-size: 1.75rem;
    color: var(--loading-color, #f43f5e);
    animation: loading-pulse 2s ease-in-out infinite;
}

/* Loading text container */
.loading-text {
    text-align: center;
}

.loading-text h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    margin: 0;
}

.loading-text p {
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #9ca3af;
}

/* Pulse animation for glow and icon */
@keyframes loading-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* Theme-specific loading colors - set via inline style or theme CSS */
/* Example: style="--loading-color: #f59e0b; --loading-glow: rgba(245, 158, 11, 0.15);" */

/* ============================================
   Hot Topic Toggle Component
   Sexy animated toggle for voting pages
   ============================================ */

.hot-topic-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hot-topic-toggle:hover {
    background: linear-gradient(135deg, rgba(251, 146, 60, 0.1), rgba(251, 146, 60, 0.05));
    border-color: rgba(251, 146, 60, 0.3);
}

.hot-topic-toggle.active {
    background: linear-gradient(135deg, rgba(251, 146, 60, 0.2), rgba(239, 68, 68, 0.15));
    border-color: rgba(251, 146, 60, 0.5);
}

.hot-topic-flame {
    font-size: 1.25rem;
    color: #94a3b8;
    transition: all 0.3s ease;
}

.hot-topic-flame.burning {
    color: #f97316;
    animation: flame-pulse 0.8s ease-in-out infinite;
    filter: drop-shadow(0 0 8px rgba(249, 115, 22, 0.5));
}

@keyframes flame-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

.hot-topic-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #94a3b8;
    transition: color 0.3s ease;
}

.hot-topic-toggle.active .hot-topic-label {
    color: #fb923c;
}

.hot-topic-switch {
    width: 40px;
    height: 22px;
    background: rgba(100, 116, 139, 0.4);
    border-radius: 11px;
    padding: 2px;
    transition: all 0.3s ease;
}

.hot-topic-toggle.active .hot-topic-switch {
    background: linear-gradient(135deg, #f97316, #ef4444);
    box-shadow: 0 0 12px rgba(249, 115, 22, 0.4);
}

.hot-topic-switch-thumb {
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hot-topic-toggle.active .hot-topic-switch-thumb {
    transform: translateX(18px);
}

/* ============================================
   Electoral Reward Prompt
   Post-vote call to action
   ============================================ */

.electoral-reward-prompt {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(217, 119, 6, 0.05));
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 0.75rem;
    padding: 1rem;
}

/* Pulsing border animation for unverified RUBI balance */
.animate-pulse-border {
    animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
    0%, 100% {
        border-color: rgba(245, 158, 11, 0.3);
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
    }
    50% {
        border-color: rgba(245, 158, 11, 0.8);
        box-shadow: 0 0 8px 0 rgba(245, 158, 11, 0.3);
    }
}

/* ============================================
   AI Review Animation
   ============================================
   Subtle neural network-inspired animation for AI processing states
*/

.ai-review-container {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
}

.ai-review-animation {
    display: flex;
    justify-content: center;
    margin-bottom: 1rem;
}

.ai-nodes {
    position: relative;
    width: 120px;
    height: 50px;
}

.ai-node {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, #818cf8, #a78bfa);
    box-shadow: 0 0 12px rgba(129, 140, 248, 0.6);
}

.ai-node.node-1 { left: 10px; top: 20px; animation: ai-node-pulse 1.5s ease-in-out infinite 0s; }
.ai-node.node-2 { left: 35px; top: 5px; animation: ai-node-pulse 1.5s ease-in-out infinite 0.2s; }
.ai-node.node-3 { left: 55px; top: 22px; animation: ai-node-pulse 1.5s ease-in-out infinite 0.4s; }
.ai-node.node-4 { left: 75px; top: 35px; animation: ai-node-pulse 1.5s ease-in-out infinite 0.6s; }
.ai-node.node-5 { left: 100px; top: 20px; animation: ai-node-pulse 1.5s ease-in-out infinite 0.8s; }

@keyframes ai-node-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.6;
        box-shadow: 0 0 8px rgba(129, 140, 248, 0.4);
    }
    50% {
        transform: scale(1.4);
        opacity: 1;
        box-shadow: 0 0 20px rgba(129, 140, 248, 0.8);
    }
}

.ai-connections {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.ai-line {
    stroke: url(#ai-gradient);
    stroke-width: 1.5;
    stroke-linecap: round;
    fill: none;
    opacity: 0.4;
}

.ai-line.line-1 { animation: ai-line-flow 2s ease-in-out infinite 0s; }
.ai-line.line-2 { animation: ai-line-flow 2s ease-in-out infinite 0.3s; }
.ai-line.line-3 { animation: ai-line-flow 2s ease-in-out infinite 0.5s; }
.ai-line.line-4 { animation: ai-line-flow 2s ease-in-out infinite 0.7s; }
.ai-line.line-5 { animation: ai-line-flow 2s ease-in-out infinite 0.9s; }
.ai-line.line-6 { animation: ai-line-flow 2s ease-in-out infinite 1.1s; }

@keyframes ai-line-flow {
    0%, 100% {
        stroke: rgba(129, 140, 248, 0.2);
        stroke-width: 1;
    }
    50% {
        stroke: rgba(167, 139, 250, 0.8);
        stroke-width: 2;
    }
}

.ai-review-text {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    font-size: 0.95rem;
    font-weight: 500;
}

.ai-shimmer-text {
    background: linear-gradient(90deg, #818cf8 0%, #c4b5fd 50%, #818cf8 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: ai-shimmer 2s linear infinite;
}

@keyframes ai-shimmer {
    0% { background-position: 200% center; }
    100% { background-position: -200% center; }
}

.ai-dots span {
    color: #a78bfa;
    animation: ai-dot-bounce 1.4s ease-in-out infinite;
}

.ai-dots span:nth-child(1) { animation-delay: 0s; }
.ai-dots span:nth-child(2) { animation-delay: 0.2s; }
.ai-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes ai-dot-bounce {
    0%, 60%, 100% { opacity: 0.3; }
    30% { opacity: 1; }
}

/* AI pulse dot for buttons */
.ai-pulse-dot {
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, #818cf8, #a78bfa);
    border-radius: 50%;
    animation: ai-pulse-glow 1s ease-in-out infinite;
}

@keyframes ai-pulse-glow {
    0%, 100% {
        box-shadow: 0 0 4px rgba(129, 140, 248, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 12px rgba(129, 140, 248, 0.8), 0 0 20px rgba(167, 139, 250, 0.4);
        transform: scale(1.2);
    }
}

/* AI Analyzing - Compact inline mode */
.ai-analyzing-compact {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 9999px;
    font-size: 0.875rem;
}

.ai-analyzing-compact .ai-pulse-dot {
    width: 6px;
    height: 6px;
}

.ai-analyzing-compact .ai-shimmer-text {
    font-size: 0.875rem;
    font-weight: 500;
}

.ai-analyzing-compact .ai-dots {
    margin-left: -0.25rem;
}

/* ============================================
   PWA & Mobile Navigation
   ============================================
   Shared mobile bottom tab navigation styles
*/

/* iOS/Android safe area support */
.safe-area-bottom {
    padding-top: 0.5rem;
    padding-bottom: calc(0.5rem + env(safe-area-inset-bottom, 0));
}

/* Content area padding to clear fixed bottom navigation */
.content-clear-bottom-nav {
    padding-bottom: calc(5rem + env(safe-area-inset-bottom, 0));
}

/* Mobile bottom tab navigation link - higher specificity to override Tailwind */
a.mobile-tab-link,
a.tab-link,
.mobile-tab-link,
.tab-link {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0.625rem 0.5rem !important;
    color: #64748b !important;
    transition: color 0.15s, transform 0.15s !important;
    min-width: 3.5rem !important;
    text-decoration: none !important;
    gap: 0.125rem !important;
    line-height: 1 !important;
}

a.mobile-tab-link i,
a.tab-link i,
.mobile-tab-link i,
.tab-link i {
    font-size: 1.25rem !important;
    line-height: 1 !important;
}

a.mobile-tab-link span,
a.tab-link span,
.mobile-tab-link span,
.tab-link span {
    font-size: 0.625rem !important;
    font-weight: 500 !important;
    text-transform: none !important;
    line-height: 1 !important;
}

a.mobile-tab-link:hover,
a.tab-link:hover,
.mobile-tab-link:hover,
.tab-link:hover {
    color: var(--theme-400, #fb7185) !important;
}

a.mobile-tab-link.active,
a.tab-link.active,
.mobile-tab-link.active,
.tab-link.active {
    color: var(--theme-500, #f43f5e) !important;
}

a.mobile-tab-link.active i,
a.tab-link.active i,
.mobile-tab-link.active i,
.tab-link.active i {
    transform: scale(1.1);
}

/* ============================================
   Admin Avatar Component
   Circular avatar with initials and theme glow
   ============================================ */

.admin-avatar {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--theme-500, #a855f7), var(--theme-600, #9333ea));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    color: white;
    box-shadow: 0 0 12px rgba(var(--theme-500-rgb, 168, 85, 247), 0.4);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.admin-avatar-sm {
    width: 32px;
    height: 32px;
    min-width: 32px;
    font-size: 0.75rem;
}

.admin-avatar-lg {
    width: 56px;
    height: 56px;
    min-width: 56px;
    font-size: 1.125rem;
}

/* Logout button for admin portals */
.btn-logout {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    color: rgba(248, 113, 113, 0.9);
    background: transparent;
    border: 1px solid rgba(248, 113, 113, 0.2);
    transition: all 0.2s ease;
    cursor: pointer;
}

.btn-logout:hover {
    color: #f87171;
    background: rgba(248, 113, 113, 0.1);
    border-color: rgba(248, 113, 113, 0.4);
}

/* ============================================
   Referendum Components (Structural Base)
   ============================================
   These classes define structural properties only.
   Color overrides are in individual theme files.
*/

/* Topic Card - structural properties */
.topic-card {
    border-radius: 0.75rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
}

.topic-card:hover {
    transform: translateY(-2px);
}

/* Voted Topic Card - green glow effect */
.topic-card-voted {
    border-color: rgba(34, 197, 94, 0.5) !important;
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.3), 0 0 30px rgba(34, 197, 94, 0.1);
}

.topic-card-voted:hover {
    border-color: rgba(34, 197, 94, 0.7) !important;
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.4), 0 0 40px rgba(34, 197, 94, 0.15);
}

/* ==========================================
   Voting Type Border Styles - GLOBAL
   Solid colored borders per voting type
   ========================================== */

/* Yes/No - Emerald */
.topic-card.topic-card-yesno {
    border: 2px solid rgb(16, 185, 129) !important;
    box-shadow: none;
}

/* Single Choice - Sky Blue */
.topic-card.topic-card-single {
    border: 2px solid rgb(14, 165, 233) !important;
    box-shadow: none;
}

/* Multi Choice - Cyan */
.topic-card.topic-card-multi {
    border: 2px solid rgb(6, 182, 212) !important;
    box-shadow: none;
}

/* Ranked Choice - Amber */
.topic-card.topic-card-ranked {
    border: 2px solid rgb(245, 158, 11) !important;
    box-shadow: none;
}

/* Town Square - Purple */
.topic-card.topic-card-townsquare {
    border: 2px solid rgb(168, 85, 247) !important;
    box-shadow: none;
}

/* Petition/AskAQuestion - Rose */
.topic-card.topic-card-petition {
    border: 2px solid rgb(244, 63, 94) !important;
    box-shadow: none;
}

/* Multi-Sig Topic Cards - Amber with gradient background */
.topic-card.topic-card-multisig {
    border: 2px solid rgb(245, 158, 11) !important;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(234, 88, 12, 0.05)) !important;
    box-shadow: none;
}

.topic-card.topic-card-multisig:hover {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(234, 88, 12, 0.08)) !important;
}

/* Vote Progress Bars - structural properties */
.vote-bar {
    height: 0.5rem;
    border-radius: 9999px;
    overflow: hidden;
}

.vote-bar-yes,
.vote-bar-no {
    height: 100%;
    transition: all 0.5s ease;
}

/* Category Badge - structural properties */
.category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.325rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border: 1px solid transparent;
    transition: all 0.15s ease;
}

/* Network/Referral Components - structural properties */
.network-level {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding: 0.75rem 0;
}

.network-node {
    width: 2.75rem;
    height: 2.75rem;
    min-width: 2.75rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex-shrink: 0;
}

.network-node-root {
    width: 3.5rem;
    height: 3.5rem;
    min-width: 3.5rem;
    font-size: 0.875rem;
}

.network-connector {
    width: 2px;
    height: 1.5rem;
    margin: 0 auto;
}

/* Leaderboard Components - structural properties */
.leaderboard-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    transition: background-color 0.2s ease;
}

.leaderboard-rank {
    width: 2rem;
    height: 2rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 700;
}

/* Share Button (FAB) - structural properties */
.share-button {
    position: fixed;
    bottom: 6rem;
    right: 1.5rem;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    z-index: 40;
    transition: transform 0.2s ease;
}

.share-button:hover {
    transform: scale(1.1);
}

@media (min-width: 768px) {
    .share-button {
        bottom: 1.5rem;
    }
}

/* Install Prompt - structural properties */
.install-prompt {
    position: fixed;
    bottom: 5rem;
    left: 1rem;
    right: 1rem;
    padding: 1rem;
    border-radius: 0.75rem;
}

@media (min-width: 768px) {
    .install-prompt {
        left: auto;
        right: 1.5rem;
        width: 20rem;
    }
}

/* Progress Ring - structural properties */
.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring-circle {
    transition: stroke-dashoffset 0.5s ease;
}

/* Stat Components - structural properties */
.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
}

.stat-label {
    font-size: 0.875rem;
}

/* ============================================
   Shared Theme Components
   ============================================
   These use CSS variables set by individual themes.
*/

/* Sidebar gradient - uses --theme-950 from active theme */
.sidebar-gradient {
    background: linear-gradient(180deg, var(--theme-950) 0%, #030712 70%);
}

/* Theme glow - uses --theme-glow from active theme */
.theme-glow {
    box-shadow: 0 0 20px var(--theme-glow, rgba(244, 63, 94, 0.3));
}

/* ============================================
   Help Zones (Theme-Aware)
   ============================================
   Uses --theme-500-rgb CSS variable from active theme.
   Each theme file must define:
     --theme-500: #hexcolor;
     --theme-500-rgb: r, g, b;
     --theme-400: #hexcolor;
     --theme-100: #hexcolor;
*/

/* Help Icons - Always visible question marks */
.help-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    font-size: 0.75rem;
    color: var(--theme-500);
    opacity: 0.6;
    cursor: help;
    transition: all 0.2s ease;
    margin-left: 6px;
    border-radius: 50%;
    background: rgba(var(--theme-500-rgb), 0.1);
    flex-shrink: 0;
}

.help-icon:hover {
    opacity: 1;
    color: var(--theme-400);
    background: rgba(var(--theme-500-rgb), 0.2);
    transform: scale(1.1);
}

/* Section header help zones - for h2 titles */
/* Default state is BRIGHT */
.help-zone-header {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    margin-left: 4px;
    border-radius: 8px;
    border: 1px dashed rgba(var(--theme-500-rgb), 0.7);
    border-left: 3px solid var(--theme-500);
    cursor: help;
    transition: all 0.2s ease;
    position: relative;
    background: rgba(var(--theme-500-rgb), 0.08);
}

/* Hover state is EVEN BRIGHTER */
.help-zone-header:hover {
    background-color: rgba(var(--theme-500-rgb), 0.18);
    border-color: var(--theme-400);
    border-left-color: var(--theme-400);
    box-shadow: 0 0 12px rgba(var(--theme-500-rgb), 0.3);
}

/* Question mark indicator for help zones */
.help-zone-header .help-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    margin-left: 10px;
    border-radius: 50%;
    background: rgba(var(--theme-500-rgb), 0.25);
    color: var(--theme-400);
    font-size: 0.8rem;
    transition: all 0.2s ease;
}

.help-zone-header:hover .help-indicator {
    background: rgba(var(--theme-500-rgb), 0.45);
    color: var(--theme-100);
    transform: scale(1.15);
    box-shadow: 0 0 8px rgba(var(--theme-500-rgb), 0.5);
}

/* Hide help zones when RubiHelper is dismissed */
body.rubi-helper-hidden .help-zone-header {
    border-color: transparent !important;
    background: transparent !important;
    border-left-color: transparent !important;
    cursor: default !important;
    padding: 0 !important;
    margin-left: 0 !important;
    border: none !important;
    box-shadow: none !important;
}

body.rubi-helper-hidden .help-zone-header:hover {
    background: transparent !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

body.rubi-helper-hidden .help-zone-header .help-indicator {
    display: none !important;
}

body.rubi-helper-hidden .help-zone-header:hover .help-indicator {
    display: none !important;
}

body.rubi-helper-hidden .cursor-help {
    cursor: default !important;
}

body.rubi-helper-hidden .help-icon {
    display: none !important;
}

/* Also hide card-level help icons (bi-question-circle in groups) when gem is hidden */
body.rubi-helper-hidden .group .bi-question-circle {
    display: none !important;
}

body.rubi-helper-hidden .cursor-help .bi-question-circle {
    display: none !important;
}

/* Smaller help icon variant for inline text */
.help-icon-sm {
    width: 14px;
    height: 14px;
    font-size: 0.65rem;
    margin-left: 4px;
}

/* ============================================
   Enhanced Registration Form Styles
   ============================================
   Modern, animated registration forms for
   PaymentPortal (User, Merchant, Referendum)
*/

/* Step Progress Indicator */
.registration-steps {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-bottom: 2rem;
    padding: 0 1rem;
}

.registration-step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.registration-step-number {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
}

.registration-step.active .registration-step-number {
    background: linear-gradient(135deg, var(--theme-500, #6366f1), var(--theme-600, #4f46e5));
    border-color: var(--theme-400, #818cf8);
    color: white;
    box-shadow: 0 0 20px rgba(var(--theme-500-rgb, 99, 102, 241), 0.4);
    animation: stepPulse 2s ease-in-out infinite;
}

@keyframes stepPulse {
    0%, 100% {
        box-shadow: 0 0 20px rgba(var(--theme-500-rgb, 99, 102, 241), 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 30px rgba(var(--theme-500-rgb, 99, 102, 241), 0.6);
        transform: scale(1.05);
    }
}

.registration-step.completed .registration-step-number {
    background: rgba(34, 197, 94, 0.2);
    border-color: #22c55e;
    color: #22c55e;
}

.registration-step-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.4);
    display: none;
}

@media (min-width: 640px) {
    .registration-step-label {
        display: block;
    }
}

.registration-step.active .registration-step-label {
    color: var(--theme-400, #818cf8);
}

.registration-step.completed .registration-step-label {
    color: #22c55e;
}

.registration-step-connector {
    width: 3rem;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 0.5rem;
}

.registration-step-connector.completed {
    background: linear-gradient(90deg, #22c55e, var(--theme-500, #6366f1));
    animation: connectorFill 0.5s ease-out;
}

@keyframes connectorFill {
    from {
        background-size: 0% 100%;
        background-position: left;
    }
    to {
        background-size: 100% 100%;
        background-position: left;
    }
}

/* Registration Form Container */
.registration-form {
    max-width: 640px;
    margin: 0 auto;
}

/* Animated Form Section */
.reg-form-section {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    /* Staggered fade-in animation */
    animation: sectionFadeIn 0.5s ease-out backwards;
}

/* Stagger delays for each section */
.reg-form-section:nth-child(1) { animation-delay: 0s; }
.reg-form-section:nth-child(2) { animation-delay: 0.1s; }
.reg-form-section:nth-child(3) { animation-delay: 0.2s; }
.reg-form-section:nth-child(4) { animation-delay: 0.3s; }
.reg-form-section:nth-child(5) { animation-delay: 0.4s; }
.reg-form-section:nth-child(6) { animation-delay: 0.5s; }

@keyframes sectionFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reg-form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--section-color, var(--theme-500)), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.reg-form-section:focus-within::before {
    opacity: 1;
}

.reg-form-section:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.reg-form-section:focus-within {
    transform: translateY(-2px);
    border-color: rgba(var(--theme-500-rgb, 99, 102, 241), 0.3);
    box-shadow: 0 8px 30px rgba(var(--theme-500-rgb, 99, 102, 241), 0.15);
}

/* Section Color Variants */
.reg-form-section-identity {
    --section-color: #3b82f6; /* Blue for personal info */
}

.reg-form-section-contact {
    --section-color: #22c55e; /* Green for contact */
}

.reg-form-section-address {
    --section-color: #f59e0b; /* Amber for address */
}

.reg-form-section-electoral {
    --section-color: #6366f1; /* Indigo for electoral */
}

.reg-form-section-security {
    --section-color: #ef4444; /* Red for security/password */
}

/* Section Header with Icon */
.reg-section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.reg-section-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--theme-500-rgb, 99, 102, 241), 0.15);
    color: var(--section-color, var(--theme-400));
    transition: all 0.3s ease;
}

.reg-form-section:hover .reg-section-icon,
.reg-form-section:focus-within .reg-section-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 0 20px rgba(var(--theme-500-rgb, 99, 102, 241), 0.3);
}

.reg-section-icon i {
    font-size: 1.125rem;
    transition: transform 0.3s ease;
}

.reg-form-section:hover .reg-section-icon i {
    transform: scale(1.1);
}

.reg-section-title {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.8);
}

.reg-section-subtitle {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 0.125rem;
}

/* Form Grid Layouts */
.reg-form-grid {
    display: grid;
    gap: 1rem;
}

.reg-form-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.reg-form-grid-3 {
    grid-template-columns: 2fr 1fr 1fr;
}

.reg-form-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 640px) {
    .reg-form-grid-2,
    .reg-form-grid-3,
    .reg-form-grid-4 {
        grid-template-columns: 1fr;
    }
}

/* Form Group with Floating Label */
.reg-form-group {
    position: relative;
}

.reg-form-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 0.5rem;
    transition: color 0.2s ease;
}

.reg-form-group:focus-within .reg-form-label {
    color: var(--theme-400, #818cf8);
}

.reg-form-label .required {
    color: #f43f5e;
    margin-left: 0.125rem;
}

.reg-form-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    color: white;
    font-size: 0.9375rem;
    transition: all 0.2s ease;
}

.reg-form-input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.reg-form-input:focus {
    outline: none;
    border-color: var(--theme-500, #6366f1);
    box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 99, 102, 241), 0.15),
                0 0 20px rgba(var(--theme-500-rgb, 99, 102, 241), 0.1),
                inset 0 1px 2px rgba(0, 0, 0, 0.2);
    background: rgba(0, 0, 0, 0.4);
    animation: inputFocusGlow 1.5s ease-in-out infinite;
}

@keyframes inputFocusGlow {
    0%, 100% {
        box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 99, 102, 241), 0.15),
                    0 0 15px rgba(var(--theme-500-rgb, 99, 102, 241), 0.1),
                    inset 0 1px 2px rgba(0, 0, 0, 0.2);
    }
    50% {
        box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 99, 102, 241), 0.25),
                    0 0 25px rgba(var(--theme-500-rgb, 99, 102, 241), 0.2),
                    inset 0 1px 2px rgba(0, 0, 0, 0.2);
    }
}

.reg-form-hint {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 0.375rem;
}

/* Select Dropdown Styling */
.reg-form-select {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    color: white;
    font-size: 0.9375rem;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 12px;
    transition: all 0.2s ease;
}

.reg-form-select:focus {
    outline: none;
    border-color: var(--theme-500, #6366f1);
    box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 99, 102, 241), 0.15);
}

.reg-form-select option {
    background: #1a1a2e;
    color: white;
}

/* ============================================
   Date of Birth Picker Component
   ============================================
   Three-dropdown DOB selector - much better UX than calendar pickers.
   Used across registration forms for age verification.
*/

.dob-picker {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1.2fr;
    gap: 0.75rem;
    align-items: end;
}

.dob-picker-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.dob-picker-month {
    /* Month dropdown needs more width for full month names */
}

.dob-picker-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.dob-picker-select {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    padding: 0.75rem 2rem 0.75rem 1rem;
    color: white;
    font-size: 0.9375rem;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 12px;
    transition: all 0.2s ease;
}

.dob-picker-select:focus {
    outline: none;
    border-color: var(--theme-500, #6366f1);
    box-shadow: 0 0 0 3px rgba(var(--theme-500-rgb, 99, 102, 241), 0.15);
    background-color: rgba(0, 0, 0, 0.4);
}

.dob-picker-select:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.dob-picker-select option {
    background: #1a1a2e;
    color: white;
    padding: 0.5rem;
}

/* Compact variant for smaller forms */
.dob-picker.dob-picker-compact {
    gap: 0.5rem;
}

.dob-picker.dob-picker-compact .dob-picker-select {
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
}

/* No-labels variant */
.dob-picker.dob-picker-no-labels .dob-picker-label {
    display: none;
}

/* Responsive: Stack on very small screens */
@media (max-width: 400px) {
    .dob-picker {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
}

/* Electoral Verification Section (Referendum) */
.electoral-verification-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(79, 70, 229, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-top: 1rem;
}

.electoral-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.electoral-badge-pending {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.electoral-badge-verified {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.electoral-info-box {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 0.75rem;
    margin-top: 1rem;
}

.electoral-info-box i {
    color: #818cf8;
    font-size: 1.25rem;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.electoral-info-text {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

/* ==========================================
   Shared Checkbox Component (RubiCheckbox)
   ========================================== */

/* Wrapper - provides hover background */
.rubi-checkbox-group,
.reg-checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.rubi-checkbox-group:hover,
.reg-checkbox-group:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

.rubi-checkbox-group.checked,
.reg-checkbox-group.checked {
    background: rgba(var(--theme-500-rgb, 99, 102, 241), 0.08);
    border-color: rgba(var(--theme-500-rgb, 99, 102, 241), 0.3);
}

/* The checkbox input itself */
.rubi-checkbox,
.reg-checkbox {
    width: 24px;
    height: 24px;
    min-width: 24px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.375rem;
    background: transparent;
    cursor: pointer;
    flex-shrink: 0;
    appearance: none;
    -webkit-appearance: none;
    transition: all 0.2s ease;
}

.rubi-checkbox:hover,
.reg-checkbox:hover {
    border-color: rgba(255, 255, 255, 0.4);
}

.rubi-checkbox:checked,
.reg-checkbox:checked {
    background: var(--theme-500, #6366f1);
    border-color: var(--theme-500, #6366f1);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='white' viewBox='0 0 16 16'%3E%3Cpath d='M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    animation: checkboxPop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.rubi-checkbox:disabled,
.reg-checkbox:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@keyframes checkboxPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

/* Label text */
.rubi-checkbox-label,
.reg-checkbox-label {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
    flex: 1;
}

.rubi-checkbox-label a,
.reg-checkbox-label a {
    color: var(--theme-400, #818cf8);
    text-decoration: none;
}

.rubi-checkbox-label a:hover,
.reg-checkbox-label a:hover {
    text-decoration: underline;
}

/* Compact variant - no background box */
.rubi-checkbox-group.compact,
.reg-checkbox-group.compact {
    padding: 0;
    background: transparent;
    border: none;
}

.rubi-checkbox-group.compact:hover,
.reg-checkbox-group.compact:hover {
    background: transparent;
}

/* Mobile responsive checkbox */
@media (max-width: 640px) {
    .rubi-checkbox-group,
    .reg-checkbox-group {
        padding: 0.75rem;
        gap: 0.625rem;
    }

    .rubi-checkbox,
    .reg-checkbox {
        width: 22px;
        height: 22px;
        min-width: 22px;
    }

    .rubi-checkbox-label,
    .reg-checkbox-label {
        font-size: 0.8rem;
    }
}

/* Submit Button - Large Gradient */
.reg-submit-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 0.75rem;
    color: white;
    background: linear-gradient(135deg, var(--theme-500, #6366f1) 0%, var(--theme-600, #4f46e5) 100%);
    box-shadow: 0 4px 15px rgba(var(--theme-500-rgb, 99, 102, 241), 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.reg-submit-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.reg-submit-btn:hover::before {
    left: 100%;
}

.reg-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(var(--theme-500-rgb, 99, 102, 241), 0.5);
}

.reg-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.reg-submit-btn:disabled:hover::before {
    left: -100%;
}

/* App-specific Submit Button Colors */
.reg-submit-btn-blue {
    --theme-500: #3b82f6;
    --theme-600: #2563eb;
    --theme-500-rgb: 59, 130, 246;
}

.reg-submit-btn-indigo {
    --theme-500: #6366f1;
    --theme-600: #4f46e5;
    --theme-500-rgb: 99, 102, 241;
}

.reg-submit-btn-green {
    --theme-500: #22c55e;
    --theme-600: #16a34a;
    --theme-500-rgb: 34, 197, 94;
}

.reg-submit-btn-amber {
    --theme-500: #f59e0b;
    --theme-600: #d97706;
    --theme-500-rgb: 245, 158, 11;
}

/* Password Strength Indicator */
.password-strength {
    display: flex;
    gap: 0.25rem;
    margin-top: 0.5rem;
}

.password-strength-bar {
    flex: 1;
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.1);
    transition: background 0.3s ease;
}

.password-strength-bar.weak { background: #ef4444; }
.password-strength-bar.medium { background: #f59e0b; }
.password-strength-bar.strong { background: #22c55e; }

.password-strength-text {
    font-size: 0.75rem;
    margin-top: 0.375rem;
}

.password-strength-text.weak { color: #ef4444; }
.password-strength-text.medium { color: #f59e0b; }
.password-strength-text.strong { color: #22c55e; }

/* Registration Success Card */
.reg-success-card {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(22, 163, 74, 0.05) 100%);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 1rem;
}

.reg-success-icon {
    width: 5rem;
    height: 5rem;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.4);
    animation: successPopIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards,
               successPulse 2s ease-in-out 0.6s infinite;
}

@keyframes successPopIn {
    0% {
        opacity: 0;
        transform: scale(0) rotate(-180deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes successPulse {
    0%, 100% {
        box-shadow: 0 0 30px rgba(34, 197, 94, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 50px rgba(34, 197, 94, 0.6);
        transform: scale(1.02);
    }
}

.reg-success-icon i {
    font-size: 2.5rem;
    color: white;
    animation: checkmarkDraw 0.4s ease-out 0.3s backwards;
}

@keyframes checkmarkDraw {
    from {
        opacity: 0;
        transform: scale(0);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.reg-success-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #4ade80;
    margin-bottom: 0.75rem;
}

.reg-success-message {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1.5rem;
}

/* Indigo Color Utilities (for Referendum) */
.text-indigo-400 { color: #818cf8 !important; }
.text-indigo-500 { color: #6366f1 !important; }
.bg-indigo-500\/10 { background-color: rgba(99, 102, 241, 0.1); }
.bg-indigo-500\/20 { background-color: rgba(99, 102, 241, 0.2); }
.border-indigo-500\/30 { border-color: rgba(99, 102, 241, 0.3); }

/* Australian States Select Option */
.state-select option[value=""] {
    color: rgba(255, 255, 255, 0.4);
}
