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

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

.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 1rem;
}

header h1 {
    text-align: center;
    margin-bottom: 1rem;
}

header h1 a {
    color: #333;
    text-decoration: none;
}

.card {
    background: #fff;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 1rem;
}

h2 {
    margin-bottom: 0.75rem;
    color: #222;
}

h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: #555;
}

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

label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 600;
    font-size: 0.9rem;
}

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

input:focus, textarea:focus {
    outline: none;
    border-color: #4a90d9;
    box-shadow: 0 0 0 2px rgba(74, 144, 217, 0.2);
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: #4a90d9;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
}

.btn:hover {
    background: #3a7bc8;
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
}

.btn-approve {
    background: #2ecc71;
}
.btn-approve:hover {
    background: #27ae60;
}

.btn-deny {
    background: #e74c3c;
}
.btn-deny:hover {
    background: #c0392b;
}

.error {
    background: #fde8e8;
    color: #c0392b;
    padding: 0.75rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

/* Calendar */
.cal-month {
    margin-bottom: 2rem;
}

.cal-month-header {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 2;
    padding: 0.5rem 0;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid #f0f0f0;
    font-size: 1.1rem;
}

.hint {
    text-align: center;
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.cal-header {
    text-align: center;
    font-weight: 600;
    font-size: 0.8rem;
    color: #888;
    padding: 0.25rem;
}

.cal-day {
    text-align: center;
    padding: 0.75rem 0.25rem;
    border-radius: 8px;
    font-size: 0.95rem;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s;
    touch-action: manipulation;
    /* reset <button> browser defaults */
    border: none;
    background: none;
    font: inherit;
    color: inherit;
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
}

@media (hover: hover) {
    .cal-day:hover:not(.blocked):not(.past):not(.empty) {
        background: #e8f0fe;
    }

    .cal-day.jesse-away:hover {
        background: #ffe0b2;
    }

    .cal-day.allison-away:hover {
        background: #c8e6c9;
    }
}

.cal-day.empty {
    cursor: default;
}

.cal-day.blocked {
    background: #fde8e8;
    color: #c0392b;
    cursor: not-allowed;
}

.cal-day.past {
    color: #ccc;
    cursor: not-allowed;
}

.cal-day.jesse-away {
    background: #fff3e0;
}

.cal-day.allison-away {
    background: #e8f5e9;
}

.cal-day.selected {
    background: #4a90d9;
    color: #fff;
}

.cal-day.in-range {
    background: #d4e5f7;
}

.selection {
    position: sticky;
    top: 0;
    z-index: 10;
    margin-bottom: 1rem;
    padding: 1rem;
    background: #e8f0fe;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(74, 144, 217, 0.25);
}

.selection .btn {
    margin-top: 0.5rem;
}

.legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
    font-size: 0.85rem;
    color: #888;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.swatch {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    display: inline-block;
}

.swatch.available {
    background: #e8f0fe;
    border: 1px solid #4a90d9;
}

.swatch.jesse-away {
    background: #fff3e0;
    border: 1px solid #e65100;
}

.swatch.allison-away {
    background: #e8f5e9;
    border: 1px solid #2e7d32;
}

.swatch.blocked {
    background: #fde8e8;
    border: 1px solid #c0392b;
}

/* Floating calendar footer */
body:has(.cal-footer) {
    padding-bottom: 4.5rem;
}

.cal-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.1);
    z-index: 100;
}

.cal-footer-inner {
    max-width: 600px;
    margin: 0 auto;
    padding: 0.6rem 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.cal-footer .legend {
    flex: 1;
    margin-top: 0;
    justify-content: flex-start;
    font-size: 0.8rem;
    gap: 1rem;
}

.cal-footer-logout {
    font-size: 0.85rem;
    color: #888;
    text-decoration: none;
    white-space: nowrap;
}

.cal-footer-logout:hover {
    color: #333;
}

/* Status badges */
.status {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
}

.status-pending {
    background: #fef9e7;
    color: #f39c12;
}

.status-approved {
    background: #eafaf1;
    color: #27ae60;
}

.status-denied {
    background: #fde8e8;
    color: #c0392b;
}

/* Booking list */
.booking-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.booking-card {
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #ddd;
}

.booking-card.pending {
    border-left-color: #f39c12;
    background: #fffdf5;
}

.booking-card.approved {
    border-left-color: #27ae60;
    background: #f5fdf8;
}

.booking-card.denied {
    border-left-color: #c0392b;
    background: #fdf5f5;
}

.booking-actions {
    margin-top: 0.5rem;
    display: flex;
    gap: 0.5rem;
}

.muted {
    color: #aaa;
    font-style: italic;
}

.text-center {
    text-align: center;
    margin-top: 1rem;
}

a {
    color: #4a90d9;
}

/* Calendar footer info link */
.cal-footer-info {
    font-size: 0.85rem;
    color: #888;
    text-decoration: none;
    white-space: nowrap;
}

.cal-footer-info:hover {
    color: #333;
}

/* Info page */
.info-section {
    margin-top: 1.25rem;
}

.info-section p {
    margin-bottom: 0.5rem;
}

.info-note {
    margin-top: 0.5rem;
    color: #555;
}

.info-mta-links {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.info-recs {
    list-style: none;
    padding: 0;
    margin-bottom: 0.5rem;
}

.info-recs li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
    line-height: 1.5;
}

.info-recs li:last-child {
    border-bottom: none;
}
