/* Mobile First Design */
:root {
    --primary-color: #00cc99;
    --primary-hover: #00b386;
    --secondary-color: #333;
    --light-bg: #f8f9fa;
    --dark-text: #2c3e50;
    --danger: #e74c3c;
    --success: #27ae60;
}

body {
    background-color: var(--light-bg);
    padding-bottom: 70px; /* Space for bottom nav */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 16px;
    color: var(--dark-text);
}

/* --- BUTTON STYLES --- */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.btn-success {
    background-color: var(--success);
    border: none;
}

/* Google Button Fixed */
.btn-google {
    background-color: white;
    color: #333;
    border: 1px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px; /* Khoảng cách giữa icon và text */
    font-weight: 600;
    font-size: 15px;
    padding: 10px 16px;
    transition: all 0.2s ease;
    border-radius: 50px; /* Bo tròn kiểu pill */
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.btn-google:hover {
    background-color: #f8f9fa;
    border-color: #c1c1c1;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    color: #333;
}

/* Fix ảnh Google bị to */
.btn-google img {
    width: 24px !important;
    height: 24px !important;
    object-fit: contain;
}

/* --- FORM STYLES --- */
.form-control-lg { 
    border-radius: 12px; 
    font-size: 1rem; 
    padding: 12px 16px;
}

/* Input đẹp hơn, bỏ viền xanh mặc định */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(0, 204, 153, 0.25);
}

.input-custom {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
}
.input-custom:focus {
    background-color: #fff;
}


/* --- CARD STYLES --- */
.card {
    border: none;
    border-radius: 16px; /* Bo góc mềm mại hơn */
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    margin-bottom: 15px;
    background: white;
}

.card-header {
    background-color: white;
    border-bottom: 1px solid #f0f0f0;
    font-weight: 700;
    border-radius: 16px 16px 0 0 !important;
    padding: 16px;
}

/* --- NAVIGATION --- */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    z-index: 1000;
}

.nav-item-link {
    text-decoration: none;
    color: #a0a0a0;
    text-align: center;
    font-size: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4px;
    transition: color 0.2s;
}

.nav-item-link i {
    font-size: 1.3rem;
    margin-bottom: 4px;
}

.nav-item-link.active {
    color: var(--primary-color);
    font-weight: 700;
}

/* --- FLOATING ACTION BUTTON --- */
.fab {
    position: fixed;
    bottom: 80px;
    right: 20px;
    background-color: var(--primary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    box-shadow: 0 4px 12px rgba(0,204,153,0.4);
    z-index: 999;
    text-decoration: none;
    transition: transform 0.2s;
}

.fab:hover {
    color: white;
    transform: scale(1.1) rotate(90deg);
}

/* --- UTILS --- */
.avatar-small { width: 32px; height: 32px; border-radius: 50%; margin-right: 8px; object-fit: cover; border: 2px solid white; box-shadow: 0 2px 4px rgba(0,0,0,0.1); }
.avatar-large { width: 80px; height: 80px; border-radius: 50%; margin-bottom: 10px; object-fit: cover; }

/* Mobile Optimization: Text Wrapping */
.text-wrap-mobile {
    white-space: normal !important;
    word-wrap: break-word;
    word-break: break-word;
    /* Giới hạn 2 dòng */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    body { font-size: 14px; }
    .card-body { padding: 16px; }
    
    .expense-date-box {
        width: 42px !important;
        height: 42px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }
}
