/* Routinen: Skill plus Zeitpunkt gleich Routine, a list like the deck's connections, a small drawer for time and days. */
.grow { flex: 1; min-width: 0; }

.rt-eq { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
.rt-eq-part { display: inline-flex; align-items: center; gap: 8px; } /* a narrow screen breaks after "=", no arrow starts a line */
.rt-eq .tag { padding: 7px 13px; font-size: 11px; }
.rt-op { font: 500 15px/1 var(--font-mono); padding: 0 2px; }
.rt-to { margin: 0 2px; }
.rt-lands { margin-bottom: 32px; }
.rt-skeleton { padding: 10px 0 32px; }

.rt-group { margin-bottom: 30px; }
.rt-group > .label { margin-bottom: 6px; }
.rt-group-note { padding-bottom: 6px; max-width: 760px; }
.rt-row { align-items: start; }
.rt-row .body { min-width: 0; }
.rt-row > .iconbox { margin-top: 1px; }
.rt-row .m { margin-top: 3px; }
.rt-row .acts { display: grid; grid-template-columns: auto 74px 46px; justify-items: end; gap: 6px; padding-top: 4px; }
.rt-row .acts .rt-run { grid-column: 1; }
.rt-row .acts .rt-edit { grid-column: 2; }
.rt-row .acts .switch { grid-column: 3; }
.rt-sep { margin: 0 3px; }
.rt-last { display: flex; align-items: baseline; flex-wrap: wrap; gap: 3px 8px; }
.rt-last .dot { align-self: center; }
.rt-last .dot.work { background: currentColor; box-shadow: none; } /* the row's accent is the row's, not the dot's */
.rt-say { display: block; overflow-wrap: anywhere; }
.rt-say .openmark { margin-right: 4px; }
.rt-noteam {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px; border: 1.5px dashed var(--line-soft); border-radius: var(--radius-md);
}
.rt-noteam-text { flex: 1 1 220px; min-width: 0; }
.rt-row .t .chip { max-width: 100%; white-space: normal; overflow-wrap: anywhere; } /* a long client name stays in its row */
.switch.rt-next { background: var(--accent); }
.switch.rt-next::after { background: var(--on-accent); }

.item.focus .link { color: inherit; }
.item.focus .btn.rt-run { background: var(--surface-raised); border-color: var(--on-accent); color: var(--ink); } /* "Neue Routine" is the page's one filled pill */
.item.focus .btn.rt-run:hover:not(:disabled) { background: var(--surface-sunken); }
.item.focus .btn.rt-run:disabled { background: transparent; border-color: var(--on-accent); color: var(--on-accent); }
.item.focus .btn.ghost { background: transparent; border-color: transparent; color: var(--on-accent); }
.item.focus .btn.ghost:hover:not(:disabled) { background: var(--surface-raised); color: var(--ink); }
.item.focus .chip { background: var(--surface-raised); color: var(--ink); border-color: var(--line); }
.item.focus .tag.soft { color: var(--on-accent); border-color: var(--on-accent); }
.item.focus .openmark { border-color: var(--on-accent); }
.item.focus .switch { border-color: var(--on-accent); }
.item.focus .switch[aria-checked="true"] { background: var(--on-accent); }
.item.focus .switch[aria-checked="true"]::after { background: var(--accent); }

.rt-empty svg { width: 340px; max-width: 100%; }
.rt-empty-say { align-items: center; max-width: 560px; }
.rt-empty-ways { justify-content: center; gap: 16px; }

.rt-costs { padding-bottom: 40px; }

.rt-bg-head { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.rt-auto { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 40px; }
.rt-auto-name { font-size: 14px; font-weight: 700; margin-right: 4px; }

.rt-drawer { width: min(480px, 100vw); }
.rt-form { display: contents; }
.rt-form h2:focus, .dialog h2:focus { outline: none; }
.rt-level { align-self: flex-start; }
.rt-when { display: flex; flex-direction: column; gap: 10px; }
.rt-time .input { width: 130px; font-family: var(--font-mono); font-size: 14px; }
.rt-days { display: flex; flex-wrap: wrap; gap: 6px; }
.rt-day {
  width: 44px; height: 38px; border: 1.5px solid var(--line); border-radius: var(--radius-pill); background: var(--surface-raised);
  font-size: 13.5px; font-weight: 700;
}
.rt-day:hover { background: var(--surface-sunken); }
.rt-day[aria-pressed="true"], .rt-day[aria-pressed="true"]:hover { background: var(--surface-inverse); color: var(--on-inverse); border-color: var(--surface-inverse); }
.rt-danger { padding-top: 2px; }
.rt-danger .small { margin-bottom: 6px; }
.rt-danger .btn { margin-left: -12px; }
.rt-save { white-space: normal; text-align: center; }

@media (max-width: 1080px) {
  .rt-auto { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 820px) {
  .rt-row .acts { display: flex; align-items: center; gap: 8px; width: 100%; padding-top: 2px; }
  .rt-row .acts .switch { margin-left: auto; }
  .rt-eq .tag { padding: 6px 10px; }
}
