@import url('https://fonts.googleapis.com/css?family=Inter:400,500,600,700,800,900&display=swap');

/* Therapeutic Discovery - Application Styles */

/* Theme Color - Change this to customize the app theme */
:root {
    --td-primary: #0d9488; /* Teal - change this to customize theme */
}

body, html {
    font-family: "Inter", sans-serif;
}

/* Bootstrap Overrides */

input.form-control, select.form-select {
    max-width: 280px;
}

textarea.form-control {
    max-width: 350px;
}

.btn {
    font-weight: 500;
    border-width: 2px;
}

.nav.nav-tabs > .nav-item {
    font-weight: bold;
}

.nav.nav-tabs > .nav-item > .nav-link.active {
    font-weight: bold;
    border-top: solid 2px var(--td-primary);
}

.navbar .nav-link.active {
    background-color: #e9ecef;
    border-radius: 5px;
    color: var(--td-primary);
}

.form-label, .form-check-label {
    font-weight: bold;
}

.popover {
    font-family: "Inter", sans-serif;
}

.alert p {
    margin-bottom: 0;
    margin-top: 10px;
}

/* End Bootstrap Overrides */

/* Page Header */

header.page-header .float-start {
    position: absolute;
    left: 15px;
}

header.page-header .float-end {
    position: absolute;
    right: 15px;
}

header.page-header h1, header.page-header h2 {
    text-align: center;
    margin-top: 0;
    font-weight: bold;
}

header.page-header.heading-left h1, header.page-header.heading-left h2 {
    text-align: left !important;
}

/* Custom Colors */

.text-td-primary {
    color: var(--td-primary);
}

.text-indigo-500 {
    color: #6610f2;
}

.text-orange-500 {
    color: #fd7e14 !important;
}

.text-purple-500 {
    color: #6f42c1 !important;
}

.border-orange-500 {
    border-color: #fd7e14 !important;
}

/* Scroll Containers */

.scroll-details-40 {
    overflow-y: auto;
    position: relative;
    height: 40vh;
}

.scroll-details-50 {
    overflow-y: auto;
    position: relative;
    height: 50vh;
}

.scroll-details-60 {
    overflow-y: auto;
    position: relative;
    height: 60vh;
}

.scroll-details-70 {
    overflow-y: auto;
    position: relative;
    height: 70vh;
}

.scroll-details-75 {
    overflow-y: auto;
    position: relative;
    height: 75vh;
}

.scroll-details-80 {
    overflow-y: auto;
    position: relative;
    height: 80vh;
}

.scroll-details-90 {
    overflow-y: auto;
    position: relative;
    height: 90vh;
}

/* Table Sticky Headers */

table.table-scroll thead td {
    position: sticky;
    top: 0;
    white-space: nowrap;
    z-index: 200;
}

table.table-scroll thead th {
    position: sticky;
    top: 0;
    white-space: nowrap;
    z-index: 100;
    background-color: #fff;
}

table.table-scroll thead > tr:nth-child(2) th {
    top: 39px;
}

table.table-scroll tfoot td {
    position: sticky;
    bottom: 0;
    white-space: nowrap;
    z-index: 100;
}

/* Alpine.js */

[x-cloak] {
    display: none !important;
}

/* Filters */

.filters input, .filters select {
    border-width: 2px !important;
}

.filters .input-group-text {
    border-width: 2px !important;
    border-left-width: 1px !important;
}

/* Section Headers */

.section-header {
    margin-top: 40px;
    margin-bottom: 20px;
    border-bottom: solid 3px #eeeeee;
}

.section-header h2 {
    font-weight: bold;
}

/* People picker */

.people-picker-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    overflow: hidden;
}

.people-picker-dropdown .list-group-item {
    white-space: normal;
}

/* Trix Editor */

.trix-container {
    max-width: 100%;
    background-color: #fff;
}

trix-toolbar .trix-button-group {
    margin-bottom: 0;
}

.rich-text h1, .rich-text h2, .rich-text h3 {
    margin-top: 0.5em;
    margin-bottom: 0.25em;
}

.rich-text ul, .rich-text ol {
    margin-bottom: 0.5em;
}

/* Activity Timeline */

.activity-date-header {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8f9fa;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.25rem;
    border-bottom: 1px solid #e5e7eb;
    font-weight: 600;
    font-size: 0.8rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    border-bottom: 1px solid #f3f4f6;
}

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

.activity-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.85rem;
    margin-top: 2px;
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-description {
    line-height: 1.5;
}
