/* ── Inter Font ─────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ── Variablen ─────────────────────────────── */
:root {
  --bg:               #0a0a0a;
  --surface:          #161616;
  --surface-2:        #1e1e1e;
  --surface-3:        #262626;
  --border:           #2a2a2a;
  --border-2:         #3a3a3a;
  --text:             #f0f0f0;
  --text-2:           #a0a0a0;
  --text-muted:       #606060;
  --green:            #22c55e;
  --green-dim:        rgba(34,197,94,.1);
  --red:              #ef4444;
  --red-dim:          rgba(239,68,68,.1);
  --yellow:           #f59e0b;
  --yellow-dim:       rgba(245,158,11,.1);
  --blue:             #3b82f6;
  --blue-dim:         rgba(59,130,246,.1);
  --radius:           8px;
  --radius-lg:        12px;
  --shadow:           0 1px 3px rgba(0,0,0,.6), 0 4px 16px rgba(0,0,0,.3);
  --shadow-card:      0 1px 3px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.03);
  --shadow-card-hover:0 8px 28px rgba(0,0,0,.65), 0 0 0 1px rgba(255,255,255,.06);
  --shadow-panel:     -16px 0 48px rgba(0,0,0,.6);
}

/* ── Light Mode ────────────────────────────── */
body.light {
  --bg:               #f6f8fa;
  --surface:          #ffffff;
  --surface-2:        #f1f5f9;
  --surface-3:        #e2e8f0;
  --border:           #e2e8f0;
  --border-2:         #cbd5e1;
  --text:             #0f172a;
  --text-2:           #475569;
  --text-muted:       #94a3b8;
  --green:            #16a34a;
  --green-dim:        rgba(22,163,74,.08);
  --red:              #dc2626;
  --red-dim:          rgba(220,38,38,.08);
  --yellow:           #d97706;
  --yellow-dim:       rgba(217,119,6,.08);
  --blue:             #2563eb;
  --blue-dim:         rgba(37,99,235,.08);
  --shadow:           0 1px 3px rgba(0,0,0,.06), 0 4px 16px rgba(0,0,0,.05);
  --shadow-card:      0 1px 4px rgba(0,0,0,.07), 0 0 0 1px rgba(0,0,0,.04);
  --shadow-card-hover:0 6px 20px rgba(0,0,0,.10), 0 0 0 1px rgba(0,0,0,.06);
  --shadow-panel:     -8px 0 24px rgba(0,0,0,.08);
}
body.light {
  background: linear-gradient(180deg, rgba(22,163,74,.06) 0%, transparent 300px), #f6f8fa;
}
body.light header {
  background: rgba(255,255,255,.95);
  border-bottom-color: #e2e8f0;
  box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 2px 8px rgba(0,0,0,.04);
}
body.light .panel { background: #ffffff; }
body.light .panel-header { background: #ffffff; }
body.light .stat { background: #ffffff; }
body.light .modal-box { background: #ffffff; }
body.light label input, body.light label select { background: #f8fafc; color: #0f172a; }
body.light .card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  border-radius: 10px;
}
body.light .card.is-down { background: linear-gradient(135deg, rgba(220,38,38,.05) 0%, #ffffff 55%); }
body.light .card.is-slow { background: linear-gradient(135deg, rgba(217,119,6,.04) 0%, #ffffff 55%); }
body.light .card.is-up   { background: linear-gradient(180deg, rgba(22,163,74,.03) 0%, #ffffff 40%); }
body.light .card:hover { box-shadow: var(--shadow-card-hover); }
body.light .sp-card,
body.light .hb-card {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 55%);
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  border-radius: 10px;
}
body.dark .card {
  background: #1a1a1a;
  border: none;
  border-top: 1px solid rgba(34,197,94,0.12);
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
}
body.dark .sp-card,
body.dark .hb-card {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 55%);
}

/* ── Reset & Base ──────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background:
    radial-gradient(ellipse 80% 35% at 50% 0%, rgba(34,197,94,.05) 0%, transparent 60%),
    #0a0a0a;
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--text-muted); text-decoration: none; transition: color .15s; }
a:hover { color: var(--text); }

/* ── Header ────────────────────────────────── */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-bottom: 1px solid rgba(255,255,255,.06);
  gap: 16px;
  flex-wrap: wrap;
  position: sticky;
  top: 0;
  background: rgba(10,10,10,.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 5;
  box-shadow: 0 1px 0 rgba(34,197,94,.04), 0 4px 16px rgba(0,0,0,.3);
}

/* ── Nav 3-Spalten ─────────────────────────── */
.nav-left  { display: flex; align-items: center; }
.nav-center { display: flex; align-items: center; gap: 2px; margin: 0 16px; }
.nav-right  { display: flex; align-items: center; gap: 8px; margin-left: auto; }

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
}
.logo-icon  { width: 35px; height: 35px; flex-shrink: 0; }
.logo-text  { font-size: 21px; font-weight: 700; letter-spacing: -.2px; color: var(--text); white-space: nowrap; }

.nav-link {
  font-size: 13px; font-weight: 500;
  color: var(--text-muted);
  padding: 5px 10px; border-radius: 6px;
  text-decoration: none;
  transition: color .15s, background .15s;
  white-space: nowrap;
}
.nav-link:hover    { color: var(--text); background: var(--surface-2); }
.nav-link.is-active{ color: var(--text); background: var(--surface-2); }

/* ── Tier Chip ─────────────────────────────── */
.tier-chip {
  font-size: 11px; font-weight: 600; letter-spacing: .3px; text-transform: uppercase;
  padding: 3px 9px; border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text-muted);
  white-space: nowrap;
}
.tier-chip.tier-starter { background: rgba(59,130,246,.1); color: #60a5fa; border-color: rgba(59,130,246,.25); }
.tier-chip.tier-pro     { background: rgba(168,85,247,.1); color: #c084fc; border-color: rgba(168,85,247,.25); }
.tier-chip.tier-business{ background: rgba(245,158,11,.1); color: #fbbf24; border-color: rgba(245,158,11,.25); }

.badge {
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .1px;
}
.badge-up      { background: var(--green-dim); color: var(--green); box-shadow: 0 0 0 1px rgba(34,197,94,.2); }
.badge-down    { background: var(--red-dim);   color: var(--red);   box-shadow: 0 0 0 1px rgba(239,68,68,.2); }
.badge-neutral { background: var(--surface-2); color: var(--text-muted); }

.last-updated { font-size: 11px; color: var(--text-muted); white-space: nowrap; }

/* ── Buttons ───────────────────────────────── */
button { cursor: pointer; border: none; font-family: inherit; font-size: 13px; transition: background .15s, color .15s, box-shadow .15s, transform .1s; }
button:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
a:focus-visible      { outline: 2px solid var(--green); outline-offset: 2px; }

.btn-primary {
  background: var(--green);
  color: #000;
  padding: 7px 14px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: -.1px;
}
.btn-primary:hover { background: #1ea34e; }
.btn-primary:active  { transform: scale(.97); }
.btn-primary:disabled { opacity: .35; cursor: not-allowed; }
.btn-sm { padding: 6px 14px; font-size: 12px; }

.btn-secondary {
  background: var(--surface-2);
  color: var(--text-2);
  padding: 7px 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  font-weight: 500;
}
.btn-secondary:hover  { background: var(--surface-3); border-color: var(--border-2); color: var(--text); }
.btn-secondary:active { transform: scale(.97); }

.btn-danger {
  background: var(--red-dim);
  color: var(--red);
  padding: 8px 16px;
  border-radius: var(--radius);
  font-weight: 500;
  width: 100%;
  border: 1px solid rgba(239,68,68,.2);
}
.btn-danger:hover { background: rgba(239,68,68,.18); }

.btn-icon {
  background: transparent;
  color: var(--text-muted);
  font-size: 16px;
  padding: 5px 8px;
  border-radius: var(--radius);
}
.btn-icon:hover  { background: var(--surface-2); color: var(--text); }
.btn-icon:active { transform: scale(.9); }

/* ── Metric Cards ──────────────────────────── */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 8px;
}
.metric-card {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 100%);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 20px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 5px;
}
body.dark .metric-card {
  border: none;
  border-top: 1px solid rgba(34,197,94,0.12);
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
}
body.light .metric-card {
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.metric-value {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -.5px;
  line-height: 1;
  color: var(--text);
}
.metric-label { font-size: 11px; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: .4px; }
#metric-up   .metric-value { color: var(--green); }
#metric-down .metric-value { color: var(--red); }

.metrics-footer {
  text-align: right;
  margin-bottom: 20px;
}

/* ── Skeleton Loading ──────────────────────── */
@keyframes skeleton-shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position:  200% 0; }
}
.skeleton-block {
  background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 50%, var(--surface-2) 75%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.4s ease-in-out infinite;
  border-radius: var(--radius);
  display: block;
}
.skeleton-metric {
  height: 32px;
  width: 60%;
  margin-bottom: 6px;
}
.skeleton-section {
  height: 16px;
  width: 35%;
  margin: 24px 0 16px;
}

/* ── Section Header ────────────────────────── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0 16px;
  margin-top: 32px;
  position: relative;
}
.section-header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-2), transparent);
}
.section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
}
.section-hint { font-size: 12px; color: var(--text-muted); font-weight: 400; }

/* ── Heartbeat Pulse Animation ─────────────── */
@keyframes heartbeat-pulse {
  0%, 100% { transform: scale(1); opacity: .7; }
  50%      { transform: scale(1.25); opacity: 1; }
}
.heartbeat-icon {
  display: inline-block;
  animation: heartbeat-pulse 2s ease-in-out infinite;
  transform-origin: center;
}
.hb-card[data-status="up"] .heartbeat-icon {
  animation-duration: 1s;
  filter: drop-shadow(0 0 6px rgba(34,197,94,.4));
}

/* ── Heartbeat Empty State ─────────────────── */
.hb-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 24px;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.7;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
}
.hb-empty-icon {
  font-size: 32px;
  margin-bottom: 12px;
  opacity: .5;
}
.hb-empty-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 6px;
}

/* ── Status Page Section ───────────────────── */
.sp-card {
  cursor: default;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.sp-card:hover { transform: none; box-shadow: var(--shadow-card); }
body.dark .sp-card {
  border: none;
  border-top: 1px solid rgba(34,197,94,0.12);
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
}
body.light .sp-card {
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.sp-state { display: flex; flex-direction: column; gap: 16px; }
.sp-desc { font-size: 13px; color: var(--text-2); line-height: 1.6; margin: 0; }
.sp-url-row { display: flex; flex-direction: column; gap: 8px; }
.sp-url-label {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .4px;
}
.sp-url-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.sp-url {
  font-size: 13px;
  color: var(--green);
  text-decoration: none;
  word-break: break-all;
  font-family: 'SF Mono', 'Fira Code', monospace;
}
.sp-url:hover { text-decoration: underline; }
.sp-disable-btn { margin-top: 8px; width: fit-content; }

/* ── Main & Card-Grid ──────────────────────── */
main {
  padding: 32px 32px 48px;
  max-width: 1200px;
  margin: 0 auto;
  background: linear-gradient(180deg, rgba(255,255,255,.012) 0%, transparent 120px);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(264px, 1fr));
  gap: 16px;
}

.card {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  cursor: pointer;
  transition: border-color .18s, box-shadow .18s, transform .12s;
  position: relative;
  box-shadow: var(--shadow-card);
}
.card:hover {
  border-color: var(--border-2);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}
.card.is-up {
  border-left: 3px solid var(--green);
  background: linear-gradient(180deg, rgba(34,197,94,.04) 0%, var(--surface) 45%);
}
.card.is-down {
  border-left: 3px solid var(--red);
  background: linear-gradient(135deg, rgba(239,68,68,.09) 0%, var(--surface) 55%);
  box-shadow: var(--shadow-card), inset 0 0 0 1px rgba(239,68,68,.07);
}
.card.is-slow {
  border-left: 3px solid var(--yellow);
  background: linear-gradient(135deg, rgba(245,158,11,.07) 0%, var(--surface) 55%);
}
.card.unchecked {
  border-left: 3px solid var(--text-muted);
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 100%);
}

.card-header {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 8px;
}

/* ── Status Dot ────────────────────────────── */
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-up      { background: var(--green);  box-shadow: 0 0 0 3px var(--green-dim),  0 0 7px rgba(34,197,94,.45); }
.dot-down    {
  background: var(--red);
  box-shadow: 0 0 0 3px var(--red-dim), 0 0 9px rgba(239,68,68,.55);
  animation: pulse-red 1.8s ease-in-out infinite;
}
.dot-slow    { background: var(--yellow); box-shadow: 0 0 0 3px var(--yellow-dim), 0 0 7px rgba(245,158,11,.45); }
.dot-unknown { background: var(--text-muted); }

@keyframes pulse-red {
  0%, 100% { box-shadow: 0 0 0 3px var(--red-dim); }
  50%       { box-shadow: 0 0 0 6px rgba(239,68,68,.05); }
}

.card-name {
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -.1px;
}

.card-url {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 10px;
  font-family: 'Fira Code', 'Consolas', monospace;
}

/* ── Card Sparkline ────────────────────────── */
.card-sparkline {
  height: 28px;
  margin-bottom: 10px;
  overflow: hidden;
}
.card-sparkline svg { display: block; }
.card-sparkline .no-data { font-size: 11px; color: var(--text-muted); line-height: 28px; }

/* ── Card Meta ─────────────────────────────── */
.card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-muted);
}

.card-meta-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── Uptime Badge ──────────────────────────── */
.uptime-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 999px;
  letter-spacing: .1px;
}
.uptime-good { background: var(--green-dim); color: var(--green); }
.uptime-warn { background: var(--yellow-dim); color: var(--yellow); }
.uptime-bad  { background: var(--red-dim); color: var(--red); }

/* ── Card Action Buttons ───────────────────── */
.card-actions {
  display: flex;
  gap: 4px;
  margin-left: auto;
}

.btn-card-action {
  background: transparent;
  color: var(--text-muted);
  border: none;
  padding: 6px 9px;
  border-radius: 6px;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: background .1s, color .1s;
  flex-shrink: 0;
}
.btn-card-action:hover { background: var(--surface-2); color: var(--text); }
.btn-card-action.paused { color: var(--yellow); }

.card-status-label { font-weight: 500; }
.label-up   { color: var(--green); }
.label-down { color: var(--red); }
.label-slow { color: var(--yellow); }
.label-maintenance { color: var(--blue); }

/* ── Toast ─────────────────────────────────── */
#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface-3);
  color: var(--text);
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 13px;
  z-index: 100;
  opacity: 0;
  transition: opacity .2s;
  border: 1px solid var(--border-2);
  pointer-events: none;
  white-space: nowrap;
}

/* ── Empty State ───────────────────────────── */
.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 80px 20px;
  font-size: 14px;
  line-height: 1.8;
}

/* ── Limit-Hinweis ─────────────────────────── */
.limit-hint {
  padding: 8px 24px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}
.limit-hint-link {
  color: var(--green);
  text-decoration: none;
  font-weight: 500;
}
.limit-hint-link:hover { text-decoration: underline; }

/* ── Detail Panel ──────────────────────────── */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(2px);
  z-index: 10;
}

.panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 420px;
  max-width: 100vw;
  height: 100vh;
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface) 60px);
  border-left: 1px solid rgba(255,255,255,.05);
  z-index: 20;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  box-shadow: var(--shadow-panel), inset -1px 0 0 rgba(255,255,255,.02);
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
  position: sticky;
  top: 0;
  background: var(--surface);
  z-index: 1;
}

.panel-header > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.panel-header h2 {
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -.2px;
}

.detail-url {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: 'Fira Code', 'Consolas', monospace;
}
.detail-url:hover { color: var(--blue); }

.panel-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border-bottom: 1px solid var(--border);
}

.stat {
  background: var(--surface);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .6px; font-weight: 500; }
.stat-value { font-size: 14px; font-weight: 600; }

.panel-section { padding: 20px; border-bottom: 1px solid var(--border); }
.panel-section h3 { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .6px; font-weight: 600; margin-bottom: 14px; }

.panel-footer {
  padding: 16px 20px;
  margin-top: auto;
  display: flex;
  gap: 10px;
}

/* ── Sparkline ─────────────────────────────── */
#detail-sparkline { height: 48px; }
#detail-sparkline svg { display: block; }
.no-data { color: var(--text-muted); font-size: 12px; }

/* ── Check-Tabelle ─────────────────────────── */
#detail-table-wrap { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  text-align: left;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .4px;
  padding: 6px 8px;
  border-bottom: 1px solid var(--border);
}
td { padding: 7px 8px; border-bottom: 1px solid rgba(255,255,255,.025); color: var(--text-2); }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,.025); }

.td-up   { color: var(--green); font-weight: 500; }
.td-down { color: var(--red);   font-weight: 500; }

/* ── Modal ─────────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.7);
  backdrop-filter: blur(4px);
  z-index: 30;
  padding: 20px;
}

.modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow);
}

.modal-box h2 { font-size: 15px; font-weight: 600; margin-bottom: 20px; letter-spacing: -.2px; }

label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 14px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: .1px;
}

label input, label select {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius);
  padding: 8px 11px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
label input:focus, label select:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-dim);
}
label select option { background: var(--surface-2); }

.form-error {
  background: var(--red-dim);
  border: 1px solid rgba(239,68,68,.25);
  color: var(--red);
  padding: 8px 12px;
  border-radius: var(--radius);
  font-size: 13px;
  margin-bottom: 12px;
}

.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }

/* ── Utilities ─────────────────────────────── */
.hidden { display: none !important; }

/* ── Advanced Form Options ──────────────────── */
.advanced-opts { margin-bottom: 14px; }
.advanced-opts summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--text-muted);
  padding: 6px 0;
  user-select: none;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
}
.advanced-opts summary::before {
  content: '▶';
  font-size: 9px;
  transition: transform .15s;
  color: var(--text-muted);
}
.advanced-opts[open] summary::before { transform: rotate(90deg); }
.advanced-content { padding: 10px 0 0; display: flex; flex-direction: column; }
.label-check {
  flex-direction: row !important;
  align-items: center;
  gap: 8px !important;
  margin-bottom: 14px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-2);
}
.label-check input { width: auto; }

/* ── Maintenance ───────────────────────────── */
.dot-maintenance { background: var(--blue); box-shadow: 0 0 0 3px var(--blue-dim), 0 0 7px rgba(59,130,246,.4); }
.card.is-maintenance {
  border-left: 3px solid var(--blue);
  background: linear-gradient(135deg, rgba(59,130,246,.07) 0%, var(--surface) 55%);
}
.label-maintenance { color: var(--blue); }

.btn-maintenance {
  background: var(--blue-dim);
  color: var(--blue);
  padding: 8px 16px;
  border-radius: var(--radius);
  font-weight: 500;
  flex: 1;
  border: 1px solid rgba(59,130,246,.2);
}
.btn-maintenance:hover { background: rgba(59,130,246,.16); }

/* ── Heartbeat Section (legacy alias) ──────── */
.hb-section-header { display: flex; align-items: center; justify-content: space-between; padding: 24px 0 12px; margin-top: 24px; }
.hb-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
}
.hb-icon { font-size: 15px; }
.hb-section-hint {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 400;
}
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ── Heartbeat Detail Modal ─────────────────── */
.modal-box-hb { max-width: 480px; }
.modal-hb-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.hb-detail-title { display: flex; align-items: center; gap: 8px; }
.hb-url-box {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
}
.hb-url-label { font-size: 11px; color: var(--text-muted); margin-bottom: 8px; font-weight: 500; text-transform: uppercase; letter-spacing: .4px; }
.hb-url-row { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.hb-url-code {
  font-family: 'Fira Code', 'Consolas', monospace;
  font-size: 12px;
  color: var(--text);
  word-break: break-all;
  flex: 1;
}
.hb-url-example {
  font-family: 'Fira Code', 'Consolas', monospace;
  font-size: 11px;
  color: var(--text-muted);
  white-space: pre;
  overflow-x: auto;
  line-height: 1.7;
  margin-top: 4px;
}
.modal-hint { font-size: 13px; color: var(--text-muted); margin-bottom: 16px; line-height: 1.6; }

/* ── Status Page Widget (Dashboard-intern) ──── */
.w-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.w-badge {
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}
.w-icon { font-size: 18px; }
.w-summary {
  font-size: 12px;
  color: var(--text-muted);
}
.w-section-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--text-muted);
  margin: 16px 0 8px;
  font-weight: 500;
}

/* ── Monitor List ── */
.w-monitors {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.w-monitor {
  background: var(--surface);
  padding: 10px 14px;
}
.w-monitor-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.w-monitor-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.w-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.w-dot-up      { background: var(--color-up, #22c55e); box-shadow: 0 0 4px var(--color-up, #22c55e); }
.w-dot-down    { background: var(--color-down, #ef4444); box-shadow: 0 0 4px var(--color-down, #ef4444); }
.w-dot-unknown { background: var(--text-muted); }
.w-monitor-name {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.w-monitor-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.w-uptime {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-up, #22c55e);
  font-variant-numeric: tabular-nums;
}
.w-label {
  font-size: 11px;
  font-weight: 500;
  padding: 1px 7px;
  border-radius: 999px;
}
.w-lbl-up      { background: rgba(34,197,94,.12); color: var(--color-up, #22c55e); }
.w-lbl-down    { background: rgba(239,68,68,.12); color: var(--color-down, #ef4444); }
.w-lbl-unknown { background: var(--surface-2); color: var(--text-muted); }

/* ── 30-Day History (compact für Widget) ── */
.w-history-bar {
  display: flex;
  gap: 1px;
  align-items: flex-end;
}
.w-day {
  flex: 1;
  height: 16px;
  border-radius: 2px;
  cursor: default;
}
.w-day-up      { background: var(--color-up, #22c55e); opacity: .65; }
.w-day-up:hover { opacity: 1; }
.w-day-partial  { background: var(--color-yellow, #f59e0b); opacity: .65; }
.w-day-partial:hover { opacity: 1; }
.w-day-down    { background: var(--color-down, #ef4444); opacity: .65; }
.w-day-down:hover { opacity: 1; }
.w-day-empty   { background: var(--border); }

/* ── Incidents ── */
.w-incidents {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.w-incident {
  background: var(--surface);
  padding: 8px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.w-incident-title {
  font-size: 12px;
  font-weight: 600;
}
.w-incident-meta {
  font-size: 11px;
  color: var(--text-muted);
  flex-shrink: 0;
}
.w-no-incidents {
  font-size: 12px;
  color: var(--green);
  padding: 8px 0;
}

/* ── Footer (URL + Buttons) ── */
.w-footer {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}
.w-url-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.w-url {
  font-family: 'Fira Code', 'Consolas', monospace;
  font-size: 11px;
  color: var(--text-muted);
  word-break: break-all;
  min-width: 0;
}
.w-url:hover { color: var(--green); }
.w-disable { color: var(--text-muted); }
.w-disable:hover { color: var(--red); }

/* ── Helper ── */
.btn-text {
  background: none;
  border: none;
  color: var(--blue);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
}
.btn-text:hover { background: rgba(59,130,246,.1); }
.btn-xs { font-size: 11px; }

/* ── Branding: Grünes MON ──────────────────── */
.mon-accent { color: var(--green); }

/* ── Status Page Header ─────────────────────── */
.hb-section-header.sp-header { margin-top: 0; }

/* ── Responsive ────────────────────────────── */
@media (max-width: 640px) {
  .nav-center { display: none; }
}
@media (max-width: 480px) {
  header { padding: 12px 16px; }
  main { padding: 16px; }
  .metrics-row { grid-template-columns: 1fr 1fr; }
  .metrics-row .metric-card:last-child { grid-column: 1 / -1; }
  .panel { width: 100vw; }
  .panel-stats { grid-template-columns: 1fr 1fr; }
}

/* ── Settings Page ─────────────────────────── */
.settings-layout {
  display: flex;
  gap: 32px;
  max-width: 960px;
  margin: 32px auto;
  padding: 0 24px;
}

.settings-nav {
  flex-shrink: 0;
  width: 180px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.settings-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: background .15s, color .15s;
}
.settings-nav-item:hover {
  background: var(--surface);
  color: var(--text);
}
.settings-nav-item.active {
  background: rgba(59,130,246,.1);
  color: var(--blue);
  font-weight: 600;
}
.nav-icon { font-size: 16px; line-height: 1; }

.settings-content {
  flex: 1;
  min-width: 0;
}

.settings-tab {
  display: block;
}
.settings-tab.hidden {
  display: none;
}

.settings-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 16px;
}
.settings-section .section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
  text-transform: none;
  letter-spacing: 0;
}
.section-desc {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0 0 14px;
  line-height: 1.6;
}
.settings-section label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.settings-section label:last-of-type { margin-bottom: 0; }
.settings-section label input,
.settings-section label select {
  display: block;
  width: 100%;
  margin-top: 6px;
}
.settings-section-danger {
  border-color: rgba(239,68,68,.2);
}
.section-title-danger { color: var(--red) !important; }

.form-error {
  font-size: 13px;
  color: var(--red);
  margin-top: 8px;
  padding: 8px 12px;
  background: rgba(239,68,68,.08);
  border-radius: 6px;
}
.form-success {
  font-size: 13px;
  color: var(--green);
  margin-top: 8px;
  padding: 8px 12px;
  background: rgba(34,197,94,.08);
  border-radius: 6px;
}
.form-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}
.form-actions .btn-primary,
.form-actions .btn-secondary { width: auto; }

.copy-field {
  display: flex;
  gap: 6px;
  align-items: center;
}
.copy-field input {
  flex: 1;
  font-family: 'Fira Code', 'Consolas', monospace;
  font-size: 12px;
  color: var(--text-muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
  cursor: default;
  outline: none;
}
.copy-hint {
  font-size: 11px;
  color: var(--green);
  margin-top: 4px;
}

.input-row {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-top: 6px;
}
.input-row input { flex: 1; margin-top: 0; }
.test-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
}
.test-btn:hover { background: var(--border); }

.quiet-hours {
  display: flex;
  gap: 16px;
  margin-top: 8px;
}
.quiet-hours label {
  flex: 1;
  margin-bottom: 0;
}
.alert-feedback {
  font-size: 12px;
  margin-top: 6px;
  padding: 6px 10px;
  border-radius: 5px;
}
.link-blue { color: var(--blue); }
.link-blue:hover { text-decoration: underline; }

/* ── Billing / Pricing Cards ── */
.billing-current-plan {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 4px 0;
}
.billing-tier-badge {
  font-size: 13px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(59,130,246,.12);
  color: var(--blue);
}
.billing-limits {
  font-size: 13px;
  color: var(--text-muted);
}

.billing-plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.billing-plan-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  transition: border-color .15s;
}
.billing-plan-card:hover { border-color: var(--text-muted); }
.billing-plan-featured {
  border-color: var(--blue);
  background: linear-gradient(135deg, rgba(59,130,246,.03), var(--surface));
}
.billing-plan-featured:hover { border-color: var(--blue); }

.plan-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  white-space: nowrap;
}

.plan-header {
  text-align: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.plan-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}
.plan-price {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
}
.plan-price span {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

.plan-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.plan-features li {
  font-size: 13px;
  color: var(--text);
  padding-left: 18px;
  position: relative;
}
.plan-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--green);
  font-weight: 700;
}

.plan-btn {
  width: 100%;
  padding: 9px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  margin-top: auto;
}
.btn-checkout {
  background: var(--blue);
  color: #fff;
}
.btn-checkout:hover { opacity: .9; }
.plan-btn[disabled] { opacity: .4; cursor: default; }

/* ── Settings Responsive ── */
@media (max-width: 768px) {
  .settings-layout { flex-direction: column; gap: 12px; margin: 16px auto; }
  .settings-nav { width: 100%; flex-direction: row; }
  .settings-nav-item { flex: 1; justify-content: center; font-size: 13px; padding: 8px 10px; }
  .billing-plans { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .settings-section { padding: 14px 16px; }
  .quiet-hours { flex-direction: column; gap: 8px; }
  .input-row { flex-direction: column; }
  .test-btn { width: 100%; }
}

/* ── Badge Modal ─────────────────────────────── */
.modal-badge-box { max-width: 520px; }
.badge-modal-hint { font-size: 12px; color: var(--text-muted); margin-bottom: 20px; line-height: 1.5; }
.badge-preview-section { margin-bottom: 18px; }
.badge-preview-label { font-size: 11px; color: var(--text-muted); font-weight: 600; letter-spacing: .3px; text-transform: uppercase; display: block; margin-bottom: 8px; }
.badge-preview-frame { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 8px; min-height: 48px; display: flex; align-items: center; }
.badge-preview-frame img { display: block; }
.badge-copy-row { display: flex; gap: 8px; }
.badge-code-input { flex: 1; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-muted); border-radius: var(--radius); padding: 7px 10px; font-size: 11px; font-family: monospace; outline: none; min-width: 0; }
.btn-copy-badge { background: var(--surface-2); border: 1px solid var(--border); color: var(--text); border-radius: var(--radius); padding: 7px 14px; font-size: 12px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: background .15s; }
.btn-copy-badge:hover { background: var(--border); }

/* ── Trust Badges (Landing Page) ───────────── */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}
.trust-badge {
  background: #141414;
  border: 1px solid #1e1e1e;
  border-radius: 10px;
  padding: 20px 12px;
  text-align: center;
  transition: border-color 0.2s;
}
.trust-badge:hover { border-color: #22c55e; }
.trust-badge .badge-icon { font-size: 24px; margin-bottom: 8px; }
.trust-badge .badge-title { font-size: 14px; font-weight: 600; color: #d4d4d4; margin-bottom: 4px; }
.trust-badge .badge-sub { font-size: 12px; color: #666; line-height: 1.4; }

/* ── Domain Expiry Badge ───────────────────── */
.card-domain-expiry {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 6px;
  font-weight: 500;
}
.expiry-ok       { color: var(--text-muted); background: transparent; }
.expiry-warn     { color: var(--yellow); background: var(--yellow-dim); }
.expiry-critical { color: var(--red);    background: var(--red-dim); }

/* ── Payment Banner Animation ──────────────── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Feedback Widget ────────────────────────── */
.btn-feedback {
  position: fixed; bottom: 24px; right: 24px;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--green); color: #fff;
  border: none; font-size: 20px;
  cursor: pointer; z-index: 100;
  box-shadow: 0 4px 16px rgba(0,0,0,.3);
  transition: transform .15s, box-shadow .15s;
}
.btn-feedback:hover { transform: scale(1.08); box-shadow: 0 6px 24px rgba(0,0,0,.4); }

.modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 24px 0;
}
.modal-header h2 { margin: 0; font-size: 18px; }
.modal-close {
  background: none; border: none; font-size: 24px;
  cursor: pointer; color: var(--text-muted); line-height: 1;
}
.modal-body { padding: 16px 24px; }
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block; font-size: 13px; font-weight: 600;
  margin-bottom: 6px; color: var(--text-2);
}
.form-select, .form-textarea {
  width: 100%; padding: 9px 12px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); font-size: 14px; font-family: inherit;
}
.form-textarea { resize: vertical; min-height: 80px; }
.form-select:focus, .form-textarea:focus {
  outline: none; border-color: var(--green); box-shadow: 0 0 0 2px var(--green-dim);
}
