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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

header {
    background-color: #2c3e50;
    color: white;
    padding: 1rem 2rem;
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: 1.5rem;
}

header a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background-color 0.3s;
}

header a:hover {
    background-color: #34495e;
}

main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.login-container {
    max-width: 400px;
    margin: 4rem auto;
    padding: 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.login-container h2 {
    margin-bottom: 1.5rem;
    text-align: center;
}

.login-container form div {
    margin-bottom: 1rem;
}

.login-container label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.login-container input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.login-container button {
    width: 100%;
    padding: 0.75rem;
    background-color: #2c3e50;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.login-container button:hover {
    background-color: #34495e;
}

.error {
    background-color: #e74c3c;
    color: white;
    padding: 0.75rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.container {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Navigation */
.nav-links {
    display: flex;
    gap: 0.5rem;
}

/* Day groups on dashboard */
.day-group {
    margin-bottom: 2rem;
}

.day-group h3 {
    color: #2c3e50;
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #2c3e50;
}

.task-list {
    list-style: none;
    padding-left: 1rem;
}

.task-list li {
    padding: 0.5rem 0;
}

.task-link {
    color: #333;
    text-decoration: none;
    cursor: pointer;
}

.task-link:hover {
    color: #2c3e50;
    text-decoration: underline;
}

.no-tasks {
    color: #999;
    font-style: italic;
    padding-left: 1rem;
}

/* Forms */
.task-form, .schedule-form, .date-form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group input[type="month"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.form-group textarea {
    resize: vertical;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.3s;
}

.btn-primary {
    background-color: #2c3e50;
    color: white;
}

.btn-primary:hover {
    background-color: #34495e;
}

.btn-secondary {
    background-color: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background-color: #7f8c8d;
}

.btn-danger {
    background-color: #e74c3c;
    color: white;
}

.btn-danger:hover {
    background-color: #c0392b;
}

.btn-small {
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
}

/* Schedule list */
.schedule-list {
    list-style: none;
    padding: 0;
}

.schedule-list li {
    padding: 0.75rem;
    background-color: #f8f9fa;
    border-radius: 4px;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* All tasks page */
.view-controls {
    margin-bottom: 1.5rem;
    display: flex;
    gap: 0.5rem;
}

.task-count {
    margin-bottom: 1rem;
    color: #666;
}

.schedule-desc {
    color: #666;
    font-size: 0.9rem;
}

.task-date {
    color: #666;
    font-size: 0.9rem;
    margin-left: 0.5rem;
}

.task-assignment {
    color: #666;
    font-size: 0.9rem;
    margin-left: 0.5rem;
    font-style: italic;
}

.pagination {
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
    align-items: center;
}

.page-info {
    color: #666;
}

/* Print view */
.print-view {
    font-family: monospace;
    line-height: 1.4;
}

.print-line {
    padding: 0.25rem 0;
}

/* Print styles */
@media print {
    body {
        background: white;
    }

    header, .no-print {
        display: none !important;
    }

    .container {
        box-shadow: none;
        padding: 0;
    }

    .print-view {
        font-size: 10pt;
        line-height: 1.2;
    }

    .print-line {
        padding: 0;
        page-break-inside: avoid;
    }

    .task-link {
        color: #000;
        text-decoration: none;
    }

    @page {
        margin: 0.5in;
    }

    .task-creator {
        display: none;
    }
}

/* Task creator info */
.task-creator {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #ddd;
    color: #666;
    font-size: 0.9rem;
}

/* About page */
.about-footer {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #ddd;
    color: #666;
    font-style: italic;
    text-align: center;
}

/* Admin user table */
.user-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.user-table thead {
    background-color: #2c3e50;
    color: white;
}

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

.user-table tbody tr:hover {
    background-color: #f8f9fa;
}

.user-table th {
    font-weight: 600;
}

/* User selection grid */
.user-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.user-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-checkbox input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.user-checkbox label {
    margin: 0;
    cursor: pointer;
}

@media (max-width: 768px) {
    .user-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .user-grid {
        grid-template-columns: 1fr;
    }
}
