/* =================================
   Design tokens now live in tokens.css (single source of truth),
   loaded before this file on every page.
   ================================= */

/* Reset et styles de base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--light-color);
    color: var(--color-text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

h1 {
    font-family: 'DM Serif Display', Georgia, serif;
    font-weight: 400;
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.header-actions h2,
.page-header h1,
.page-header h2,
.stats-header h2,
.presences-header h2 {
    font-family: 'DM Serif Display', Georgia, serif;
    font-weight: 400;
    font-size: 1.75rem;
    color: var(--dark-color);
    margin-bottom: 0;
}

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


/* =================================
   Date Filter Component
   ================================= */
.date-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.date-filter-month {
    min-width: 150px;
    max-width: 180px;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: var(--light-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition);
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2.5rem;
}

.date-filter-month:hover {
    background-color: var(--border-color);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236c757d' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}

.date-filter-month:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(var(--primary-rgb), 0.2);
}

.date-filter-toggles {
    display: flex;
    gap: 0.25rem;
}

.date-filter-btn {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: var(--light-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition);
}

.date-filter-btn:hover {
    background: var(--border-color);
}

.date-filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.date-filter-custom-wrapper {
    position: relative;
    display: inline-block;
}

.date-filter-custom-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    padding: 0.75rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 100;
    white-space: nowrap;
}

.date-filter-custom-dropdown input[type="date"] {
    width: 140px;
    padding: 0.4rem 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
}

.date-filter-custom-dropdown span {
    color: var(--secondary-color);
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .date-filter {
        flex-direction: column;
        align-items: stretch;
    }

    .date-filter-month {
        max-width: 100%;
    }

    .date-filter-toggles {
        flex-wrap: wrap;
    }

    .date-filter-custom-dropdown {
        right: auto;
        left: 0;
    }
}

/* =================================
   Messages
   ================================= */
.messages-container {
    max-width: 1200px;
    margin: 0.75rem auto;
    padding: 0 1rem;
}

.message {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-radius: var(--border-radius);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    animation: message-slide-in 0.3s ease;
}

.message-success {
    background-color: #eaf6ec;
    color: #1b6b30;
    border: 1px solid #cfe9d4;
}

.message-error {
    background-color: #fbeced;
    color: #a01521;
    border: 1px solid #f4ced1;
}

.message-warning {
    background-color: #fdf1e0;
    color: #8a5310;
    border: 1px solid #f7ddba;
}

.message-info {
    background-color: var(--status-info-bg);
    color: var(--status-info-fg);
    border: 1px solid var(--border-color);
}

.message-close {
    background: none;
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
    color: inherit;
    opacity: 0.6;
    padding: 0 0.25rem;
    line-height: 1;
}

.message-close:hover {
    opacity: 1;
}

@keyframes message-slide-in {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =================================
   Confirm Modal
   ================================= */
.confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.confirm-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
}

.confirm-modal-content {
    position: relative;
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    max-width: 400px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    animation: message-slide-in 0.2s ease;
}

.confirm-modal-content h3 {
    margin: 0 0 0.75rem 0;
    font-size: 1.1rem;
}

.confirm-modal-content p {
    margin: 0 0 1.5rem 0;
    color: var(--secondary-color);
    font-size: 0.95rem;
    line-height: 1.5;
}

.confirm-modal-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

/* =================================
   App Layout
   ================================= */
.app-layout {
    display: flex;
    min-height: 100vh;
}

.main-wrapper {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

/* =================================
   Sidebar
   ================================= */
.sidebar {
    width: 220px;
    flex-shrink: 0;
    background: white;
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 100;
}

.sidebar.animated {
    transition: width 0.2s ease;
}

.sidebar.collapsed,
html.sidebar-is-collapsed .sidebar {
    width: 60px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    min-height: 56px;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.95rem;
    min-width: 0;
    line-height: 1.25;
}

.sidebar-brand-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-brand-initials {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    flex-shrink: 0;
}

.sidebar-brand img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    flex-shrink: 0;
}

.sidebar.collapsed .sidebar-brand-text,
html.sidebar-is-collapsed .sidebar .sidebar-brand-text {
    display: none;
}

/* When collapsed, the brand (logo or initials) acts as expand button */
.sidebar.collapsed .sidebar-brand,
html.sidebar-is-collapsed .sidebar .sidebar-brand {
    cursor: pointer;
}

.sidebar.collapsed .sidebar-toggle,
html.sidebar-is-collapsed .sidebar .sidebar-toggle {
    display: none;
}

.sidebar.collapsed .sidebar-header,
html.sidebar-is-collapsed .sidebar .sidebar-header {
    justify-content: center;
}

.sidebar-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    color: var(--secondary-color);
    border-radius: var(--radius-sm);
    transition: all 0.2s;
    flex-shrink: 0;
}

.sidebar-toggle:hover {
    background: var(--light-color);
    color: var(--dark-color);
}

.sidebar.collapsed .sidebar-toggle svg {
    transform: rotate(180deg);
}

/* Tenant switcher (Sprint 4.2) */
.tenant-switcher {
    position: relative;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.tenant-switcher-current {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--dark-color);
    cursor: pointer;
    text-align: left;
}

.tenant-switcher-current:hover {
    background: var(--border-color);
}

.tenant-switcher-label {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tenant-switcher-menu {
    position: absolute;
    top: 100%;
    left: 0.75rem;
    right: 0.75rem;
    margin: 0.25rem 0 0;
    padding: 0.25rem 0;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    list-style: none;
    z-index: 50;
    max-height: 240px;
    overflow-y: auto;
}

.tenant-switcher-menu li a {
    display: block;
    padding: 0.5rem 0.75rem;
    color: var(--dark-color);
    text-decoration: none;
    font-size: 0.85rem;
}

.tenant-switcher-menu li a:hover {
    background: var(--light-color);
}

.sidebar.collapsed .tenant-switcher,
html.sidebar-is-collapsed .sidebar .tenant-switcher {
    display: none;
}

/* Sidebar Navigation */
.sidebar-nav {
    flex: 1;
    padding: 0.5rem 0;
    overflow-y: auto;
}

.nav-group {
    padding: 0.25rem 0;
}

.nav-group-label {
    display: block;
    padding: 0.5rem 1rem 0.25rem;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--secondary-color);
    white-space: nowrap;
    overflow: hidden;
}

.sidebar.collapsed .nav-group-label,
html.sidebar-is-collapsed .sidebar .nav-group-label {
    display: none;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 1rem;
    color: var(--secondary-color);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 0;
    transition: all 0.15s ease;
    white-space: nowrap;
    overflow: hidden;
    position: relative;
}

.nav-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.sidebar-avatar {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.sidebar-avatar-initials {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: white;
    font-size: 0.6rem;
    font-weight: 600;
}

.nav-item:hover {
    color: var(--primary-color);
    background-color: rgba(var(--primary-rgb), 0.06);
}

.nav-item.active {
    color: var(--primary-color);
    background-color: rgba(var(--primary-rgb), 0.1);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.25rem;
    bottom: 0.25rem;
    width: 3px;
    background: var(--primary-color);
    border-radius: 0 2px 2px 0;
}

.sidebar.collapsed .nav-label,
html.sidebar-is-collapsed .sidebar .nav-label {
    display: none;
}

.sidebar.collapsed .nav-item,
html.sidebar-is-collapsed .sidebar .nav-item {
    justify-content: center;
    padding: 0.5rem;
}

/* Sidebar Footer */
.sidebar-footer {
    padding: 0.5rem 0;
    border-top: 1px solid var(--border-color);
    margin-top: auto;
}

/* Sidebar Backdrop (mobile) */
.sidebar-backdrop {
    display: none;
}

/* =================================
   Topbar (mobile only)
   ================================= */
.topbar {
    display: none;
}

.topbar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.1rem;
}

.topbar-brand img {
    height: 28px;
}

.topbar-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--dark-color);
    border-radius: var(--radius-sm);
}

.topbar-menu-btn:hover {
    background: var(--light-color);
}

/* =================================
   Navbar (main domain fallback)
   ================================= */
.navbar {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--primary-color);
    text-decoration: none;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-menu a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius);
    transition: all 0.2s ease;
}

.user-menu a:hover {
    color: var(--primary-color);
    background-color: rgba(var(--primary-rgb), 0.08);
}

/* =================================
   Content Layout
   ================================= */
.content {
    flex: 1;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

/* =================================
   Mobile Responsive
   ================================= */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        transform: translateX(-100%);
        z-index: 1000;
        width: 260px;
        box-shadow: none;
    }

    .sidebar.mobile-open {
        transform: translateX(0);
        box-shadow: var(--shadow-lg);
    }

    .sidebar.collapsed {
        width: 260px;
    }

    .sidebar.collapsed .nav-label,
    .sidebar.collapsed .nav-group-label,
    .sidebar.collapsed .sidebar-brand-text {
        display: block;
    }

    .sidebar.collapsed .nav-item {
        justify-content: flex-start;
        padding: 0.45rem 1rem;
    }

    /* Touch target: comfortable rows in the mobile overlay menu. */
    .nav-item {
        min-height: 44px;
    }

    .sidebar-toggle {
        display: none;
    }

    .sidebar-backdrop {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.4);
        z-index: 999;
    }

    .sidebar.mobile-open ~ .sidebar-backdrop {
        display: block;
    }

    .topbar {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        padding: 0.75rem 1rem;
        background: white;
        border-bottom: 1px solid var(--border-color);
        position: sticky;
        top: 0;
        z-index: 100;
    }

    .content {
        padding: 1rem;
    }
}


/* =================================
   Breadcrumbs
   ================================= */
.breadcrumbs {
    font-size: 0.85rem;
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.breadcrumbs a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs .separator {
    margin: 0 0.4rem;
    color: #ccc;
}

/* Duration input group */
.duration-group {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: white;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.duration-group:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(var(--primary-rgb), 0.15);
}

.duration-group input {
    border: none;
    outline: none;
    text-align: center;
    width: 60px;
    padding: 0.5rem 0.25rem;
    font-size: 1.1rem;
    font-weight: 500;
    background: transparent;
    -moz-appearance: textfield;
}

.duration-group input::-webkit-outer-spin-button,
.duration-group input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.duration-group .duration-sep {
    padding: 0.5rem 0.5rem;
    color: var(--secondary-color);
    font-size: 0.85rem;
    font-weight: 500;
    background: var(--light-color);
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    user-select: none;
}

.duration-group .duration-unit {
    padding: 0.5rem 0.6rem;
    color: var(--secondary-color);
    font-size: 0.85rem;
    font-weight: 500;
    user-select: none;
}

/* =================================
   Footer
   ================================= */
.site-footer {
    margin-top: auto;
    padding: 1.5rem 1rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    font-size: 0.8rem;
    color: var(--secondary-color);
}

.footer-content a {
    color: var(--secondary-color);
    text-decoration: none;
}

.footer-content a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.app-version {
    margin-left: 0.5rem;
    opacity: 0.5;
    font-size: 0.75rem;
}

/* =================================
   Onboarding Wizard
   ================================= */

.onboarding-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.onboarding-modal {
    background: white;
    border-radius: 16px;
    max-width: 560px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.onboarding-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #999;
    cursor: pointer;
    line-height: 1;
}

.onboarding-close:hover { color: #333; }

.onboarding-progress {
    text-align: center;
    margin-bottom: 1.5rem;
}

.onboarding-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.onboarding-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-border-subtle);
    transition: all 0.3s;
}

.onboarding-dot.active {
    background: var(--primary-color);
    transform: scale(1.3);
}

.onboarding-dot.done {
    background: var(--primary-color);
    opacity: 0.5;
}

.onboarding-step h2 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.onboarding-desc {
    text-align: center;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.onboarding-form .form-group {
    margin-bottom: 1rem;
}

.onboarding-row {
    display: flex;
    gap: 0.75rem;
}

.onboarding-row .form-group { flex: 1; }

.onboarding-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
}


/* Choice cards (membership mode) */
.onboarding-choice-group {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.onboarding-choice {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid var(--color-border-subtle);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: border-color 0.2s;
}

.onboarding-choice:has(input:checked) {
    border-color: var(--primary-color);
    background: rgba(var(--primary-rgb), 0.04);
}

.onboarding-choice input { display: none; }

.onboarding-choice-content strong {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 0.2rem;
}

.onboarding-choice-content span {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

/* Category suggestions */
.onboarding-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.onboarding-tag {
    padding: 0.4rem 0.8rem;
    border: 1.5px solid var(--color-border-subtle);
    border-radius: var(--radius-pill);
    background: white;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.onboarding-tag:hover { border-color: var(--primary-color); }

.onboarding-tag.selected {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.onboarding-cat-item {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.6rem;
    background: var(--color-bg-subtle);
    border-radius: 6px;
    margin: 0.2rem;
    font-size: 0.85rem;
}

/* Toggle switch (scoped for onboarding — canonical version in settings.css) */
.onboarding-modal .toggle-switch { position: relative; display: inline-block; width: 44px; height: 24px; flex-shrink: 0; }
.onboarding-modal .toggle-switch input { opacity: 0; width: 0; height: 0; }
.onboarding-modal .toggle-slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #ccc; border-radius: 24px; transition: 0.2s; }
.onboarding-modal .toggle-slider:before { content: ""; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px; background-color: white; border-radius: 50%; transition: 0.2s; }
.onboarding-modal input:checked + .toggle-slider { background-color: var(--primary-color); }
.onboarding-modal input:checked + .toggle-slider:before { transform: translateX(20px); }

/* Module toggles */
.onboarding-module {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-bg-subtle);
    gap: 1rem;
}

.onboarding-module:last-child { border-bottom: none; }

.onboarding-module-desc {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    margin: 0.2rem 0 0;
}

/* Logo preview */
.onboarding-logo-preview {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 2px dashed var(--color-border-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
}

.onboarding-logo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.onboarding-logo-placeholder {
    font-size: 0.7rem;
    color: var(--color-text-faint);
    text-align: center;
}

/* Recap */
.onboarding-recap-items {
    text-align: center;
    padding: 1rem;
}

.onboarding-recap-item {
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

@media (max-width: 576px) {
    .onboarding-modal { padding: 1.25rem; }
    .onboarding-row { flex-direction: column; gap: 0; }
    .onboarding-choice-group { flex-direction: column; }
}

/* =================================
   Print Styles
   ================================= */
@media print {
    .navbar, .sidebar, .topbar, .user-menu,
    .btn, button, .bulk-actions, .filter-card, .breadcrumbs,
    .messages-container, #confirm-modal,
    .batch-panel, .filters-container, .pagination, .site-footer {
        display: none !important;
    }

    body {
        background: white;
        color: black;
        font-size: 12pt;
    }

    .content {
        padding: 0;
        margin: 0;
        max-width: 100%;
    }

    .container {
        max-width: 100%;
        padding: 0;
    }

    .card, .sidebar-card, .stat-card, .presences-header,
    .presences-list, .form-section {
        box-shadow: none;
        border: 1px solid #ddd;
        break-inside: avoid;
    }

    .data-table,
    table {
        border-collapse: collapse;
        width: 100%;
    }

    .data-table th,
    .data-table td,
    table th,
    table td {
        border: 1px solid #ccc;
        padding: 4px 8px;
    }

    a {
        color: black;
        text-decoration: none;
    }

    a[href]:after {
        content: none;
    }
}

/* =================================
   Toast Notifications
   ================================= */
.toast {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    z-index: 10002;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s, transform 0.3s;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.toast-visible { opacity: 1; transform: translateY(0); }
.toast-success { background: var(--status-success-bg); color: var(--status-success-fg); }
.toast-error { background: var(--status-danger-bg); color: var(--status-danger-fg); }
.toast-info { background: var(--status-info-bg); color: var(--status-info-fg); }

/* =================================
   Demo Banner
   ================================= */
.demo-banner {
    background: #fef3c7;
    color: #92400e;
    text-align: center;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    font-weight: 500;
    z-index: 10001;
    position: relative;
}
.demo-banner a {
    color: #92400e;
    font-weight: 700;
    margin-left: 0.5rem;
}

/* =================================
   Maintenance Banner
   ================================= */
.maintenance-banner {
    background: #fef3c7;
    color: #92400e;
    text-align: center;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    font-weight: 500;
    z-index: 10001;
    position: relative;
}
