﻿/* Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification
for details on configuring this project to bundle and minify static web assets. */

a.navbar-brand {
  white-space: normal;
  text-align: center;
  word-break: break-all;
}

/* Provide sufficient contrast against white background */
a {
  color: #0366d6;
}

.btn-primary {
  color: #fff;
  background-color: #1b6ec2;
  border-color: #1861ac;
}

.nav-pills .nav-link.active, .nav-pills .show > .nav-link {
  color: #fff;
  background-color: #1b6ec2;
  border-color: #1861ac;
}

/* Sticky footer styles
-------------------------------------------------- */
html {
  font-size: 14px;
}
@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.border-top {
  border-top: 1px solid #e5e5e5;
}
.border-bottom {
  border-bottom: 1px solid #e5e5e5;
}

.box-shadow {
  box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05);
}

button.accept-policy {
  font-size: 1rem;
  line-height: inherit;
}

/* Layout base styles
-------------------------------------------------- */
html {
  height: 100%;
}

body {
  height: 100%;
  margin: 0;
  overflow-x: hidden;
}
.footer {
  position: absolute;
  bottom: 0;
  width: 100%;
  white-space: nowrap;
  line-height: 60px; /* Vertically center the text there */
}

.validation-summary {
    color: red;
    font-size: smaller;
}

.report-question-block {
    margin-top: 2pc;
}

.report-sub-text {
    font-size: smaller;
    font-style: italic;
}

.report-intro-text {
    background: #eea300;
    padding: 10px;
    font-size: small;
    font-weight: bold;
}

.custom-card {
    background-color: #505050; 
}

.custom-card-header {
    background-color: #505050;
    padding: 0.5rem 0.25rem 0;
    border-bottom: none;
    color: silver;
}

.custom-card-body {
    padding: 0.25rem 0.7rem;
    font-size: 0.85em;
    font-weight:400;
}

.dropdown-menu .dropdown-toggle:after {
    border-top: .3em solid transparent;
    border-right: 0;
    border-bottom: .3em solid transparent;
    border-left: .3em solid;
}

.dropdown-menu .dropdown-menu {
    margin-left: 0;
    margin-right: 0;
}

.dropdown-menu li {
    position: relative;
}

.nav-item .submenu {
    display: none;
    position: absolute;
    left: 100%;
    top: -7px;
}

.nav-item .submenu-left {
    right: 100%;
    left: auto;
}

.dropdown-menu > li:hover {
    background-color: #f1f1f1
}

    .dropdown-menu > li:hover > .submenu {
        display: block;
    }
.textarea-dark {
    color: white;
    background: #343a40 !important;
}

.textarea-md {
    height: 100px !important;
}
.textarea-lg {
    height: 250px !important;
}

.modal-dialog {
    max-width: 70%
}

.badge-small {
    font-size: 0.7em;
    vertical-align: super;
}

textarea.form-control.height-150 {
    height: 150px;
}

textarea.form-control.json-box {
    height: 500px;
    color: white;
    background: #343a40;
}

.word-break-all {
    word-break: break-all;
}

/* Force long words/URLs to wrap in table cells */
.table td {
    word-wrap: break-word;
    word-break: break-word;
}

/* Unified layout container */
.main-layout-container {
    display: flex;
    min-height: calc(100vh - 56px);
    padding-top: 56px; /* Height of fixed navbar */
}

/* Bootstrap Dashboard-inspired sidebar styles */
.sidebar-desktop {
    width: 280px;
    height: calc(100vh - 56px);
    position: fixed;
    top: 56px;
    left: 0;
    z-index: 1000;
    background-color: #f8f9fa !important;
    border-right: 1px solid #dee2e6 !important;
}

.sidebar-content {
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0;
}

/* Main content area - unified for all layouts */
.main-content-unified {
    flex: 1;
    min-height: calc(100vh - 56px);
}

.main-content-unified.with-sidebar {
    margin-left: 280px;
}

.main-content-unified.no-sidebar {
    margin-left: 0;
}

/* Legacy main-content class for backwards compatibility */
.main-content {
    margin-left: 280px;
    min-height: calc(100vh - 56px);
    padding-top: 56px; /* Height of fixed navbar */
}

/* Dashboard-style sidebar navigation */
.sidebar-nav .nav-link {
    color: #333;
    padding: 8px 20px;
    border-radius: 0;
    font-size: 0.9rem;
}

.sidebar-nav .nav-link:hover {
    color: #007bff;
    background-color: rgba(0, 123, 255, 0.1);
}

.sidebar-nav .nav-link.active {
    color: #007bff;
    background-color: rgba(0, 123, 255, 0.1);
}

.sidebar-nav .nav-link i {
    width: 16px;
    text-align: center;
    font-size: 0.8rem;
}

.sidebar-heading {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.sidebar-section {
    margin-bottom: 1rem;
}

/* Navbar improvements */
.navbar-brand .layout-test-site {
    background: #ffc107 !important;
    color: #212529 !important;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Better mobile navbar ordering */
@media (max-width: 991.98px) {
    .navbar-brand span {
        font-size: 0.9rem;
    }
    
    /* Improve mobile navbar spacing */
    .navbar-brand {
        padding-right: 0.5rem;
    }
}


/* Mobile phone breakpoint */
@media (max-width: 575.98px) {
    .navbar-brand img {
        height: 30px;
    }
    
    /* Ensure mobile sidebar has proper spacing */
    .container-fluid.pt-5.mt-2 {
        padding-top: 4rem !important;
        margin-top: 0.5rem !important;
    }
}

/* Layout for non-authenticated users (no sidebar) */
.main-content-no-sidebar {
    min-height: calc(100vh - 56px);
    padding-top: 56px; /* Height of fixed navbar */
    width: 100%;
}

/* Dashboard-style page header (matching Bootstrap dashboard example) */
.border-bottom {
    border-bottom: 1px solid #dee2e6 !important;
}

/* Page header responsive improvements */
.page-header {
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Tablet and mobile page header adjustments */
@media (max-width: 991.98px) {
    .page-header {
        padding-top: 1rem !important; /* Reduce from pt-3 (1.5rem) to 1rem */
        padding-left: 1.5rem;
        padding-right: 1.5rem;
        margin-bottom: 1.5rem !important; /* Reduce from mb-3 (1.5rem) */
    }
}

/* Mobile phone specific adjustments */
@media (max-width: 575.98px) {
    .page-header {
        padding-top: 0.75rem !important; /* Further reduce top padding on mobile */
        padding-left: 1rem;
        padding-right: 1rem;
        margin-bottom: 1rem !important;
    }
    
    /* Better title/subtitle spacing on mobile */
    .page-header h1 {
        margin-bottom: 0.25rem;
        font-size: 1.5rem;
        font-weight: 600;
        line-height: 1.2;
    }
    
    .page-header .text-muted {
        font-size: 0.9rem;
        line-height: 1.3;
        margin-bottom: 0;
    }
}

/* Enhanced typography for page headers across all devices */
.page-header h1 {
    font-weight: 600;
    color: #343a40;
    margin-bottom: 0.5rem;
}

.page-header .text-muted {
    color: #6c757d !important;
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* Tablet-specific title improvements */
@media (min-width: 576px) and (max-width: 991.98px) {
    .page-header h1 {
        font-size: 1.75rem;
        margin-bottom: 0.375rem;
    }
    
    .page-header .text-muted {
        font-size: 0.925rem;
    }
}

/* Action buttons in header toolbar */
.btn-toolbar .btn-group .btn {
    font-size: 0.875rem;
}

/* Prevent unwanted scrollbars */
.main-content main {
    min-height: auto;
    padding-bottom: 2rem; /* Some breathing room at bottom */
}

.main-content-no-sidebar main {
    min-height: auto;
    padding-bottom: 2rem; /* Some breathing room at bottom */
}

/* Mobile responsive layout adjustments */
@media (max-width: 991.98px) {
    /* Hide desktop sidebar */
    .sidebar-desktop {
        display: none !important;
    }
    
    /* Reset main layout container for mobile */
    .main-layout-container {
        display: block;
        padding-top: 56px;
    }
    
    /* Mobile main content adjustments */
    .main-content-unified.with-sidebar {
        margin-left: 0;
    }
    
    /* Legacy main-content mobile behavior */
    .main-content {
        margin-left: 0;
        padding-top: 56px;
        min-height: calc(100vh - 56px);
    }
    
    /* Better mobile content spacing */
    .d-lg-none.container-fluid {
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* Fix mobile navigation header sizing */
@media (max-width: 767.98px) {
    .d-lg-none .h3 {
        font-size: 1.5rem;
    }
    
    .d-lg-none .small {
        font-size: 0.8rem;
    }
}

/* Back button styling for enhanced navigation */
.btn-back {
    display: inline-flex;
    align-items: center;
    color: #6c757d !important;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.375rem 0.75rem;
    border-radius: 0.25rem;
    transition: all 0.15s ease-in-out;
    margin-bottom: 1rem;
}

.btn-back:before {
    content: "← ";
    margin-right: 0.5rem;
    font-weight: bold;
}

.btn-back:hover {
    color: #495057 !important;
    background-color: #f8f9fa;
    text-decoration: none;
    transform: translateX(-2px);
}

.btn-back:focus {
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.25);
}

/* Responsive back button adjustments */
@media (max-width: 575.98px) {
    .btn-back {
        font-size: 0.85rem;
        padding: 0.25rem 0.5rem;
    }
}