/* CSS Custom Properties for consistent font usage */
:root {
    --font-family-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-family-mono: 'JetBrains Mono', 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    --font-weight-light: 300;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;
    --font-weight-black: 900;
}

/* Mobile Bottom Navigation Toolbar */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1a1a1a;
    border-top: 1px solid #333;
    z-index: 1000;
    padding: 1px 0px 1px 0px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

.mobile-bottom-nav .nav-item {
    flex: 1;
    text-align: center;
    padding: 8px 4px;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.mobile-bottom-nav .nav-item:hover,
.mobile-bottom-nav .nav-item.active {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.1);
}

.mobile-bottom-nav .nav-item .material-symbols-outlined {
    font-size: 24px;
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

.mobile-bottom-nav .nav-item .nav-label {
    font-size: 11px;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    line-height: 1.2;
}

/* Adjust body padding to account for mobile toolbar */
@media (max-width: 768px) {
    body {
        padding-bottom: 100px !important;
    }
    
    .mobile-bottom-nav {
        display: flex;
    }
}

body { 
    background-color: #f3f3f5; 
    font-family: var(--font-family-primary);
    font-weight: var(--font-weight-normal);
    font-size: 1.1rem;
    color: #1d1d1f; 
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

.logo {
    width: 48px;
    height: 48px;
    margin-right: 8px;
    vertical-align: middle;
}

.mb-6 { 
    margin-bottom: 1.5rem; 
}

.mt-6 { 
    margin-top: 3.5rem; 
}

.mb-4 { 
    font-weight: var(--font-weight-extrabold); 
}

.title { 
    font-size: 1.75rem !important;
    font-weight: var(--font-weight-bold); 
    color: #FFF; 
    margin-right: 30px; 
    letter-spacing: -0.025em;
}

.title:hover { 
    color: #999; 
}

.navbar a, .navbar button { 
    margin-top: 0px; 
    font-size: 1.125rem;
    font-weight: var(--font-weight-semibold);
    letter-spacing: -0.02em;
}

.navbar-nav .nav-item {
    margin-right: 0.75rem;
}

.navbar-nav .nav-item:last-child {
    margin-right: 0;
}

.user, .small {
    font-size: 0.875rem;
    color: #BBB !important;
    font-style: italic;
    padding-right: 10px;
    font-weight: var(--font-weight-normal);
}

.italic { 
    font-style: italic; 
}

.dim { 
    color: #888; 
}

.container {     
    gap: 3rem;
    flex-direction: column;
    justify-content: center;
    display: flex;
    align-items: center;
    margin-top: 50px; 
}

.container-tight {
    gap: 1rem;
}

.page-title { 
    display: flex; 
    justify-content: flex-end; 
    align-items: flex-end; 
    width: 100%; 
}

.page-title h1 { 
    margin: 0; 
}

.sustaining-alert {
    background-color: #0d6efd;
    transition: all 0.2s ease-in-out;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .3);
}

.sustaining-alert:hover {
    background-color: #0b5ed7;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.sustaining-alert .flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sustaining-alert .flex-none {
    flex: 0 0 auto;
}

.sustaining-alert .flex-1 {
    flex: 1 1 0%;
}

.card-dashboard { 
    width: 100%; 
    border: none; 
    border-radius: 12px; 
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05); 
    padding: 2rem; 
    background-color: #ffffff; 
}

.card-history {
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.2); 
    background-color: #fafafa;
}

.sustaining-card { 
    font-size: larger;
}

.sustaining-card, .card { 
    padding: 1.0em !important; 
}

.card { 
    width: 100%; 
    max-width: 720px; 
    border: none; 
    border-radius: 12px; 
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05); 
    padding: 1.5em; 
    background-color: #ffffff; 
    margin-bottom: 20px;
}

.card-body {
    padding: 0;
}

.card-body-small { 
    padding: 0.75rem 1.25rem !important;
}

.note-card .card {
    border: none;
    background-color: #f8f9fa;
    margin-bottom: 0.5rem;
}

.d-flex.justify-content-between.align-items-start {
    margin-bottom: 0.25rem !important;  /* Reduces space between date and note */
}

.note-card p {
    margin-top: 0;  /* Removes top margin from note text */
    line-height: 1.4;  /* Tightens line height for note text */
}

.note-card:last-child .card {
    margin-bottom: 0;
}

.text-muted {
    font-size: 0.875rem;
}

.card-header { 
    margin-bottom: 2rem; 
}

.btn {
    height: 45px;  /* Set fixed height for all buttons */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-size: 1.1rem; /* Increased from 1rem */
    line-height: 1.5;
    font-family: var(--font-family-primary);
    font-weight: var(--font-weight-medium);
    letter-spacing: -0.01em;
}

.btn-short {
    height: 30px;
}

.btn-primary:hover { 
    background-color: #0062cc; 
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.btn-primary:disabled {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.btn-link:disabled {
    color: #6c757d;
}

/* Override default button height for small buttons */
.btn-sm.py-0 {
    height: auto !important;
    line-height: 1.5;
    padding-top: 2px !important;
    padding-bottom: 2px !important;
}

/* Ensure icons in small buttons are properly sized */
.btn-sm .fa-xs {
    font-size: 0.65rem;
    margin-right: 3px;
}

.material-symbols-outlined {
  font-variation-settings:
  'FILL' 0,
  'wght' 400,
  'GRAD' 0,
  'opsz' 48
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.2em;
    margin-right: 0.5rem;
}

.form-label { 
    font-weight: var(--font-weight-medium);
    font-size: 1rem;
    color: #495057;
    margin-bottom: 0.5rem;
}

.form-control, .form-select { 
    font-family: var(--font-family-primary);
    font-size: 1.2rem;
    font-weight: var(--font-weight-semibold);
    height: 55px;
    border-radius: 8px; 
    border: 2px solid #bfbfc1;
    padding: 8px; 
}

.search {
    height: 45px;
    font-size: 1.0rem;
}

.notes{
    height: 145px;
}

.form-check-input { 
    border-radius: 4px; 
}

.select2-container--default .select2-selection--single { 
    display: flex; 
    flex: 1; 
    border: 2px solid #bfbfc1; 
    border-radius: 8px; 
    height: 55px; 
    padding: 5px 10px; 
}

.select2-container--default .select2-selection__rendered { 
    display: flex; 
    flex: 1; 
    line-height: 40px !important; 
    color: #1d1d1f;
}

.select2-selection__rendered { 
    line-height: 28px; 
    color: #1d1d1f; 
    font-size: 1.3rem; 
    line-height: 40px !important; 
    font-weight: 500; 
}

.select2-container--default .select2-selection__arrow { 
    height: 90px; 
}

.select2-results__options .select2-results__message,
.select2-search {
    background-color: #f3f3f5;
}

.select2-search__field {
    padding: 8px !important;
    line-height: 30px; 
}

.btn-link { 
    color: #FFF; 
}

#approve-all-btn { 
    color: #007aff; 
    margin-left: auto;
}

.btn-link:hover { 
    color: #CCC; 
}

th a {
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

th a:hover {
    text-decoration: underline;
}

.approval-log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0px;
}

.completed-callings {
    opacity: 0.6;
}

.table {
    margin-bottom: 0;
}

.table-muted {
    color: #6c757d;
}

.table-muted a {
    color: #495057;
}

.table-muted strong {
    color: #495057;
}

.circled-number {
  width: 1.5em;
  height: 1.5em;
  line-height: 1.5em; /* Centers text vertically */
  text-align: center; /* Centers text horizontally */
  background-color: #0d6efd; /* Optional: Add a background color for the circle */
  border-radius: 50%; /* Creates the circle shape */
  display: inline-block; /* Allows the circle to be styled like a block element */
  color: #FFF; /* Optional: Set the text color */
  font-weight: bold; /* Optional: Make the number bold */
  font-size: 1em; /* Optional: Set the font size */
}

/* MY ASSIGNMENTS */

.assignments-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    margin-top: 1.5rem;
}

.assignment-card {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.assignment-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.assignment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: #f8f9fa;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.assignment-date {
    font-size: 0.875rem;
    color: #6c757d;
}

.status-badge {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 500;
    background: #e9ecef;
    color: #495057;
}

.tag-badge {
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.75) !important;
}

.assignment-body {
    padding: 1.25rem;
    flex: 1;
}

.assignment-title {
    font-size: 1.375rem;
    font-weight: var(--font-weight-semibold);
    margin-bottom: 0.5rem;
}

.assignment-title a {
    color: #0d6efd;
    text-decoration: none;
}

.assignment-title a:hover {
    text-decoration: underline;
}

.assignment-org {
    color: #6c757d;
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.assignment-details {
    margin: 1rem 0;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    padding: 0.3rem 0;
}

.recommended {
    /* padding: 0.3rem .75rem; */
    /* border: 1px solid #EEE; */
    /* border-radius: 25px; */
    font-size: 1.125rem;
}

.detail-label {
    color: #6c757d;
    font-weight: 500;
}

.detail-value {
    color: #212529;
    font-weight: var(--font-weight-extrabold); 
}

.assignment-description {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: #6c757d;
}

.assignment-footer {
    padding: 1rem;
    background: #f8f9fa;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.no-assignments {
    grid-column: 1 / -1;
    padding: 2rem;
    text-align: center;
}

/* MODALS */
.modal-backdrop {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1000 !important;
    pointer-events: none !important;
    -webkit-tap-highlight-color: transparent;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1100 !important;
    -webkit-overflow-scrolling: touch;
}

.modal-dialog {
    position: relative;
    z-index: 1105 !important;
    pointer-events: auto !important;
    margin: 0.5rem auto;
}

.modal-content {
    position: relative;
    z-index: 1110 !important;
    pointer-events: auto !important;
}

.modal-footer .btn {
    pointer-events: auto !important;
    touch-action: manipulation !important;
    -webkit-user-select: none;
    user-select: none;
    min-height: 44px;
    padding: 12px 20px;
    position: relative;
    z-index: 1115 !important;
}

.footer-container {
    display: block;
    margin: 40px 250px;
    gap: 0;
    align-items: unset;
    justify-content: unset;
    flex-direction: unset;
}


@supports (-webkit-touch-callout: none) {
    .modal-open {
        position: fixed;
        width: 100%;
        height: 100%;
    }

    .modal {
        -webkit-transform: none !important;
        transform: none !important;
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
    }

    .modal-content {
        -webkit-transform: none !important;
        transform: none !important;
        touch-action: manipulation;
        -webkit-user-select: none;
        user-select: none;
    }

    .modal-dialog {
        transform: none !important;
        margin: 1rem auto !important;
        max-width: calc(100% - 2rem) !important;
    }
}

@media (max-width: 1400px) {
    .container-lg {
        max-width: 1300px;
    }

    .container {
        max-width: 1300px;
    }
    
    .assignments-grid {
        display: grid;
        gap: 2.5rem;
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }

    .footer-container {
        margin: 40px 100px;
    }
    
}

@media (max-width: 768px) {
    .assignments-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 0;  /* Remove padding on mobile */
    }

    .card-dashboard {
        padding: 1rem;  /* Remove left padding on mobile to align with grid */
    }

    .assignment-card {
        margin-bottom: 1rem;
    }

    .detail-row {
        flex-direction: column;
        gap: 0.25rem;
    }

    .detail-value {
        margin-left: 1rem;
    }

    
    .modal-footer .btn {
        min-height: 44px;
        padding: 12px 20px;
        margin: 4px;
        font-size: 16px;
    }

    .btn-close {
        padding: 12px !important;
        margin: -12px -12px -12px auto !important;
    }

    h1 {
        font-size: 2rem; /* Increased from 1.75rem */
    }
    
    h2 {
        font-size: 1.5rem; /* Increased from 1.375rem */
    }
    
    h3 {
        font-size: 1.25rem; /* Increased from 1.125rem */
    }
    
    .title {
        font-size: 1.5rem !important; /* Increased from 1.25rem */
    }
    
    .assignment-title {
        font-size: 1.25rem; /* Increased from 1rem */
    }
    
    .btn {
        font-size: 1rem; /* Increased from 0.9rem */
    }
    
    .table th,
    .table td {
        font-size: 0.9rem; /* Increased from 0.8rem */
    }

    .footer-container {
        margin: 40px 50px;
    }
}

/* Ensure navbar doesn't interfere */
.navbar.fixed-top {
    z-index: 1030 !important;
}

/* Avoid stacking context issues with container */
.container {
    position: static !important;
    z-index: auto !important;
}

/* Typography improvements */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-primary);
    font-weight: var(--font-weight-semibold);
    letter-spacing: -0.025em;
    line-height: 1.2;
}

h1 {
    font-weight: var(--font-weight-bold);
    font-size: 2.25rem;
}

h2 {
    font-weight: var(--font-weight-semibold);
    font-size: 1.75rem;
}

h3 {
    font-weight: var(--font-weight-medium);
    font-size: 1.5rem;
}

hr {
    border-color: #f8f9fa;
}

.btn {
    font-family: var(--font-family-primary);
    font-weight: var(--font-weight-medium);
    letter-spacing: -0.01em;
}

.card-header h3 {
    font-size: 1.75rem;
    font-weight: var(--font-weight-bold);
    letter-spacing: -0.05em;
    color: #1d1d1f;
    margin-bottom: 0.5rem;
}

.assignment-title {
    font-weight: var(--font-weight-semibold);
    font-size: 1.375rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
}

.assignment-org {
    font-weight: var(--font-weight-medium);
    color: #6c757d;
    font-size: 1rem;
}

.status-badge {
    font-weight: var(--font-weight-medium);
    font-size: 0.95rem;
}

.table th {
    font-weight: var(--font-weight-semibold);
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.table td {
    font-size: 1rem;
    line-height: 1.4;
}

.modal-title {
    font-weight: var(--font-weight-semibold);
    font-size: 1.375rem;
}

/* Monospace font for code elements */
code, pre, .mono {
    font-family: var(--font-family-mono);
    font-size: 0.95rem; /* Increased from 0.875rem */
}

/* Improve text selection */
::selection {
    background-color: #0d6efd;
    color: white;
}

::-moz-selection {
    background-color: #0d6efd;
    color: white;
}

