/* TrackSyst SMSI — feuille de style principale */

:root {
    --ts-navbar-height: 60px;
    --ts-sidebar-width: 250px;
    --ts-primary: #0d6efd;

    /* Variables branding réutilisables */
    --ts-brand-primary: #0d6efd;
    --ts-brand-primary-dark: #0a58ca;
    --ts-brand-text-on-primary: #ffffff;
    --ts-brand-bg-soft: #f8f9fb;
    --ts-brand-radius: 0.5rem;
}

/* === Pages publiques (auth, password, errors) === */
.ts-page-bg-soft {
    background-color: var(--ts-brand-bg-soft);
}

/* Brand header variant "large" — pages auth */
.ts-brand-header-large {
    text-align: center;
    margin-bottom: 1.5rem;
}
.ts-brand-header-large .ts-brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background-color: var(--ts-brand-primary);
    color: var(--ts-brand-text-on-primary);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.25);
}
.ts-brand-header-large .ts-brand-icon i {
    font-size: 2rem;
    line-height: 1;
}
.ts-brand-header-large h1 {
    margin-top: 0.75rem;
    margin-bottom: 0.25rem;
    font-size: 1.5rem;
    font-weight: 600;
    color: #212529;
}
.ts-brand-header-large .ts-brand-tagline {
    margin: 0;
    font-size: 0.875rem;
    color: #6c757d;
}

body {
    padding-top: var(--ts-navbar-height);
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

#app-wrapper {
    flex: 1 0 auto;
    min-height: calc(100vh - var(--ts-navbar-height) - 50px);
}

#app-navbar {
    height: var(--ts-navbar-height);
    z-index: 1030;
}

#app-sidebar {
    width: var(--ts-sidebar-width);
    min-height: calc(100vh - var(--ts-navbar-height));
    position: sticky;
    top: var(--ts-navbar-height);
    align-self: flex-start;
    flex-shrink: 0;
}

#app-sidebar .nav-link {
    color: #495057;
    border-left: 3px solid transparent;
    border-radius: 0;
    padding: 0.6rem 1rem;
    transition: background-color 0.15s, border-color 0.15s;
}

#app-sidebar .nav-link i {
    width: 1.25em;
    margin-right: 0.5rem;
}

#app-sidebar .nav-link:hover {
    background-color: #f1f3f5;
}

#app-sidebar .nav-link.active {
    color: var(--ts-primary);
    background-color: #e7f1ff;
    border-left-color: var(--ts-primary);
    font-weight: 600;
}

#app-main {
    max-width: 1140px;
    width: 100%;
}

@media (max-width: 767.98px) {
    #app-sidebar {
        display: none;
    }
    #app-sidebar.is-open {
        display: block;
        position: fixed;
        top: var(--ts-navbar-height);
        left: 0;
        height: calc(100vh - var(--ts-navbar-height));
        z-index: 1020;
        box-shadow: 2px 0 8px rgba(0, 0, 0, 0.15);
    }
}
