/* =========================
   RESET + BASE
========================= */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, Helvetica, Arial, sans-serif;
  background: #f3f4f6;
  color: #111827;
}

a {
  color: #2563eb;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
}

input, button {
  font-family: inherit;
}

/* =========================
   LAYOUT
========================= */
.container {
  max-width: 900px;
  margin: 32px auto;
  padding: 0 16px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
}

.topbar h1 {
  font-size: 26px;
  margin: 0;
}

.card {
  background: #ffffff;
  border-radius: 16px;
  padding: 20px;
  box-shadow:
    0 1px 2px rgba(0,0,0,0.05),
    0 10px 20px rgba(0,0,0,0.06);
}

/* =========================
   TYPO
========================= */
.muted {
  color: #6b7280;
  font-size: 14px;
}

.small {
  color: #6b7280;
  font-size: 13px;
  margin-top: 12px;
}

.meta {
  margin: 12px 0;
  font-size: 14px;
  color: #374151;
}

/* =========================
   FORM / SEARCH
========================= */
.toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.toolbar input {
  flex: 1 1 380px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
  font-size: 15px;
}

.toolbar input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37,99,235,0.15);
}

.toolbar button {
  padding: 12px 18px;
  border-radius: 12px;
  border: none;
  background: #2563eb;
  color: #ffffff;
  font-weight: 700;
  cursor: pointer;
}

.toolbar button:hover {
  background: #1e40af;
}

/* =========================
   ALERT / HINT
========================= */
.alert {
  margin: 10px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fef3c7;
  color: #92400e;
  font-size: 14px;
}

/* =========================
   SEARCH RESULT ITEM
========================= */
.item {
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  margin-bottom: 12px;
  background: #ffffff;
}

.item:hover {
  background: #f9fafb;
}

.title {
  font-weight: 700;
  line-height: 1.5;
  font-size: 15px;
}

/* highlight keyword */
mark {
  background: #fff2a8;
  padding: 0 3px;
  border-radius: 6px;
}

/* =========================
   ACTION BUTTONS
========================= */
.actions {
  margin-top: 10px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  border: 1px solid #e5e7eb;
  cursor: pointer;
  transition: all .15s ease;
}

.btn-view {
  background: #111827;
  color: #ffffff;
  border-color: #111827;
}

.btn-view:hover {
  background: #000000;
}

.btn-download {
  background: #ffffff;
  color: #111827;
}

.btn-download:hover {
  background: #f3f4f6;
}

/* =========================
   WALLET / HISTORY
========================= */
.balance {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.tx {
  padding: 12px;
  border-bottom: 1px solid #e5e7eb;
}

.tx:last-child {
  border-bottom: none;
}

.tx .type {
  font-weight: 700;
}

.tx .amount.plus {
  color: #059669;
}

.tx .amount.minus {
  color: #dc2626;
}

/* =========================
   LOGIN / AUTH
========================= */
.auth-card {
  max-width: 420px;
  margin: 80px auto;
}

.auth-card h1 {
  text-align: center;
  margin-bottom: 20px;
}

.auth-card input {
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 12px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
}

.auth-card button {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: none;
  background: #2563eb;
  color: #ffffff;
  font-weight: 700;
  cursor: pointer;
}

.auth-card button:hover {
  background: #1e40af;
}

/* =========================
   FOOTER / MISC
========================= */
.footer {
  text-align: center;
  color: #9ca3af;
  font-size: 13px;
  margin-top: 24px;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 640px) {
  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .toolbar {
    flex-direction: column;
  }

  .toolbar button {
    width: 100%;
  }
}
