:root {
  /* Core palette */
  --bg: #f8f8f8;
  --surface: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --border: #e5e7eb;

  /* Brand (Clarity-style magenta) */
  --brand: #c80068;
  --brand-2: #d656a8;

  /* Effects */
  --shadow: 0 10px 20px rgba(17, 24, 39, 0.06);
  --shadow-sm: 0 6px 14px rgba(17, 24, 39, 0.06);

  /* Layout */
  --radius: 16px;
  --radius-sm: 12px;
  --sidebar: 260px;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto,
    Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

/* =========================
   Box (main container)
   ========================= */

.box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  max-width: 500px;
  margin: 50px auto;
  text-align: center;
}

/* =========================
   App layout
   ========================= */

.app {
  display: block;
  min-height: 100vh;
}

/* =========================
   Sidebar
   ========================= */

.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  padding: 22px 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  margin-bottom: 18px;
}

.brand-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, var(--brand-2), var(--brand));
}

.brand-title {
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: 18px;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}

.nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}

.nav a .icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.nav a.active {
  color: var(--brand);
  background: rgba(200, 0, 104, 0.08);
}

.nav a.active .icon {
  color: var(--brand);
}

.nav a:hover {
  background: rgba(17, 24, 39, 0.04);
}

/* =========================
   Main content
   ========================= */

.main {
  padding: 26px clamp(10px, 5vw, 40px);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.topbar-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.kicker {
  font-size: 13px;
  color: var(--muted);
}

.title {
  font-size: 30px;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pill {
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 10px 12px;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  gap: 8px;
  color: #374151;
  font-weight: 600;
  font-size: 14px;
}

/* =========================
   Grid / cards
   ========================= */

.grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 18px;
  align-items: start;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.card-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
}

.card-subtitle {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
}

.divider {
  height: 1px;
  background: var(--border);
  margin: 12px 0 16px;
}

/* =========================
   Verification area
   ========================= */

.verify-wrap {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) 1fr;
  gap: 18px;
}

.qr-box {
  border: 1px dashed rgba(200, 0, 104, 0.35);
  border-radius: var(--radius-sm);
  background: rgba(200, 0, 104, 0.03);
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.qr-box img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid var(--border);
  padding: 10px;
}

.status {
  font-weight: 700;
  color: #374151;
  font-size: 14px;
}

.hint {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.4;
  text-align: center;
}

/* =========================
   Buttons
   ========================= */

.btn {
  border: 0;
  background: var(--brand);
  color: #ffffff;
  font-weight: 800;
  font-size: 14px;
  padding: 12px 14px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 10px 18px rgba(200, 0, 104, 0.18);
  transition: transform 0.08s ease, filter 0.15s ease;
}

.btn:hover {
  filter: brightness(1.03);
}

.btn:active {
  transform: translateY(1px);
}

.btn.secondary {
  background: #ffffff;
  color: var(--brand);
  border: 1px solid rgba(200, 0, 104, 0.35);
  box-shadow: var(--shadow-sm);
}

/* =========================
   Claims / badges
   ========================= */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #ffffff;
  font-weight: 700;
  font-size: 13px;
  color: #374151;
}

.badge-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #f59e0b;
}

.badge-dot.pending {
  background: #f59e0b;
}

.badge-dot.error {
  background: #ef4444;
}

.badge-dot.verified {
  background: #10b981;
}

/* =========================
   Code / JSON display
   ========================= */

pre {
  margin: 0;
  padding: 14px;
  border-radius: var(--radius-sm);
  background: #f3f4f6;
  border: 1px solid var(--border);
  overflow: auto;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text);
}

/* =========================
   Responsive
   ========================= */

@media (max-width: 980px) {
  .sidebar {
    position: sticky;
    top: 0;
    z-index: 5;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .verify-wrap {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .main {
    padding: 16px 10px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .title {
    font-size: 24px;
  }
}
