/* Modal overlay (welcome + delete) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    padding: 1rem;
    overflow: auto;
}

.modal-box {
    background: #202020;
    border: 2px solid #444;
    border-radius: 6px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.45);
    width: 100%;
    max-width: 420px;
    /* prevents giant desktop modals */
    max-height: 90vh;
    /* never overflow vertically */
    overflow-y: auto;
    /* scroll *inside* modal if content too tall */
    padding: 1.25rem;
    font-family: 'Cutive Mono', monospace;
    color: ivory;
}

/* mobile modal-box */
@media (max-width: 600px) {
    .modal-box {
        width: 80%;
    }
}

/* tablet modal-box */
@media (min-width: 601px) and (max-width: 900px) {
    .modal-box {
        width: 60%;
    }
}

/* Title bar for modal */
.modal-title {
    background: linear-gradient(to bottom, #757575ff, #585858ff);
    color: white;
    padding: 5px 10px;
    font-weight: bold;
    font-size: 14px;
    margin: -15px -15px 10px -15px;
}

/* Modal footer */
.modal-footer {
    text-align: center;
    margin-top: 10px;
}

/* Old-style modal button; real buttons are in button.css */
.modalbutton {
    background-color: #dcdcdc;
    border: 1px solid #808080;
    padding: 3px 10px;
    font-size: 12px;
    cursor: pointer;
}

.modalbutton:hover {
    background-color: #c0c0c0;
}

/* Danger variation for delete-account modal */
.modal-box-danger {
    border-color: #ae2727;
    box-shadow: 0 4px 24px rgba(174, 39, 39, 0.6);
}

.modal-title-danger {
    background: linear-gradient(to bottom, #b91c1c, #7f1d1d);
}

@media (max-width: 380px) {
    .modal-box {
        padding: 0.9rem;
        font-size: 0.9rem;
    }
}