body,
html {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f3f4f5;
    color: #000;
    overflow-x: hidden;
    /* Prevent horizontal scrollbars during animation */
}

/* Sub-page styles */
.sub-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    position: sticky;
    top: 0;
    z-index: 3;
}

.sub-page-header h1 {
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    flex-grow: 1;
    margin: 0;
}

.back-button {
    color: #007aff;
    text-decoration: none;
    font-size: 1rem;
    position: absolute;
}

.sub-page-content {
    padding: 20px 0;
}

/* Transactions List Styles */
.transactions-list {
    list-style: none;
    padding: 0 16px;
    margin: 0;
}

.transaction-item {
    display: flex;
    background-color: #fff;
    border-radius: 10px;
    margin-bottom: 10px;
    padding: 16px;
}

.transaction-item:last-child {
    margin-bottom: 0;
}

.transaction-date {
    width: 55px;
    color: #8e8e93;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.transaction-details {
    display: flex;
    justify-content: space-between;
    flex-grow: 1;
    gap: 10px;
    align-items: flex-start;
}

.transaction-description {
    font-size: 0.9rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
}

.transaction-amount {
    font-weight: 500;
    white-space: nowrap;
}

.transaction-amount.expense {
    color: #ff3b30;
}

.transaction-amount.income {
    color: #34c759;
}


.nav-bar {
    position: sticky;
    top: 0;
    background: #f3f4f5;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.back-link {
    position: absolute;
    left: 12px;
    text-decoration: none;
    color: #007aff;
    font-weight: 500;
}

.title {
    font-size: 16px;
}