/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

/* Notification Toast */
#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    background: white;
    border-left: 4px solid;
    padding: 12px 20px;
    border-radius: 4px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    font-size: 14px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    pointer-events: auto;
    min-width: 300px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast-success {
    border-color: #10B981;
    color: #064E3B;
}

.toast-error {
    border-color: #EF4444;
    color: #7F1D1D;
}

.toast-info {
    border-color: #3B82F6;
    color: #1E3A8A;
}

/* Print Styles */
@media print {
    @page {
        margin: 1cm;
        size: A4;
    }

    body {
        background: white;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    /* Hide UI elements */
    aside,
    nav,
    button,
    .hidden-print,
    #modal-simulation,
    #toast-container,
    header {
        display: none !important;
    }

    /* Layout adjustments */
    #app-container {
        padding: 0 !important;
        margin: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
        box-shadow: none !important;
    }

    /* Reveal content if hidden by screen logic, OR rely on current view? */
    /* Let's rely on current view but ensure it uses full width */
    main {
        margin-left: 0 !important;
        width: 100% !important;
        overflow: visible !important;
    }

    /* Table specific optimizations */
    table {
        width: 100%;
        border-collapse: collapse;
        page-break-inside: auto;
    }

    tr {
        page-break-inside: avoid;
        page-break-after: auto;
    }

    thead {
        display: table-header-group;
    }

    tfoot {
        display: table-footer-group;
    }

    th,
    td {
        border: 1px solid #e5e7eb;
        padding: 6px 8px !important;
        font-size: 9pt !important;
        color: black !important;
    }

    th {
        background-color: #f9fafb !important;
        font-weight: bold;
    }

    /* Card styling for print */
    .bg-gradient-to-br,
    .bg-gradient-to-b {
        background: none !important;
        border: 1px solid #ddd !important;
    }

    .shadow-sm,
    .shadow-md,
    .shadow-xl {
        box-shadow: none !important;
    }

    .text-white {
        color: black !important;
    }

    /* Header for print */
    .print-header {
        display: block !important;
        margin-bottom: 20px;
        border-bottom: 2px solid #e2001a;
        padding-bottom: 10px;
    }
}

.print-header {
    display: none;
}