/* General Layout & Typography */
body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background-color: #f3f9ff;
    margin: 0;
    padding: 0;
    color: #333;
}

a {
    text-decoration: none;
}

/* Navbar Style */
.navbar {
    background-color: #212529;
    color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
}

.navbar-brand {
    font-size: 1.25rem;
    font-weight: bold;
}

.navbar-user {
    font-size: 0.95rem;
}

.btn-logout {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    margin-left: 10px;
    font-size: 0.85rem;
    cursor: pointer;
    display: inline-block;
}

.btn-logout:hover {
    background-color: #bb2d3b;
}

/* Main Container */
.container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Header Banner */
.header-banner {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    border: 1px solid #e9ecef;
    margin-bottom: 30px;
}

.header-banner h2 {
    margin: 0 0 5px 0;
    color: #198754;
    text-transform: uppercase;
    font-weight: bold;
    font-size: 1.75rem;
}

.header-banner p {
    margin: 0;
    color: #6c757d;
    font-size: 0.95rem;
}

/* Summary Grid Cards */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.summary-card {
    padding: 20px;
    border-radius: 8px;
    color: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.summary-card h5 {
    margin: 0 0 10px 0;
    font-size: 1rem;
    font-weight: 500;
}

.summary-card h3 {
    margin: 0;
    font-size: 1.8rem;
    font-weight: bold;
}

.bg-patients { background-color: #0d6efd; }
.bg-invoices { background-color: #198754; }
.bg-income { background-color: #0dcaf0; color: #000; }
.bg-expense { background-color: #dc3545; }

/* Quick Links & Analytics Section */
.analytics-section {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding: 25px;
    margin-bottom: 40px;
}

.analytics-header h5 {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    color: #212529;
    display: flex;
    align-items: center;
}

.analytics-header p {
    margin: 0 0 20px 0;
    color: #6c757d;
    font-size: 0.875rem;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

/* Transition Buttons Design */
.transition-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    border-radius: 8px;
    border: 2px solid;
    font-weight: bold;
    font-size: 0.85rem;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    text-align: center;
    box-sizing: border-box;
}

.transition-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.1);
}

.transition-btn i {
    font-size: 1.75rem;
    margin-bottom: 8px;
}

.btn-sales { border-color: #0d6efd; color: #0d6efd; }
.btn-sales:hover { background-color: #0d6efd; color: white; }

.btn-expense-link { border-color: #dc3545; color: #dc3545; }
.btn-expense-link:hover { background-color: #dc3545; color: white; }

.btn-db { border-color: #198754; color: #198754; }
.btn-db:hover { background-color: #198754; color: white; }

.btn-comm { border-color: #ffc107; color: #212529; }
.btn-comm:hover { background-color: #ffc107; color: #212529; }

/* Data Management Panel */
.panel-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    overflow: hidden;
    border: 1px solid #dee2e6;
}

.panel-header {
    background-color: #6c757d;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.panel-header h5 {
    margin: 0;
    font-size: 1.1rem;
}

.badge-warning {
    background-color: #ffc107;
    color: #212529;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
}

.panel-body {
    padding: 20px;
}

.text-danger-notice {
    color: #dc3545;
    font-size: 0.9rem;
    margin-top: 0;
    margin-bottom: 15px;
}

/* Custom Table Style */
.custom-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.custom-table th, .custom-table td {
    border: 1px solid #dee2e6;
    padding: 12px;
    text-align: left;
}

.custom-table th {
    background-color: #f8f9fa;
    font-weight: 600;
}

.custom-table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* Action Buttons within Table */
.btn-action {
    padding: 6px 12px;
    font-size: 0.85rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    color: white;
    display: inline-block;
}

.btn-action-primary { background-color: #0d6efd; color: white; }
.btn-action-primary:hover { background-color: #0b5ed7; }

.btn-action-warning { background-color: #ffc107; color: #212529; margin-right: 5px; }
.btn-action-warning:hover { background-color: #ffca2c; }

.btn-action-danger { background-color: #dc3545; color: white; }
.btn-action-danger:hover { background-color: #bb2d3b; }

.status-success {
    color: #198754;
    font-weight: bold;
}

.me-2 {
    margin-right: 8px;
}