/**
* BFH Science Self-Service Portal
* Copyright (C) 2025-2026 IKUS Software
*/

/* Disable text wrap for btn */
.btn {
    white-space: nowrap;
}

/* User Picture with proper aspect ratio */
img.ssp-profile-picture {
    max-width: 100%;
    max-height: 9em;
    height: auto;
    width: auto;
}

/* Make the Form labels bold */
.form-label {
    font-weight: bold;
}

/* Locked field to mimic readonly field. */
.form-control.ssp-locked {
    pointer-events: none;
    cursor: not-allowed;
    background-color: var(--bs-tertiary-bg);
}

/* Show-hide clipboard buttons */
.ssp-hover-zone .ssp-hover-show.btn-clipboard {
    opacity: 0;
}

.ssp-hover-zone:hover .ssp-hover-show.btn-clipboard {
    opacity: 1;
}

.ssp-label {
    font-weight: 700;
}

.ssp-hover-zone {
    position: relative;
}

.ssp-hover-show.btn-clipboard {
    position: absolute;
    /* Use gutter spaces to display copy button. */
    left: calc(var(--bs-gutter-x) * -1);
    top: -0.25em;
}

/* In datatable detailed section, enforce gutter to make enought space for clipboard button. */
.dtr-data-cell > .ssp-hover-zone {
    padding-left: calc(var(--bs-gutter-x) - 12px);
}

/* Show-hide for Nerd Mode */
body:not(.nerd-mode) .ssp-nerd-only {
    display: none !important;
}

/* Show icons on external link */
a.ssp-external::after {
  font-family: "bootstrap-icons";
  content: "\F1C5"; /* bi-box-arrow-up-right */
  display: inline-block;
  margin-inline-start: 0.25em;
  font-size: 0.9em;
  line-height: 1;
  vertical-align: baseline;
}

/* Show ellipsis on button opening a dialog */
.ssp-show-modal::after {
  content: "…";
  display: inline-block;
  margin-inline-start: 0;
  font-size: 0.9em;
  line-height: 1;
  vertical-align: baseline;
}

/* Center navbar search field */
.ssp-search {
    @media (min-width: 992px) {
        /* breakpoint-xl */
        margin-right: -10em;
        width: 20em;
        position: absolute;
        right: 50%;
        z-index: 1;
    }
    @media (min-width: 1200px) {
        margin-right: -13em;
        width: 26em;
    }
    @media (min-width: 1400px) {
        margin-right: -15em;
        width: 30em;
    }
}

/* Show info icon for tooltip */
.ssp-tooltip[data-bs-toggle="tooltip"]::after {
  content: "\F431"; /* bi-info-circle */
  display: inline-block;
  font-family: "bootstrap-icons";
  font-size: 1em;
  font-style: normal;
  font-variant: normal;
  font-weight: normal !important;
  line-height: 1;
  margin-inline-start: 0.25em;
  text-transform: none;
  vertical-align: -.125em;
}

.ssp-tooltip-warning[data-bs-toggle="tooltip"]::after {
  content: "\F33B"; /* bi-exclamation-triangle */
}

/* Adjust space for flash messages */
.container > .flash-messages {
  min-height: 6em;
}

/* Define background gray color. */
.bg-gray {
    background-color: var(--bs-gray);
}