/* Platform Admin Panel CSS Styles */
:root {
    --platform-primary: #dc3545;
    --platform-primary-dark: #6f42c1;
    --platform-secondary: #64748b;
    --platform-success: #059669;
    --platform-warning: #d97706;
    --platform-danger: #dc2626;
    --platform-info: #0891b2;
    --platform-light: #f8fafc;
    --platform-dark: #1e293b;
    --platform-gray: #6b7280;
    --platform-border: #e2e8f0;
    --platform-shadow: rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--platform-light);
    color: var(--platform-dark);
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    width: 100%;
}

/* Navigation - Fixed Header Styles */
.platform-header {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
    color: white;
    padding: 0;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.15);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0;
    border-radius: 0;
}

.platform-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 70px;
    padding: 12px 24px;
    gap: 32px;
    max-width: 100%;
}

.platform-logo {
    font-size: 22px;
    font-weight: 700;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    transition: opacity 0.2s;
}

.platform-logo:hover {
    opacity: 0.9;
    text-decoration: none;
    color: white;
}

.platform-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: center;
    max-width: 600px;
}

.platform-nav a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    white-space: nowrap;
    position: relative;
    border: 1px solid transparent;
}

.platform-nav a:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
    text-decoration: none;
}

.platform-nav a.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
    font-weight: 600;
}

.platform-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 20px;
    right: 20px;
    height: 2px;
    background: white;
    border-radius: 2px;
}

.platform-user {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.platform-user span {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    font-size: 14px;
    white-space: nowrap;
}

.platform-user a {
    color: white;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.15);
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    white-space: nowrap;
}

.platform-user a:hover {
    background-color: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
    text-decoration: none;
    color: white;
}

/* Card Components */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px var(--platform-shadow);
    margin-bottom: 24px;
    overflow: hidden;
}

.card-header {
    background: var(--platform-primary);
    color: white;
    padding: 16px 24px;
    border-bottom: 1px solid var(--platform-border);
}

.card-header h1,
.card-header h2,
.card-header h3 {
    margin: 0;
    font-weight: 600;
}

.card-body {
    padding: 24px;
}

.card-footer {
    background: var(--platform-light);
    padding: 16px 24px;
    border-top: 1px solid var(--platform-border);
    text-align: right;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 1.5;
}

.btn-primary {
    background: var(--platform-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--platform-primary-dark);
}

.btn-secondary {
    background: var(--platform-secondary);
    color: white;
}

.btn-secondary:hover {
    background: #475569;
}

.btn-success {
    background: var(--platform-success);
    color: white;
}

.btn-success:hover {
    background: #047857;
}

.btn-warning {
    background: var(--platform-warning);
    color: white;
}

.btn-warning:hover {
    background: #b45309;
}

.btn-danger {
    background: var(--platform-danger);
    color: white;
}

.btn-danger:hover {
    background: #b91c1c;
}

.btn-info {
    background: var(--platform-info);
    color: white;
}

.btn-info:hover {
    background: #0e7490;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--platform-dark);
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    border: 2px solid var(--platform-border);
    border-radius: 6px;
    transition: border-color 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--platform-primary);
}

.form-control.is-invalid {
    border-color: var(--platform-danger);
}

.form-control.is-valid {
    border-color: var(--platform-success);
}

.form-text {
    font-size: 12px;
    color: var(--platform-gray);
    margin-top: 4px;
}

.invalid-feedback {
    color: var(--platform-danger);
    font-size: 12px;
    margin-top: 4px;
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 0;
}

.table th,
.table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--platform-border);
}

.table th {
    background: var(--platform-light);
    font-weight: 600;
    color: var(--platform-dark);
}

.table tbody tr:hover {
    background: #f1f5f9;
}

.table-striped tbody tr:nth-of-type(odd) {
    background: var(--platform-light);
}

.table-bordered {
    border: 1px solid var(--platform-border);
}

.table-bordered th,
.table-bordered td {
    border: 1px solid var(--platform-border);
}

.table-sm th,
.table-sm td {
    padding: 8px;
}

/* Alerts */
.alert {
    padding: 16px;
    margin-bottom: 20px;
    border: 1px solid transparent;
    border-radius: 6px;
    position: relative;
}

.alert-primary {
    background: #dbeafe;
    color: #1e40af;
    border-color: #93c5fd;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border-color: #6ee7b7;
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
    border-color: #fcd34d;
}

.alert-danger {
    background: #fecaca;
    color: #991b1b;
    border-color: #f87171;
}

.alert-info {
    background: #cffafe;
    color: #0c4a6e;
    border-color: #67e8f9;
}

.alert-dismissible {
    padding-right: 50px;
}

.alert .btn-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
}

/* Dashboard Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 2px 4px var(--platform-shadow);
    text-align: center;
    border-left: 4px solid var(--platform-primary);
}

.stat-card.success {
    border-left-color: var(--platform-success);
}

.stat-card.warning {
    border-left-color: var(--platform-warning);
}

.stat-card.danger {
    border-left-color: var(--platform-danger);
}

.stat-card.info {
    border-left-color: var(--platform-info);
}

.stat-number {
    font-size: 36px;
    font-weight: bold;
    color: var(--platform-primary);
    margin-bottom: 8px;
    display: block;
}

.stat-label {
    font-size: 14px;
    color: var(--platform-gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Status Badges */
.status-badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    border-radius: 20px;
    letter-spacing: 0.5px;
}

.status-active {
    background: #d1fae5;
    color: #065f46;
}

.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.status-suspended {
    background: #fee2e2;
    color: #991b1b;
}

.status-deleted {
    background: #f3f4f6;
    color: #6b7280;
}

.status-archived {
    background: #e0e7ff;
    color: #3730a3;
}

/* Sidebar Styles */
.sidebar {
    min-height: 100vh;
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
}

.sidebar .nav-link i {
    margin-right: 8px;
}

.main-content {
    background-color: #f8f9fa;
    min-height: 100vh;
}

.stats-card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: all 0.3s;
}

.stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Modern Modal Styles */
.modern-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1060;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modern-modal-overlay.show {
    opacity: 1;
    visibility: visible;
}

.modern-modal {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    transform: scale(0.9) translateY(-20px);
    transition: transform 0.3s ease;
}

.modern-modal-overlay.show .modern-modal {
    transform: scale(1) translateY(0);
}

.modern-modal-header {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.modern-modal-icon {
    width: 48px;
    height: 48px;
    background: #fee2e2;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-right: 12px;
}

.modern-modal-title {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.modern-modal-body {
    margin-bottom: 24px;
}

.modern-modal-message {
    color: #6b7280;
    line-height: 1.6;
    margin: 0;
}

.modern-modal-footer {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.modern-modal-btn {
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modern-modal-btn-cancel {
    background: #f3f4f6;
    color: #374151;
}

.modern-modal-btn-cancel:hover {
    background: #e5e7eb;
    color: #374151;
}

.modern-modal-btn-danger {
    background: #dc2626;
    color: white;
}

.modern-modal-btn-danger:hover {
    background: #b91c1c;
    color: white;
}

/* Fixed Position Toast Notifications */
.toast-notifications {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 400px;
    width: 100%;
}

.toast-notification {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    margin-bottom: 12px;
    padding: 18px 24px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.18);
    border-left: 5px solid;
    transform: translateX(120%);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    min-width: 340px;
}

.toast-notification.show {
    transform: translateX(0);
    opacity: 1;
}

.toast-notification.hiding {
    transform: translateX(100%);
    opacity: 0;
}

.toast-notification-danger {
    border-left-color: #dc3545;
    background: #ffffff;
}

.toast-notification-success {
    border-left-color: #198754;
    background: #ffffff;
}

.toast-notification-warning {
    border-left-color: #ffc107;
    background: #ffffff;
}

.toast-notification-info {
    border-left-color: #0dcaf0;
    background: #ffffff;
}

.toast-notification-content {
    display: flex;
    align-items: flex-start;
}

.toast-notification-icon {
    font-size: 20px;
    margin-right: 12px;
    margin-top: 2px;
    flex-shrink: 0;
}

.toast-notification-danger .toast-notification-icon {
    color: #dc3545;
}

.toast-notification-success .toast-notification-icon {
    color: #198754;
}

.toast-notification-warning .toast-notification-icon {
    color: #ffc107;
}

.toast-notification-info .toast-notification-icon {
    color: #0dcaf0;
}

.toast-notification-body {
    flex: 1;
}

.toast-notification-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
    line-height: 1.2;
    color: #212529;
}

.toast-notification-message {
    font-size: 13px;
    line-height: 1.4;
    color: #495057;
}

.toast-notification-close {
    background: none;
    border: none;
    font-size: 18px;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    margin-left: 12px;
    flex-shrink: 0;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.toast-notification-close:hover {
    opacity: 1;
}

.toast-notification:hover {
    transform: translateX(-4px);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
}

/* DataTable Styling */
.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: 6px !important;
    margin: 0 2px !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%) !important;
    border: 1px solid #dc3545 !important;
    color: white !important;
}

.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
    border-radius: 6px;
    border: 1px solid #dee2e6;
    padding: 0.375rem 0.75rem;
}

.dataTables_wrapper .dataTables_filter input:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

table.dataTable thead th {
    background: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
}

table.dataTable tbody tr:hover {
    background-color: rgba(220, 53, 69, 0.05) !important;
}

/* Platform Auth Styles */
.platform-badge {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Auth Page Overrides */
body.auth-page {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
}

.auth-header {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
    color: white;
    padding: 2rem;
    text-align: center;
}

.auth-body {
    padding: 2rem;
}

.auth-card .form-control:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.auth-card .btn-primary {
    background: linear-gradient(135deg, #dc3545 0%, #6f42c1 100%);
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
}

.auth-card .btn-primary:hover {
    background: linear-gradient(135deg, #c82333 0%, #5a359a 100%);
    transform: translateY(-1px);
}

.auth-card .btn-outline-secondary {
    border-color: #6c757d;
    color: #6c757d;
}

.auth-card .btn-outline-secondary:hover {
    background-color: #6c757d;
    border-color: #6c757d;
}

.auth-card .text-decoration-none {
    color: #dc3545 !important;
}

.auth-card .text-decoration-none:hover {
    color: #6f42c1 !important;
}

.footer-text {
    text-align: center;
    margin-top: 2rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

/* Auth Footer Overrides */
body.auth-page footer {
    background-color: transparent !important;
    border-top: none !important;
}

body.auth-page footer .text-muted {
    color: rgba(255, 255, 255, 0.8) !important;
}

body.auth-page footer a.text-muted {
    color: rgba(255, 255, 255, 0.8) !important;
}

body.auth-page footer a.text-muted:hover {
    color: white !important;
    text-decoration: underline !important;
}

/* Platform Modals CSS */
.modal-backdrop {
    z-index: 1040;
}

.modal {
    z-index: 1050;
}

.toast {
    z-index: 11050;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

.alert {
    margin-bottom: 0;
}

/* Toast Animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Toast container responsive */
#toast-container {
    max-height: 100vh;
    overflow-y: auto;
}

#toast-container .toast {
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 80px rgba(0, 0, 0, 0.2);
}

#toast-container .toast.bg-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
    border-left: 5px solid #155724;
}

#toast-container .toast.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
    border-left: 5px solid #721c24;
}

#toast-container .toast.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%) !important;
    border-left: 5px solid #856404;
}

#toast-container .toast.bg-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%) !important;
    border-left: 5px solid #0c5460;
}

#toast-container .toast .toast-body {
    padding: 12px 16px;
    letter-spacing: 0.3px;
}

/* Mobile responsive for toast notifications */
@media (max-width: 768px) {
    .toast-notifications {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    #toast-container {
        left: 10px;
        right: 10px;
        padding: 0.5rem !important;
    }
    
    #toast-container .toast {
        min-width: auto !important;
        width: 100%;
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .platform-header .container {
        gap: 20px;
        padding: 12px 20px;
    }

    .platform-nav {
        gap: 2px;
        max-width: 500px;
    }

    .platform-nav a {
        padding: 10px 16px;
        font-size: 13px;
    }

    .platform-user span {
        font-size: 13px;
    }

    .platform-user a {
        padding: 8px 14px;
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .platform-header .container {
        flex-direction: column;
        gap: 16px;
        padding: 16px 20px;
        min-height: auto;
    }

    .platform-logo {
        font-size: 20px;
        align-self: center;
    }

    .platform-nav {
        order: 3;
        justify-content: center;
        flex-wrap: wrap;
        width: 100%;
        max-width: none;
        gap: 8px;
    }

    .platform-nav a {
        padding: 8px 16px;
        font-size: 13px;
        flex: 0 0 auto;
    }

    .platform-user {
        order: 2;
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .platform-user span {
        font-size: 13px;
    }

    .platform-user a {
        padding: 10px 20px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .platform-header .container {
        padding: 12px 16px;
    }

    .platform-logo {
        font-size: 18px;
    }

    .platform-nav {
        gap: 4px;
    }

    .platform-nav a {
        padding: 8px 12px;
        font-size: 12px;
    }

    .platform-user a {
        padding: 8px 16px;
        font-size: 13px;
    }
}

/* Login Page Styles */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--platform-primary) 0%, var(--platform-primary-dark) 100%);
}

.login-card {
    width: 100%;
    max-width: 400px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.login-header {
    background: var(--platform-primary);
    color: white;
    padding: 32px 24px;
    text-align: center;
}

.login-header h1 {
    margin: 0 0 8px 0;
    font-size: 28px;
    font-weight: 700;
}

.login-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 14px;
}

.login-body {
    padding: 32px 24px;
}

.login-footer {
    padding: 24px;
    text-align: center;
    border-top: 1px solid var(--platform-border);
    background: var(--platform-light);
}

.login-footer a {
    color: var(--platform-primary);
    text-decoration: none;
    font-size: 14px;
}

.login-footer a:hover {
    text-decoration: underline;
}

/* System Status Indicators */
.system-status {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
}

.status-item {
    flex: 1;
    padding: 16px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px var(--platform-shadow);
    text-align: center;
    border-left: 4px solid var(--platform-gray);
}

.status-item.success {
    border-left-color: var(--platform-success);
}

.status-item.warning {
    border-left-color: var(--platform-warning);
}

.status-item.error {
    border-left-color: var(--platform-danger);
}

.status-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.status-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--platform-dark);
}

.status-description {
    font-size: 12px;
    color: var(--platform-gray);
    margin-top: 4px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-top: 24px;
}

.pagination a,
.pagination span {
    padding: 8px 12px;
    border: 1px solid var(--platform-border);
    color: var(--platform-primary);
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s;
}

.pagination a:hover {
    background: var(--platform-primary);
    color: white;
}

.pagination .current {
    background: var(--platform-primary);
    color: white;
    border-color: var(--platform-primary);
}

/* Action Buttons Group */
.action-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.action-buttons .btn {
    flex: none;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--platform-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-left {
    text-align: left;
}

.text-muted {
    color: var(--platform-gray);
}

.text-primary {
    color: var(--platform-primary);
}

.text-success {
    color: var(--platform-success);
}

.text-warning {
    color: var(--platform-warning);
}

.text-danger {
    color: var(--platform-danger);
}

.mb-0 {
    margin-bottom: 0;
}

.mb-1 {
    margin-bottom: 8px;
}

.mb-2 {
    margin-bottom: 16px;
}

.mb-3 {
    margin-bottom: 24px;
}

.mb-4 {
    margin-bottom: 32px;
}

.mt-0 {
    margin-top: 0;
}

.mt-1 {
    margin-top: 8px;
}

.mt-2 {
    margin-top: 16px;
}

.mt-3 {
    margin-top: 24px;
}

.mt-4 {
    margin-top: 32px;
}

.d-none {
    display: none;
}

.d-block {
    display: block;
}

.d-inline {
    display: inline;
}

.d-inline-block {
    display: inline-block;
}

.d-flex {
    display: flex;
}

.justify-content-between {
    justify-content: space-between;
}

.align-items-center {
    align-items: center;
}

.w-100 {
    width: 100%;
}

.w-50 {
    width: 50%;
}

.w-25 {
    width: 25%;
}

.float-right {
    float: right;
}

.float-left {
    float: left;
}

.clearfix {
    clear: both;
}

/* Sortable.js Drag & Drop Styles */
.sortable-ghost {
    opacity: 0.4;
    background-color: #f8f9fa !important;
}

.sortable-chosen {
    background-color: #e3f2fd !important;
}

.sortable-drag {
    opacity: 0.8;
    transform: rotate(5deg);
}

/* Drag Handle Styles */
.drag-handle {
    cursor: grab !important;
    transition: all 0.2s ease;
}

.drag-handle:hover {
    background-color: #e9ecef !important;
    transform: scale(1.1);
}

.drag-handle:active {
    cursor: grabbing !important;
    transform: scale(0.95);
}

/* Model table specific styles */
.model-row:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.model-row.sortable-chosen {
    background-color: rgba(33, 136, 255, 0.1) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.model-row .drag-handle .bi-grip-vertical {
    opacity: 0.6;
}

.model-row:hover .drag-handle .bi-grip-vertical {
    opacity: 1;
}