/* css/base.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

:root {
    --primary: #2563eb; /* Modern Blue */
    --primary-hover: #1d4ed8;
    --bg-body: #f3f4f6;
    --bg-card: #ffffff;
    --text-main: #1f2937;
    --text-muted: #6b7280;
    --border: #e5e7eb;
    --success: #10b981;
    --danger: #ef4444;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background-color: --bg-body;
    color: var(--text-main);
    margin: 0;
    padding: 0;
    font-size: 14px;
}

/* --- Layout --- */
.navbar {
    background: #1e293b;
    color: white;
    padding: 0.8rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.brand { font-size: 1.2rem; font-weight: 600; }
.user-menu a { color: #94a3b8; margin-left: 15px; text-decoration: none; }
.user-menu a:hover { color: white; }

.container {
    max-width: 1300px;
    margin: 2rem auto;
    padding: 0 1rem;
}

/* --- Cards --- */
.card {
    background: var(--bg-card);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 1px solid var(--border);
    margin-bottom: 2rem;
    padding: 1.5rem;
}

/* --- Forms & Filters --- */
.filter-form {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}
input[type="text"], input[type="password"] {
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 4px;
    outline: none;
}
input[type="text"]:focus { border-color: var(--primary); }

.checkboxes { display: flex; gap: 10px; }
.check-label {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    background: #f9fafb;
    border: 1px solid var(--border);
}
.check-label.success { color: #047857; }
.check-label.failed { color: #b91c1c; }

/* --- Buttons --- */
.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
}
.btn-primary:hover { background: var(--primary-hover); }
.btn-secondary {
    background: white;
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    display: inline-block;
}

/* --- Table --- */
.data-table {
    width: 100%;
    border-collapse: collapse;
}
.data-table th {
    text-align: left;
    padding: 12px;
    background: #f9fafb;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
    font-weight: 600;
}
.data-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border);
}
.data-table tr:hover { background: #f9fafb; }

/* Badges */
.badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
}
.badge-success { background: #d1fae5; color: #065f46; }
.badge-failed { background: #fee2e2; color: #991b1b; }
.badge-warning { background: #fef3c7; color: #f1af28; }

/* --- Login Page --- */
.login-page {
    background: #f3f4f6;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}
.login-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}
.login-header { margin-bottom: 2rem; color: var(--primary); }
.form-group { margin-bottom: 1rem; text-align: left; }
.form-group label { display: block; margin-bottom: 5px; font-weight: 600; }
.form-group input { width: 100%; }
.btn-block { width: 100%; padding: 10px; font-size: 1rem; }
.alert-error {
    background: #fee2e2; color: #991b1b;
    padding: 10px; border-radius: 4px; margin-bottom: 1rem;
}
.text-right { text-align: right; }
.text-center { text-align: center; }
.btn-icon.delete { color: #d1d5db; transition: color 0.2s; }
.btn-icon.delete:hover { color: var(--danger); }

/* --- MODAL (POPUP) STYLES --- */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5); /* Black w/ opacity */
}

.modal-content {
    background-color: #fff;
    margin: 50px auto;
    padding: 20px;
    border: 1px solid #888;
    width: 90%;
    max-width: 1200px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    max-height: 80vh; /* Allow scrolling if list is long */
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.close-modal {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: #000;
}

.disk-segment {
    display: inline-block;
    margin-right: 8px;
    font-size: 1.05em; /* Requested: little bigger */
    font-weight: 500;
}

.text-success { color: #059669; }
.text-warning { color: #d97706; }
.text-danger  { color: #dc2626; }

/* Blinking animation for critical alerts */
.blink-alert {
    color: #dc2626;
    margin-right: 5px;
}
