body {
    font-family: monospace;
    color: #282c34;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

input {
    font-family: monospace;
}

.text-center {
    text-align: center;
}

body::after {
    content: "";
    background: url('images/bg.jpg') no-repeat center center fixed;
    background-size: cover;
    opacity: 0.6;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    position: absolute;
    z-index: -1;   
}

.desktop {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 20px;
}

.icon {
    width: 100px;
    margin: 10px;
    text-align: center;
    cursor: pointer;
    border: 2px solid transparent;
    user-select: none;
    padding: 10px;
}

.icon img {
    width: 100%;
}

.icon span {
    display: block;
    margin-top: 5px;
}

.icon.selected {
    border-color: #61dafb;
    background-color: rgba(97, 218, 251, 0.2);
}

.modal {
    display: none;
    position: fixed;
    z-index: 1;
    width: 60%;
    height: 60%;
    left: 20%;
    top: 20%;
    background-color: rgba(0, 0, 0, 0.9);
    overflow: auto;
    border: 1px solid #444;
    color: #fff;
    border-radius: 10px;
    box-shadow: 0 0px 32px rgb(0 0 0 / 30%);
}

.modal-content {
    padding: 20px;
    color: #fff;
}

#modal-content[contenteditable="true"] {
    min-height: 70%;
}

.modal-content.files {
    display: flex;
}

.modal-header {
    background-color: #282c34;
    padding: 10px;
    text-align: center;
    font-size: 20px;
    border-bottom: 1px solid #444;
    position: relative;
    color: #fff;
}

.modal-header .close {
    position: absolute;
    top: 6px;
    right: 10px;
    background-color: #f1f1f1;
    color: #282c34;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    text-align: center;
    line-height: 26px;
    font-size: 30px;
    cursor: pointer;
}

.modal-header .close:hover {
    background-color: #bbb;
}

.thumbnail {
    height: 100px;
    margin: 10px;
    cursor: pointer;
    display: inline-block;
    vertical-align: top;
    text-align: center;
}

.thumbnail-container {
    display: flex;
    flex-direction: column;
    height: 200px;
    overflow: hidden;
    text-align: center;
}

.thumbnail img {
    height: 200px;
    display: block;
}

.thumbnail span {
    display: block;
    color: #61dafb;
    margin-top: 5px;
}

/* Login modal styles */
.login-modal {
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    z-index: 2;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
}

.login-modal-content {
    background-color: #282c34;
    padding: 2rem;
    border: 7px solid #cad6ed8f;
    color: #61dafb;
    text-align: center;
    border-radius: 25px;
    box-shadow: 7px 10px 10px #0000003d;
    width: 400px;
}


.login-modal-content img {
    display: inline;
    position: relative;
    width: 40%;
    text-align: center;
    margin-top: 1em;
    margin-bottom: 1em;
}

.login-modal-content input {
    margin-top: 10px;
    padding: 10px;
    border: none;
    border-radius: 3px;
    display: block;
    width: calc(100% - 20px);
}

.button {
    border: 1px solid #ffffff;
    border-radius: 3px;
}
.button:hover {
    background-color: #f0f0f0;
    cursor: pointer;
}

.login-modal-content button {
    background-color: #cad6ed;
    padding: 8px 20px;
    font-weight: bold;
    margin-top: 10px;
}

.login-modal-content button:hover {
    background-color: #99b3e5;
}


.login-modal-content a:link, .login-modal-content a:visited {
    color: #cad6ed;
    font-size: 1em;
}

.saved {
    display: none;
    position: absolute;
    right: 1rem;
    bottom: .7rem;
    color: #282c34;
}

#timer {
    position: fixed;
    top: 10px;
    right: 10px;
    font-size: 32px;
    font-weight: bold;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    text-shadow: #000 1px 0 10px;
}

.hint-popup {
    display: none;
    position: fixed;
    top: 40%;
    left: 40%;
    background-color: #ffffff;
    border: 6px solid rgb(99 99 99);
    z-index: 1000;
    width: 20%;
    text-align: center;
    box-shadow: 0 0px 32px rgb(41 128 185 / 44%);
    border-radius: 15px;
    font-weight: bold;
}

.video-modal {
    top: 15%;
    left: 17%;
    width: 1280px;
    height: 720px;
    overflow: hidden;
    display: none;
    position: fixed;
    background-color: white;
    border: 1px solid #ccc;
    z-index: 1000;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    overflow: hidden;
}

.hint-popup-content {
    padding: 20px;
}

.hint-header {
    font-size: 18px;
    margin-bottom: 20px;
}

.hint-actions {
    display: flex;
    justify-content: space-around;
}

.hint-button {
    font-size: 20px;
    cursor: pointer;
    border: none;
    background: none;
    outline: none;
}

.green-button {
    color: green;
}

.red-button {
    color: red;
}

.video-modal-content {
    position: relative;
}

.video-modal-content video {
    width: 100%;
    height: auto;
}

.close {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 30px;
    cursor: pointer;
}

.hint-actions img {
    width: 50px;
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.fade-out {
    animation: fadeOut 1s forwards;
}

.notepad .modal-content {
    display: block;
    color: black;
}

.modal.notepad {
    background-color: white;
    width: 40%;
    left: 30%;
}

/* Image Viewer Modal */
.image-viewer-modal {
    display: none; /* Modal is hidden by default */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
}

/* Center the image using transform */
.image-viewer-content {
    max-width: 80%;
    max-height: 80%;
    margin: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: block;
}

/* Close button styling */
.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}


table.info tr td:first-child {
    width: 25%;
    font-weight: bold;
}

div#noteblockModal1 {
    z-index: 2;
    top: 14%;
}

table.journal tr:first-child td {
    font-weight: bold;
    font-size: 1.2rem;
    background-color: #eee;
    padding-left: 5px;
}

table.journal, table.journal tr {
    border: 1px solid;
    border-collapse: collapse;
    margin-top: 1rem;
    width: 100%;
}
div#decipherkModal1 {
    width: 25%;
    left: 38%;
    height: 30%;
    top: 30%;
    text-align: center;
}

div#decipherkModal1:before {
    content: ' ';
    display: block;
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    opacity: 0.2;
    background-image: url('images/wearelegend.gif');
    background-repeat: no-repeat;
    background-position: 50% 0;
    background-size: cover;
    z-index:-1;
}

#decipherkModal1 input#input-text {
    margin-top:30px;
    background-color: black;
    border: 1px solid white;
    padding: 10px;
    color: white;
    text-transform: uppercase
}

button#decrypt-btn {
    background-color: black;
    border: 1px solid white;
    padding: 10px;
    color: white;
    font-weight: bold;
    text-transform: uppercase;
}

div#cipher-output {
    font-size: 1.2rem;
    font-weight: bold;
    margin-top: 10px;
}


/* Button styling */
.toolbar button {
    padding: 5px 10px;
    margin-right: 5px;
    font-size: 16px;
    cursor: pointer;
}

[contenteditable] { 
    outline: 0px solid transparent; 
} 

div#toolbar {
    margin-top: 0px;
    right: 10px;
    background-color: #e0e0e0;
    padding: 5px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    border-bottom: 1px solid #ccc;
}

.toolbar button {
    color: #000;
    background-color: #fff;
    border: 1px solid #bfbfbf;
    font-size: 0.9em;
    padding: 8px;
    margin: 0 0 0 0;
    display: inline-block;
    min-width: 35px;
    border-radius: 8px;
    margin: 0;
}

div#version {
    text-align: left;
}