/* =============================================================================
   TechWin Support Portal - Site styles
   ============================================================================= */

/* Brand colour tokens */
:root {
    --tw-brand: #212529;
    --tw-brand-hover: #343a40;
    --tw-brand-subtle: #e9ecef;
    --tw-brand-rgb: 33, 37, 41;
    --bs-primary: var(--tw-brand);
    --bs-primary-rgb: var(--tw-brand-rgb);
    --bs-link-color: var(--tw-brand);
    --bs-link-hover-color: var(--tw-brand-hover);
}

/* Solid primary button */
.btn-primary {
    --bs-btn-bg: var(--tw-brand);
    --bs-btn-border-color: var(--tw-brand);
    --bs-btn-hover-bg: var(--tw-brand-hover);
    --bs-btn-hover-border-color: var(--tw-brand-hover);
    --bs-btn-active-bg: #1a1e21;
    --bs-btn-active-border-color: #1a1e21;
    --bs-btn-disabled-bg: var(--tw-brand);
    --bs-btn-disabled-border-color: var(--tw-brand);
    --bs-btn-color: #fff;
    --bs-btn-hover-color: #fff;
    --bs-btn-active-color: #fff;
}

/* Outline primary button */
.btn-outline-primary {
    --bs-btn-color: var(--tw-brand);
    --bs-btn-border-color: var(--tw-brand);
    --bs-btn-hover-bg: var(--tw-brand);
    --bs-btn-hover-border-color: var(--tw-brand);
    --bs-btn-hover-color: #fff;
    --bs-btn-active-bg: var(--tw-brand);
    --bs-btn-active-color: #fff;
}

/* Outline secondary button */
.btn-outline-secondary {
    --bs-btn-color: #495057;
    --bs-btn-border-color: #adb5bd;
    --bs-btn-hover-bg: #f8f9fa;
    --bs-btn-hover-color: #212529;
}

/* Colour utilities */
.text-primary {
    color: var(--tw-brand) !important;
}

.border-primary {
    border-color: var(--tw-brand) !important;
}

.bg-primary {
    background-color: var(--tw-brand) !important;
}

/* Links */
a {
    color: var(--tw-brand);
}

    a:hover {
        color: var(--tw-brand-hover);
    }

/* Page chrome */
body {
    background: #f4f6f9;
    font-size: 0.92rem;
}

.navbar-brand img {
    height: 45px;
}

/* Sidebar */
.sidebar {
    min-height: calc(100vh - 72px);
    background: #fff;
    border-right: 1px solid #dee2e6;
}

    .sidebar .nav-link {
        color: #495057;
        border-radius: 6px;
        padding: 0.5rem 0.85rem;
    }

        .sidebar .nav-link:hover,
        .sidebar .nav-link.active {
            background: var(--tw-brand-subtle);
            color: var(--tw-brand);
        }

        .sidebar .nav-link i {
            width: 18px;
        }

/* Navbar user dropdown */
.navbar .dropdown-menu {
    min-width: 180px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
}

.navbar .dropdown-item {
    font-size: 0.875rem;
    padding: 0.45rem 1rem;
}

    .navbar .dropdown-item:active,
    .navbar .dropdown-item:focus {
        background-color: var(--tw-brand-subtle);
        color: var(--tw-brand);
    }

/* Status colours */
.status-open {
    color: #0d6efd;
}

.status-in-progress {
    color: #ffc107;
}

.status-waiting {
    color: #0dcaf0;
}

.status-resolved {
    color: #198754;
}

.status-closed {
    color: #6c757d;
}

/* Priority colours */
.priority-critical {
    color: #dc3545;
    font-weight: 600;
}

.priority-high {
    color: #fd7e14;
}

.priority-medium {
    color: #6c757d;
}

.priority-low {
    color: #adb5bd;
}

/* Card heading icon accents */
.card-header h6 i,
.card-header h5 i,
.card-header h4 i {
    color: var(--tw-brand);
}

/* Focus ring */
.form-control:focus,
.form-select:focus {
    border-color: var(--tw-brand);
    box-shadow: 0 0 0 0.2rem rgba(var(--tw-brand-rgb), 0.2);
}
