.office-calendar {
    display: grid;
    gap: 2rem;
    padding: 1rem 0;
}

.office-calendar-month {
    page-break-inside: avoid;
}

.office-calendar-header {
    margin-bottom: 0.75rem;
    text-align: center;
}

.office-calendar-header h2 {
    margin: 0;
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 600;
}

.office-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.5rem;
}

.office-calendar-grid > * {
    min-height: 5.5rem;
}

.day-name {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    color: #4a4a4a;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 0.25rem;
}

.day {
    background: #f5f5f5;
    border-radius: 0.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 0.75rem;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.07);
    color: #1f2933;
}

.day.status-weekend {
    border-style: dashed;
    background: #fff;
}

.day.status-empty {
    background: #fdfdfd;
    color: #444;
    opacity: 0.9;
}

.day.is-today {
    box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.2);
}

.day-number {
    font-size: 1.5rem;
    font-weight: 700;
    display: inline-flex;
    align-items: flex-start;
    gap: 0.15em;
}

.day-number-value {
    line-height: 1;
}

.day-number-suffix {
    font-size: 0.65em;
    font-weight: 600;
    line-height: 1;
    margin-top: 0.15em;
}

@media (min-width: 701px) {
    .day-number-suffix {
        margin-left: -2px;
        margin-top: 0;
    }
}

.day-status {
    font-size: 0.85rem;
    font-weight: 600;
}

.day-meta {
    display: none;
}

.status-anniston {
    background: #a6d8ff;
    color: #0b3d63;
}

.status-gadsden {
    background: #6b4c9a;
    color: #ffffff;
}

.status-admin {
    background: #d87800;
    color: #ffffff;
}

.status-closed {
    background: #e53e3e;
    color: #ffffff;
}

.status-weekend {
    background: #ffffff;
    color: #4a4a4a;
    border: 1px dashed #d1d5db;
}

.office-calendar-legend {
    list-style: none;
    margin: 0;
    padding: 1.5rem;
    display: grid;
    gap: 1rem;
    background: #f9fafb;
    border-radius: 0.75rem;
    border: 1px solid #e5e7eb;
}

.office-calendar-legend li {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    background: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

.legend-swatch {
    display: inline-block;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(15, 23, 42, 0.08);
    flex-shrink: 0;
}

.legend-label {
    font-weight: 700;
    font-size: 0.95rem;
    color: #0f172a;
}

.legend-description {
    font-size: 0.85rem;
    color: #475569;
}

.office-calendar-notice {
    font-size: 0.9rem;
    font-style: italic;
    margin: 0;
    padding: 0.75rem;
    background: #f8f8f8;
    border-left: 4px solid #6b4c9a;
}

.legend-swatch.status-anniston {
    background: #a6d8ff;
}

.legend-swatch.status-gadsden {
    background: #6b4c9a;
}

.legend-swatch.status-admin {
    background: #d87800;
}

.legend-swatch.status-closed {
    background: #e53e3e;
}

.legend-swatch.status-weekend {
    background: #ffffff;
}

@media (max-width: 800px) {
    .office-calendar-grid {
        gap: 0.35rem;
    }

    .office-calendar-grid > * {
        min-height: 4.5rem;
    }

    .day {
        padding: 0.6rem;
    }
}

@media (max-width: 700px) {
    .office-calendar {
        gap: 1.5rem;
    }

    .office-calendar-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .day-name,
    .day.day--pad {
        display: none;
    }

    .day {
        min-height: auto;
        padding: 1rem;
        border-radius: 1rem;
        box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
    }

    .day-number {
        display: none;
    }

    .day-meta {
        display: block;
        margin-top: 0.35rem;
    }

    .day-meta-date {
        display: block;
        font-size: 1.05rem;
        font-weight: 700;
        color: inherit;
    }

    .day-meta-weekday {
        display: block;
        font-size: 0.95rem;
        font-weight: 600;
        opacity: 0.85;
    }

    .day-status {
        margin-top: 0.5rem;
        font-size: 1.05rem;
    }

    .status-weekend {
        color: #1f2933;
    }

    .day.is-today {
        box-shadow: inset 0 0 0 2px rgba(14, 116, 144, 0.35);
    }
}

@media (max-width: 480px) {
    .office-calendar-grid {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .day {
        padding: 0.85rem;
    }
}

.calendar-fullwidth-template .calendar-fullwidth-container {
    width: 95%;
    max-width: 960px;
    margin: 0 auto;
    padding: 0 0 3rem;
}

@media (max-width: 1024px) {
    .calendar-fullwidth-template .calendar-fullwidth-container {
        width: 95%;
        padding-bottom: 3rem;
    }
}

@media (max-width: 640px) {
    .calendar-fullwidth-template .calendar-fullwidth-container {
        width: 95%;
    }
}

@media print {
    .office-calendar {
        gap: 1.5in;
    }

    .office-calendar-month {
        break-after: page;
    }

    .office-calendar-notice {
        break-before: avoid;
    }
}
