/* group-a.css — page-specific styles for dashboard, calendar, bookings, customers */

/* ---------- shared helpers for this group */
.min0 { min-width: 0; }
.pill-xs { padding: 1px 7px; font-size: 10px; }
.bk-text, .cust-notes { white-space: pre-wrap; word-break: break-word; }
.field-check { align-self: end; min-height: 40px; }
.kv .avatar { width: 22px; height: 22px; font-size: 10px; vertical-align: middle; }

/* ---------- dashboard */
.dash-time { min-width: 56px; text-align: center; }
.dash-time .strong { font-size: 16px; font-variant-numeric: tabular-nums; }
.dash-item .avatar { width: 28px; height: 28px; font-size: 11px; }
.dash-revenue { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.dash-revenue .strong { font-size: 18px; }
.timeline a.tl-item:hover { background: var(--surface-2); margin: 0 -8px; padding-left: 8px; padding-right: 8px; border-radius: 8px; }
.status-strip a.status-count:hover { border-color: var(--border-strong); background: var(--surface-2); }
@media (max-width: 700px) {
  .dash-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .dash-kpis .kpi { padding: 12px; min-height: 72px; gap: 10px; }
  .dash-kpis .kpi-icon { width: 36px; height: 36px; }
  .dash-item .phone-links { display: none; }
}

/* ---------- calendar */
.cal-toolbar .cal-date { width: auto; }
.cal-title { font-size: 18px; }
.cal-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.cal-day { display: grid; grid-template-columns: 60px repeat(var(--cal-bays, 2), minmax(170px, 1fr)); min-width: 100%; }
.cal-corner, .cal-head { position: sticky; top: 0; z-index: 3; background: var(--surface-2); border-bottom: 1px solid var(--border); padding: 10px 12px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); text-align: center; }
.cal-corner { position: sticky; left: 0; z-index: 4; }
.cal-times { position: sticky; left: 0; z-index: 2; background: var(--surface); }
.cal-time { height: var(--cal-row, 56px); font-size: 12px; color: var(--muted); padding: 4px 6px 0 0; text-align: right; border-top: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.cal-time:first-child { border-top-color: transparent; }
.cal-col { position: relative; border-left: 1px solid var(--border); display: flex; flex-direction: column; }
.cal-cell { height: var(--cal-row, 56px); border: 0; border-top: 1px dashed var(--border); background: transparent; cursor: pointer; padding: 0; width: 100%; }
.cal-cell:first-child { border-top-color: transparent; }
.cal-cell:hover { background: #fffbeb; }
.cal-cell:hover::after { content: "+"; color: var(--accent-600); font-weight: 800; font-size: 18px; }
.cal-block { position: absolute; left: 4px; right: 4px; display: block; border-radius: 8px; padding: 6px 8px; background: var(--blk, var(--accent)); color: #fff; font-size: 12px; line-height: 1.3; overflow: hidden; box-shadow: 0 1px 3px rgba(15,23,42,.25); border-left: 4px solid rgba(0,0,0,.18); z-index: 1; transition: transform .08s, box-shadow .08s; }
.cal-block:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); z-index: 2; }
.cal-block.faded { opacity: .45; filter: grayscale(.6); z-index: 0; }
.cal-block-head { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.cal-block-time { font-weight: 700; font-variant-numeric: tabular-nums; }
.cal-block-name { font-weight: 700; font-size: 13px; margin-top: 2px; }
.cal-block-sub { opacity: .92; }
.cal-block-sub .icon { width: 13px; height: 13px; vertical-align: -2px; }
.cal-block-services { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cal-block .pill-xs { background: rgba(255,255,255,.9); }

.cal-week { display: grid; grid-template-columns: repeat(7, minmax(130px, 1fr)); gap: 8px; }
.cal-wday { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); display: flex; flex-direction: column; min-height: 160px; box-shadow: var(--shadow); overflow: hidden; }
.cal-wday.closed { background: var(--surface-2); }
.cal-wday.closed .cal-wday-body { opacity: .7; }
.cal-wday.today { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
.cal-wday-head { border: 0; background: var(--surface-2); border-bottom: 1px solid var(--border); padding: 8px 10px; font: inherit; cursor: pointer; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; text-align: left; min-height: 44px; }
.cal-wday-head:hover { background: var(--accent-soft); }
.cal-wday.today .cal-wday-head { background: var(--accent-soft); }
.cal-wday-name { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.cal-wday-num { font-size: 18px; font-weight: 800; }
.cal-wday-head .small { margin-left: auto; }
.cal-wday-body { padding: 6px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.cal-wblock { display: flex; gap: 6px; align-items: center; padding: 5px 8px; border-radius: 6px; background: var(--blk, var(--accent)); color: #fff; font-size: 12px; font-weight: 600; border-left: 3px solid rgba(0,0,0,.18); min-height: 32px; }
.cal-wblock:hover { filter: brightness(1.08); }
.cal-wblock.faded { opacity: .45; filter: grayscale(.6); }
.cal-wblock-time { font-variant-numeric: tabular-nums; flex: none; }
.cal-wempty { padding: 6px 4px; }
.cal-wday-add { margin: 0 6px 6px auto; }
@media (max-width: 700px) {
  .cal-toolbar .cal-new span { display: none; }
  .cal-toolbar .cal-new { width: 40px; padding: 8px; }
  .cal-day { grid-template-columns: 52px repeat(var(--cal-bays, 2), minmax(150px, 1fr)); }
  .cal-time { font-size: 11px; }
  .cal-week { grid-template-columns: 1fr; }
  .cal-wday { min-height: 0; }
  .cal-wday-body:empty { display: none; }
}

/* ---------- bookings */
.bk-intake button { display: inline-flex; align-items: center; gap: 6px; }
.bk-intake .icon { width: 16px; height: 16px; }
.bk-edit-slots .slot-grid { grid-template-columns: repeat(auto-fill, minmax(68px, 1fr)); }
.page-booking .kv dd { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* ---------- customers */
.cust-vehicle .icon { vertical-align: -4px; }
.cust-kpis .kpi { min-height: 76px; }
@media (max-width: 700px) {
  .cust-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .cust-kpis .kpi { padding: 10px; flex-direction: column; align-items: flex-start; gap: 6px; }
  .cust-kpis .kpi-icon { width: 30px; height: 30px; }
  .cust-kpis .kpi-icon .icon { width: 16px; height: 16px; }
  .cust-kpis .kpi-value { font-size: 17px; }
  .cust-kpis .kpi-label { font-size: 11px; }
}

/* ---------- services */
.svc-desc { max-width: 420px; white-space: normal; }
.page-services .table td:last-child { white-space: nowrap; }
