/* Color Variables */
:root {
    /* Primary Green Colors */
    --primary: #003b10; /* Dark Green */
    --primary-light: #0b5d1e; /* Medium Green */
    --primary-dark: #002709; /* Darker Green */
    --accent: #4caf50; /* Material Green */
    --success: #2e7d32; /* Forest Green */
    --warning: #8bc34a; /* Light Green */
    --danger: #c62828; /* Red */
    --light: #e8f5e9; /* Very Light Green */
    --border: #c8e6c9; /* Light Green Border */

    /* Additional Green Shades */
    --green-100: #f1f8e9;
    --green-200: #dcedc8;
    --green-300: #81c784;
    --green-400: #66bb6a;
}

body {
    margin: 0;
    /* background: #E5F5E7; */
    font-family: "Segoe UI", Arial, sans-serif;
    color: #222;
}
.container {
    display: flex;
}
.menu a {
    text-decoration: none !important;
    color: inherit;
    display: block;
}
/* Section Title Styles */
.section-title {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: white;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 59, 16, 0.08);
}

.title-icon {
    width: 48px;
    height: 48px;
    min-width: 48px;
    background: #003b10;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.title-icon i {
    font-size: 1.5rem;
    color: white;
}

.title-content {
    flex: 1;
}

.title-content h2 {
    color: #003b10;
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.2;
}

.title-content .subtitle {
    color: #6c757d;
    font-size: 0.95rem;
    margin: 0.25rem 0 0 0;
}

.main-contentt {
    margin-left: 235px;
    padding: 40px 30px 60px 30px;
    flex: 1;
    background: #fff7f7 !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .section-title {
        padding: 1rem;
    }

    .title-icon {
        width: 40px;
        height: 40px;
        min-width: 40px;
    }

    .title-content h2 {
        font-size: 1.5rem;
    }
}
.sidebar {
    min-width: 235px;
    max-width: 255px;
    height: 100vh;
    background: linear-gradient(160deg, #1b365d 80%, #2299c8 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-top: 18px;
    box-shadow: 3px 0 10px rgba(34, 57, 120, 0.07);
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 99;
}
.sidebar .logo {
    font-size: 24px;
    font-weight: 700;
    padding: 0 28px 18px 28px;
    letter-spacing: 1.5px;
    margin-bottom: 16px;
}
.sidebar .menu {
    width: 100%;
}
.sidebar .menu-item {
    padding: 13px 32px;
    /* width: 100%; */
    font-size: 15px;
    display: flex;
    align-items: center;
    border: none;
    background: none;
    color: #fff;
    cursor: pointer;
    outline: none;
    border-left: 4px solid transparent;
    transition:
        background 0.18s,
        border-left 0.18s;
}
.sidebar .menu-item:hover,
.sidebar .menu-item.active {
    background: #1d4875;
    border-left: 4px solid #22b9c8;
}
.sidebar .menu-item span.icon {
    display: inline-block;
    width: 28px;
    font-size: 18px;
    margin-right: 9px;
    text-align: center;
}
.sidebar .bottom {
    margin-top: auto;
    width: 100%;
    padding: 18px 0 16px 0;
    border-top: 1px solid #23536a77;
    text-align: center;
}
.sidebar .logout-btn {
    background: none;
    color: #fff;
    border: none;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    padding: 10px 0;
    letter-spacing: 1px;
}
.main-content {
    margin-left: 235px;
    padding: 40px 30px 60px 30px;
    flex: 1;
    background: #fff7f7 !important;
}
.section-title {
    font-size: 28px;
    color: #1a3866;
    font-weight: 700;
    margin-bottom: 28px;
    border-bottom: 2px solid #22b9c8;
    padding-bottom: 8px;
}

/* Main Layout */
/* Main Layout */
.main-content {
    padding: 2rem;
    background: var(--light);
    min-height: 100vh;
    /* margin-left: 125px !important; */
}

/* Page Title */
.page-title {
    color: var(--primary);
    font-weight: 800;
    font-size: 1.8rem;
    margin-bottom: 0;
}

/* Cards */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.card-header {
    background: #fff;
    border-bottom: 1px solid #e3eaf5;
}

.card-title {
    color: var(--primary);
    font-weight: 600;
}

/* Form Controls */
.input-group-text {
    border: 1.5px solid #d0d7e1;
    border-right: none;
}

.form-control,
.form-select {
    border: 1.5px solid #d0d7e1;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
}

.input-group .form-control {
    border-left: none;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(0, 59, 16, 0.15);
}

/* Table Styles */
.table-responsive {
    margin: 0;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: #22b9c8 #e3eaf5;
}

.table {
    font-size: 0.9rem;
    border-radius: 0px !important;
    min-width: 1200px; /* Ensures table maintains minimum width */
}

.table th {
    font-weight: 600;
    color: #fff;
    background-color: var(--primary);
    white-space: nowrap;
}

/* Specific column widths */
.table th:nth-child(1) {
    width: 60px;
} /* Sl No. */
.table th:nth-child(2) {
    width: 120px;
} /* Offer No */
.table th:nth-child(3) {
    width: 100px;
} /* Date */
.table th:nth-child(4) {
    width: 180px;
} /* Project Name */
.table th:nth-child(5) {
    width: 150px;
} /* Location */
.table th:nth-child(6) {
    width: 180px;
} /* Company Name */
.table th:nth-child(7) {
    width: 150px;
} /* Contact Person */
.table th:nth-child(8) {
    width: 180px;
} /* Email */
.table th:nth-child(9) {
    width: 120px;
} /* Phone */
.table th:nth-child(10) {
    width: 150px;
} /* Consultant */
.table th:nth-child(11) {
    width: 100px;
} /* Due Date */
.table th:nth-child(12) {
    width: 100px;
} /* Attachments */
.table th:nth-child(13) {
    width: 120px;
} /* Status */
.table th:nth-child(14) {
    width: 160px;
} /* Actions */

.table td {
    vertical-align: middle;
    max-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Status Badges */
.badge {
    padding: 0.5em 0.8em;
    font-weight: 500;
}

.badge-success {
    background: var(--success);
}

.badge-warning {
    background: var(--warning);
    color: var(--primary-dark);
}

.badge-danger {
    background: var(--danger);
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    min-width: 320px;
}

.action-buttons .btn {
    padding: 6px 12px;
    font-size: 13px;
    border-radius: 6px;
    white-space: nowrap;
    font-weight: 500;
    transition: all 0.2s ease;
}

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

.btn-primary:hover {
    background: var(--primary-light);
    box-shadow: 0 4px 12px rgba(0, 59, 16, 0.15);
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-editupdate {
    background: var(--primary);
    color: #fff;
}

.btn-hold {
    background: var(--warning);
    color: var(--primary-dark);
}

.btn-loss {
    background: var(--danger);
    color: #fff;
}

.btn-order {
    background: var(--success);
    color: #fff;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 59, 16, 0.15);
}

/* Pagination */
.pagination {
    margin: 0;
}

.page-link {
    padding: 0.5rem 0.75rem;
    color: var(--primary);
    border-color: #e3eaf5;
}

.page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
}

/* Responsive Design */
@media (max-width: 1400px) {
    .action-buttons {
        min-width: 280px;
    }

    .action-buttons .btn {
        padding: 4px 8px;
        font-size: 12px;
    }
}

@media (max-width: 992px) {
    .main {
        margin-left: 0;
    }

    .page-title {
        font-size: 1.5rem;
    }

    .action-buttons {
        flex-direction: column;
        min-width: 120px;
        gap: 4px;
    }

    .action-buttons .btn {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .main {
        padding: 15px;
    }

    .card {
        border-radius: 8px;
    }

    .table {
        font-size: 0.8rem;
    }
}

/* Custom scrollbar styling */
.table-responsive::-webkit-scrollbar {
    height: 8px;
}

.table-responsive::-webkit-scrollbar-track {
    background: #e3eaf5;
    border-radius: 4px;
}

.table-responsive::-webkit-scrollbar-thumb {
    background: var(--primary);
}

.table-responsive::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Modal Styling */
.modal-content {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-header {
    background: var(--primary);
    border-radius: 1rem 1rem 0 0;
    padding: 1.25rem 1.5rem;
}

.modal-header.bg-gradient {
    background: linear-gradient(90deg, var(--primary) 60%, var(--accent) 100%);
    border-radius: 1rem 1rem 0 0;
    padding: 1.25rem 1.5rem;
}

.modal-title {
    font-weight: 600;
    letter-spacing: 0.5px;
}

.modal-body {
    padding: 1.5rem;
}

.form-floating > .form-control,
.form-floating > .form-select {
    border: 1.5px solid #d0d7e1;
    border-radius: 0.5rem;
    height: calc(3.5rem + 2px);
    line-height: 1.25;
}

.form-floating > textarea.form-control {
    height: auto;
}

.form-floating > .form-control:focus,
.form-floating > .form-select:focus {
    border-color: #22b9c8;
    box-shadow: 0 0 0 0.25rem rgba(34, 185, 200, 0.25);
}

.form-floating > label {
    padding: 1rem 0.75rem;
    color: #6c757d;
}

.modal-footer {
    border-top: 1px solid #e3eaf5;
    border-radius: 0 0 1rem 1rem;
    padding: 1rem 1.5rem;
}

.btn-light {
    background: #f8f9fa;
    border: 1.5px solid #d0d7e1;
    font-weight: 500;
}

.btn-light:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-primary {
    background: var(--primary);
    border: none;
    font-weight: 500;
}

.btn-primary:hover {
    background: var(--primary-light);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(34, 185, 200, 0.15);
}

.input-group-text {
    background-color: #fff;
    border-right: none;
}

.input-group .form-control {
    border-left: none;
}

.input-group .form-control:focus {
    border-color: #dee2e6;
    box-shadow: none;
}

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-header {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    border-radius: 0.5rem 0.5rem 0 0;
    padding: 1.5rem;
}

.modal-title {
    font-weight: 600;
    color: #ffffff;
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    background-color: #f8f9fa;
    border-top: 2px solid #dee2e6;
    border-radius: 0 0 0.5rem 0.5rem;
    padding: 1rem 1.5rem;
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.5rem;
}

.form-control {
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    padding: 0.75rem;
    transition:
        border-color 0.15s ease-in-out,
        box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Status Badges */
.badge-success {
    background: var(--success);
}

.badge-warning {
    background: var(--warning);
    color: var(--primary-dark);
}

.badge-danger {
    background: var(--danger);
}

/* Input Groups */
.input-group-text {
    background-color: var(--green-100);
    border-color: var(--border);
    color: var(--primary);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 20;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}
.modal-dialog {
    max-width: 800px;
    margin: 1.75rem auto;
}
.modal-backdrop.show {
    display: none;
}
.modal-content {
    background-color: white;
    max-width: 600px;
    margin: 70px auto;
    padding: 25px 30px;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    position: relative;
}
.modal-content {
    background: white;
    border-radius: 12px;
}
.modal-header {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    border-radius: 0.5rem 0.5rem 0 0;
    padding: 1.5rem;
}
.modal-title {
    font-weight: 600;
    color: #2c3e50;
}
.modal-body {
    padding: 2rem;
}
.modal-footer {
    background-color: #f8f9fa;
    border-top: 2px solid #dee2e6;
    border-radius: 0 0 0.5rem 0.5rem;
    padding: 1rem 1.5rem;
}
.modal-close {
    position: absolute;
    top: 18px;
    right: 22px;
    font-size: 28px;
    cursor: pointer;
    color: #777;
    transition: color 0.3s;
}
.modal-close:hover {
    color: var(--primary);
}
.form-group {
    margin-bottom: 1.25rem;
}
.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--primary);
}
.form-group label {
    color: var(--primary);
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    font-size: 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    color: var(--primary);
    box-sizing: border-box;
}
.form-group textarea {
    min-height: 70px;
    resize: vertical;
}
.form-buttons {
    text-align: right;
    margin-top: 20px;
}
.form-buttons button {
    padding: 12px 28px;
    border-radius: 12px;
    border: none;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    color: white;
    background-color: var(--accent);
    margin-left: 12px;
}
.form-buttons button.close-btn {
    background-color: var(--border);
    color: var(--primary);
}
.form-buttons button:hover {
    opacity: 0.85;
}

/* Dashboard Header */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.header-left h1 {
    color: var(--primary);
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
}

.period {
    color: #6c757d;
    font-size: 1rem;
    margin-top: 0.5rem;
}

/* Overview Cards */
.overview-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.pending-card .card-icon {
    background: var(--primary);
}
.offers-card .card-icon {
    background: var(--success);
}
.target-card .card-icon {
    background: var(--warning);
}

.trend {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 0.9rem;
}

.trend.positive {
    color: var(--success);
}
.trend.negative {
    color: var(--danger);
}

.stat-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.stat-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
}

.stat-card.pending::before {
    background: var(--primary);
}
.stat-card.offers::before {
    background: var(--success);
}
.stat-card.pipeline::before {
    background: var(--warning);
}
.stat-card.sales::before {
    background: var(--accent);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 59, 16, 0.15);
}

.stat-card-body {
    padding: 1.5rem;
    display: flex;
    gap: 1.25rem;
    min-height: 180px;
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    background: var(--primary);
}

.pending .stat-icon {
    background: var(--primary);
}
.offers .stat-icon {
    background: var(--success);
}
.pipeline .stat-icon {
    background: var(--warning);
}
.sales .stat-icon {
    background: var(--accent);
}

.stat-content {
    display: flex;
    flex-direction: column;
    min-height: 140px;
    position: relative;
}

.stat-title {
    color: #6c757d;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-value {
    color: #1b365d;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    line-height: 1;
}

.stat-text {
    margin-bottom: auto;
    color: #6c757d;
    font-size: 0.875rem;
    line-height: 1.4;
}

.trend {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 0.5rem;
    width: fit-content;
    position: relative;
    z-index: 1;
}

.trend.positive {
    background: var(--green-100);
    color: var(--success);
    border: 1px solid var(--success);
}

.trend.negative {
    background: #ffebee;
    color: var(--danger);
    border: 1px solid var(--danger);
}

.trend i {
    font-size: 0.7rem;
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}
#viewDetailsModal .table {
    margin-bottom: 20px;
}

#viewDetailsModal .form-buttons {
    text-align: right;
    padding-top: 15px;
}
.modal .table th {
    background: #eaeaea !important;
    color: #000 !important;
}
.modal h2 {
    margin-top: 0;
    color: #1a3866;
    font-weight: 700;
    margin-bottom: 20px;
}

.attachment-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.attachment-item:last-child {
    border-bottom: none;
}

.attachment-item span {
    flex-grow: 1;
    margin-right: 10px;
}

.attachments-list {
    max-height: 300px;
    overflow-y: auto;
    margin-top: 20px;
}
.modal .table {
    min-width: 100%;
}

/* Remarks Modal Styles */
.remarks-history {
    max-height: 300px;
    overflow-y: auto;
}

.remarks-item {
    padding: 12px;
    background-color: #f8f9fa;
    border-radius: 6px;
}

.remarks-date {
    color: #6c757d;
    margin-bottom: 4px;
}

.remarks-text {
    color: #212529;
    line-height: 1.5;
}

.reamarks_btn .btn {
    padding: 6px 12px;
    font-size: 0.875rem;
    white-space: nowrap;
}

.reamarks_btn_view {
    background-color: #0dcaf0 !important;
    color: white;
    border: none;
    transition: all 0.2s;
}

.reamarks_btn_view:hover {
    background-color: #0baccd;
    color: white;
    transform: translateY(-1px);
}

/* Enhanced Tabs Filter Design */
/* Button-style Tabs Filter */
.tabs_filtter {
    margin-bottom: 2rem;
    border-radius: 1rem;
    padding: 1rem 1rem 0.5rem 1rem;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.tabs_filtter .nav-tabs {
    border-bottom: none;
    gap: 0.75rem;
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.tabs_filtter .nav-link {
    border: none;
    border-radius: 2rem;
    background: #f4f6fa;
    color: #003b10;
    font-weight: 600;
    padding: 0.6rem 2rem;
    margin-bottom: 0;
    margin-right: 0;
    transition:
        background 0.18s,
        color 0.18s,
        box-shadow 0.18s;
    box-shadow: 0 1px 3px rgba(44, 62, 80, 0.04);
    position: relative;
    outline: none;
    letter-spacing: 0.5px;
    font-size: 1rem;
    cursor: pointer;
    display: inline-block;
}

.tabs_filtter .nav-link.active,
.tabs_filtter .nav-link:focus,
.tabs_filtter .nav-link:active {
    background: #0d6efd;
    color: #fff;
    box-shadow: 0 4px 16px rgba(13, 110, 253, 0.1);
    font-weight: 700;
}

.tabs_filtter .nav-link:not(.active):hover {
    background: #e9ecef;
    color: #0d6efd;
}

.tabs_filtter .nav-link.active::after {
    display: none;
}
.icon {
    margin-right: 7px;
}
/* ===== Layout Fix for Fixed Sidebar ===== */
/* ===== Sales Layout ===== */
.main-content-wrapper {
    margin-left: 255px;
    padding: 20px;
    min-height: 100vh;
    background: #f7fafd; /* optional, matches your UI */
}
