/* Reset e configurações básicas */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* Tela de Login */
.login-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 2rem;
}

.login-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    animation: loginSlideIn 0.5s ease;
}

@keyframes loginSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header h1 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

.login-header p {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.login-form {
    margin-bottom: 1.5rem;
}

.login-form .form-group {
    margin-bottom: 1.5rem;
}

.login-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #2c3e50;
}

.login-form input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.login-form input:focus {
    outline: none;
    border-color: #667eea;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

.login-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.login-footer p {
    font-size: 0.8rem;
    color: #7f8c8d;
    margin: 0;
}

.login-footer strong {
    color: #2c3e50;
}

/* Sistema Principal */
.main-system {
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: white;
}

.user-info span {
    font-weight: 600;
}

.header h1 {
    font-size: 1.8rem;
    font-weight: 600;
}

.header h1 i {
    margin-right: 10px;
}

.nav {
    display: flex;
    gap: 10px;
}

.nav-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.nav-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

.nav-btn.active {
    background: rgba(255,255,255,0.3);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.nav-btn i {
    margin-right: 8px;
}

/* Main Content */
.main {
    padding: 2rem 0;
    min-height: calc(100vh - 80px);
}

.section {
    display: none;
}

.section.active {
    display: block;
}

.section h2 {
    margin-bottom: 2rem;
    color: #2c3e50;
    font-size: 2rem;
    font-weight: 600;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

/* Dashboard */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-right: 1rem;
}

.stat-content h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.stat-content p {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.dashboard-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

/* Sales Stats Grid */
.sales-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.sales-stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    transition: transform 0.3s ease;
    border-left: 5px solid;
}

.sales-stat-card:hover {
    transform: translateY(-5px);
}

.sales-stat-card:nth-child(2) {
    border-left-color: #28a745;
}

.sales-stat-card:nth-child(3) {
    border-left-color: #007bff;
}

.sales-stat-card:nth-child(4) {
    border-left-color: #6f42c1;
}

.sales-stat-card.weekly-goal {
    border-left-color: #fd7e14;
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
}

.sales-stat-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-right: 1rem;
}

.sales-stat-card:nth-child(2) .sales-stat-icon {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.sales-stat-card:nth-child(3) .sales-stat-icon {
    background: linear-gradient(135deg, #007bff 0%, #6610f2 100%);
}

.sales-stat-card:nth-child(4) .sales-stat-icon {
    background: linear-gradient(135deg, #6f42c1 0%, #e83e8c 100%);
}

.weekly-goal .sales-stat-icon {
    background: linear-gradient(135deg, #fd7e14 0%, #ffc107 100%);
}

.sales-stat-content h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.sales-stat-content p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.sales-stat-content small {
    color: #6c757d;
    font-size: 0.8rem;
}

/* Goal Progress */
.goal-progress {
    margin-top: 0.5rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #28a745 0%, #20c997 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.btn-outline {
    background: transparent;
    border: 2px solid #007bff;
    color: #007bff;
    padding: 6px 12px;
    font-size: 0.8rem;
}

.btn-outline:hover {
    background: #007bff;
    color: white;
    transform: translateY(-2px);
}

.recent-products {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.recent-products h3 {
    margin-bottom: 1rem;
    color: #2c3e50;
}

/* Filtros */
.filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    align-items: center;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 250px;
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #7f8c8d;
}

.search-box input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
}

.filters select {
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.filters select:focus {
    outline: none;
    border-color: #667eea;
}

/* Botões */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
    transform: translateY(-2px);
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
    transform: translateY(-2px);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
}

/* Botões de ação compactos para tabela */
.outputs-table .btn-sm {
    padding: 4px 8px;
    font-size: 0.75rem;
    min-width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Tabelas */
.products-table,
.outputs-table,
.expenses-table {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.products-table table,
.outputs-table table,
.expenses-table table {
    width: 100%;
    border-collapse: collapse;
}

.products-table th,
.outputs-table th,
.expenses-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.products-table td,
.outputs-table td,
.expenses-table td {
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
}

.products-table tr:hover,
.outputs-table tr:hover,
.expenses-table tr:hover {
    background-color: #f8f9fa;
}

.products-table tr:last-child td,
.outputs-table tr:last-child td,
.expenses-table tr:last-child td {
    border-bottom: none;
}

.outputs-table .output-date {
    font-size: 0.9rem;
    color: #7f8c8d;
}

.outputs-table .output-value {
    font-weight: 600;
    color: #2c3e50;
}

/* Estilos específicos para tabela de despesas */
.expenses-table {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.expenses-table table {
    min-width: 1000px;
}

.expenses-table th,
.expenses-table td {
    padding: 0.75rem 0.5rem;
    font-size: 0.9rem;
}

.expenses-table th:nth-child(1), /* Data */
.expenses-table td:nth-child(1) {
    width: 10%;
    min-width: 100px;
}

.expenses-table th:nth-child(2), /* Categoria */
.expenses-table td:nth-child(2) {
    width: 12%;
    min-width: 120px;
}

.expenses-table th:nth-child(3), /* Descrição */
.expenses-table td:nth-child(3) {
    width: 25%;
    min-width: 200px;
}

.expenses-table th:nth-child(4), /* Valor */
.expenses-table td:nth-child(4) {
    width: 10%;
    min-width: 100px;
    text-align: right;
    font-weight: 600;
}

.expenses-table th:nth-child(5), /* Vencimento */
.expenses-table td:nth-child(5) {
    width: 10%;
    min-width: 100px;
}

.expenses-table th:nth-child(6), /* Pagamento */
.expenses-table td:nth-child(6) {
    width: 10%;
    min-width: 100px;
}

.expenses-table th:nth-child(7), /* Status */
.expenses-table td:nth-child(7) {
    width: 8%;
    min-width: 80px;
    text-align: center;
}

.expenses-table th:nth-child(8), /* Tipo */
.expenses-table td:nth-child(8) {
    width: 8%;
    min-width: 80px;
    text-align: center;
}

.expenses-table th:nth-child(9), /* Ações */
.expenses-table td:nth-child(9) {
    width: 7%;
    min-width: 80px;
    text-align: center;
}

/* Status badges para despesas */
.status-badge.overdue {
    background: #dc3545;
    color: white;
}

/* Badges de categoria para despesas */
.category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    color: white;
    white-space: nowrap;
}

.category-badge i {
    font-size: 0.7rem;
}

/* Badges de tipo de pagamento */
.payment-type-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 500;
    background: #e9ecef;
    color: #495057;
    white-space: nowrap;
}

/* Valores de despesas */
.expense-value {
    font-weight: 600;
    color: #dc3545;
}

/* Tabela de saídas compacta - sem scroll horizontal */
.outputs-table {
    overflow: visible;
    position: relative;
}

.outputs-table table {
    width: 100%;
    table-layout: fixed; /* Força larguras fixas para melhor controle */
}

.outputs-table th,
.outputs-table td {
    padding: 0.5rem 0.3rem; /* Padding reduzido */
    font-size: 0.85rem; /* Fonte menor */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Larguras específicas otimizadas para caber em uma tela */
.outputs-table th:nth-child(1), /* Data */
.outputs-table td:nth-child(1) {
    width: 8%;
    white-space: normal;
    font-size: 0.75rem;
}

.outputs-table th:nth-child(2), /* Produto */
.outputs-table td:nth-child(2) {
    width: 18%;
    white-space: normal;
    word-break: break-word;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(3), /* Quantidade */
.outputs-table td:nth-child(3) {
    width: 5%;
    text-align: center;
    font-weight: 600;
}

.outputs-table th:nth-child(4), /* Quantidade Paga */
.outputs-table td:nth-child(4) {
    width: 5%;
    text-align: center;
    font-weight: 600;
}

.outputs-table th:nth-child(5), /* Pessoa */
.outputs-table td:nth-child(5) {
    width: 15%;
    white-space: normal;
    word-break: break-word;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(6), /* Valor Unitário */
.outputs-table td:nth-child(6) {
    width: 8%;
    text-align: right;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(7), /* Valor Total */
.outputs-table td:nth-child(7) {
    width: 8%;
    text-align: right;
    font-weight: 600;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(8), /* Valor Pago */
.outputs-table td:nth-child(8) {
    width: 8%;
    text-align: right;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(9), /* Valor Pendente */
.outputs-table td:nth-child(9) {
    width: 8%;
    text-align: right;
    font-weight: 600;
    font-size: 0.8rem;
}

.outputs-table th:nth-child(10), /* Status */
.outputs-table td:nth-child(10) {
    width: 7%;
    text-align: center;
}

.outputs-table th:nth-child(11), /* Ações */
.outputs-table td:nth-child(11) {
    width: 10%;
    text-align: center;
}

/* Status badges compactos */
.status-badge {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
    min-width: 60px;
    text-align: center;
}

.status-badge.low {
    background: #ffeaa7;
    color: #d63031;
}

.status-badge.medium {
    background: #74b9ff;
    color: white;
}

.status-badge.high {
    background: #00b894;
    color: white;
}

.status-badge.pending {
    background: #ffc107;
    color: #212529;
}

.status-badge.partial {
    background: #fd7e14;
    color: white;
}

.status-badge.paid {
    background: #28a745;
    color: white;
}

/* Grid de categorias */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease;
    border-left: 5px solid;
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.category-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
}

.category-actions {
    display: flex;
    gap: 8px;
}

.category-description {
    color: #7f8c8d;
    margin-bottom: 1rem;
}

.category-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: #7f8c8d;
}

/* Relatórios */
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
}

.report-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.report-card h3 {
    margin-bottom: 1rem;
    color: #2c3e50;
}

.report-content {
    min-height: 200px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: white;
    margin: 2% auto;
    padding: 0;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.3s ease;
    position: relative;
    top: 50%;
    transform: translateY(-50%);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) translateY(-50%);
    }
    to {
        opacity: 1;
        transform: translateY(-50%);
    }
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.3rem;
}

.close {
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.close:hover {
    opacity: 0.7;
}

.modal form {
    padding: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #2c3e50;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
}

/* Toast */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 1001;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    border-left: 4px solid;
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    border-left-color: #28a745;
}

.toast.error {
    border-left-color: #dc3545;
}

.toast.warning {
    border-left-color: #ffc107;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast-icon {
    font-size: 1.2rem;
}

.toast.success .toast-icon {
    color: #28a745;
}

.toast.error .toast-icon {
    color: #dc3545;
}

.toast.warning .toast-icon {
    color: #ffc107;
}

.toast-message {
    font-weight: 500;
}

/* Lista de produtos */
.product-list {
    max-height: 300px;
    overflow-y: auto;
}

.product-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.3s ease;
}

.product-item:hover {
    background-color: #f8f9fa;
}

.product-item:last-child {
    border-bottom: none;
}

.product-info {
    flex: 1;
}

.product-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.product-details {
    font-size: 0.9rem;
    color: #7f8c8d;
}

/* Responsividade */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-btn {
        font-size: 0.8rem;
        padding: 8px 16px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .search-box {
        min-width: auto;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .products-table {
        overflow-x: auto;
    }
    
    .products-table table {
        min-width: 600px;
    }
    
    /* Ajustes para tabela compacta em mobile */
    .outputs-table th,
    .outputs-table td {
        padding: 0.4rem 0.2rem;
        font-size: 0.8rem;
    }
    
    .outputs-table th:nth-child(1), /* Data */
    .outputs-table td:nth-child(1) {
        font-size: 0.7rem;
    }
    
    .outputs-table th:nth-child(2), /* Produto */
    .outputs-table td:nth-child(2) {
        font-size: 0.75rem;
    }
    
    .outputs-table th:nth-child(5), /* Pessoa */
    .outputs-table td:nth-child(5) {
        font-size: 0.75rem;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .reports-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 10% auto;
        width: 95%;
        top: 50%;
        transform: translateY(-50%);
    }
    
    /* Modal de saídas - garantir centralização */
    #output-modal .modal-content {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        margin: 0;
        max-height: 95vh;
        width: 90%;
        max-width: 600px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .toast {
        right: 10px;
        left: 10px;
        transform: translateY(-100px);
    }
    
    .toast.show {
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .main {
        padding: 1rem 0;
    }
    
    .section h2 {
        font-size: 1.5rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .stat-content h3 {
        font-size: 1.5rem;
    }
    
    /* Ajustes finais para telas muito pequenas */
    .outputs-table th,
    .outputs-table td {
        padding: 0.3rem 0.1rem;
        font-size: 0.75rem;
    }
    
    .outputs-table .btn-sm {
        padding: 2px 6px;
        font-size: 0.7rem;
        min-width: 24px;
        height: 24px;
    }
}
