body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 10px;
    background-color: #f5f5f5;
    line-height: 1.6;
}
.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.header {
    padding-bottom: 8px;
    margin-bottom: 8px;
    display: flex;
    justify-content: flex-end;
    align-items: flex-start;
}
.nav {
    margin: 0;
}
.nav a {
    text-decoration: none;
    color: #4CAF50;
    margin-right: 20px;
    font-weight: 500;
}
.nav a:hover {
    text-decoration: underline;
}
.btn {
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    margin: 5px;
    min-width: 100px;
    text-align: center;
    height: 40px;
    box-sizing: border-box;
    line-height: 20px;
}
.btn:hover {
    background-color: #45a049;
}
.btn-complete {
    background-color: #4CAF50;
}
.btn-complete:hover {
    background-color: #45a049;
}
.btn-danger {
    background-color: #f44336;
}
.btn-danger:hover {
    background-color: #da190b;
}

/* Dropdown menu styles */
.dropdown {
    position: relative;
    display: inline-block;
}
.dropdown-toggle {
    background-color: #666;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}
.dropdown-toggle:hover {
    background-color: #555;
}
.dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    background-color: white;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    border-radius: 4px;
    z-index: 1;
}
.dropdown-menu a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
}
.dropdown-menu a:hover {
    background-color: #f1f1f1;
}
.dropdown:hover .dropdown-menu {
    display: block;
}
.messages {
    margin: 20px 0;
}
.message {
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
    cursor: pointer;
    transition: opacity 0.5s ease-out;
}
.message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}
.message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}
.form-group {
    margin: 15px 0;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}
.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}
.event-card {
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin: 10px 0;
    background: #fafafa;
    transition: all 0.2s ease;
}

/* Time-based color coding */
.event-card.time-status-not-due {
    border-color: #4CAF50;
    background: #e8f5e8;
}
.event-card.time-status-due-soon {
    border-color: #FFC107;
    background: #fff8e1;
}
.event-card.time-status-due-now {
    border-color: #FF5722;
    background: #fce4ec;
}
.event-card.time-status-overdue {
    border-color: #9C27B0;
    background: #f3e5f5;
}
.event-card.time-status-completed {
    border-color: #607D8B;
    background: #eceff1;
    opacity: 0.7;
}

/* Emergency overlay styling */
.event-card.emergency {
    border-style: dashed;
    border-width: 3px;
    box-shadow: 0 0 10px rgba(255, 152, 0, 0.3);
}

/* Status badge styling */
.status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: bold;
    color: white;
}
.status-badge.status-not-due {
    background-color: #4CAF50;
}
.status-badge.status-due-soon {
    background-color: #FFC107;
    color: #333;
}
.status-badge.status-due-now {
    background-color: #FF5722;
}
.status-badge.status-overdue {
    background-color: #9C27B0;
}
.status-badge.status-completed {
    background-color: #607D8B;
}
.status-badge.status-grey {
    background-color: #999;
}

/* Time pill styling */
.time-pill {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: bold;
    color: white;
    margin-right: 8px;
    display: inline-block;
}

.time-pill.pill-black {
    background-color: #333 !important;
    color: white !important;
}

.time-pill.pill-yellow {
    background-color: #FFC107 !important;
    color: #333 !important;
}

.time-pill.pill-orange {
    background-color: #FF5722 !important;
    color: white !important;
}

.time-pill.pill-green {
    background-color: #4CAF50 !important;
    color: white !important;
}

.time-pill.pill-purple {
    background-color: #9C27B0 !important;
    color: white !important;
}

.time-pill.pill-red {
    background-color: #f44336 !important;
    color: white !important;
}
.event-meta {
    color: #666;
    font-size: 0.9em;
    margin: 5px 0;
}
.centered-section {
    text-align: center;
    padding: 20px 10px;
    margin-bottom: 15px;
}
.centered-section h2 {
    color: #333;
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 15px;
}
.btn-primary {
    background-color: #2196F3;
}
.btn-primary:hover {
    background-color: #1976D2;
}

/* Recurring event styles */
.recurrence-info {
    padding: 8px 0;
    margin: 10px 0;
    font-size: 0.9em;
}

.recurrence-pattern {
    color: #1976D2;
    font-weight: 500;
}

.recurrence-badge {
    display: inline-block;
    padding: 2px 8px;
    background: #E3F2FD;
    color: #1976D2;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: 500;
    margin-left: 10px;
}

/* Older events styling */
.older-event {
    background: #f9f9f9;
    border-color: #ccc;
}

.btn-complete-grey {
    background-color: #999;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    margin: 5px;
    min-width: 100px;
    text-align: center;
    height: 40px;
    box-sizing: border-box;
    line-height: 20px;
}

.btn-complete-grey:hover {
    background-color: #777;
}

.btn-danger-grey {
    background-color: #aaa;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    margin: 5px;
    min-width: 100px;
    text-align: center;
    height: 40px;
    box-sizing: border-box;
    line-height: 20px;
}

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