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

:root {
  --bg: #0c0a0b;
  --card: #171314;
  --border: #271f21;
  --text: #f3eef0;
  --muted: #948a8c;
  --accent: #e63950;
  --accent-dim: rgba(230, 57, 80, 0.14);
  --warn: #f5a623;
  --warn-dim: rgba(245, 166, 35, 0.14);
  --danger: #b91c1c;
  --radius: 18px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

.wrap {
  max-width: 480px;
  margin: 0 auto;
  padding: 20px 16px 60px;
  animation: fadeIn 0.5s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

header.app-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 0 22px;
  position: relative;
}
header.app-header::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

header.app-header .logo {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--accent-dim);
  border: 1px solid rgba(230, 57, 80, 0.35);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}

header.app-header h1 {
  font-size: 17px;
  margin: 0;
  font-weight: 600;
}

header.app-header p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 16px;
}

label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin: 14px 0 6px;
}
label:first-of-type { margin-top: 0; }

input, textarea {
  width: 100%;
  background: #0d0f14;
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 14px;
  padding: 11px 12px;
  font-size: 15px;
  outline: none;
}
input:focus, textarea:focus { border-color: var(--accent); }

select {
  width: 100%;
  background: #0d0f14;
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 14px;
  padding: 11px 12px;
  font-size: 15px;
  outline: none;
}
select:focus { border-color: var(--accent); }

input[type="checkbox"] {
  width: auto;
  accent-color: var(--accent);
}

input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
  padding: 0;
  background: transparent;
  border: none;
}

button {
  border: none;
  border-radius: 14px;
  padding: 13px 16px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-secondary {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.btn-row { display: flex; gap: 10px; margin-top: 16px; }
.btn-row button { width: auto; flex: 1; }

.status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.status-btn {
  background: #0d0f14;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 13px;
  padding: 12px 8px;
}
.status-btn.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}
.status-btn.delay {
  grid-column: 1 / -1;
}
.status-btn.delay.active {
  background: var(--warn-dim);
  border-color: var(--warn);
  color: var(--warn);
}

.link-box {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
.link-box input { flex: 1; font-size: 13px; }
.link-box button { width: auto; padding: 11px 14px; }

#map {
  width: 100%;
  height: 280px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  border: 1px solid var(--border);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  background: var(--accent-dim);
  color: var(--accent);
}
.status-pill.delayed { background: var(--warn-dim); color: var(--warn); }
.status-pill .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.timeline { margin-top: 6px; }
.timeline-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
}
.timeline-step .marker {
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border);
  flex-shrink: 0;
  margin-top: 2px;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
}
.timeline-step.done .marker {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.timeline-step .label { font-size: 14px; }
.timeline-step .sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.timeline-step.done .label { color: var(--text); }
.timeline-step:not(.done) .label { color: var(--muted); }

.muted { color: var(--muted); font-size: 13px; }
.center { text-align: center; }
.small { font-size: 12px; }
.error-box {
  background: #2a1416;
  border: 1px solid #5c2327;
  color: #ffb4b8;
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 13px;
  margin-top: 12px;
}
.success-box {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 13px;
  margin-top: 12px;
}
a { color: var(--accent); }