/* ---------------------------------------------------------------------------
   DayPilot Calendar – Lemaro overrides (calendar_default theme)

   The DayPilot Pro JavaScript engine injects its own base "calendar_default"
   stylesheet at runtime. This file layers Lemaro-specific refinements on top so
   the rendered week matches the reference screenshot: compact coloured vertical
   event cards, a clear time gutter and small round status badges inside events.
   --------------------------------------------------------------------------- */

/* Time gutter: big hour, small superscript minutes ('8' + '00'). */
.calendar_default_rowheader_inner {
    font-size: 13px;
    color: #5b6b7a;
    padding-right: 6px;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
}

.calendar_default_rowheader_inner sup {
    font-size: 9px;
    margin-left: 1px;
}

/* Column header hierarchy: level 1 = date, level 2 = inspector. */
.calendar_default_colheader {
    overflow: hidden; /* stay within scroll container */
}

/* Clamp the date (level-0) row to 24 px; headerLevelHeights handles allocation. */
.calendar_default_colheader[data-y="0"] .calendar_default_colheader_inner {
    height: 24px !important;
    align-items: center;
    font-size: 12px;
    font-weight: 600;
    color: #1f2d3d;
}

.calendar_default_colheader_inner {
    font-size: 12px;
    font-weight: 600;
    color: #1f2d3d;
    text-align: center;
    overflow: hidden;
}

/* Vertical text wrapper injected by wireDiagonalHeaders() for leaf columns. */
.ldp-vert-wrap {
    display: flex;
    align-items: flex-end;   /* name reads from bottom up */
    justify-content: center;
    height: 100%;
    width: 100%;
    overflow: hidden;
    padding-bottom: 4px;
}

.ldp-vert-text {
    writing-mode: vertical-rl;
    transform: rotate(180deg);  /* bottom → top direction */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 64px;
    font-size: 11px;
    font-weight: 600;
    color: #1f2d3d;
}

.calendar_default_cornerright,
.calendar_default_corner_inner {
    background: #f4f6f8;
}

/* Coloured vertical event cards. */
.calendar_default_event_inner {
    font-size: 11px;
    line-height: 1.15;
    padding: 2px 3px;
    border-radius: 3px;
    color: #1f2d3d;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
}

.calendar_default_event_bar {
    border-radius: 3px 0 0 3px;
}

/* Lemaro status badges rendered inside event HTML. */
.ldp-event {
    display: flex;
    flex-direction: column;
    gap: 0;
    height: 100%;
}

.ldp-event__title {
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ldp-event__meta {
    font-size: 10px;
    color: #4a5a6a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ldp-event__type {
    font-size: 10px;
    color: #4a5a6a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}

/* Traffic-light status rows (one per workflow step).
   Matches LemaroPlanning's fa-plus-circle (green) / fa-minus-circle (red) look:
   - Green dot with + = stap is geactiveerd (bool = true)
   - Red  dot with − = stap is niet geactiveerd (bool = false)
*/
.ldp-traffic {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 2px;
}

.ldp-tl {
    display: flex;
    align-items: center;
    gap: 3px;
    white-space: nowrap;
    line-height: 1;
    padding: 0;
    min-height: 14px;
}

/* The circle itself — sized to match fa-2x icon at small scale */
.ldp-tl__dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    font-weight: 900;
    color: #fff;
    flex-shrink: 0;
    /* Outer white ring mimics Font Awesome circle icon border */
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.70);
}

.ldp-tl--red   .ldp-tl__dot { background: #d63031; } /* fa-minus-circle red  */
.ldp-tl--green .ldp-tl__dot { background: #27ae60; } /* fa-plus-circle  green */

.ldp-tl__label {
    font-size: 10px;
    font-weight: 400;
    color: #1f2d3d;
    line-height: 1;
}

/* Legacy badge styles kept for backward compatibility. */
.ldp-badges {
    margin-top: auto;
    display: flex;
    gap: 3px;
    align-items: center;
}

.ldp-badge {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 8px;
    font-weight: 700;
    color: #fff;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .65);
}

.ldp-badge--red    { background: #e3342f; }
.ldp-badge--green  { background: #38a169; }
.ldp-badge--amber  { background: #dd9b22; }
