diff --git a/app/globals.css b/app/globals.css index fb49981..e05840c 100644 --- a/app/globals.css +++ b/app/globals.css @@ -104,6 +104,18 @@ background: var(--color-surface-hover) !important; } +/* ── Park month calendar — responsive row heights ───────────────────────── */ +/* Mobile: fixed uniform rows so narrow columns don't cause height variance */ +.park-calendar-grid { + grid-auto-rows: 72px; +} +/* sm+: let rows breathe and grow with their content (cells are wide enough) */ +@media (min-width: 640px) { + .park-calendar-grid { + grid-auto-rows: minmax(96px, auto); + } +} + /* ── Pulse animation for skeleton ───────────────────────────────────────── */ @keyframes pulse { 0%, 100% { opacity: 1; } diff --git a/components/ParkMonthCalendar.tsx b/components/ParkMonthCalendar.tsx index 537bf63..d31bd03 100644 --- a/components/ParkMonthCalendar.tsx +++ b/components/ParkMonthCalendar.tsx @@ -119,15 +119,15 @@ export function ParkMonthCalendar({ parkId, year, month, monthData, today, timez {/* - All day cells in ONE flat grid so every row shares the same - fixed height — no per-week wrapper divs that could produce - rows of different heights on mobile. + All day cells in ONE flat grid — eliminates per-week wrapper + divs that caused independent row heights and the slant effect. + Row height is controlled responsively via .park-calendar-grid CSS: + mobile = 72px fixed, sm+ = minmax(96px, auto). */} -
+
{cells.map((cell, idx) => { const ci = idx % 7; const isLastRow = idx >= cells.length - 7; @@ -137,6 +137,7 @@ export function ParkMonthCalendar({ parkId, year, month, monthData, today, timez if (!cell.day || !cell.iso) { return (
- {/* Status — single-line pill so all cells stay uniform height */} + {/* ── Mobile status: colored dot only (sm:hidden) ──────── */} + {/* Cells are ~55px wide on mobile — no room for hours text */} {!dayData ? ( - + + ) : isOpen ? ( +
+ ) : null} + + {/* ── Desktop status: full pill with hours (hidden sm:block) */} + {!dayData ? ( + ) : isPH && isOpen ? ( -
-
+
Passholder
-
- {dayData.hoursLabel} {tzAbbr} +
+ {dayData.hoursLabel} +
+
+ {tzAbbr}
) : isOpen ? ( -
-
- {dayData.hoursLabel} {tzAbbr} +
+ {dayData.hoursLabel} +
+
+ {tzAbbr}
) : ( - · + · )}
);