.content-row {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.file-row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
    width: 100%;
}

.box {
    border: 2px dashed #aaa;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    background: #f9f9f9;
    position: relative;
    width: 100%;
}

.box.highlight {
    border-color: #c8e6c9;
    background: #e8f5e9;
}

.box input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

#uploaded-files {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
}

.file-item {
    flex: 1 0 calc(100% / 6 - 20px);
    max-width: calc(100% / 6 - 20px);
    min-width: calc(100% / 6 - 20px);
    height: 300px;
    border: 2px solid #ddd;
    border-radius: 4px;
    padding: 10px;
    margin: 10px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    overflow: hidden;
    position: relative;

}

.file-name {
    margin-bottom: 10px;
    font-weight: bold;
    text-align: center;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-bottom: 1px solid #ddd;
    padding-bottom: 8px;
    z-index: 2;
}

.file-preview {
    width: 100%;
    height: auto;
    max-height: calc(100% - 90px); /* Adjust to accommodate filename and buttons */
    object-fit: contain;
    margin-bottom: 5px;
    margin-top: 5px;
    z-index: 1; /* Ensure the canvas is below the buttons */
    transition: transform 0.3s ease-in-out, width 0.3s ease-in-out, height 0.3s ease-in-out;
}

.button-container {
    display: flex;
    justify-content: space-around;
    width: 100%;
    margin-top: 5px;
    z-index: 2; /* Ensure the buttons are above the canvas */
    position: absolute;
    bottom: 5px;
    left: 0;
    right: 0;
}

.file-button {
    background: #eb5d1e;
    color: #fff;
    padding: 5px 10px;
    border: 1px solid;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 5px;
}

.button {
    background: #eb5d1e;
    color: #fff;
    padding: 5px 10px;
    border: 1px solid;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 20px;
}

.button:hover {
    background: #c54811;
}

.hr {
    height: 5px; /* Adjust the pixel value for desired thickness */
    border: none;
}

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

.button-div .button {
    padding: 10px 20px;
}

/* Highlight drop area */
#drop-area.highlight {
    border: 2px dashed #4CAF50;
}



/* Style for each file item */
.file-item {
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
    position: relative;
}

.dragging {
    opacity: 0.5;
    transform: scale(1.05);
    z-index: 1000;
    position: absolute;
}

.placeholder {
    border: 2px dashed #4CAF50;
    background-color: #f0f0f0;
    min-height: 100px;
    transition: height 0.3s ease-in-out, margin 0.3s ease-in-out;
    visibility: visible;
}

/* Default styling for larger screens (desktop) */
.file-item {
    flex: 1 0 calc(100% / 6 - 20px);
    max-width: calc(100% / 6 - 20px);
}

/* Styling for large tablets and small desktops */
@media screen and (max-width: 1200px) {
    .file-item {
        flex: 1 0 calc(100% / 4 - 20px);
        max-width: calc(100% / 4 - 20px);
    }
}

/* Styling for tablets */
@media screen and (max-width: 992px) {
    .file-item {
        flex: 1 0 calc(100% / 3 - 20px);
        max-width: calc(100% / 3 - 20px);
    }
}

/* Styling for large phones */
@media screen and (max-width: 768px) {
    .file-item {
        flex: 1 0 calc(100% / 2 - 20px);
        max-width: calc(100% / 2 - 20px);
    }
}

/* Styling for small phones */
@media screen and (max-width: 576px) {
    .file-item {
        flex: 1 0 calc(100% - 20px);
        max-width: calc(100% - 20px);
    }
}




/* Add styles for password input and error messages */
.password-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    position: absolute;
    margin-top: 30%;
    z-index: 5;
}

.password-input {
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 10px;
    width: 80%;
    height: 20%;
}

.password-error {
    color: red;
    font-size: 12px;
    margin-top: 5px;
}

.submit-password-button {
    background: #eb5d1e;
    color: #fff;
    padding: 5px 10px;
    border: 1px solid;
    border-radius: 10px;
    cursor: pointer;
    height: 30%;
    font-size: small;
}

.submit-password-button:hover {
    background: #c54811;
}




/* Loader animation */
/* Loader animation */
.loader {
    border: 4px solid #f3f3f3;
    border-radius: 50%;
    border-top: 4px solid #eb5d1e;
    width: 20px;
    height: 20px;
    -webkit-animation: spin 2s linear infinite;
    animation: spin 2s linear infinite;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@-webkit-keyframes spin {
    0% { -webkit-transform: rotate(0deg); }
    100% { -webkit-transform: rotate(360deg); }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.button[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
    position: relative;
}
