﻿@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap');

html {
    font-size: 1rem;
    position: relative;
    min-height: 100%;
}

@media (min-width: 992px) {
    html {
        max-width: 80%;
        font-size: 0.8rem;
    }
}

.sidebar-logo img {
    max-width: 100%;
    height: auto;
    padding: 10px;
}

@font-face {
    font-family: 'Inter';
    font-weight: normal;
    font-style: normal;
}

body {
    color: #525252;
    font-family: 'Open Sans', sans-serif;
    background-color: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Section */
.header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* Search and Filter Section */
.search-form .form-control {
    width: 300px;
    height: 40px;
    font-size: 14px;
    border-radius: 5px;
}

.search-form .btn {
    height: 40px;
    font-size: 14px;
    padding: 0 20px;
    border-radius: 5px;
    background-color: #298da5;
    color: white;
    border: none;
}

    .search-form .btn:hover {
        background-color: #298da5;
    }

.custom-card {
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 20px;
    font-family: 'Open Sans', sans-serif;
}

    .custom-card .card-header {
        font-weight: 600;
        padding-bottom: 10px;
        border-bottom: 1px solid #ddd;
    }

    .custom-card input[type=text]:focus, .custom-card input[type=number]:focus {
        border-color: #80bdff;
        outline: 0;
        box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
    }

    .custom-card .btn-success {
        padding: 10px 20px;
        font-weight: 500;
    }

        .custom-card .btn-success:hover {
            background-color: #218838;
        }

    .custom-card .form-group {
        margin-bottom: 1.5rem;
    }

        .custom-card .form-group:last-child {
            text-align: right;
        }

input.form-control:invalid {
    border-color: red !important;
    box-shadow: 0 0 0 0.2rem rgba(255, 0, 0, 0.25) !important;
}

input:invalid::-webkit-validation-bubble {
    display: none;
}

.quick-action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 70px;
}

.custom-button {
    background-color: #fff;
    border: 2px solid transparent;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    padding: 10px 20px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s, border-color 0.2s;
}

    .custom-button:hover {
        background-color: #007BFF;
        color: #fff;
        border-color: #007BFF;
        transform: scale(1.05);
    }

    .custom-button:active {
        transform: scale(0.95);
    }

.card-link {
    color: inherit;
    text-decoration: none;
}

    .card-link:hover,
    .card-link:focus {
        color: inherit;
        text-decoration: none;
    }

.filter-form-container {
    margin-bottom: 1rem;
    padding: 1rem;
    background-color: #fff;
    border-radius: 0.375rem;
    box-shadow: 0 0.46875rem 2.1875rem rgb(90 97 105 / 10%);
}

.table {
    width: 100%;
    margin-bottom: 1rem;
    color: #212529;
}

    .table th {
        padding: 0.75rem;
        vertical-align: top;
    }

    .table td {
        padding: 0.75rem;
        vertical-align: top;
        border-top: 1px solid #dee2e6;
    }

.table-hover tbody tr:hover {
    color: #212529;
    background-color: rgba(0, 0, 0, 0.075);
}

.table-bordered {
    border-collapse: collapse;
    width: 100%;
}

    .table-bordered th,
    .table-bordered td {
        border: 1px solid #ddd;
        padding: 8px;
    }

    .table-bordered thead th {
        background-color: #f2f2f2;
        border-bottom: 2px solid #ddd;
    }

.custom-table {
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

@media screen and (max-width: 768px) {
    .filter-form-container {
        flex-direction: column;
    }

        .filter-form-container .col {
            width: 100%;
            max-width: 100%;
            flex: 0 0 100%;
            margin-bottom: 0.5rem;
        }

    .new-customer-btn-container {
        display: flex;
        justify-content: center;
    }
}

.action-icons {
    justify-content: center;
    align-items: center;
}

.action-icon {
    margin: 0 0.2rem;
    transition: background-color 0.3s;
}

    .action-icon:hover {
        background-color: #f8f9fa;
    }

    .action-icon.delete {
        color: #dc3545;
    }

.is-valid {
    border-color: #28a745;
}

.is-invalid {
    border-color: #dc3545;
}

.form-group {
    margin-bottom: 10px;
}

.card-header {
    background: #298da5;
    color: white;
}

.status-button {
    border: none;
    cursor: pointer;
}

.status-unpaid {
    color: #dc3545;
}

.status-paid {
    color: #28a745;
}

.status-incomplete {
    color: #ffc107;
}

.status-paid {
    color: white;
    background-color: #28a745;
}

.status-unpaid {
    color: white;
    background-color: #dc3545;
}

.status-incomplete {
    color: white;
    background-color: #ffc107;
}

.status-button {
    display: inline-block;
    width: auto;
    border: none;
    padding: 0.375rem 0.75rem;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 0.875rem;
    line-height: 1.5;
}

#invoicesTable_wrapper .row:first-of-type {
    margin-top: 1rem;
}

.btn-fix-payment {
    color: #fff;
    background-color: #007bff;
    border-color: #007bff;
    border-radius: 5px;
    padding: .375rem .75rem;
    line-height: 1;
    border: 1px solid transparent;
    font-size: 0.75rem;
}

    .btn-fix-payment:hover {
        background-color: #0056b3;
        border-color: #0056b3;
    }

.btn-complete-payment {
    color: #fff;
    background-color: #28a745;
    border-color: #28a745;
    border-radius: 5px;
    padding: .375rem .75rem;
    line-height: 1;
    border: 1px solid transparent;
    font-size: 0.75rem;
}

    .btn-complete-payment:hover {
        background-color: #218838;
        border-color: #1e7e34;
    }

.btn-paid {
    color: #fff;
    background-color: #28a745;
    border-color: #28a745;
    border-radius: 5px;
    padding: .375rem .75rem;
    line-height: 1;
    border: 1px solid transparent;
    font-size: 0.75rem;
    cursor: default;
    opacity: 0.7;
}

.btn-click-effect:active {
    transform: scale(0.95);
    transition: transform 0.1s;
}

.fa, .fa-solid, .fas {
    color: white;
}

.field-validation-valid {
    display: none;
}

.field-validation-error {
    color: #ff0000;
}

.modal-body {
    padding-left: 50px;
    padding-right: 50px;
}

/* Table Styling */
.custom-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

    .custom-table thead th {
        background-color: #298da5;
        color: white;
        padding: 12px;
        text-align: left;
        font-size: 14px;
        font-weight: bold;
    }

    .custom-table tbody td {
        padding: 12px;
        border-bottom: 1px solid #dee2e6;
    }

    .custom-table tbody tr:hover {
        background-color: #f1f1f1;
    }
/* Transaction Cards */
.transaction-header {
    border-bottom: 2px solid #007bff;
    padding-bottom: 1rem;
    margin-bottom: 2rem;
}

.action-card {
    transition: transform 0.2s, box-shadow 0.2s;
    background: #f8f9fa;
}

    .action-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    }

/* Form Styling */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.5rem;
}

/* Button Enhancements */
.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
}

/* Input Group Enhancements */
.input-group-text {
    background-color: #e9ecef;
    border-color:   #ced4da;
}

.btn-app-main {
    background: #298da5;
    color: white;
    transition: background-color 0.3s ease, color 0.3s ease;
}

    .btn-app-main:hover {
        background: #1f6d83;
        color: #e0f7fa;
    }
.btn-cancel {
    background: #f0f0f0;
    color: #333;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.btn-cancel:hover {
    background: #d4d4d4;
    color: #000;
}

.btn-info {
    background-color: #17a2b8;
    color: white;
}

    .btn-info:hover {
        background-color: #138496;
        color: white;
    }

.btn-outline-custom {
    color: #298da5;
    border-color: #298da5;
    border-radius: unset;
}

    .btn-outline-custom:hover {
        background-color: #298da5;
        color: white;
    }

    .btn-outline-custom.active {
        background-color: #298da5;
        color: white;
    }
.btn i {
    font-size: 0.875rem;
}
.btn-reset {
    background-color: #ffc107;
    color: white;
}

    .btn-reset:hover {
        background-color: #e0a800;
        color: white;
    }
/* Custom Breadcrumb Styles */
.custom-breadcrumb {
    background-color: #f8f9fa;
    border-radius: 0.25rem;
    padding: 0.75rem 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

    .custom-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
        content: ">";
    }

    .custom-breadcrumb .breadcrumb-item a {
        color: #298da5;
        text-decoration: none;
    }

        .custom-breadcrumb .breadcrumb-item a:hover {
            color: darkslategrey;
            text-decoration: underline;
        }

    .custom-breadcrumb .breadcrumb-item.active {
        color: #6c757d;
    }
/* RTL-specific styles */
html[dir="rtl"] .custom-breadcrumb {
    direction: rtl;
}

    html[dir="rtl"] .custom-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
        content: "<";
    }

    html[dir="rtl"] .custom-breadcrumb .breadcrumb-item {
        margin-left: 0.5rem;
        margin-right: 0;
    }

        html[dir="rtl"] .custom-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
            margin-right: 0.5rem;
            margin-left: 0;
        }

.edit-icon {
    font-size: 0.875rem !important;
    color: #298da5 !important;
}

.delete-icon {
    font-size: 0.875rem !important;
    color: red !important;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.page-link {
    padding: 8px 12px;
    margin: 0 5px;
    border: 1px solid #298da5;
    border-radius: 5px;
    color: #298da5;
    text-decoration: none;
}

    .page-link.active {
        background-color: #298da5;
        color: white;
    }

/* Modal Styling */
.modal-content {
    border-radius: 10px;
}

.modal-header {
    background-color: #298da5;
    color: white;
    border-radius: 10px 10px 0 0;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
}

.btn-md {
    background: none;
    border: none;
    color: #007bff;
    font-size: 16px;
    transition: color 0.3s ease;
}

    .btn-md:hover {
        color: #0056b3;
    }

.fa-trash-alt {
    color: #dc3545;
    transition: color 0.3s ease;
}

    .fa-trash-alt:hover {
        color: #a71d2a;
    }

.form-label {
    font-weight: bold;
    font-size: 0.9em;
    color: #343a40;
}

.status-badge {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.3px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: capitalize;
}

    .status-badge i {
        font-size: 0.875rem;
    }

/* Status-specific hover effects */
.bg-success-subtle:hover {
    background-color: var(--bs-success-bg-subtle);
    box-shadow: 0 0 0 1px var(--bs-success);
}

.bg-warning-subtle:hover {
    background-color: var(--bs-warning-bg-subtle);
    box-shadow: 0 0 0 1px var(--bs-warning);
}

.bg-danger-subtle:hover {
    background-color: var(--bs-danger-bg-subtle);
    box-shadow: 0 0 0 1px var(--bs-danger);
}

.bg-info-subtle:hover {
    background-color: var(--bs-info-bg-subtle);
    box-shadow: 0 0 0 1px var(--bs-info);
}

.bg-secondary-subtle:hover {
    background-color: var(--bs-secondary-bg-subtle);
    box-shadow: 0 0 0 1px var(--bs-secondary);
}

/* Transition effects */
.status-badge {
    transition: all 0.2s ease-in-out;
}

    .status-badge:hover {
        transform: translateY(-1px);
    }

.bg-success-subtle {
    animation: pulse 2s infinite;
}

.fa, .fa-solid, .fas {
    color: white;
}

.btn {
    transition: all 0.3s ease;
}

    .btn:disabled,
    .btn[disabled] {
        cursor: not-allowed;
        opacity: 0.65;
    }

/* Custom hover effects for each button type when enabled */
.btn-success:not([disabled]):hover {
    background-color: #157347;
    transform: translateY(-2px);
}

.btn-primary:not([disabled]):hover {
    background-color: #0a58ca;
    transform: translateY(-2px);
}

.btn-warning:not([disabled]):hover {
    background-color: #ffca2c;
    transform: translateY(-2px);
}

/* Optional: Add an indicator for disabled state */
.btn[disabled]::after {
    content: '🔒';
    margin-left: 0.5rem;
    font-size: 0.875rem;
}

/* Optional: Add transition for tooltip */
.tooltip {
    transition: opacity 0.3s ease;
}

/* Status-dependent button styles */
.btn-secondary[disabled] {
    background-color: #6c757d;
    border-color: #6c757d;
    color: #fff;
}
.date-label {
    display: block;
    font-size: 0.9rem;
    font-style: italic;
    color: #298da5; /* Themed blue color */
    font-weight: 600;
    margin-top: 3px;
    transition: opacity 0.3s ease-in-out;
    opacity: 1;
}