/* SupportHub - Custom Application Styles
 * Plain CSS - no Tailwind directives
 * Loaded after Bootstrap 5 and Bootstrap Icons
 */

/* ===== CSS Custom Properties ===== */
:root {
    --color-primary: #4f46e5;
    --color-primary-content: #ffffff;

    --sidebar-width: 240px;
    --sidebar-bg: #1e293b;
    --sidebar-text: #94a3b8;
    --sidebar-text-active: #ffffff;
    --sidebar-hover-bg: rgba(255, 255, 255, 0.06);
    --sidebar-active-bg: rgba(255, 255, 255, 0.1);
    --sidebar-divider: rgba(255, 255, 255, 0.06);
}

/* ===== Base Styles ===== */
body {
    background-color: #f5f5f5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: rgba(79, 70, 229, 0.18);
}

/* Slim custom scrollbars */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(128, 128, 128, 0.15) transparent;
}
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(128, 128, 128, 0.15);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(128, 128, 128, 0.25);
}

/* Global transitions on interactive elements */
a,
button,
input,
select,
textarea,
[role="button"] {
    transition: all 0.15s ease;
}

/* Muted placeholder text */
::placeholder,
.form-control::placeholder {
    color: #d0d0d0 !important;
    opacity: 1 !important;
}

/* Enhanced focus rings */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

/* ===== App Sidebar Navigation ===== */
.app-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    display: flex;
    flex-direction: column;
    z-index: 40;
    overflow-y: auto;
    overflow-x: hidden;
}

.app-content {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    height: 100vh;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.app-content > main {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.app-content > main > div {
    flex: 1;
    min-height: 0;
}

body:has(.modal.show) {
    overflow: hidden;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    margin: 1px 0.5rem;
    border-radius: 0.5rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--sidebar-text);
    transition:
        background 0.15s ease,
        color 0.15s ease;
    text-decoration: none;
}

.sidebar-nav-link:hover {
    background: var(--sidebar-hover-bg);
    color: var(--sidebar-text-active);
    text-decoration: none;
}

.sidebar-nav-link.active {
    background: var(--sidebar-active-bg);
    color: var(--sidebar-text-active);
}

.sidebar-section-label {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(148, 163, 184, 0.5);
    padding: 1.25rem 1.5rem 0.5rem;
}

.sidebar-divider {
    height: 1px;
    background: var(--sidebar-divider);
    margin: 0.5rem 1rem;
}

/* ===== Avatar Initials ===== */
.avatar-initial {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    font-weight: 600;
    text-transform: uppercase;
    flex-shrink: 0;
}
.avatar-initial-sm {
    width: 1.5rem;
    height: 1.5rem;
    font-size: 0.625rem;
}
.avatar-initial-md {
    width: 2rem;
    height: 2rem;
    font-size: 0.75rem;
}
.avatar-initial-lg {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 0.875rem;
}

/* ===== Status Dots ===== */
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    flex-shrink: 0;
}
.status-dot-open {
    background: #22c55e;
}
.status-dot-waiting {
    background: #eab308;
}
.status-dot-closed {
    background: #737373;
}
.status-dot-pulse {
    animation: dot-pulse 2s ease-in-out infinite;
}
@keyframes dot-pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.4;
    }
}

/* ===== Empty State ===== */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: rgba(128, 128, 128, 0.35);
}

/* ===== Utility Classes ===== */
.cursor-pointer {
    cursor: pointer;
}
