/* ============================================================================
   Conserva - backend\static\branding\brand.css
   Author: ZioTitanok (v. 2026.05.29)
   ============================================================================ */

@import url("../vendor/leaflet/leaflet.css");

/* --- Variables -------------------------------------------------------------- */

:root {
    --brand-primary: #2F5F8F;
    --brand-primary-dark: #213F5F;
    --brand-accent: #A66A3F;
    --brand-danger: #A94A52;
    --brand-danger-dark: #82343C;
    --brand-ink: #1F2730;
    --brand-stone: #626D78;
    --bs-primary: #2F5F8F;
    --bs-primary-rgb: 47, 95, 143;
    --bs-danger: #A94A52;
    --bs-danger-rgb: 169, 74, 82;
    --bs-secondary-color: #626D78;
    --bs-body-color: #27313A;
    --bs-body-bg: #F3F5F7;
    --bs-link-color: #2F5F8F;
    --bs-link-hover-color: #213F5F;
    --bs-light-rgb: 247, 249, 250;
    --bs-tertiary-bg: #F7F9FA;
    --bs-border-radius: 0.375rem;
    --bs-border-color: rgba(31, 41, 51, 0.15);
    --bs-box-shadow-sm: 0 10px 28px rgba(31, 41, 51, 0.075);
    --bs-focus-ring-color: rgba(47, 95, 143, 0.2);
}

/* --- Base ------------------------------------------------------------------- */

body {
    font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
    line-height: 1.55;
}

h1, h2, h3, h4, h5, h6, .app-brand {
    color: var(--brand-ink);
    font-family: "IBM Plex Serif", Georgia, serif;
    letter-spacing: 0;
}

.app-brand {
    font-size: 1.65rem;
    letter-spacing: 0;
}

.app-version {
    font-size: 0.72rem;
    line-height: 1.15;
}

.app-beta-flag {
    align-items: center;
    bottom: 0;
    color: #ffffff;
    display: inline-flex;
    font-size: 0.68rem;
    font-weight: 800;
    height: 5.2rem;
    justify-content: center;
    letter-spacing: 0;
    line-height: 1;
    pointer-events: none;
    position: fixed;
    right: 0;
    text-indent: -999rem;
    text-transform: uppercase;
    width: 5.2rem;
    z-index: 2000;
}

.app-beta-flag::before {
    border-bottom: 5.2rem solid var(--brand-accent);
    border-left: 5.2rem solid transparent;
    bottom: 0;
    content: "";
    filter: drop-shadow(0 8px 18px rgba(32, 39, 37, 0.18));
    position: absolute;
    right: 0;
}

.app-beta-flag::after {
    bottom: 0.95rem;
    content: "BETA";
    position: absolute;
    right: 0.25rem;
    text-indent: 0;
    transform: rotate(-45deg);
}

.app-su-banner {
    align-items: center;
    background: var(--brand-ink);
    border-radius: 999px;
    bottom: 0.75rem;
    color: #ffffff;
    display: inline-flex;
    gap: 0.75rem;
    left: 50%;
    max-width: calc(100vw - 8rem);
    padding: 0.55rem 0.85rem;
    position: fixed;
    transform: translateX(-50%);
    z-index: 2100;
}

/* --- Navigation ------------------------------------------------------------- */

.app-nav .nav-link {
    --bs-nav-link-color: var(--brand-stone);
    --bs-nav-link-hover-color: var(--brand-primary);
    font-weight: 600;
}

.btn-primary {
    --bs-btn-bg: var(--brand-primary);
    --bs-btn-border-color: var(--brand-primary);
    --bs-btn-hover-bg: var(--brand-primary-dark);
    --bs-btn-hover-border-color: var(--brand-primary-dark);
    --bs-btn-active-bg: var(--brand-primary-dark);
    --bs-btn-active-border-color: var(--brand-primary-dark);
    --bs-btn-disabled-bg: var(--brand-primary);
    --bs-btn-disabled-border-color: var(--brand-primary);
}

.btn-outline-danger {
    --bs-btn-color: var(--brand-danger);
    --bs-btn-border-color: rgba(169, 74, 82, 0.55);
    --bs-btn-hover-bg: var(--brand-danger);
    --bs-btn-hover-border-color: var(--brand-danger);
    --bs-btn-active-bg: var(--brand-danger-dark);
    --bs-btn-active-border-color: var(--brand-danger-dark);
    --bs-btn-disabled-color: #8B99A5;
    --bs-btn-disabled-border-color: rgba(98, 109, 120, 0.35);
}

.form-check-input:checked {
    background-color: var(--brand-primary);
    border-color: var(--brand-primary);
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus {
    border-color: rgba(47, 95, 143, 0.45);
    box-shadow: 0 0 0 0.25rem var(--bs-focus-ring-color);
}

.table {
    --bs-table-bg: #ffffff;
    --bs-table-hover-bg: #F7F9FA;
}

.table-light {
    --bs-table-bg: #F7F9FA;
    --bs-table-border-color: rgba(31, 41, 51, 0.16);
}

/* --- Shared components ------------------------------------------------------ */

.page-title {
    font-size: 2.05rem;
    line-height: 1.05;
}

.app-page-icon {
    height: 3.25rem;
    width: 3.25rem;
}

.square-btn {
    height: 2.4rem;
    min-width: 2.4rem;
    width: 2.4rem;
}

.inspection-state-confirmed {
    background-color: #18C7FF;
    color: #062434;
}

.inspection-sheet-actions {
    display: inline-grid;
    gap: 0.25rem;
    grid-template-columns: repeat(2, 2.4rem);
    justify-content: center;
}

.inspection-sheet-actions--manager {
    grid-template-columns: repeat(3, 2.4rem);
}

.inspection-sheet-action {
    display: inline-flex;
    height: 2.4rem;
    margin: 0;
    min-width: 2.4rem;
    width: 2.4rem;
}

.inspection-sheet-action--submit,
.inspection-sheet-action--confirm {
    grid-column: 1;
}

.inspection-sheet-action--reject {
    grid-column: 2;
}

.inspection-sheet-action--edit {
    grid-column: 2;
}

.inspection-sheet-actions--manager .inspection-sheet-action--edit {
    grid-column: 3;
}

.inspection-sheet-actions--manager .inspection-sheet-action--submit {
    grid-column: 2;
}

.min-w-0 {
    min-width: 0;
}

.color-swatch {
    background-color: var(--swatch-color, transparent);
    height: 0.75rem;
    width: 0.75rem;
}

.status-toggle-badge {
    cursor: pointer;
    font-family: inherit;
    line-height: 1;
    padding: 0.35em 0.65em;
}

.status-toggle-badge:hover,
.status-toggle-badge:focus {
    filter: brightness(0.96);
    text-decoration: underline;
}

/* --- Interaction ------------------------------------------------------------ */

.drag-handle {
    align-items: center;
    cursor: grab;
    display: inline-flex;
    justify-content: center;
    min-height: 1.75rem;
    width: 1.25rem;
}

.drag-handle:active {
    cursor: grabbing;
}

.catalog-handle-column {
    max-width: 2.25rem;
    width: 2.25rem;
}

[data-catalog-row].is-dragging {
    opacity: 0.5;
}

[data-catalog-row].is-drop-before {
    box-shadow: inset 0 0.25rem 0 var(--bs-primary);
}

[data-catalog-row].is-drop-after {
    box-shadow: inset 0 -0.25rem 0 var(--bs-primary);
}

[data-material-group-rows].is-drop-inside {
    box-shadow: inset 0 0 0 0.2rem var(--bs-primary);
}

.drag-preview {
    background: #ffffff;
    border: 1px solid var(--bs-border-color);
    border-left: 0.25rem solid var(--bs-primary);
    border-radius: 0.375rem;
    color: var(--brand-ink);
    font-size: 0.9rem;
    font-weight: 600;
    left: 0;
    max-width: 22rem;
    overflow: hidden;
    padding: 0.45rem 0.65rem;
    pointer-events: none;
    position: fixed;
    text-overflow: ellipsis;
    top: 0;
    transform: translate(-200vw, -200vh);
    white-space: nowrap;
    z-index: 1080;
}

/* --- Parameters ------------------------------------------------------------- */

.catalog-name-cell .form-control,
.element-type-code-cell .form-control,
.element-type-label-cell .form-control,
.degradation-name-cell .form-control {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.degradation-loss-switch {
    min-height: 1.5rem;
    padding-left: 2.5rem;
}

.degradation-loss-switch .form-check-input {
    cursor: pointer;
    margin-left: -2.5rem;
}

.degradation-row-actions {
    display: inline-grid;
    gap: 0.5rem;
    grid-template-columns: 2.75rem 2.75rem;
    justify-content: center;
}

.degradation-action-placeholder {
    opacity: 0;
    pointer-events: none;
}

[data-drag-kind] {
    position: relative;
}

[data-degradation-row].is-dragging,
[data-drag-kind].is-dragging {
    opacity: 0.5;
}

[data-drag-kind].is-drop-before::before,
[data-drag-kind].is-drop-after::after {
    background: var(--bs-primary);
    border-radius: 999px;
    content: "";
    height: 0.2rem;
    left: 0.5rem;
    pointer-events: none;
    position: absolute;
    right: 0.5rem;
    z-index: 2;
}

[data-drag-kind].is-drop-before::before {
    top: -0.15rem;
}

[data-drag-kind].is-drop-after::after {
    bottom: -0.15rem;
}

[data-degradation-row].is-drop-before > td {
    box-shadow: inset 0 0.2rem 0 var(--bs-primary);
}

[data-degradation-row].is-drop-after > td {
    box-shadow: inset 0 -0.2rem 0 var(--bs-primary);
}

tr[data-drag-kind].is-drop-before > td {
    box-shadow: inset 0 0.2rem 0 var(--bs-primary);
}

tr[data-drag-kind].is-drop-after > td {
    box-shadow: inset 0 -0.2rem 0 var(--bs-primary);
}

.question-builder-list {
    min-height: 8rem;
}

.question-builder-item {
    cursor: pointer;
}

.question-builder-item[draggable="true"] {
    cursor: grab;
}

.question-builder-item.is-selected {
    background: rgba(var(--bs-primary-rgb), 0.08);
    border-color: var(--bs-primary) !important;
}

/* --- Credits ---------------------------------------------------------------- */

.login-notice {
    line-height: 1.35;
}

.login-notice p {
    margin-bottom: 0;
}

.credits-content h2,
.credits-content h3 {
    border-left: 0.22rem solid var(--brand-primary);
    margin: 1.4rem 0 0.85rem;
    padding-left: 0.75rem;
}

.credits-content h2:first-child,
.credits-content h3:first-child {
    margin-top: 0;
}

.credits-content h2 {
    font-size: 1.35rem;
}

.credits-content h3 {
    font-size: 1.12rem;
}

.credits-content code {
    background: rgba(47, 95, 143, 0.09);
    border-radius: 0.25rem;
    color: var(--brand-primary-dark);
    padding: 0.1rem 0.3rem;
}

.credits-content pre {
    background: var(--brand-ink);
    border-radius: var(--bs-border-radius);
    color: #ffffff;
    overflow: auto;
    padding: 1rem;
}

.credits-logo-strip {
    overflow: hidden;
}

.credits-logo-strip img {
    display: block;
    height: auto;
    max-width: 100%;
    object-fit: contain;
    width: 100%;
}

/* --- Projects --------------------------------------------------------------- */

.project-table-thumb {
    width: 64px;
    height: 64px;
}

.project-table-thumb-placeholder {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0;
}

.project-detail-carousel .carousel-control-prev,
.project-detail-carousel .carousel-control-next {
    width: 2.75rem;
    background: rgba(26, 23, 22, 0.28);
}

.project-ifc-model-canvas {
    cursor: grab;
    display: block;
    min-height: 320px;
}

.project-ifc-model-canvas.is-dragging {
    cursor: grabbing;
}

.report-risk-subelement-cell {
    min-width: 300px;
    width: 32%;
}

.report-risk-subelement {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.report-risk-subelement-code {
    color: var(--bs-emphasis-color);
    font-size: 1.02rem;
    font-weight: 700;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.report-risk-subelement-detail {
    color: var(--bs-secondary-color);
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.report-risk-score-cell {
    vertical-align: middle;
    width: 5rem;
}

.report-risk-score {
    align-items: center;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    justify-content: flex-start;
}

.report-risk-score-label {
    color: var(--bs-secondary-color);
    line-height: 1.25;
    min-height: 2.5rem;
    text-align: center;
}

.report-risk-trend-cell {
    min-width: 300px;
    vertical-align: middle;
    width: 300px;
}

.report-risk-trend-panel {
    background:
        linear-gradient(180deg, rgba(248, 250, 252, 0.98), rgba(255, 255, 255, 0.96)),
        repeating-linear-gradient(
            0deg,
            rgba(15, 23, 42, 0.04) 0,
            rgba(15, 23, 42, 0.04) 1px,
            transparent 1px,
            transparent 24px
    );
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 6px;
    height: 104px;
    padding: 7px 10px 5px;
    width: 280px;
}

.report-risk-trend-chart {
    display: block;
    height: 92px;
    max-width: 100%;
    width: 260px;
}

.project-location-map {
    height: 260px;
    min-height: 220px;
}

.project-detail-map,
.project-detail-carousel,
.project-detail-image-empty {
    aspect-ratio: 4 / 3;
    flex: 0 0 auto;
    width: 100%;
}

.project-detail-map,
.project-detail-carousel {
    overflow: hidden;
}

.project-map-legend-marker {
    display: block;
    flex: 0 0 auto;
    height: 24px;
    object-fit: contain;
    width: 15px;
}

.project-detail-carousel {
    background: var(--bs-tertiary-bg);
    position: relative;
}

.project-detail-carousel .carousel-inner {
    inset: 0;
    position: absolute;
}

.project-detail-carousel .carousel-item {
    height: 100%;
}

.project-detail-image-empty {
    min-height: 16rem;
}

.inspection-facade-choice {
    display: grid;
    grid-template-columns: 2rem minmax(9rem, 12rem) minmax(0, 1fr);
}

.inspection-facade-choice:has(.form-check-input:checked) {
    background: rgba(var(--bs-primary-rgb), 0.04);
    border-color: rgba(var(--bs-primary-rgb), 0.45);
}

.inspection-facade-preview {
    aspect-ratio: 2 / 1;
}

.ifc-upload-strip {
    grid-template-columns: minmax(0, 1fr) minmax(10rem, 14rem);
}

#ifc-preview-meta {
    grid-column: 1 / -1;
}

.ifc-change-new {
    border-color: rgba(23, 131, 74, 0.42);
    box-shadow: inset 4px 0 0 #17834a;
}

.ifc-change-updated {
    border-color: rgba(166, 106, 63, 0.48);
    box-shadow: inset 4px 0 0 #a66a3f;
}

.ifc-sub-table tr.ifc-change-new > * {
    --bs-table-bg: rgba(23, 131, 74, 0.08);
}

.ifc-sub-table tr.ifc-change-updated > * {
    --bs-table-bg: rgba(166, 106, 63, 0.12);
}

.ifc-facade-accordion .accordion-button,
.ifc-facade-accordion .accordion-button:not(.collapsed) {
    background-color: #fff;
    color: inherit;
}

.ifc-scene-canvas {
    height: 28rem;
}

.ifc-scene-placeholder {
    pointer-events: none;
}

.ifc-elevation-canvas {
    height: 26rem;
}

.ifc-element-canvas {
    aspect-ratio: 2 / 1;
    max-height: 14rem;
}

.ifc-scroll-target {
    scroll-margin-top: 5.5rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ifc-scroll-target.is-ifc-scroll-highlight {
    border-color: rgba(var(--bs-primary-rgb), 0.68) !important;
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.12), inset 4px 0 0 var(--bs-primary);
}

/* --- Weather ---------------------------------------------------------------- */

.weather-map-placeholder {
    min-height: 320px;
}

.weather-leaflet-map {
    height: min(72vh, 720px);
    min-height: 420px;
    width: 100%;
}

.weather-wind-vector-icon {
    background: transparent;
    border: 0;
}

.weather-wind-vector {
    align-items: center;
    display: flex;
    height: 4.5rem;
    justify-content: center;
    transform: rotate(var(--wind-angle, 0deg));
    transform-origin: 50% 50%;
    width: 4.5rem;
}

.weather-wind-vector-arrow {
    background: var(--wind-color, #0f766e);
    border-radius: 999px;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.75);
    display: block;
    height: 0.24rem;
    position: relative;
    width: var(--wind-length, 2rem);
}

.weather-wind-vector-arrow::before {
    background: var(--wind-color, #0f766e);
    border-radius: 999px;
    content: "";
    height: 0.42rem;
    left: -0.2rem;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 0.42rem;
}

.weather-wind-vector-arrow::after {
    border-bottom: 0.42rem solid transparent;
    border-left: 0.64rem solid var(--wind-color, #0f766e);
    border-top: 0.42rem solid transparent;
    content: "";
    position: absolute;
    right: -0.38rem;
    top: 50%;
    transform: translateY(-50%);
}

.weather-wind-vector-popup {
    min-width: 12rem;
}

.weather-wind-vector-legend {
    align-items: center;
    display: inline-flex;
    height: 1.6rem;
    justify-content: center;
    width: 2.6rem;
}

.weather-wind-vector-legend .weather-wind-vector-arrow {
    --wind-color: #0f766e;
    --wind-length: 1.8rem;
}

.weather-gradient-scale {
    background: var(--weather-gradient);
    border-radius: var(--bs-border-radius-sm);
    display: inline-block;
    height: 78px;
    width: 14px;
}

.weather-sensor-chart {
    background: #ffffff;
    height: 180px;
    width: 100%;
}

.weather-graph-card {
    background: #ffffff;
}

.weather-chart-period-list {
    display: grid;
    gap: 0.45rem;
}

.weather-chart-period:not(:last-child) {
    border-bottom: 1px solid var(--bs-border-color);
    padding-bottom: 0.45rem;
}

.weather-chart-period-label {
    color: var(--brand-stone);
    font-weight: 600;
    max-width: 100%;
}

.weather-sensor-chart-lg {
    height: 260px;
}

.weather-sensor-icon {
    --weather-sensor-icon-size: 2rem;
    align-items: center;
    aspect-ratio: 1 / 1;
    background: #ffffff;
    border: 1px solid var(--brand-ink);
    border-radius: 50%;
    box-sizing: border-box;
    color: var(--brand-ink);
    display: inline-flex;
    flex: 0 0 var(--weather-sensor-icon-size);
    height: var(--weather-sensor-icon-size);
    justify-content: center;
    line-height: 1;
    max-height: var(--weather-sensor-icon-size);
    max-width: var(--weather-sensor-icon-size);
    min-height: var(--weather-sensor-icon-size);
    min-width: var(--weather-sensor-icon-size);
    width: var(--weather-sensor-icon-size);
}

.weather-sensor-icon.is-active {
    background: #eaf4ee;
    border-color: #17834a;
    color: #17834a;
}

.weather-sensor-set {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.weather-sensor-set-icon {
    --weather-sensor-icon-size: 1.65rem;
    font-size: 0.8rem;
}

.weather-sensor-choice {
    align-items: center;
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius);
    display: inline-flex;
    gap: 0.35rem;
    min-height: 2rem;
    padding: 0.25rem 0.5rem;
}

.weather-sensor-choice.form-check {
    padding-left: 0.5rem;
}

.weather-sensor-choice .form-check-input {
    flex: 0 0 auto;
    float: none;
    margin-left: 0;
    margin-top: 0;
}

.weather-sensor-choice .form-check-label {
    align-items: baseline;
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.weather-sensor-choice:has(.form-check-input:checked) {
    background: #eaf4ee;
    border-color: #17834a;
}

.weather-visual-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(13rem, 0.9fr) minmax(18rem, 1.4fr) minmax(16rem, 1fr);
}

.weather-score-chart-shell {
    height: 12rem;
    max-width: 12rem;
    position: relative;
    width: 100%;
}

.weather-score-chart-shell canvas {
    height: 100% !important;
    width: 100% !important;
}

.weather-score-chart-center {
    align-items: center;
    background: #ffffff;
    border-radius: 999px;
    display: flex;
    flex-direction: column;
    height: 7.1rem;
    justify-content: center;
    left: 50%;
    pointer-events: none;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 7.1rem;
}

.weather-score-gauge-value {
    color: var(--brand-ink);
    font-size: 2.35rem;
    font-weight: 800;
    line-height: 1;
}

.weather-score-gauge-label {
    color: var(--brand-stone);
    font-size: 0.86rem;
    font-weight: 700;
}

.weather-top-list {
    display: grid;
    gap: 0.65rem;
}

.weather-top-item {
    align-items: center;
    display: grid;
    gap: 0.65rem;
    grid-template-columns: 2.25rem minmax(0, 1fr);
}

.weather-top-icon {
    align-items: center;
    background: #F4F7F9;
    border-radius: 999px;
    color: var(--brand-primary);
    display: inline-flex;
    height: 2.25rem;
    justify-content: center;
    width: 2.25rem;
}

.weather-top-icon--rain {
    background: #EAF4FB;
    color: #1677a7;
}

.weather-top-icon--humidity {
    background: #E7F5F2;
    color: #0f766e;
}

.weather-top-icon--cold {
    background: #EAF0F8;
    color: #2F5F8F;
}

.weather-top-icon--heat,
.weather-top-icon--temperature {
    background: #FBEDEF;
    color: var(--brand-danger);
}

.weather-chart-box {
    height: 13rem;
    min-width: 0;
    position: relative;
}

.weather-chart-box canvas {
    height: 100% !important;
    width: 100% !important;
}

.weather-chart-box--timeline {
    height: 12rem;
}

#station-detail-map {
    height: 360px;
    min-height: 320px;
    width: 100%;
}

#weather-stations-map {
    height: min(76vh, 760px);
    min-height: 520px;
    width: 100%;
}

/* --- Directory -------------------------------------------------------------- */

.permission-board-head {
    align-items: center;
    background: #f7f9fa;
    border-bottom: 1px solid var(--bs-border-color);
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    min-height: 3.1rem;
    padding: 0.7rem 1rem;
}

.permission-board-title {
    color: var(--brand-ink);
    font-weight: 700;
}

.permission-role-row + .permission-role-row {
    border-top: 1px solid var(--bs-border-color);
}

.permission-role-layout {
    display: grid;
    gap: 0.85rem;
    grid-template-columns: 1fr;
    padding: 1rem;
}

.permission-role-handle {
    margin-top: 0;
}

.permission-role-handle.is-disabled {
    opacity: 0.35;
}

.permission-module-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    min-width: 0;
}

.permission-module-panel {
    background: #ffffff;
    border: 1px solid var(--bs-border-color);
    border-radius: 0.375rem;
    min-width: 0;
    overflow: hidden;
}

.permission-module-header,
.permission-feature-row {
    align-items: center;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(0, 1fr) auto;
}

.permission-module-header {
    background: #f7f9fa;
    min-height: 3.25rem;
    padding: 0.55rem 0.65rem;
}

.permission-module-access {
    align-items: center;
    display: inline-flex;
    gap: 0.45rem;
    justify-self: end;
    margin: 0;
    min-height: 2rem;
}

.permission-module-access .form-check-input {
    cursor: pointer;
    height: 1.25rem;
    margin: 0;
    width: 2.35rem;
}

.permission-module-access .form-check-label {
    color: var(--brand-stone);
    font-size: 0.86rem;
    font-weight: 600;
}

.permission-module-title {
    align-items: center;
    color: var(--brand-ink);
    display: inline-flex;
    font-weight: 700;
    gap: 0.45rem;
    min-width: 0;
}

.permission-module-title span,
.permission-feature-label {
    min-width: 0;
    overflow-wrap: anywhere;
}

.permission-feature-list {
    border-top: 1px solid var(--bs-border-color);
}

.permission-module-off {
    border-top: 1px solid var(--bs-border-color);
    font-size: 0.9rem;
    padding: 0.7rem 0.65rem;
}

.permission-module-panel:not(.is-disabled) .permission-module-off {
    display: none;
}

.permission-module-panel.is-disabled {
    background: #fbfcfd;
}

.permission-module-panel.is-disabled .permission-feature-list {
    display: none;
}

.permission-module-panel.is-disabled .permission-module-title {
    color: var(--brand-stone);
}

.permission-feature-row {
    min-height: 2.9rem;
    padding: 0.45rem 0.65rem;
}

.permission-feature-row + .permission-feature-row {
    border-top: 1px solid rgba(31, 41, 51, 0.09);
}

.permission-feature-label {
    color: var(--brand-stone);
    font-size: 0.9rem;
}

.permission-cell {
    flex-shrink: 0;
    white-space: nowrap;
}

.permission-cell .btn {
    align-items: center;
    display: inline-flex;
    height: 2rem;
    justify-content: center;
    padding: 0;
    width: 2.1rem;
}

.permission-cell .btn-check:disabled + .btn,
.permission-cell .btn.disabled {
    background: #f3f5f7;
    border-color: #d8dee4;
    color: #9aa4ae;
    opacity: 0.55;
    pointer-events: none;
}

.audit-data-table .col-when   { width: 11rem; }
.audit-data-table .col-actor  { width: 12rem; }
.audit-data-table .col-action { width: 9rem;  }
.audit-data-table .col-target { width: 14rem; }

.user-filter-search {
    min-width: min(100%, 16rem);
}

.user-filter-role   { min-width: 12rem; }
.user-filter-status { min-width: 9rem;  }

.fixed-col-table {
    table-layout: fixed;
}

.fixed-col-table td,
.fixed-col-table th {
    overflow: hidden;
}

/* --- Responsive ------------------------------------------------------------- */

@media (min-width: 992px) {
    .project-location-map {
        height: 240px;
    }
}

@media (max-width: 991.98px) {
    .project-detail-image-empty {
        min-height: 14rem;
    }

    .permission-module-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .ifc-upload-strip {
        grid-template-columns: 1fr;
    }

    .ifc-scene-canvas {
        height: 20rem;
    }

    .ifc-elevation-canvas {
        height: 18rem;
    }

    .permission-module-grid {
        grid-template-columns: 1fr;
    }

    .app-main {
        padding-left: 0.75rem !important;
        padding-right: 0.75rem !important;
    }

    .page-title {
        font-size: 1.55rem;
    }

    .app-page-header-body {
        gap: 0.75rem !important;
        padding: 1rem;
    }

    .app-page-icon {
        display: none !important;
    }

    .app-page-actions {
        justify-content: flex-end;
        width: 100%;
    }

    .project-ifc-model-canvas {
        min-height: 360px;
    }

    .inspection-facade-choice {
        grid-template-columns: 2rem minmax(0, 1fr);
    }

    .inspection-facade-preview {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    #weather-stations-map {
        height: 68vh;
        min-height: 420px;
    }

    .weather-leaflet-map {
        height: 62vh;
        min-height: 380px;
    }

    .weather-sensor-chart {
        min-height: 170px;
    }

    .weather-visual-grid {
        grid-template-columns: 1fr;
    }

    .weather-score-chart-shell {
        height: 10.5rem;
        max-width: 10.5rem;
    }

    .weather-score-chart-center {
        height: 6.2rem;
        width: 6.2rem;
    }

    .weather-chart-box {
        height: 12rem;
    }

    .app-su-banner {
        align-items: flex-start;
        border-radius: var(--bs-border-radius);
        bottom: 0.75rem;
        flex-direction: column;
        font-size: 0.85rem;
        gap: 0.25rem;
        left: 0.75rem;
        max-width: calc(100vw - 6.75rem);
        transform: none;
    }
}

@media (max-width: 575.98px) {
    .permission-board-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .permission-role-layout {
        gap: 0.75rem;
        padding: 0.85rem;
    }

    .permission-role-handle {
        align-self: center;
        justify-self: center;
    }

    .permission-module-header,
    .permission-feature-row {
        align-items: center;
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .permission-cell {
        justify-self: end;
    }

    .permission-module-access {
        justify-self: end;
    }

    .user-filter-search {
        min-width: calc(100% - 3rem);
    }

    .user-filter-role,
    .user-filter-status {
        flex: 1 1 8rem;
    }
}
