/* R3-20 / R4-10: the vendor's persian-datepicker is built for right-to-left
   pages: it floats the grid and header cells right and sets direction:rtl on
   the day table, so on an English page the weekdays read Sa..Su and the last
   column is clipped. Every rule is scoped to body:not(.rtl) (the vendor's own
   RTL marker, see layout/overflow_guard), so Arabic keeps its mirrored grid. */
body:not(.rtl) .datepicker-plot-area {
    max-width: 100%;
    box-sizing: border-box;
}

body:not(.rtl) .datepicker-plot-area .datepicker-day-view .table-days {
    direction: ltr;
}

/* The vendor gives every plot-area table width:90%; margin:0 5%, which shifts the
   100%-wide day table 5% right, out of line with its header and past the
   overflow:hidden plot area. */
body:not(.rtl) .datepicker-plot-area .datepicker-day-view .table-days {
    margin-left: 0;
    margin-right: 0;
    /* the panel theme pads the table 12px a side on top of width:100% (content-box), which
       widens it past the plot area and moves the day columns off the header cells */
    box-sizing: border-box;
    padding-left: 0;
    padding-right: 0;
}

body:not(.rtl) .datepicker-plot-area .datepicker-day-view .month-grid-box {
    float: left;
}

body:not(.rtl) .datepicker-plot-area .datepicker-day-view .month-grid-box .header .header-row-cell {
    float: left;
}

/* The panel theme grids each week row with a 6px column gap, which the header
   row does not have, so day columns drift up to 4px off their weekday letters.
   No column gap: each day sits under its header cell. */
body:not(.rtl) .datepicker-plot-area .datepicker-day-view .table-days tr {
    column-gap: 0;
}
