#sf-login-box {
    width: 100%;
    max-width: 400px;
}
#sf-menu {
    font-size: 0.85rem;
}

/* 

Additonal css details for ajax-test.php, not related to system messages.

*/

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }
    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-6px);
    }
    20%,
    40%,
    60%,
    80% {
        transform: translateX(6px);
    }
}
.error-state {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25) !important;
    animation: shake 0.82s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Optional: make disabled button look better with spinner */
.btn:disabled .spinner-border {
    vertical-align: middle;
}

/* Optional: fade the text a bit when loading */
.btn-loading {
    opacity: 0.85;
    cursor: not-allowed;
}

/* If you want the spinner to be the only content (no text) */
.btn-spinner-only[data-loading] {
    min-width: 3rem; /* prevent shrinking */
}

/*  messages.css - Full-width bottom message bar  */

#system-messages {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    pointer-events: none;
}

.system-message {
    padding: 16px;
    text-align: center;
    color: white;
    font-weight: 500;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.system-message.show {
    opacity: 1;
    transform: translateY(0);
}

.system-message.hide {
    opacity: 0;
    transform: translateY(20px);
}

/* Background colors */
.system-message.success,
.system-message.mess-good {
    background-color: #28a745; /* green */
}

.system-message.danger,
.system-message.mess-bad {
    background-color: #dc3545; /* red */
}

.system-message.warning,
.system-message.mess-warning {
    background-color: #ffc107; /* yellow */
}

.navbar-fs-small a {
    font-size: 0.85rem !important;
}

/** Modal display fix - ensure modals are always visible when shown, even if they were hidden with display:none */
.modal {
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.modal.show {
    opacity: 1;
    transform: translateY(0);
    display: block !important; 
}

.modal.d-none {
    display: none !important;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.modal-backdrop.show {
    opacity: 1;
}

/* ====================== MODAL FONT SIZE ====================== */

/* Scale entire modal content to ~80% */
.modal {
    font-size: 0.875rem;     /* ≈ 14px (80% of default 16px) */
}

/* Optional: Make it slightly more compact */
.modal .modal-content {
    font-size: 0.875rem;
}

/* If you want even more control */
.modal-dialog {
    font-size: 0.875rem;
}

/* Keep form controls and buttons readable */
.modal input,
.modal textarea,
.modal select,
.modal .form-control,
.modal .btn {
    font-size: 0.875rem;
}

/* Optional: Make headings a bit larger than body text */
.modal .modal-title,
.modal h5,
.modal h6 {
    font-size: 1.1rem;   /* Slightly bigger than body text */
}

.version-number {
    font-size: 0.8em;
    color: #c2c2c2;
    margin-left: 8px;
}

.version-number::before {
    content: "v";
}

.small-font {
    font-size: 0.85rem;
}

.dropdown-item.active, .dropdown-item:active {
    background-color: #007bff57 !important;
    color: #000;
}

.m-berth-select {
    height: 481px;
}