/* ============================================
   Invoice Tracker Custom CSS
   Only what Bootstrap doesn't provide
   ============================================ */

/* Gradient Backgrounds (Your Brand) */
.bg-gradient-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.btn-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-gradient:hover {
    background: linear-gradient(135deg, #5a67d8 0%, #6b4292 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-gradient:active {
    transform: translateY(0);
}

/* Brand Colors */
.text-brand {
    color: #667eea;
}

.border-brand {
    border-color: #667eea;
}

.bg-brand-light {
    background-color: rgba(102, 126, 234, 0.1);
}

/* Pricing Cards */
.pricing-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    border-radius: 20px;
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.pricing-card .card-body {
    padding: 2rem;
}

.pricing-card .card-title {
    font-size: 1.75rem;
    font-weight: bold;
}

.pricing-card .price-amount {
    font-size: 3rem;
    font-weight: bold;
    color: #667eea;
}

/* Popular Badge */
.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: bold;
    white-space: nowrap;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 80px 0;
    color: white;
}

.hero-section h1 {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

.hero-section .lead {
    font-size: 1.25rem;
    opacity: 0.95;
}

/* Dashboard Stats Cards */
.stat-card {
    border: none;
    border-radius: 15px;
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card .stat-icon {
    font-size: 2.5rem;
    color: #667eea;
}

.stat-card .stat-number {
    font-size: 2rem;
    font-weight: bold;
    color: #333;
}

/* Invoice Table (Responsive) */
.invoice-table-wrapper {
    overflow-x: auto;
}

.invoice-table {
    min-width: 600px;
}

.invoice-table th {
    background-color: #f8f9fa;
    font-weight: 600;
}

/* Status Badges */
.status-paid {
    background-color: #d1fae5;
    color: #065f46;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.status-pending {
    background-color: #fed7aa;
    color: #92400e;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.status-overdue {
    background-color: #fee2e2;
    color: #991b1b;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    transition: all 0.3s;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Mobile Responsive Overrides */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }

    .hero-section .lead {
        font-size: 1rem;
    }

    .pricing-card .card-body {
        padding: 1.5rem;
    }

    .stat-card .stat-number {
        font-size: 1.5rem;
    }
}

/* Animation for fade-in elements (optional) */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.show {
    opacity: 1;
    transform: translateY(0);
}



/* Gradient text on hover for user dropdown */
.navbar-nav .dropdown-toggle .gradient-text {
    transition: all 0.3s ease;
}

.navbar-nav .dropdown-toggle:hover .gradient-text,
.navbar-nav .dropdown-toggle:focus .gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-nav .dropdown-toggle:hover i,
.navbar-nav .dropdown-toggle:focus i {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}


/* Trust Badges Styling */
.trust-item {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: default;
}

.trust-item:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.2) !important;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.trust-item i {
    transition: transform 0.2s ease;
}

.trust-item:hover i {
    transform: scale(1.1);
}



    .totals {
        text-align: right;
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid #e0e0e0;
    }

    .totals-row {
        margin: 0.5rem 0;
        display: flex;
        justify-content: flex-end;
        align-items: center;
        gap: 1rem;
    }

    .totals-label {
        font-weight: 500;
        color: #555;
        min-width: 100px;
        text-align: right;
    }

    .totals-value {
        min-width: 180px;
        text-align: right;
        font-weight: 500;
    }

    .grand-total {
        margin-top: 0.75rem;
        padding-top: 0.75rem;
        border-top: 2px solid #667eea;
        font-size: 1.1rem;
        font-weight: bold;
    }

    .grand-total .totals-label,
    .grand-total .totals-value {
        font-weight: bold;
        color: #667eea;
    }

    .tax-input-group {
        display: flex;
        gap: 1rem;
        justify-content: flex-end;
    }

    .tax-input-group label {
        display: inline-flex;
        align-items: center;
        gap: 0.25rem;
        font-weight: normal;
        cursor: pointer;
        margin-bottom: 0;
    }

    .tax-input-group input[type="radio"] {
        width: auto;
        margin: 0;
        cursor: pointer;
    }

    #tax_percentage, #tax_fixed {
        padding: 0.25rem 0.5rem;
        border: 1px solid #e0e0e0;
        border-radius: 8px;
        text-align: right;
    }

    #tax_percentage:focus, #tax_fixed:focus {
        outline: none;
        border-color: #667eea;
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    }

    @media (max-width: 768px) {
        .totals-row {
            flex-direction: column;
            align-items: flex-end;
            gap: 0.25rem;
        }

        .totals-label {
            min-width: auto;
        }

        .totals-value {
            min-width: auto;
        }

        .tax-input-group {
            justify-content: flex-start;
        }
    }