/* General Styles */
body {
    background-color: #f8f9fa;
    color: #212529;
    font-size: 16px;
    line-height: 1.6;
}

/* Container width for larger screens */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

/* Navigation */
.navbar {
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    padding: 1rem 2rem;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.5rem;
}

.nav-link {
    font-size: 1.1rem;
    padding: 0.75rem 1.25rem !important;

/* Additional styling for consistent blue accent */
a {
    color: #092c7b;
}

a:hover {
    color: #071f56;
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link:focus {
    color: #092c7b;
}

.navbar-light .navbar-nav .active > .nav-link,
.navbar-light .navbar-nav .nav-link.active {
    color: #092c7b;
}

.btn-outline-primary {
    color: #092c7b;
    border-color: #092c7b;
}

.btn-outline-primary:hover {
    background-color: #092c7b;
    border-color: #092c7b;
}

.page-link {
    color: #092c7b;
}

.page-item.active .page-link {
    background-color: #092c7b;
    border-color: #092c7b;
}

.text-primary {
    color: #092c7b !important;
}

.bg-primary {
    background-color: #092c7b !important;
}

}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0.25rem 0.75rem rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    border-radius: 0.5rem;
}

.card-header {
    background-color: #fff;
    border-bottom: 1px solid rgba(0,0,0,0.125);
    padding: 1.25rem 1.5rem;
    font-size: 1.25rem;
}

.card-body {
    padding: 1.5rem;
}

/* Forms */
.form-control {
    padding: 0.75rem 1rem;
    font-size: 1.1rem;
    border-radius: 0.5rem;
}

.form-control:focus {
    border-color: #4a5c9b;
    box-shadow: 0 0 0 0.25rem rgba(9,44,123,0.25);
}

.form-label {
    font-weight: 500;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
    border-radius: 0.5rem;
}

.btn-primary {
    background-color: #092c7b;
    border-color: #092c7b;
}

.btn-primary:hover {
    background-color: #071f56;
    border-color: #061a49;
    transform: translateY(-1px);
}

/* Tables */
.table {
    background-color: #fff;
    font-size: 1.1rem;
}

.table thead th {
    border-top: none;
    background-color: #f8f9fa;
    padding: 1rem;
    font-size: 1.1rem;
}

.table td {
    padding: 1rem;
    vertical-align: middle;
}

/* Alerts */
.alert {
    border: none;
    border-radius: 0.5rem;
    padding: 1rem 1.5rem;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

/* Password Strength Indicator */
.password-strength {
    font-size: 1rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

/* Tool Cards */
.tool-card {
    height: 400px;
    transition: transform 0.2s ease-in-out;
    padding: 1.5rem;
}

.tool-card .card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.tool-card .card-body {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.tool-card .card-title {
    margin-bottom: 1rem;
}

.tool-card .card-text {
    flex: 1;
    overflow-y: auto;
}

.tool-card:hover {
    transform: translateY(-3px);
}

.tool-card .card-body {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tool-card .tool-description {
    flex: 1;
    overflow: hidden;
    position: relative;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 12; /* Approximately 500 characters with current font size */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.5;
    max-height: 270px; /* ~12 lines * 1.5 line height * font-size */
    min-height: 270px; /* Force minimum height to match max-height */
}

.tool-card .card-footer {
    margin-top: auto; /* Push footer to bottom */
    padding-top: 1rem;
    border-top: 1px solid rgba(0,0,0,0.1);
}

/* Analytics Charts */
.chart-container {
    position: relative;
    height: 400px;
    margin-bottom: 2rem;
}

/* Access Codes */
code {
    background-color: #f8f9fa;
    padding: 0.3rem 0.6rem;
    border-radius: 0.3rem;
    font-size: 1.1rem;
}

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

.modal-header {
    padding: 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1.5rem;
}

/* Organization page specific styles */
.organization-header {
    padding: 3rem 0;
    background-color: #fff;
    margin-bottom: 2.5rem;
}

.organization-header h1 {
    margin-bottom: 0;
    font-size: 2.5rem;
}

/* Admin dashboard specific styles */
.admin-stats {
    background-color: #fff;
    padding: 2rem;
    border-radius: 0.5rem;
    margin-bottom: 2.5rem;
}

.stats-number {
    font-size: 2.5rem;
    font-weight: 600;
    color: #092c7b;
}

/* Tool usage tracking */
.tool-usage-count {
    font-size: 1rem;
    color: #6c757d;
}

/* Badge styles */
.badge {
    padding: 0.6em 1em;
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 0.4rem;
}

/* Headings */
h1, .h1 { font-size: 2.5rem; }
h2, .h2 { font-size: 2rem; }
h3, .h3 { font-size: 1.75rem; }
h4, .h4 { font-size: 1.5rem; }
h5, .h5 { font-size: 1.25rem; }
h6, .h6 { font-size: 1.1rem; }

/* Spacing utilities */
.mt-lg { margin-top: 3rem !important; }
.mb-lg { margin-bottom: 3rem !important; }
.py-lg { padding-top: 3rem !important; padding-bottom: 3rem !important; }
.px-lg { padding-left: 3rem !important; padding-right: 3rem !important; }

/* Responsive adjustments */
@media (max-width: 768px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .table-responsive {
        margin-bottom: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
}

/* Organization page specific styles */
.organization-header {
    padding: 2rem 0;
    background-color: #fff;
    margin-bottom: 2rem;
}

.organization-header h1 {
    margin-bottom: 0;
}

/* Admin dashboard specific styles */
.admin-stats {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 0.25rem;
    margin-bottom: 2rem;
}

.stats-number {
    font-size: 2rem;
    font-weight: 600;
    color: #092c7b;
}

/* Tool usage tracking */
.tool-usage-count {
    font-size: 0.875rem;
    color: #6c757d;
}

/* Badge styles */
.badge {
    padding: 0.5em 0.75em;
    font-weight: 500;
}

/* Custom badge colors */
.badge.bg-secondary {
    background-color: #092c7b !important;
}

.badge.bg-primary {
    background-color: #092c7b !important;
}

/* Override Bootstrap alert colors */
.alert-primary {
    background-color: rgba(9, 44, 123, 0.1);
    border-color: rgba(9, 44, 123, 0.2);
    color: #092c7b;
}

.alert-info {
    background-color: rgba(9, 44, 123, 0.1);
    border-color: rgba(9, 44, 123, 0.2);
    color: #092c7b;
}

/* Override success badge but keep it green */
.badge.bg-success {
    background-color: #198754 !important;
}

/* Override danger badge but keep it red */
.badge.bg-danger {
    background-color: #dc3545 !important;
}

/* Chart colors override */
.chart-colors {
    background-color: #092c7b !important;
}

/* Progress bar colors */
.progress-bar {
    background-color: #092c7b !important;
}

/* Focus ring color */
.form-select:focus {
    border-color: #4a5c9b;
    box-shadow: 0 0 0 0.25rem rgba(9,44,123,0.25);
}

/* Link colors in dropdown menus */
.dropdown-item.active, 
.dropdown-item:active {
    background-color: #092c7b;
}

/* Table row highlighting */
.table-primary {
    background-color: rgba(9, 44, 123, 0.1);
}

/* Custom pagination active state */
.pagination .page-item.active .page-link {
    background-color: #092c7b;
    border-color: #092c7b;
}