/* 145 Alive Event Logging System Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f4f4f4;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

header {
    background: #003366;
    color: white;
    padding: 20px;
    margin: -20px -20px 20px -20px;
    border-radius: 5px 5px 0 0;
}

header h1 {
    font-size: 24px;
    margin-bottom: 10px;
}

.nav {
    margin-top: 15px;
}

.nav a {
    color: white;
    text-decoration: none;
    margin-right: 15px;
    padding: 5px 10px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
}

.nav a:hover {
    background: rgba(255,255,255,0.2);
}

.user-info {
    float: right;
    font-size: 14px;
}

.user-info a {
    color: white;
    text-decoration: underline;
}

h2 {
    color: #003366;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #003366;
}

h3 {
    color: #003366;
    margin: 20px 0 10px 0;
}

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

label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

input[type="text"],
input[type="email"],
input[type="password"],
select,
textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
}

textarea {
    min-height: 80px;
    resize: vertical;
}

input[type="checkbox"] {
    margin-right: 5px;
}

button,
.btn {
    background: #003366;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
}

button:hover,
.btn:hover {
    background: #004488;
}

.btn-secondary {
    background: #666;
}

.btn-secondary:hover {
    background: #777;
}

.btn-danger {
    background: #cc0000;
}

.btn-danger:hover {
    background: #dd0000;
}

.btn-small {
    padding: 5px 10px;
    font-size: 12px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

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

table th {
    background: #003366;
    color: white;
    font-weight: bold;
}

table tr:hover {
    background: #f9f9f9;
}

table td.actions {
    white-space: nowrap;
}

table td.actions a,
table td.actions button {
    margin-right: 5px;
}

.message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 3px;
}

.message.success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.message.error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.message.info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.auth-container {
    max-width: 400px;
    margin: 50px auto;
}

.auth-container .container {
    padding: 30px;
}

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

.mt-2 {
    margin-top: 20px;
}

.mb-2 {
    margin-bottom: 20px;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
}

.card {
    background: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.invalid {
    border-color: #cc0000 !important;
}

.error-text {
    color: #cc0000;
    font-size: 12px;
    margin-top: 5px;
}

.help-text {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

@media (max-width: 768px) {
    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }
    
    table {
        font-size: 12px;
    }
    
    table th,
    table td {
        padding: 5px;
    }
    
    .user-info {
        float: none;
        margin-top: 10px;
    }
}

/* Log entry table specific styles */
.log-table {
    font-size: 13px;
}

.log-table input[type="text"] {
    padding: 4px;
    font-size: 12px;
}

.log-table td {
    padding: 5px;
}

.log-table .btn-small {
    padding: 3px 8px;
}

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

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    border-radius: 5px;
    width: 80%;
    max-width: 500px;
}

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

.modal-close:hover {
    color: #000;
}
