
:root {
    /* --primary-color: #241d13; 
    --primary-color-hover: #0056b3; 
    --light-color: #F3EFE4;  */
    --background-color: #F3EFE4;
    --background-color-hover: #e3dac0;
    
    --primary-color: #007aff; 
    --primary-color-hover: #0056b2; 
    --light-color: #b4d8ff; 
  }
  /* // #007aff; */
  /* 0071e3 */
  /* 0056b3 */
  /* b4d8ff light*/
  

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    line-height: 1.5;
    color: #333;
    background-color: #F3EFE4;
    margin: 0;
    padding: 0;
}
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}
h1 {
    font-size: 40px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 30px;
}
.intro {
    font-size: 18px;
    text-align: center;
    margin-bottom: 40px;
}
.scale {
    background-color: #fff;
    border-radius: 18px;
    padding: 20px;
    margin-bottom: 40px;
}
.scale h2 {
    font-size: 24px;
    margin-bottom: 15px;
}
.scale ul {
    list-style-type: none;
    padding: 0;
}
.scale li {
    /* margin-bottom: 10px; */
}
.question-container {
    background-color: #fff;
    border-radius: 18px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 15px;
}

.question {
    font-size: 18px;
    font-weight: 500;
    margin: 0;
}

.info-button {
    position: relative;
    /* background-color: #b6b6b6; */
    color: #b6b6b6;
    border: none;
    width: 20px; /* Bazowa szerokość */
    padding-top: 20px; /* To tworzy kwadrat */
    border-radius: 50%; /* To zamienia kwadrat w koło */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    margin-left: 10px;
    transition: background-color 0.3s ease;
    /* overflow: hidden; */
    background: none;
}

.info-button::after {
    content: '�';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #b6b6b6;
}

.info-button:hover::after  {
    color: var(--primary-color-hover);
}

.info-button:focus {
    outline: none;
    /* box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.5); */
}

/* Dodajmy trochę przestrzeni wokół przycisku dla lepszego wyglądu */
.question-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.question {
    margin-right: 10px; /* Dodaje trochę przestrzeni między pytaniem a przyciskiem */
    flex: 1; /* Pozwala pytaniu zajmować dostępną przestrzeń */
}


.options-container {
    display: flex;
    justify-content: center;
        margin-top: 15px;
}

.option-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}

.option-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    color: var(--primary-color);
    transition: all 0.3s ease;

}

.scale-popup {
    position: absolute;
    top: 100%;
    right: 0;
    background-color: var(--primary-color);
    border: 1px solid var(--primary-color);
    color: #fff;
    border-radius: 8px;
    padding: 10px;
    z-index: 1000;
    /* box-shadow: 0 2px 10px rgba(0,0,0,0.1); */
    /* max-width: 300px; */
}

.scale-popup h4 {
    margin-top: 0;
}

.scale-popup ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.scale-popup li {
    margin-bottom: 5px;
}

strong{
    font-size: 2rem;
    color: var(--primary-color);
}

#submitButton,  #generateLinkButton {
    background-color: var(--primary-color);
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: block;
    margin: 20px auto;
}
#submitButton:hover,  #generateLinkButton:hover {
    background-color: var(--primary-color-hover);
}

#autoFillButton{
    background-color: #a5a5a5;
    opacity: 1;
    background-color: #cecece;
    color: #fff;
    font-size: 11px;
    font-weight: 300;
    padding: 3px 7px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: block;
    /* margin: 20px; */
    position: absolute;
    left: 20px;
    margin-bottom:10px
}

#results {
    /* background-color: #fff; */
    border-radius: 18px;
    /* padding: 30px; */
    margin-top: 40px;
}
.result-item {
    margin-bottom: 15px;
}
.result-item strong {
    font-weight: 600;
}
.total-score{
    font-size: 24px;
    font-weight: 700;
    /* margin-top: 30px; */
    text-align: center;
    color: var(--primary-color);
}

.total-score-header {
    font-size: 24px;
    font-weight: 700;
    margin-top: 30px;
    text-align: center;
}

#results table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 20px;
    background-color: #fff;
    border-radius: 7px;
    overflow: hidden;
}
#results th,
#results td {
    padding: 20px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}
#results th {
    /* background-color: #f2f2f7; */
    font-weight: 600;
    color: #1d1d1f;
}
#results tr:last-child td {
    border-bottom: none;
    /* padding: 5px; */
}
#results tr:nth-child(even) {
    /* background-color: #fafafa; */
    padding: 5px;
}
.option-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    color: var(--primary-color);
    transition: all 0.3s ease;
}
input[type="radio"] {
    display: none;
}
input[type="radio"]:checked + .option-circle {
    background-color: var(--primary-color);
    color: white;
}
.question-container.unanswered {
    border: 2px solid #ff3b30;
    background-color: #fff1f0;
}
.question-container.unanswered .question {
    color: #ff3b30;
}
#progressBarContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 10px;
    background-color: var(--light-color); ;
    z-index: 1000;
}
#progressBar {
    height: 100%;
    background-color: var(--primary-color);
    width: 0;
    transition: width 0.3s ease;
}
body {
    padding-top: 10px;
}
.personal-info {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
}

.input-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 300px;
}

.input-group label {
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
}

.input-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 16px;
    text-align: center;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.2);
}

.info-box {
    background-color: #fff;
    border-radius: 18px;
    padding: 20px;
    margin-bottom: 40px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.info-box h2 {
    font-size: 24px;
    margin-bottom: 15px;
    color: #333;
}

.personal-info {
    display: flex;
    flex-wrap: wrap;
    /* gap: 20px; */
    justify-content: center; /* Centruje elementy w poziomie */
    align-items: center; /* Centruje elementy w pionie */
}

.input-group {
    flex: 0 1 auto; /* Zmiana z flex: 1 na flex: 0 1 auto */
    min-width: 200px;
    max-width: 300px; /* Dodajemy maksymalną szerokość */
   
}

.input-group input {
    /* width: 100%; */
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    border: 2px solid var(--primary-color);
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.2);
}
.graph-container {
    width: 150px;
    height: 15px;
    position: relative;
    margin: 0;
}

.graph-line {
    width: 100%;
    height: 10px;
    background-color: #d5d5d5;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 5px;
    overflow: hidden;
}

/* .graph-fill {
    height: 100%;
    position: absolute;
    left: 0;
    top: 0;
} */
.graph-fill {
    height: 100%;
    position: absolute;
    left: 0;
    top: 0;
    background-image: linear-gradient(to right, rgba(255,255,255,0.1), rgba(255,255,255,0.3));
    box-shadow: 0 0 10px rgba(255,100,0,0.5);
    transition: width 0.3s ease, background-color 0.3s ease;
}


.graph-label {
    position: absolute;
    top: 100%;
    transform: translateX(-50%);
    font-size: 10px;
    color: #c0c0c0;
}

.graph-label-min {
    left: 0;
}

.graph-label-max {
    right: 0;
    transform: translateX(50%);
}

.graph-value {
    position: absolute;
    top: -20px;
    transform: translateX(-50%);
    font-size: 12px;
    font-weight: bold;
    color: #333;
}

#copyPromptButton {
    background-color: var(--background-color);
    color: black;
    font-size: 10px;
    font-weight: 600;
    padding: 12px 24px;
    border: 1px solid black;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: block;
    margin: 20px auto;
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: .1rem;
}

#copyPromptButton:hover {
    background-color: var(--background-color-hover);
}

.option-label {
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
}

.option-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    color: var(--primary-color);
    transition: all 0.3s ease;
    margin-right: 5px;
}

.tooltip-trigger {
    font-size: 14px;
    cursor: pointer;
    margin-left: 5px;
}

.tooltip-trigger::before,
.tooltip-trigger::after {
    content: "";
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s ease, bottom 0.3s ease;
    pointer-events: none;
}

.tooltip-trigger::before {
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid rgba(0, 0, 0, 1);
    bottom: calc(100% + 10px);
}

.tooltip-trigger::after {
    content: attr(data-tooltip);
    background-color: rgba(0, 0, 0, 1);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    bottom: calc(100% + 18px);
    z-index: 1000;

}


/* Dla urządzeń nie-dotykowych (desktopy) */
@media (hover: hover) and (pointer: fine) {
    .option-circle:hover::after {
        content: attr(title);
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        background-color: var(--primary-color);
        color: white;
        padding: 5px 10px;
        border-radius: 4px;
        font-size: 12px;
        white-space: nowrap;
        margin-bottom: 5px;
    }

    .info-button {
        display: none;
    }
}

/* Dla urządzeń dotykowych */
@media (hover: none) {
    .option-circle:hover::after {
        display: none;
    }
}

@media screen and (max-width: 600px) {
    #results table,
    #results thead,
    #results tbody,
    #results th,
    #results td,
    #results tr {
        display: block;
        background-color: #F3EFE4;;
        
    }

    #results thead {
        display: none;
        background-color: #fff;
    }

    #results tr {
        margin-bottom: 15px;
        border-radius: 12px;
        overflow: hidden;
        padding: 10px;
        /* box-shadow: 0 2px 5px rgba(0,0,0,0.1); */
        background-color: #fff;
        

    }

    #results td {
        border: none;
        position: relative;
        padding: 10px;
        text-align: left;
    }

    #results td:first-child {
        font-weight: bold;
        font-size: 1em;
        background-color: #fff;
        border-top-left-radius: 12px;
        border-top-right-radius: 12px;
        padding-bottom: 0px;
    }

    /* #results td:nth-child(2),
    #results td:nth-child(3) {
        display: inline-block;
        width: 50%;
        box-sizing: border-box;
    } */

    #results td:nth-child(2),
    #results td:nth-child(3) {
        display: none;
    }

    #results td:nth-child(4) {
        padding-top: 0;
        background: white;
    }

    #results td:nth-child(2)::before,
    #results td:nth-child(3)::before {
        /* content: attr(data-label); */
        font-weight: bold;
        display: block;
        margin-bottom: 5px;
    }

    .graph-container {
        width: 100%;
        margin: 10px 0;
    }

    .graph-value {
        top: 15px;
        font-size: 14px;
    }

    .graph-label {
        font-size: 12px;
    }
}