* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #1e293b;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 24px 16px;
  overflow-x: hidden;
}

.card {
  background: #f8fafc;
  border-radius: 14px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
  width: 100%;
  max-width: 480px;
  padding: 40px 36px;
}

.brand {
  text-align: center;
  margin-bottom: 28px;
}

.brand img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 12px;
  background: #fff;
  padding: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

@media (max-width: 420px) {
  body {
    padding: 16px 10px;
    align-items: center;
  }

  .card {
    padding: 28px 18px;
    border-radius: 10px;
  }

  .brand img {
    width: 68px;
    height: 68px;
  }

  .brand h1 {
    font-size: 19px;
  }

  .nav-links {
    gap: 12px;
  }
}

.brand h1 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #0f172a;
  margin: 14px 0 4px;
}

.brand p {
  font-size: 13px;
  color: #64748b;
  margin: 0;
}

.brand p span {
  color: #2563eb;
  font-weight: 700;
}

h2.title {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 20px;
  text-align: center;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  margin-bottom: 24px;
  font-size: 13px;
}

.nav-links a {
  color: #64748b;
  text-decoration: none;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.nav-links a.active {
  color: #2563eb;
  font-weight: 700;
  border-bottom-color: #2563eb;
}

form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

label {
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
  display: block;
}

input,
select,
textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 16px; /* prevents iOS Safari auto-zoom on focus */
  color: #0f172a;
  background: #fff;
  outline: none;
  font-family: inherit;
}

input:focus,
select:focus,
textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

textarea {
  resize: vertical;
  min-height: 90px;
}

.hint {
  font-size: 12px;
  color: #94a3b8;
  margin-top: 4px;
}

button[type="submit"] {
  margin-top: 6px;
  padding: 12px;
  background: #16a34a;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
}

button[type="submit"]:hover:not(:disabled) {
  background: #15803d;
}

button[type="submit"]:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.alert {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 16px;
  display: none;
}

.alert.error {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.alert.success {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.alert.show {
  display: block;
}

.ticket-id-box {
  text-align: center;
  padding: 20px;
  background: #eff6ff;
  border: 1px dashed #2563eb;
  border-radius: 10px;
  margin-bottom: 16px;
}

.ticket-id-box .label {
  font-size: 12px;
  color: #64748b;
  margin-bottom: 6px;
}

.ticket-id-box .id {
  font-size: 22px;
  font-weight: 800;
  color: #1d4ed8;
  letter-spacing: 0.03em;
}

.timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  border-left: 2px solid #e2e8f0;
}

.timeline li {
  position: relative;
  padding: 4px 0 16px 20px;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2563eb;
}

.timeline li:last-child::before {
  background: #16a34a;
}

.timeline .status {
  font-weight: 700;
  color: #0f172a;
  font-size: 14px;
}

.timeline .time {
  font-size: 12px;
  color: #94a3b8;
}

.timeline .remarks {
  font-size: 12px;
  color: #475569;
  margin-top: 2px;
}

.status-pill {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: #dbeafe;
  color: #1d4ed8;
}

.result-block {
  display: none;
}

.result-block.show {
  display: block;
}
