html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  height:100vh;
  overflow-x:hidden;
}


h1, h2 {
    color: var(--tertiaryText) !important;
    font-weight: bold;
}

h1 {
    font-size: 1.4em;
}

h2 {
    font-size: 1.1em;
}

.modal a {
    color: var(--tertiaryText);
    font-weight: bold;
    text-decoration: none;
}

a img {
    border:none;
}

a .tree-link {
    text-decoration: none;
}

.container {
    max-height: calc(100vh - 72px);
    /*overflow-y: auto;*/
}

main[role="main"] {
    height: 100%;
}

header {
    background: var(--primary);
    color: var(--secondary);
}

    header .nav-link {
        color: var(--secondary) !important;
        font-weight: 700 !important;
    }

    header img {
        height: 2em;
    }

    header .dropdown-item.active, .dropdown-item:active {
        background: #fff !important;
        color: var(--secondary) !important;
    }

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'><path stroke='%2346E3B1' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/></svg>") !important;
}

.btn-primary, .page-link, .page-link:active, .page-link:hover, thead, .nav-link.active {
    color: var(--primaryText) !important;
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
}

.btn-secondary, .btn-secondary.active, .btn-secondary:hover {
    color: var(--secondaryText) !important;
    font-weight: bold !important;
    background-color: var(--secondary) !important;
    border-color: var(--secondary) !important;
}

.nav-link {
    color: var(--tertiaryText) !important;
    font-weight: 700;
}

.modal-dialog {
    margin-top: 96px !important;
    margin-bottom: 0px;
}

.readonly-ui {
    pointer-events: none;
    background-color: #e9ecef !important;
    color: #495057 !important;
}

#questionContainer {
    /*max-height: calc(100vh - 130px);*/
    height: auto; /* Höhe passt sich dem Inhalt an */
    display: block; /* Standard-Layout-Verhalten */
    overflow: visible; /* Inhalt nicht verstecken */
    position: relative;
}

.question-card {
    text-align: left !important; /* Text links */
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: .25rem;
    /*max-width: 500px;*/
    /*width: 100%;*/
    box-sizing: border-box;
}

.answers {
    text-align: left;
}

.visually-disabled {
    pointer-events: none;
    background-color: #e9ecef;
    border-color: #dee2e6;
}

@media (max-width: 768px) {
    .question-card {
        max-width: 100% !important;
    }
}

/* Für eingerückte Karten: */
.indent-1 {
    margin-left: 40px;
    max-width: 340px;
}

.indent-2 {
    margin-left: 80px;
    max-width: 380px;
}

.indent-3 {
    margin-left: 120px;
    max-width: 420px;
}

.jstree-ocl {
    display: none !important;
    pointer-events: none !important;
}

.jstree-default .jstree-anchor {
    height:auto !important;
}

#tree {
    text-align: left;
}

    #tree .jstree-container-ul {
        padding-left: 0; /* Basislevel linksbündig */
    }

    /* Erste Ebene (Kinder von Root) */
    #tree ul {
        margin-left: 10px;
    }

    #tree li > a {
        min-height: 30px;
        line-height: 30px;
        display: flex;
        align-items: center;
        padding: 0 8px; /* etwas horizontaler Abstand */
        font-size: 0.95rem;
    }

    #tree li span[name="text"] {
        max-width: 100%;
        display: inline-block;
        white-space: normal;
        word-break: break-word;
    }

    /* Falls du wholerow nutzt: sicherstellen, dass die Hintergrundzeile genauso groß ist */
    #tree .jstree-wholerow {
        min-height: 30px;
        line-height: 30px;
    }

.tree-question {
    display: flex;
    align-items: flex-start;
}

.tree-checkbox {
    pointer-events: none;
    margin-right: 14px;
}

.tree-quantity, .tree-text, .tree-price, .tree-data {
    width: 40px;
    margin-left: 0px;
    background-color: #e9ecef;
    color: #495057;
    border: 1px solid #ced4da;
    font-size: 0.9rem;
    text-align: center;
}

.tree-radio {
    vertical-align: top;
    margin-top: 10px; /* optional für Feintuning */
}

.tree-data {
    width: 100px;
}

.tree-remove-product {
    font-size: 0.9rem;
    margin-left: 8px;
    padding: 0;
    line-height: 1;
}

.tree-product {
    white-space: nowrap;
    cursor: help;
}

.w-120px {
    width:120px;
}

.w-140px {
    width: 140px;
}

#questionForm {
    height: 100%;
}

.question-slide {
    position: absolute;
    width: 100%;
    transform: translateX(100%);
    transition: transform 0.4s ease;
    opacity: 0;
}

    .question-slide.enter {
        transform: translateX(0);
        opacity: 1;
    }

    .question-slide.leave {
        transform: translateX(-100%);
        opacity: 0;
    }


.quantity-input {
    width: 80px;
    border: 1px solid #ced4da;
    text-align: center;
    padding: 0 4px;
    font-size: 0.9rem;
}

.text-input {
    width: 200px;
    border: 1px solid #ced4da;
    text-align: left;
    padding: 0 4px;
    font-size: 0.9rem;
}

.price-input {
    width: 80px;
    border: 1px solid #ced4da;
    text-align: left;
    padding: 0 4px;
    font-size: 0.9rem;
}


.progress-wrapper {
    max-width: 800px;
    margin: 0px auto;
    padding: 0 20px; 
    margin-bottom: 15px;
}

.progress-container {
    position: relative;
    height: 50px;
}

.progress-line,
.progress-line-filled {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 5px;
    transform: translateY(-50%);
    border-radius: 5px;
    z-index: 1;
}

.progress-line {
    background-color: var(--primary);
}

.progress-line-filled {
    background-color: var(--secondary);
    width: 0%;
    z-index: 2;
    transition: width 0.3s;
}

.step {
    position: absolute;
    top: 50%;
    width: 40px;
    height: 40px;
    background-color: var(--primary);
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    color: var(--primaryText);
    font-weight: bold;
    transform: translate(-50%, -50%);
    z-index: 3;
    transition: background-color 0.3s;
}

    .step.completed {
        background-color: var(--secondary);
        color: var(--secondaryText);
    }

/* WebKit-Browser (Chrome, Safari) */
input[type="range"]::-webkit-slider-runnable-track {
    background: transparent;
}

/* Firefox */
input[type="range"]::-moz-range-track {
    background: transparent;
}

/* Edge (falls nötig) */
input[type="range"]::-ms-track {
    background: transparent;
    color: transparent;
    border: none;
}

input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(to right, green 0%, green 0%, var(--tertiary) 0%, var(--tertiary) 100%);
    outline: none;
}

    input[type="range"]::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: var(--secondary);
        cursor: pointer;
        margin-top: -5px;
        border: 2px solid white;
    }

    input[type="range"]::-moz-range-thumb {
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: var(--secondary);
        cursor: pointer;
        border: 2px solid white;
    }

