:root {
    --spacing-50: 4px;
    --spacing-100: 8px;
}

*,
*::after,
*::before {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    background: #fafafa;
    height: 100vh;
    overflow: hidden;
    font-family: "Inter", sans-serif;
    -webkit-font-smoothing: antialiased;
}

.material-fill {
    font-variation-settings: 'FILL' 1;
}

/*
  svg {
    box-shadow: 0 0 0 1px black;
  }*/

.relative {
    position: relative !important;
}

.block {
    display: block !important;
}

.column {
    flex-flow: column;
}

.flex {
    display: flex !important;
}

.center {
    justify-content: center;
    align-items: center;
}
.hidden {
    display: none !important;
}

.ml-2{
    margin-left: 12px;
}

/* .container {} */

#ctn {
    position: absolute;
    top: 0;
    left: 0;
    transform-origin: center center;
}

#ctn .holder {
    position: absolute;
    display: block;
    justify-content: center;
    align-items: center;

    background: #fff;
    /* font-size: 22px; */
    font-size: 0.8rem;
    font-family: sans-serif;
    width: 100px;
    cursor: pointer;

    border-radius: 4px;
    padding: 6px;
}

.holder .box {
    display: flex;
    align-items: center;
    gap: 6px;

    transform-origin: left center;
}

#ctn .holder * {
    pointer-events: none;
    user-select: none;
}

#ctn .holder p{
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

#ctn .holder b{
    flex-grow: 0;
}

/*
  #ctn .holder:hover{ } */

#main {
    position: absolute;
    left: 0;
    transition: left .2s ease-in-out;
}

#control.active~#main {
    left: 270px;
}

#screen {
    width: 100vw;
    min-height: 100vh;
    display: flex;
}

#control.active {
    transform: unset;
}

.control {
    min-width: 270px;
    width: 270px;
    height: 100vh;
    z-index: 1;
    background: #fff;
}

#r-control {
    border-left: 0.555556px solid rgba(0, 0, 0, 0.08);
    position: relative;
    line-height: 20px;
    font-family: sans-serif;
}

#control {
    border-right: 0.555556px solid rgba(0, 0, 0, 0.08);

    position: absolute;
    transform: translateX(-100%);
    transition: transform .2s ease-in-out;
}

#control section {
    flex-flow: column;
    display: flex;
    height: 100%;
}

#control header {
    padding: 19px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#control header b {
    font-size: 14px;
    font-weight: 800;
}

#control h3 {
    font-size: 14px;
    /*14.2px;*/
    font-weight: 600;

    line-height: 20px;
    tab-size: 4;
}

#control header i.close {
    font-size: 9.2px;
    cursor: pointer;
    width: 15px;
    height: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#control .ctn {
    flex-grow: 1;
    padding: 0 16px;
    overflow-y: auto;
}


#control footer {
    padding: 16px;
    display: flex;
    justify-content: space-between;
    align-self: center;
    width: 100%;
}

#control .left-box {
    display: flex;
    gap: 8px;
}

#control .dropdown {
    position: fixed;
    /*      left: 0; top: 100%; */
    padding-top: 4px;
    top: 0;
    left: 0;
    z-index: 1;
}

.dropdown>div {
    min-width: 510px;
    background: #fff;
    box-shadow: rgba(0, 0, 0, 0.08) 0px 2px 4px, rgba(0, 0, 0, 0.06) 0px 2px 12px;
    border-radius: 4px;
    border: 0.888889px solid rgb(187, 187, 187);
}

.dropdown .search {
    display: flex;
    height: 50px;
    padding: 0px 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.07);
}

.dropdown .search i {
    width: 32px;
    margin-left: 2px;
    line-height: 20px;
    justify-content: center;
    align-items: center;
    display: flex;
}

.dropdown .search input {
    font-size: 16px;
    line-height: 24px;
    width: 100%;
    flex: 1 1 0;
    border: none;
    outline: none;
    padding: 7px 13px 7px 0px;
}

.dropdown .items {
    overflow-y: auto;
    max-height: 240px;
    padding: 8px 0px;
}

.dropdown .items .options {
    padding: 4px 0px;
}

.dropdown .items .options:empty {
    display: none;
}

.dropdown .options>div {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    cursor: pointer;
}


.remove-all {
    font-size: 14px;
    text-decoration-line: underline;
    color: rgb(140, 3, 3);
    display: flex;
    align-items: center;
    cursor: pointer;
}

.btn {
    border: none;
    font-size: 14px;
    border-radius: 4px;
    padding: 6px 12px;
    cursor: pointer;
}

.btn-black {
    color: #fff;
    background: rgb(38, 38, 39);
}

.btn-gray {
    color: rgb(38, 38, 39);
    background: rgb(227, 227, 227);
}

.bl-label {
    color: rgb(38, 38, 39);
    background: #fff;
    box-shadow: rgba(0, 0, 0, 0.05) 0px 2px 4px, rgba(0, 0, 0, 0.03) 0px 2px 12px;
    padding: 8px 13px;

    display: flex;
    gap: 14px;
    font-size: 14px;
}

.bl-label .fit-screen {
    font-size: 12px;
}

.opt {
    background: rgb(240, 240, 240);
    margin-bottom: 8px;
    border-radius: 4px;
    padding: 8px;

    display: flex;
    justify-content: space-between;
    position: relative;

    font-size: 12.6px;
}

.opt>.name {
    font-weight: 400;
}

.opt .to {
    display: flex;
    gap: 4px;
    margin-right: 2px;
    cursor: pointer;
}

.opt .to span {
    font-weight: 300;
}

.opt .to p {
    font-size: 11.8px;
    line-height: 1.35;
    font-weight: 700;
}


.bl-actions {
    position: absolute;
    left: 100%;
    bottom: 0;
    padding: 14.6px;
    caret-color: transparent;
}


/* ==== Mode: content ==== */

#questions {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 32px 16px 64px;

    border-left: 0.555556px solid;
    border-right: 0.555556px solid;
    border-color: #00000014;

}

#questions .whiteboard {
    background: #fff;
    min-height: 70%;
    width: 100%;
    border-radius: 8px;
    /*      box-shadow: rgba(0, 0, 0, 0.08) 0px 2px 4px; */
    box-shadow: #00000014 0px 2px 4px, #0000000f 0px 2px 12px;
    display: flex;
    align-items: center;
}

.whiteboard>div {
    width: 100%;
    padding-inline: 46px;
    transform: scale(0.9);
}

.whiteboard .box {
    width: 100%;
    max-width: 720px;
    margin: 0px auto;
    position: relative;

}

.whiteboard .box > h3.title {
    font-size: 24px;
    font-weight: 400;
    line-height: 32px;
    font-family: "Segoe UI", sans-serif;
    outline: none;
}
.whiteboard .box > h3.title.blank:focus {
    opacity: 0.35;
}
.whiteboard .desc-place.blank:focus{
    opacity: 0.35;
}

.whiteboard .box .desc-place {
    position: relative;
    font-size: 16px;
    line-height: 26px;
    margin-top: 6px;
    
    outline: none;
    white-space: nowrap;
    opacity: 0.7;
}

/*
.whiteboard .desc-place p {
    opacity: 0.7;
}*/

.whiteboard .desc-place.blank::before {
    overflow-wrap: break-word;
    word-break: keep-all;

    color: inherit;
    content: attr(data-placeholder);
    font-style: italic;
    pointer-events: none;
    position: absolute;
}
.whiteboard .box > h3.title.blank::before {
    opacity: 0.7;
    overflow-wrap: break-word;
    word-break: keep-all;

    color: inherit;
    content: attr(data-placeholder);
    font-style: italic;
    pointer-events: none;
    position: absolute;
}

.whiteboard .box .id {
    display: flex;
    gap: 6px;
    align-items: center;
    position: absolute;
    margin-right: 12px;
    right: 100%;
    top: 0;
    caret-color: transparent;
}

.whiteboard .box .id-n {
    color: rgb(4, 69, 175);
    font-size: 14px;
    line-height: 32.2px;
}

.whiteboard .box .id svg {
    font-size: 14px;
    height: 10px;
    fill: rgb(4, 69, 175);
    ;
}

.whiteboard .structure {
    margin-block-start: 24px;
}

/**/
.choice-list .choice label {
	width: 100%;
	min-height: 40px;
    position: relative;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	background: #0445af1a;
	color: #0445af;
	box-shadow: #0445af99 0px 0px 0px 1px inset;
	padding: 0.25rem 1.5rem 0.25rem 0.5rem;
	border-radius: 0.2rem;
	font-family: "Segoe UI", sans-serif;
	font-size: 1.25rem;
	word-break: break-word;
	white-space: nowrap;
    line-height: 28px;
	cursor: pointer;
	box-sizing: border-box;
}

.choice-list .choice label::before {
    content: attr(data-letter);
	height: 24px;
	min-width: 22px;
	display: flex;
	justify-content: center;
	align-items: center;
	background: #fffc;
	border: 0.888889px solid #0445af99;
	border-radius: 0.125rem;
	font-size: 11.4px;
	font-weight: 700;
	aspect-ratio: 1;
}

.choice-list .choice label:has(input:checked) {
    background-color: rgba(4, 69, 175, 0.1);
    box-shadow: rgba(4, 69, 175, 0.8) 0px 0px 0px 2px inset;
}

.choice-list .choice label:has(input:checked)::before {
    border-width: 1px;
    border-style: solid;
    border-color: rgb(4, 69, 175);
    background-color: rgb(4, 69, 175);
    color: #fff;
}




/**/
.choice-list {
    /* gap: 10px; */
    display: table;
	border-collapse: separate;
	border-spacing: 0 10px;
	margin: -10px 0;
}

.choice-list li {
    display: block;
}

.choice-list .choice {
    width: 100%;
	display: table-row;
    font-family: sans-serif;
}

.choice-list .tool {
    min-height: 40px;
    display: flex;
    align-items: center;
}

.choice-list .has-many {
    font-family: "Segoe UI", sans-serif;
    font-size: 14px;
    line-height: 20px;
    color: rgb(4, 69, 175);
    margin-bottom: 6px;
}

.choice-list .choice>div {
    position: relative;
    display: inline-flex;
    align-items: center;
    border-radius: 3px;
    background: #0445af1a;
    box-shadow: #0445af99 0px 0px 0px 1px inset;
    color: #0445af;
    max-width: 100%;
    outline: 0px;
    padding: 0.25rem 1.5rem 0.25rem 0.5rem;
    word-break: break-word;
    cursor: pointer;
    gap: 8px;

    min-height: 40px;
    box-sizing: border-box;
}

.choice-list .choice .remove {
    display: flex;
    position: absolute;
    width: 22px;
    height: 22px;
    right: -10px;
    background: rgba(38, 38, 39, 0.7);
    border: 1px solid rgb(255, 255, 255);
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    opacity: 0;
    outline: none;
}

.choice-list .choice .remove img {
    width: 9.6px;
    height: 9.6px;
}

.choice-list li .name {
    color: rgb(4, 69, 175);

    font-size: 20px;
    width: var(--w, 100%);
    min-width: 100px;
    outline: none;
    cursor: text;
    display: inline-block;
    white-space: nowrap;

    line-height: 28px;
    font-family: "Segoe UI", sans-serif;
}

.choice-list li .remove:hover,
.choice-list li .name:focus~.remove,
.choice-list li .name:hover~.remove {
    opacity: 1;
}


.choice-list .add {
    cursor: pointer;
}

.choice-list .letter {
    width: 24px;
    min-width: 22px;
    height: 24px;

    border: 0.888889px solid #0445af99;
    background: #ffffffcc;
    color: #0445af;

    border-radius: 2px;
    font-size: 11.4px;
    font-weight: 700;
}

.choice-list .add p {
    color: rgb(4, 69, 175);
    text-decoration-line: underline;
    font-size: 18px;
    font-family: sans-serif;
}

#control .content header div {
    width: 32px;
    height: 32px;
    background-color: rgb(227, 227, 227);
    border-radius: 4px;
    font-size: 14px;
    line-height: 20px;

    display: flex;
    align-items: center;
    justify-content: center;
}

#control .new-question{
    cursor: pointer;
}
#control .content header h3 {
    font-size: 14px;
    font-weight: 600;
}

/* #control .qu{} */

#control .qu>div {
    display: flex;
    font-size: 12px;
    align-items: center;
    gap: 10px;

    padding: 8px 0;
}

/* remove question */
.qu>div i {
    display: none;

    margin-left: auto;
    background: #f50f0f;
    border: 1px inset #0000004b;
    color: #fff;

    width: 15px; min-width: 15px;
    height: 15px;

    font-size: 8px;
    border-radius: 3px;

    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.qu>div:hover > i{

    display: flex;
}



#control .qu .key {
    font-size: 14px;
    font-weight: 600;
}

#control .qu .title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    cursor: pointer;
}

#r-control .ctn {
    padding: 0 16px;
    margin-top: 19px;
    overflow-y: auto;
}

#qu-type {
    display: flex;
    height: 40px;
    padding: 0 8px;
    color: rgb(38, 38, 39);
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: #fff;
    border: 1px solid rgb(187, 187, 187);
    border-radius: 4px;
    font-size: 14px;
}

.qu-settings {
    padding: 20px 0;
    gap: 20px;
    font-size: 14px;
    font-family: "Segoe UI", sans-serif;
}

.qu-settings h4 {
    font-weight: 500;
}

.qu-settings .list {
    gap: 20px;
    font-weight: 400;
}

.qu-settings .list li {
    display: flex;
    justify-content: space-between;
}

.hr-1 {
    border-bottom: 1px solid rgba(25, 25, 25, 0.15);
    margin: 16px 0px 0px;
    display: flex;
}
/* TODO: remove */
.save-2 {
    margin-left: auto;
    margin-right: 10px;
    cursor: pointer;
}

.switch {
    height: 16px;
    padding: 2px;
    min-width: 30px;

    background: rgb(187, 187, 187);
    border: 1px solid rgba(0, 0, 0, 0);
    border-radius: 9999px;
    cursor: pointer;
    position: relative;
}

.switch i {
    display: block;
    width: 10px;
    height: 10px;
    background: rgb(255, 255, 255);
    border-radius: 9999px;
    transition: transform 150ms ease 0s;
    transform: translateX(0px);
}

.switch[checked] {
    background: rgb(4, 135, 175);
}

.switch[checked] i {
    transform: translateX(14px);
}

.control .input {
    background: rgb(255, 255, 255);
    border: 1px solid rgb(187, 187, 187);
    border-radius: 4px;
    padding: 4px 0px 4px 12px;
    height: 32px;

    color: rgb(38, 38, 39);
    width: 100%;
}

.input input {
    border: none;
    font-size: 14px;
    /*line-height: 20px;*/
    line-height: 24.4px;
    width: 100%;
    outline: none;
}

.qu-settings li[for-opt] {
    display: none;
}

/*=== select virtual overlay ====*/
.v-select {
    position: fixed;
    top: 0;
    left: 0;
    border-radius: 4px;
    border: 0.888889px solid rgb(187, 187, 187);
    font-family: "Segoe UI", sans-serif;
    line-height: 20.3px;
    background: #fff;
    z-index: 1;
    max-height: calc(96vh - 16px * 2);
    overflow-y: auto;
}

.v-select .search {
    display: flex;
    min-height: 40px;
    align-items: center;
    padding: 0 12px;
    gap: 8px;
}

.v-select .search input {
    border: 1px solid transparent;
    color: rgb(132, 132, 132);
    font-stretch: 100%;
    box-sizing: content-box;
    width: 100%;
    outline: none;
}

.v-select li {
    padding: 8px 10px;
    display: flex;
    justify-content: start;
    background-color: #fff;

    transition-property: background-color, color;
    transition-duration: 0.2s;
    cursor: pointer;
}
.v-select li:hover{
    color: rgb(0, 0, 0);
    background-color: rgb(240, 240, 240);
}
.v-select li.active {
    background: rgb(240, 240, 240);
}

.recall {
    position: fixed;
    top: 2px;
    left: 0;
    padding: 0 !important;

    animation: 125ms ease-in-out 0s 1 normal none running fadeIn;

    transform-origin: left top;
    width: 258px !important;
    z-index: 2;

    font-family: "Segoe UI", sans-serif;
}

.recall>div {
    background: rgb(255, 255, 255);
    color: rgb(38, 38, 39);
    border-radius: 8px;
    box-shadow: rgba(0, 0, 0, 0.08) 0px 2px 4px;

    display: flex;
    flex-flow: column;
}

.recall .label {
    font-size: 12px;
    line-height: 18px;
    font-weight: 500;

    padding: 12px 16px;
}

.recall .items {
    padding-bottom: 8px;
    overflow-y: scroll;
    max-height: 400px;
}

.recall li {
    font-size: 14px;
    line-height: 20px;
    list-style: none;

    padding: 4px 16px;
    cursor: pointer;
}

.recall li div {
    display: flex;
    gap: 5px;
}

.recall li p {
    color: rgb(38, 38, 39);
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.recall-module>span {

    overflow: hidden;
    height: 24px;
    border-radius: 4px;
    box-sizing: border-box;
    border: 1px solid rgb(155, 207, 223);
    padding-left: 8px;
    padding-right: 8px;
    margin: 0px 2px;
    display: inline-flex;
    align-items: center;
    background-color: rgb(230, 243, 247);
    color: rgb(3, 108, 140);

    font-size: 16px;
    font-weight: 400;
    gap: 5px;

    line-height: 20px;
}

.recall-module .close {
    padding-inline-start: 2px;
    margin-bottom: 2px;
    cursor: pointer;
}

.recall-module .close::before {
    content: "×";
    font-size: 18px;
    font-weight: 700;
}

.text-form{
    gap: 12px;
    font-family: system-ui, sans-serif;
}
textarea.auto-size {
    display: block;
    width: 100%;
    color: rgb(4, 69, 175);
    padding-block-start: 0px;
    padding-block-end: var(--spacing-100);
    padding-inline: 0px;
    border: none;
    outline: none;
    background: transparent;
    font-size: 24px;
    line-height: 32px;
    overflow-wrap: break-word;
    resize: none;
    overflow: hidden;
    overflow-x: hidden;
    transition: box-shadow 0.1s ease-out 0s;
    box-shadow: rgba(4, 69, 175, 0.3) 0px 1px;
    font-family: system-ui;
}
textarea::placeholder {
    color: rgb(180, 199, 231);
}
textarea::-webkit-input-placeholder {
    color: #b4c7e7;
}
textarea.auto-size:focus {
    box-shadow: #0445af 0px 2px;
}

.text-form .long .btn, :is(.box, #controls) > .btn-blue {
    display: flex;
    align-items: flex-start;
    color: #fff;
    font-weight: 700;
    min-height: 40px;
    font-family: system-ui, sans-serif;
    caret-color: transparent;
    user-select: none;
}

.btn.btn-blue[disabled] {
	background: #808080 !important;
	cursor: unset;
    user-select: none;
}

.long > div, .box > .btn-blue {
    margin-top: 1rem;
}

.long > p {
    color: #06409f;
    font-size: 12px;
    line-height: 16px;
}

.long .btn, :is(.box, #controls) > .btn-blue {
    padding: 8px 14px 8px 13.5px;
    border: 1px solid transparent;
    border-radius: 4px;
    background: #06409f;
}

.long .enter{
    font-size: 12px;
    line-height: 16px;
}

:is(.long .btn, :is(.box, #controls) > .btn-blue) p {
    line-height: 1;
    font-size: 1.25rem;
}

:is(.long .btn, .box > .btn-blue) svg {
    margin-left: 0.5rem;
    align-self: center;
}


@keyframes fadeIn {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@media (max-width: 600px) {
    #questions {
        padding: 0;
    }
    body {
        overflow: auto;
    }
}