* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7fa;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 28px;
}

h2 {
    color: #2c3e50;
    margin: 30px 0 15px 0;
    font-size: 22px;
    border-bottom: 2px solid #3498db;
    padding-bottom: 10px;
}

.report-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #3498db;
}

.company-info {
    margin-bottom: 20px;
}

.company-info h2 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 24px;
    border: none;
}

.period {
    color: #7f8c8d;
    font-size: 18px;
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

table th, table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ecf0f1;
}

table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
}

.total {
    font-weight: bold;
    font-size: 16px;
}

.total-row {
    background-color: #f8f9fa;
    font-weight: bold;
}

.grand-total {
    background-color: #3498db;
    color: white;
    font-weight: bold;
    font-size: 18px;
}

.positive {
    color: #27ae60;
}

.negative {
    color: #e74c3c;
}

.section-title {
    background-color: #f8f9fa;
    font-weight: bold;
    padding: 10px;
    margin-top: 15px;
    border-radius: 4px;
    color: #2c3e50;
}

.note {
    margin-top: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-left: 4px solid #3498db;
    font-style: italic;
    color: #7f8c8d;
}

.back-link {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.back-link:hover {
    background-color: #2980b9;
}

.nav-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}

.nav-tabs::-webkit-scrollbar {
    display: none;
}

.nav-tab {
    padding: 10px 20px;
    background-color: #ecf0f1;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    color: #2c3e50;
    transition: all 0.3s;
    white-space: nowrap;
    flex-shrink: 0;
    scroll-snap-align: start;
}

.nav-tab:hover {
    background-color: #bdc3c7;
}

.nav-tab.active {
    background-color: #3498db;
    color: white;
}

.t-accounts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.t-account {
    background: white;
    border: 2px solid #3498db;
    border-radius: 8px;
    overflow: hidden;
}

.t-account-header {
    background: #3498db;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: bold;
    font-size: 16px;
}

.t-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.t-table th,
.t-table td {
    padding: 8px 5px;
    text-align: left;
    border-bottom: 1px solid #ecf0f1;
    font-size: 13px;
}

.t-table th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-right: 2px solid #3498db;
}

.t-debit {
    border-right: 2px solid #3498db !important;
    background-color: #e8f6f3 !important;
    color: #27ae60;
}

.t-credit {
    background-color: #fdedec !important;
    color: #e74c3c;
}

.t-total {
    font-weight: bold;
    background-color: #f8f9fa;
    border-top: 2px solid #3498db;
}

.t-balance {
    background-color: #fff3cd;
    font-weight: bold;
    text-align: center;
}

.t-summary {
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.t-summary h3 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.summary-table {
    width: 100%;
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .t-accounts-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .t-account-header {
        font-size: 14px;
        padding: 8px;
    }

    .t-table th,
    .t-table td {
        font-size: 11px;
        padding: 5px 3px;
    }

    .t-table small {
        display: block;
        font-size: 9px;
        color: #7f8c8d;
    }
}

.section-content {
    display: none;
}

.section-content.active {
    display: block;
}

@media print {
    body {
        background: white;
        padding: 0;
    }

    .container {
        box-shadow: none;
        border: none;
        padding: 0;
    }

    .back-link, .nav-tabs {
        display: none;
    }

    .section-content {
        display: block !important;
    }
}

@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    .container {
        padding: 15px;
    }

    h1 {
        font-size: 22px;
    }

    h2 {
        font-size: 18px;
    }

    table {
        font-size: 12px;
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap;
    }
    
    table th, table td {
        padding: 6px 4px;
    }

    .nav-tabs {
        gap: 8px;
        padding-bottom: 10px;
    }

    .nav-tab {
        padding: 8px 16px;
        font-size: 14px;
    }

    .period {
        font-size: 14px;
    }
}
