/* Base styles */
body {
    background-color: #f5f5f5;
}

.header {
    background-color: #04284B;
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
}

.header-left img {
    margin-right: 10px;
    width: 60px;
}

.header-title {
    font-size: 1.8rem;
    font-weight: bold;
}

.header-subtitle {
    font-size: 1.2rem;
}

/* Datacenter Information */
.datacenter-info {
    text-align: right;
}

.datacenter-info-title {
    font-size: 1.8rem;
    font-weight: bold;
}

.status-circle {
    height: 15px;
    width: 15px;
    background-color: green;
    border-radius: 50%;
    display: inline-block;
    margin-right: 5px;
}

.datacenter-info div {
    margin-bottom: 5px;
}

/* Alerts */
.alerts {
    margin-top: 20px;
}

.alert-message {
    background-color: #ffdddd;
    border-left: 6px solid #f44336;
    padding: 20px;
    margin-bottom: 15px;
}

.alert-message p {
    margin: 0;
    color: #d8000c;
    font-weight: bold;
}

/* Graph Container */
.graph-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
}

.service-container {
    flex: 1 1 calc(25% - 20px);
    box-sizing: border-box;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: #f9f9f9;
    margin-bottom: 20px;
}

.service-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
}

.service-name {
    font-weight: bold;
    font-size: 14px; /* Reduced size */
    flex: 1;
}

.status-info {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 1;
}

.uptime-percentage {
    margin-right: 10px;
}

.status-indicator {
    display: flex;
    align-items: center;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 5px;
}

.status-blocks {
    display: flex;
    margin-top: 5px;
    overflow: hidden;
    justify-content: space-between; /* Ensure blocks cover full width */
    width: 100%;
}

.status-block {
    flex: 1;
    margin-right: 2px;
    background-color: gray; /* Prefilled color */
    border-radius: 2px;
    height: 15px; /* Adjusted for a sleeker look */
}

.status-block.operational {
    background-color: green;
}

.status-block.warning {
    background-color: yellow;
}

.status-block.down {
    background-color: red;
}

.status-indicator {
    display: flex;
    align-items: center;
    font-size: 12px; /* Reduced size */
    color: green;
    white-space: nowrap; /* Ensure the status remains on a single line */
}

.status-dot {
    width: 8px; /* Reduced size */
    height: 8px; /* Reduced size */
    background-color: green;
    border-radius: 50%;
    margin-right: 5px;
}

/* Footer */
footer {
    background-color: #04284B;
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.footer-left,
.footer-center,
.footer-right {
    display: flex;
    align-items: center;
}

.footer-left .status-circle,
.footer-right .status-circle {
    margin-right: 5px;
}

/* Login Page Styles */
.login-container {
    max-width: 400px;
    margin: 50px auto;
    padding: 30px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.login-container h2 {
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 20px;
    color: #04284B;
}

.form-group {
    margin-bottom: 15px;
    text-align: left;
}

.form-group label {
    font-weight: bold;
    font-size: 1rem;
    color: #333;
}

.form-control {
    width: 100%;
    padding: 10px;
    margin: 5px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box;
    font-size: 1rem;
}

.btn-primary {
    background-color: #04284B;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    width: 100%;
}

.btn-primary:hover {
    background-color: #021d36;
}

.error-message {
    display: none;
    color: #f44336;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: center;
}

small.form-text {
    display: block;
    margin-top: 10px;
    font-size: 0.9rem;
    color: #777;
}

/* Menu Styles */
.menu-container {
    display: flex;
    justify-content: center;
    margin-top: 40px;
    margin-bottom: 40px;
    gap: 40px;
}

.menu-item {
    text-align: center;
    background-color: #04284B;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 3px 3px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s;
    width: 200px;
}

.menu-item:hover {
    transform: scale(1.05);
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.3);
}

.menu-item a {
    text-decoration: none;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.menu-icon {
    font-size: 3rem;
    margin-bottom: 10px;
}

.menu-label {
    font-size: 1.5rem;
    font-weight: bold;
}

/* Maintenance Page Styles */
.maintenance-container {
    padding: 20px;
}

.table-container {
    margin-top: 20px;
    width: 100%;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

table th,
table td {
    padding: 8px 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

table th {
    background-color: #04284B;
    color: white;
    font-weight: bold;
    text-transform: uppercase;
}

table tr {
    line-height: 1.2;
}

button.btn {
    background-color: #04284B;
    color: white;
    padding: 5px 15px;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
    border-radius: 50px;
    margin: 2px 4px;
}

button.btn:hover {
    background-color: #035085;
}

button.btn-edit {
    background-color: #28a745;
}

button.btn-delete {
    background-color: #dc3545;
}

button.btn-edit:hover {
    background-color: #218838;
}

button.btn-delete:hover {
    background-color: #c82333;
}

/* Additional Rounded Button Styles */
.btn-round-white {
    background-color: white;
    color: #04284B;
    padding: 10px 20px;
    border-radius: 50px;
    border: 2px solid #04284B;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    margin-right: 10px;
}

.btn-round-white:hover {
    background-color: #04284B;
    color: white;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 20px;
    width: 50%;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.3);
    border-radius: 5px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

input[type="text"],
input[type="url"] {
    width: 100%;
    padding: 10px;
    margin: 5px 0 15px 0;
    display: inline-block;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.header-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.header-right .btn-round-white {
    margin-left: 10px;
}
