:root {
  color-scheme: dark;
  --bg: #070c17;
  --bg-2: #0f172a;
  --card: rgba(20, 30, 48, 0.78);
  --card-solid: #162136;
  --card-hover: rgba(30, 45, 70, 0.92);
  --border: rgba(148, 163, 184, 0.14);
  --border-strong: rgba(148, 163, 184, 0.28);
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-2: #818cf8;
  --gold: #f59e0b;
  --green: #10b981;
  --danger: #ef4444;
  --radius: 20px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background:
    radial-gradient(circle at 12% 8%, rgba(56, 189, 248, 0.14) 0%, transparent 38%),
    radial-gradient(circle at 88% 12%, rgba(129, 140, 248, 0.13) 0%, transparent 40%),
    linear-gradient(180deg, var(--bg-2) 0%, var(--bg) 100%);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

.hidden {
  display: none !important;
}

/* Login Screen */
.login-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  width: 100%;
  max-width: 400px;
  background: var(--card);
  backdrop-filter: blur(18px);
  border: 1px solid var(--border-strong);
  border-radius: 24px;
  padding: 32px 28px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.login-logo {
  font-size: 2.2rem;
  margin-bottom: 10px;
}

.login-card h1 {
  font-size: 1.55rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.login-card p {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 20px;
}

/* Main Dashboard Shell */
.shell {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px 20px 36px;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.clock-block {
  display: flex;
  align-items: center;
  gap: 16px;
}

.clock-time {
  font-size: clamp(2.15rem, 3.6vw, 2.7rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 0.95;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(135deg, #f8fafc, #93c5fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  flex-shrink: 0;
}

.greeting-wrap {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
  padding-left: 16px;
  border-left: 1px solid rgba(148, 163, 184, 0.24);
}

.greeting-line {
  font-size: 1.06rem;
  font-weight: 700;
  line-height: 1.2;
}

.date-line {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.2;
}

@media (max-width: 440px) {
  .clock-block {
    gap: 12px;
  }
  .greeting-wrap {
    padding-left: 12px;
  }
}

/* Search Bar */
.search-form {
  flex: 1;
  min-width: 260px;
  max-width: 480px;
  display: flex;
  align-items: center;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  padding: 4px 6px;
  gap: 6px;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.search-form:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.16);
}

.search-engine-select {
  background: rgba(30, 41, 59, 0.9);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 7px 9px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.search-input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 0.94rem;
  padding: 7px 6px;
  min-width: 0;
}

.search-input:focus {
  outline: none;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Buttons & Inputs */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 11px;
  border: 1px solid var(--border);
  background: var(--card-solid);
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.btn:hover {
  background: #23324d;
  border-color: var(--border-strong);
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: linear-gradient(135deg, #38bdf8, #6366f1);
  border-color: transparent;
  color: #060b16;
  font-weight: 800;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #7dd3fc, #818cf8);
}

.btn-ghost {
  background: rgba(20, 30, 48, 0.55);
  color: var(--muted);
}

.btn-ghost:hover {
  color: var(--text);
}

.btn-sm {
  padding: 6px 10px;
  font-size: 0.78rem;
  border-radius: 9px;
}

.btn-icon {
  padding: 6px 8px;
  font-size: 0.82rem;
  line-height: 1;
}

.btn-danger {
  background: rgba(239, 68, 68, 0.14);
  border-color: rgba(239, 68, 68, 0.32);
  color: #fca5a5;
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.24);
}

.input, .textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 11px;
  border: 1px solid var(--border);
  background: rgba(10, 16, 30, 0.85);
  color: var(--text);
  font-size: 0.92rem;
  font-family: inherit;
}

.input:focus, .textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.inline-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
}

.span-12 { grid-column: span 12; }
.span-8  { grid-column: span 8; }
.span-7  { grid-column: span 7; }
.span-6  { grid-column: span 6; }
.span-5  { grid-column: span 5; }
.span-4  { grid-column: span 4; }

@media (max-width: 1080px) {
  .span-8, .span-7, .span-6, .span-5, .span-4 {
    grid-column: span 12;
  }
}

.card {
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.card-title {
  font-size: 0.84rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Quick Links Grid */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 10px;
}

.link-tile {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 13px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid var(--border);
  transition: transform 0.14s ease, border-color 0.15s ease, background 0.15s ease;
  min-width: 0;
}

.link-tile:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.45);
  background: var(--card-hover);
}

.link-icon {
  font-size: 1.45rem;
  line-height: 1;
  flex-shrink: 0;
}

.link-info {
  min-width: 0;
  flex: 1;
}

.link-name {
  font-weight: 700;
  font-size: 0.92rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.link-desc {
  font-size: 0.76rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tile-del {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid rgba(239, 68, 68, 0.4);
  background: rgba(15, 23, 42, 0.9);
  color: #fca5a5;
  font-size: 0.75rem;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
}

.edit-mode .tile-del {
  display: inline-flex;
}

/* Server Monitor */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

@media (max-width: 640px) {
  .metrics-row {
    grid-template-columns: 1fr;
  }
}

.metric-box {
  background: rgba(10, 16, 30, 0.62);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 13px;
}

.metric-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 6px;
}

.metric-label {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.metric-val {
  font-size: 1.25rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.metric-sub {
  font-size: 0.76rem;
  color: var(--muted);
  margin-top: 6px;
  font-variant-numeric: tabular-nums;
}

.progress-track {
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.14);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.5s ease, background-color 0.3s ease;
}

.sparkline-wrap {
  width: 100%;
  height: 46px;
  margin-bottom: 14px;
  background: rgba(10, 16, 30, 0.52);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  min-width: 0;
}

.sparkline-meta {
  font-size: 0.76rem;
  color: var(--muted);
  white-space: nowrap;
  flex-shrink: 0;
}

.sparkline-svg {
  flex: 1;
  width: 100%;
  min-width: 0;
  height: 32px;
  display: block;
  overflow: hidden;
}

/* Services Monitor List */
.services-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.service-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  background: rgba(10, 16, 30, 0.55);
  border: 1px solid var(--border);
  font-size: 0.88rem;
}

.service-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-dot.online {
  background: #10b981;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.75);
}

.status-dot.offline {
  background: #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.75);
}

.service-ping {
  font-size: 0.78rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--muted);
  white-space: nowrap;
}

/* Weather Widget */
.weather-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.weather-temp-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.weather-icon-big {
  font-size: 3rem;
  line-height: 1;
}

.weather-temp {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.weather-cond {
  font-size: 0.9rem;
  color: var(--muted);
  margin-top: 3px;
}

.weather-details {
  text-align: right;
  font-size: 0.82rem;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.forecast-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: auto;
}

.forecast-day {
  background: rgba(10, 16, 30, 0.58);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 9px 6px;
  text-align: center;
}

.forecast-name {
  font-size: 0.74rem;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
}

.forecast-ico {
  font-size: 1.35rem;
  margin: 4px 0;
}

.forecast-temps {
  font-size: 0.8rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.forecast-rain {
  font-size: 0.72rem;
  color: #38bdf8;
  margin-top: 2px;
}

.city-search-results {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.city-option {
  text-align: left;
  padding: 8px 10px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.85);
  color: var(--text);
  font-size: 0.84rem;
  cursor: pointer;
}

.city-option:hover {
  border-color: var(--accent);
}

/* Todos */
.todo-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
  max-height: 290px;
  overflow-y: auto;
  padding-right: 2px;
}

.todo-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
}

.todo-item.priority-high {
  border-left: 3px solid var(--gold);
}

.todo-item.done {
  opacity: 0.55;
}

.todo-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.todo-check {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 2px solid var(--border-strong);
  background: transparent;
  color: #060b16;
  font-size: 0.78rem;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.todo-item.done .todo-check {
  background: var(--green);
  border-color: var(--green);
}

.todo-text {
  font-size: 0.9rem;
  word-break: break-word;
}

.todo-item.done .todo-text {
  text-decoration: line-through;
}

/* Calendar & Events */
.cal-split {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 16px;
}

@media (max-width: 680px) {
  .cal-split {
    grid-template-columns: 1fr;
  }
}

.mini-cal {
  background: rgba(10, 16, 30, 0.55);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
}

.cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.86rem;
  font-weight: 700;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
  text-align: center;
}

.cal-dow {
  font-size: 0.68rem;
  color: var(--muted);
  font-weight: 700;
  padding-bottom: 4px;
}

.cal-day {
  font-size: 0.76rem;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  position: relative;
  color: #cbd5e1;
}

.cal-day.today {
  background: linear-gradient(135deg, #38bdf8, #6366f1);
  color: #060b16;
  font-weight: 900;
}

.cal-day.has-event::after {
  content: "";
  position: absolute;
  bottom: 2px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gold);
}

.cal-day.today.has-event::after {
  background: #060b16;
}

.events-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 215px;
  overflow-y: auto;
}

.event-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
}

.event-countdown {
  font-size: 0.74rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.15);
  color: #7dd3fc;
  white-space: nowrap;
}

.event-countdown.soon {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
}

.event-countdown.past {
  background: rgba(148, 163, 184, 0.14);
  color: var(--muted);
}

/* Notes */
.notes-area {
  flex: 1;
  min-height: 215px;
  resize: vertical;
  line-height: 1.55;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.86rem;
}

.notes-status {
  font-size: 0.76rem;
  color: var(--muted);
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(4, 8, 18, 0.72);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  z-index: 200;
}

.modal-card {
  width: 100%;
  max-width: 440px;
  background: #111c30;
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.modal-card h3 {
  font-size: 1.12rem;
  margin-bottom: 14px;
}

.field {
  margin-bottom: 12px;
}

.field label {
  display: block;
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 5px;
  font-weight: 600;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(130%);
  background: #0f172a;
  border: 1px solid rgba(56, 189, 248, 0.45);
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 0.88rem;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.45);
  z-index: 300;
  transition: transform 0.25s ease;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

.empty-msg {
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
  padding: 16px 8px;
}

/* === Google Kalender & Interaktiver Mini-Kalender === */
.cal-day {
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.14s, border-color 0.14s;
}

.cal-day:hover {
  background: rgba(56, 189, 248, 0.14);
}

.cal-day.selected-day {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.22);
  color: #ffffff;
  font-weight: 800;
}

.cal-day.has-google::before {
  content: "";
  position: absolute;
  bottom: 2px;
  right: 5px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #38bdf8;
}

.cal-day.has-event.has-google::after {
  left: 5px;
}

.cal-day.today.has-google::before {
  background: #060b16;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.pill-btn {
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(10, 16, 30, 0.6);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.14s ease;
}

.pill-btn:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.pill-btn.active {
  background: rgba(56, 189, 248, 0.18);
  border-color: rgba(56, 189, 248, 0.5);
  color: #7dd3fc;
}

.event-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 5px;
}

.event-main {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  min-width: 0;
  flex: 1;
}

.event-meta {
  font-size: 0.76rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 2px;
}

.gcal-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.modal-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
  background: rgba(10, 16, 30, 0.7);
  padding: 4px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.modal-tab {
  flex: 1;
  padding: 8px 10px;
  border-radius: 9px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

.modal-tab.active {
  background: var(--card-solid);
  color: var(--text);
}

.howto-box {
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 12px;
  padding: 11px 13px;
  font-size: 0.8rem;
  color: #cbd5e1;
  margin-bottom: 14px;
  line-height: 1.5;
}

.howto-box ol {
  margin-left: 16px;
  margin-top: 5px;
}

.connected-cal-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 12px;
  max-height: 170px;
  overflow-y: auto;
}

.connected-cal-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(10, 16, 30, 0.65);
  border: 1px solid var(--border);
  font-size: 0.82rem;
}

.modal-card-wide {
  max-width: 520px;
}

/* =========================================================
   v3: Widget-Manager, Drag & Drop, Watchlist, News, Pomodoro, Habits, App-Zentrale
   ========================================================= */

.btn-accent-active {
  background: rgba(56, 189, 248, 0.2) !important;
  border-color: rgba(56, 189, 248, 0.55) !important;
  color: #7dd3fc !important;
}

/* Layout-Bearbeitungsmodus auf dem Dashboard */
.layout-edit-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 11px 16px;
  margin-bottom: 16px;
  border-radius: 14px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.38);
  font-size: 0.86rem;
  color: #e0f2fe;
}

.widget-edit-bar {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  margin: -6px -6px 12px;
  border-radius: 11px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px dashed rgba(56, 189, 248, 0.42);
}

.layout-editing .widget-edit-bar {
  display: flex;
}

.layout-editing .card[data-widget-id] {
  border-color: rgba(56, 189, 248, 0.32);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.layout-editing .card[data-widget-id].dragging {
  opacity: 0.45;
  transform: scale(0.985);
}

.layout-editing .card[data-widget-id].drag-over {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.45);
}

.drag-grip {
  cursor: grab;
  font-size: 0.9rem;
  font-weight: 800;
  color: #7dd3fc;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.drag-grip:active {
  cursor: grabbing;
}

/* Widget-Manager Modal Liste */
.widget-manager-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 55vh;
  overflow-y: auto;
  padding-right: 2px;
}

.wm-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  background: rgba(10, 16, 30, 0.68);
  border: 1px solid var(--border);
  transition: border-color 0.15s, opacity 0.15s;
}

.wm-row.wm-off {
  opacity: 0.55;
}

.wm-row.wm-drag-over {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
}

.wm-left {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  flex: 1;
}

.wm-handle {
  cursor: grab;
  color: var(--muted);
  font-size: 1rem;
  padding: 2px 4px;
  user-select: none;
}

.wm-name {
  font-size: 0.88rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wm-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.wm-span-select {
  background: rgba(30, 41, 59, 0.95);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px 6px;
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
}

/* Toggle Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 22px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-slider {
  position: absolute;
  inset: 0;
  cursor: pointer;
  background: rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  transition: background 0.2s;
}

.switch-slider::before {
  content: "";
  position: absolute;
  height: 16px;
  width: 16px;
  left: 3px;
  bottom: 3px;
  background: #f8fafc;
  border-radius: 50%;
  transition: transform 0.2s;
}

.switch input:checked + .switch-slider {
  background: #10b981;
}

.switch input:checked + .switch-slider::before {
  transform: translateX(16px);
}

/* === Watchlist Widget === */
.watchlist-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 310px;
  overflow-y: auto;
  padding-right: 2px;
}

.quote-row {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) 74px auto auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 13px;
  background: rgba(10, 16, 30, 0.58);
  border: 1px solid var(--border);
}

@media (max-width: 560px) {
  .quote-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
  }
  .quote-spark {
    display: none;
  }
}

.quote-sym-line {
  display: flex;
  align-items: center;
  gap: 6px;
}

.quote-symbol {
  font-weight: 800;
  font-size: 0.9rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.asset-tag {
  font-size: 0.64rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}

.asset-tag.crypto {
  background: rgba(245, 158, 11, 0.18);
  color: #fbbf24;
}

.asset-tag.etf {
  background: rgba(56, 189, 248, 0.16);
  color: #7dd3fc;
}

.quote-label {
  font-size: 0.76rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.quote-spark {
  width: 74px;
  height: 26px;
}

.quote-price-col {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.quote-price {
  font-weight: 800;
  font-size: 0.94rem;
}

.quote-chg {
  display: inline-block;
  margin-top: 2px;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 999px;
}

.quote-chg.pos {
  background: rgba(16, 185, 129, 0.16);
  color: #34d399;
}

.quote-chg.neg {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
}

.quote-chg.flat {
  background: rgba(148, 163, 184, 0.14);
  color: var(--muted);
}

/* === News & RSS Widget === */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 310px;
  overflow-y: auto;
  padding-right: 2px;
}

.news-item {
  display: block;
  padding: 10px 12px;
  border-radius: 13px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
  transition: border-color 0.15s, background 0.15s;
}

.news-item:hover {
  border-color: rgba(56, 189, 248, 0.42);
  background: rgba(20, 32, 54, 0.8);
}

.news-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
  font-size: 0.72rem;
  color: var(--muted);
}

.news-source-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 700;
  color: #e2e8f0;
}

.news-source-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.news-title {
  font-weight: 700;
  font-size: 0.89rem;
  line-height: 1.32;
  color: var(--text);
}

.news-summary {
  font-size: 0.77rem;
  color: var(--muted);
  margin-top: 3px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* === Pomodoro & Habit Tracker === */
.pomo-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-radius: 15px;
  background: rgba(10, 16, 30, 0.62);
  border: 1px solid var(--border);
  margin-bottom: 14px;
}

.pomo-ring-wrap {
  position: relative;
  width: 88px;
  height: 88px;
  flex-shrink: 0;
}

.pomo-ring-svg {
  width: 88px;
  height: 88px;
  transform: rotate(-90deg);
}

.pomo-ring-bg {
  fill: none;
  stroke: rgba(148, 163, 184, 0.16);
  stroke-width: 7;
}

.pomo-ring-fg {
  fill: none;
  stroke: #38bdf8;
  stroke-width: 7;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.4s linear, stroke 0.25s ease;
}

.pomo-ring-time {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.12rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.pomo-side {
  flex: 1;
  min-width: 185px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pomo-modes {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.habits-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.habits-table {
  display: flex;
  flex-direction: column;
  gap: 7px;
  max-height: 210px;
  overflow-y: auto;
}

.habit-days-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 206px 48px 26px;
  gap: 6px;
  align-items: center;
  padding: 0 8px 4px;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--muted);
  text-align: center;
}

.habit-days-cols,
.habit-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  align-items: center;
}

.habit-day-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.habit-day-lbl {
  display: none;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 4px;
  line-height: 1;
}

.habit-day-lbl.is-today-lbl {
  color: #38bdf8;
}

.habit-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 206px 48px 26px;
  gap: 6px;
  align-items: center;
  padding: 7px 8px;
  border-radius: 11px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
}

.habit-label {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-size: 0.84rem;
  font-weight: 600;
}

.habit-name-txt {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.habit-dot-btn {
  width: 24px;
  height: 24px;
  margin: 0 auto;
  border-radius: 7px;
  border: 1.5px solid var(--border-strong);
  background: rgba(15, 23, 42, 0.7);
  color: transparent;
  font-size: 0.75rem;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.14s ease;
}

.habit-dot-btn.is-today {
  border-color: rgba(56, 189, 248, 0.55);
}

.habit-dot-btn.done {
  background: #10b981;
  border-color: #10b981;
  color: #05101b;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.35);
}

.habit-streak {
  font-size: 0.74rem;
  font-weight: 800;
  text-align: right;
  color: #fbbf24;
  white-space: nowrap;
}

/* === App-Zentrale (Getränke-Counter Live + Docker) === */
.dc-live-box {
  padding: 13px 15px;
  border-radius: 15px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16) 0%, rgba(15, 23, 42, 0.78) 65%);
  border: 1px solid rgba(245, 158, 11, 0.36);
  margin-bottom: 12px;
}

.dc-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.dc-leader-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.dc-leader-name {
  font-size: 1.25rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dc-leader-val {
  font-size: 1.35rem;
  font-weight: 900;
  color: #fbbf24;
  font-variant-numeric: tabular-nums;
}

.dc-podium-mini {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.dc-chip {
  font-size: 0.74rem;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(10, 16, 30, 0.65);
  border: 1px solid var(--border);
  color: #e2e8f0;
}

.docker-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  max-height: 185px;
  overflow-y: auto;
}

.docker-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 11px;
  border-radius: 11px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
  font-size: 0.83rem;
}

.docker-ports {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
  color: #7dd3fc;
  white-space: nowrap;
}

/* =========================================================
   Elegante Dark-Mode Scrollbars (alle Listen & Hauptseite)
   ========================================================= */
.events-list,
.todo-list,
.watchlist-list,
.news-list,
.habits-table,
.docker-list,
.widget-manager-list,
.connected-cal-list {
  padding-right: 6px;
}

/* Chrome, Edge, Brave, Opera, Safari */
*::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

*::-webkit-scrollbar-track {
  background: transparent;
  margin: 4px 0;
}

*::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.24);
  border-radius: 999px;
  transition: background 0.2s ease;
}

*:hover::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.4);
}

*::-webkit-scrollbar-thumb:hover {
  background: rgba(56, 189, 248, 0.72);
}

*::-webkit-scrollbar-thumb:active {
  background: rgba(56, 189, 248, 0.92);
}

*::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

/* Firefox Fallback (ohne Chrome/Edge WebKit-Styling zu überschreiben) */
@supports not selector(::-webkit-scrollbar) {
  * {
    scrollbar-width: thin;
    scrollbar-color: rgba(148, 163, 184, 0.35) transparent;
  }
}

/* =========================================================
   v6: Mobile- & Responsive-Feinschliff
   ========================================================= */
html, body {
  overflow-x: hidden;
}

.nowrap-meta {
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
}

.card-head {
  flex-wrap: wrap;
  row-gap: 8px;
}

.card-head .btn {
  white-space: nowrap;
}

.card-title {
  flex-wrap: wrap;
  row-gap: 3px;
  min-width: 0;
}

.card-head .inline-row {
  flex-wrap: wrap;
  row-gap: 6px;
}

.header-actions {
  flex-wrap: wrap;
}

@media (max-width: 900px) {
  .header {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .clock-block {
    width: 100%;
    min-width: 0;
  }

  .greeting-wrap {
    min-width: 0;
    flex: 1;
  }

  .search-form {
    flex: none;
    width: 100%;
    min-width: 0;
    max-width: none;
  }

  .search-engine-select {
    flex-shrink: 0;
  }

  .search-form .btn {
    flex-shrink: 0;
  }

  .header-actions {
    width: 100%;
    justify-content: space-between;
  }
}

@media (max-width: 640px) {
  .shell {
    padding: 14px 12px 30px;
  }

  .header {
    gap: 11px;
    margin-bottom: 14px;
  }

  .clock-time {
    font-size: clamp(1.9rem, 9vw, 2.35rem);
  }

  .greeting-line {
    font-size: 0.98rem;
  }

  .date-line {
    font-size: 0.8rem;
  }

  .header-actions .btn {
    flex: 1 1 auto;
    white-space: nowrap;
  }

  .bento-grid {
    gap: 12px;
  }

  .card {
    padding: 15px 14px;
    border-radius: 17px;
  }

  .card-head {
    margin-bottom: 12px;
  }

  /* Schnellzugriff auf Handy als kompaktes 2-Spalten-Raster */
  .links-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .link-tile {
    padding: 10px 10px;
    gap: 8px;
  }

  .link-icon {
    font-size: 1.25rem;
  }

  .link-name {
    font-size: 0.85rem;
  }

  /* Pomodoro schön zentriert auf schmalen Displays */
  .pomo-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
  }

  .pomo-side {
    width: 100%;
    min-width: 0;
    align-items: center;
  }

  .pomo-modes {
    justify-content: center;
  }

  /* Habit-Tracker: 2-zeilige Karten statt abgeschnittener Tabelle */
  .habit-days-head {
    display: none;
  }

  .habits-table {
    max-height: none;
    padding-right: 0;
    gap: 9px;
  }

  .habit-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
    grid-template-areas:
      "label streak del"
      "days days days";
    column-gap: 8px;
    row-gap: 10px;
    padding: 10px 10px;
  }

  .habit-label {
    grid-area: label;
    font-size: 0.9rem;
  }

  .habit-streak {
    grid-area: streak;
    text-align: right;
  }

  .habit-del-btn {
    grid-area: del;
  }

  .habit-days {
    grid-area: days;
    width: 100%;
    gap: 5px;
    padding-top: 6px;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
  }

  .habit-day-lbl {
    display: block;
  }

  .habit-dot-btn {
    width: 30px;
    height: 30px;
    border-radius: 9px;
    font-size: 0.85rem;
  }

  /* Wetter & Vorhersage kompakt */
  .weather-main {
    flex-wrap: wrap;
    gap: 10px;
  }

  .weather-details {
    text-align: left;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px 12px;
  }

  .forecast-day {
    padding: 8px 4px;
  }

  /* Widget-Edit-Bar & Widget-Manager auf Handy umbrechen */
  .widget-edit-bar {
    flex-wrap: wrap;
    margin: -4px -4px 10px;
  }

  .wm-row {
    flex-wrap: wrap;
    row-gap: 8px;
  }

  .wm-controls {
    width: 100%;
    justify-content: flex-end;
  }

  .service-item,
  .event-item,
  .docker-item {
    padding: 9px 10px;
  }

  .service-left {
    min-width: 0;
    flex: 1;
  }
}

@media (max-width: 380px) {
  .links-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   v9: Server- & Docker-Verwaltung + Live-Log-Viewer
   ========================================================= */
.docker-list {
  max-height: 270px;
}

.docker-item {
  flex-wrap: wrap;
  row-gap: 7px;
}

.docker-item-right {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.docker-port-link {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.72rem;
  font-weight: 700;
  color: #7dd3fc;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.28);
  white-space: nowrap;
  transition: background 0.14s, border-color 0.14s;
}

.docker-port-link:hover {
  background: rgba(56, 189, 248, 0.26);
  border-color: rgba(56, 189, 248, 0.55);
}

.docker-lock-tag {
  font-size: 0.66rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.16);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.34);
  white-space: nowrap;
}

.docker-self-tag {
  font-size: 0.66rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(129, 140, 248, 0.18);
  color: #c7d2fe;
  border: 1px solid rgba(129, 140, 248, 0.38);
  white-space: nowrap;
}

.btn-ok {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.38);
  color: #34d399;
}

.btn-ok:hover {
  background: rgba(16, 185, 129, 0.28);
}

.modal-card-xl {
  max-width: 780px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.dm-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.dm-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  padding-right: 4px;
  flex: 1;
  min-height: 140px;
}

.dm-card {
  padding: 13px 14px;
  border-radius: 14px;
  background: rgba(10, 16, 30, 0.68);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 9px;
  transition: border-color 0.15s;
}

.dm-card.is-running {
  border-left: 3px solid #10b981;
}

.dm-card.is-stopped {
  border-left: 3px solid #64748b;
  opacity: 0.86;
}

.dm-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.dm-name-line {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.dm-name {
  font-size: 0.98rem;
  font-weight: 800;
}

.dm-meta {
  font-size: 0.76rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 3px;
}

.dm-stats-strip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 0.75rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: #7dd3fc;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.22);
  padding: 4px 10px;
  border-radius: 9px;
}

.dm-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.dm-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.log-terminal {
  flex: 1;
  min-height: 260px;
  max-height: 58vh;
  overflow: auto;
  background: #050912;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.76rem;
  line-height: 1.5;
  color: #cbd5e1;
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
}

@media (max-width: 640px) {
  .modal-card-xl {
    padding: 16px 14px;
    max-height: 92vh;
  }

  .docker-item-right {
    width: 100%;
    justify-content: flex-end;
  }

  .dm-actions .btn {
    flex: 1 1 auto;
  }
}

/* =========================================================
   v10: Netunco-Integration, Erreichbarkeit & Host-Units-Info
   ========================================================= */
.docker-group-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin: 6px 0 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.docker-group-label:first-child {
  margin-top: 0;
}

.docker-crit-tag {
  font-size: 0.66rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.36);
  white-space: nowrap;
}

.docker-prov-tag {
  font-size: 0.66rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.32);
  white-space: nowrap;
}

.docker-reach-ok {
  font-size: 0.68rem;
  font-weight: 700;
  color: #34d399;
}

.docker-reach-err {
  font-size: 0.68rem;
  font-weight: 700;
  color: #fca5a5;
}

.docker-loopback-pill {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.7rem;
  color: var(--muted);
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid var(--border);
  white-space: nowrap;
}

.dm-netunco-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 9px 12px;
  margin-bottom: 10px;
  border-radius: 12px;
  background: rgba(10, 16, 30, 0.72);
  border: 1px solid var(--border);
  font-size: 0.78rem;
}

.dm-probe-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(20, 30, 48, 0.85);
  border: 1px solid var(--border);
  font-weight: 700;
}

.dm-probe-pill:hover {
  border-color: rgba(56, 189, 248, 0.45);
}

.dm-impact-note {
  font-size: 0.74rem;
  color: #fcd34d;
  background: rgba(245, 158, 11, 0.09);
  border: 1px solid rgba(245, 158, 11, 0.24);
  border-radius: 9px;
  padding: 6px 9px;
  line-height: 1.4;
}

.dm-host-units-box {
  margin-top: 10px;
  padding: 11px 12px;
  border-radius: 13px;
  background: rgba(10, 16, 30, 0.56);
  border: 1px solid var(--border);
}

.dm-host-unit-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 5px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.1);
  font-size: 0.76rem;
}

.dm-host-unit-row:last-child {
  border-bottom: none;
}

/* =========================================================
   v11: Farbcodierte Termin-Countdowns & Kalender-Kategorien
   ========================================================= */
.event-countdown {
  font-size: 0.74rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
}

.event-countdown.cd-today {
  background: rgba(239, 68, 68, 0.22);
  border-color: rgba(239, 68, 68, 0.48);
  color: #fca5a5;
}

.event-countdown.cd-tomorrow {
  background: rgba(249, 115, 22, 0.22);
  border-color: rgba(249, 115, 22, 0.46);
  color: #fdba74;
}

.event-countdown.cd-very-soon {
  background: rgba(234, 179, 8, 0.2);
  border-color: rgba(234, 179, 8, 0.44);
  color: #fde047;
}

.event-countdown.cd-week {
  background: rgba(16, 185, 129, 0.18);
  border-color: rgba(16, 185, 129, 0.42);
  color: #6ee7b7;
}

.event-countdown.cd-month {
  background: rgba(56, 189, 248, 0.16);
  border-color: rgba(56, 189, 248, 0.38);
  color: #7dd3fc;
}

.event-countdown.cd-later {
  background: rgba(139, 92, 246, 0.18);
  border-color: rgba(139, 92, 246, 0.4);
  color: #c4b5fd;
}

.event-countdown.cd-past {
  background: rgba(148, 163, 184, 0.14);
  border-color: rgba(148, 163, 184, 0.24);
  color: var(--muted);
}

.cat-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  white-space: nowrap;
}

.cal-color-picker {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}

.cal-color-picker::-webkit-color-swatch-wrapper {
  padding: 2px;
}

.cal-color-picker::-webkit-color-swatch {
  border: none;
  border-radius: 4px;
}
