/* ==========================================================================
   Utilities & shared animations
   ========================================================================== */

/* Theme toggle button — shared by the navbar and the login page */
.theme-toggle-btn {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--t-radius-pill);
    border: 1px solid var(--t-border);
    background: var(--t-bg);
    color: var(--t-muted);
    cursor: pointer;
    transition: all var(--t-transition-fast);
}
.theme-toggle-btn:hover {
    color: var(--t-primary);
    border-color: var(--t-primary);
    transform: rotate(-8deg);
}
.theme-toggle-btn i { font-size: 15px; }
.theme-toggle-btn .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle-btn .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle-btn .icon-moon { display: inline-block; }
.t-fade-in { animation: t-fade-in 260ms ease both; }
.t-scale-in { animation: t-scale-in 200ms ease both; }

.card, .btn, .badge, .alert, .modal-content, .info-box, .stat-card {
    animation: t-fade-in 240ms ease both;
}

/* Dropdown open animation already covered by Bootstrap's display toggle + our .dropdown-menu keyframe */

/* Nice focus ring utility reused where needed */
.t-ring-primary:focus { box-shadow: 0 0 0 3px rgba(var(--t-primary-rgb), 0.2); }

/* Section heading style, opt-in for any custom grouped content */
.t-section-title {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--t-muted);
    margin: 1rem 0 0.4rem 0.25rem;
}

/* Reduce motion for users who ask for it */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
}
