:root {
  --green-deep: #1a2413;
  --green: #26321b;
  --green-mid: #3a4d2c;
  --green-light: #4e6840;
  --gold: #d7a45e;
  --gold-light: #e4bb7a;
  --gold-dark: #b8883a;
  --warm-white: #f7f3ec;
  --paper: #fdfbf6;
  --ink: #1a1a1a;
  --muted: #6b7363;
  --danger: #a23b2a;
  --success: #4e6840;
  --shadow-sm: 0 2px 8px rgba(26, 36, 19, 0.06);
  --shadow-md: 0 8px 24px rgba(26, 36, 19, 0.1);
  --shadow-lg: 0 24px 60px rgba(26, 36, 19, 0.15);
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(140deg, var(--paper) 0%, var(--warm-white) 100%);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
}

.bg-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.18;
  z-index: 0;
  pointer-events: none;
}

.bg-blob-1 {
  top: -10%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: var(--green-mid);
}

.bg-blob-2 {
  bottom: -15%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: var(--gold);
  opacity: 0.12;
}

.shell {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin: 0 auto;
  padding: 28px 20px 40px;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.brand-mark {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--green);
  color: var(--gold);
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  font-size: 22px;
  display: grid;
  place-items: center;
  letter-spacing: 0.5px;
  box-shadow: var(--shadow-sm);
}

.brand-line {
  font-family: "Cormorant Garamond", serif;
  font-size: 22px;
  font-weight: 600;
  color: var(--green-deep);
  line-height: 1.1;
}

.brand-sub {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 2px;
}

.card {
  background: white;
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(26, 36, 19, 0.06);
}

.card + .card,
.card + #results,
#results + .status-bar {
  margin-top: 18px;
}

.card-title {
  font-family: "Cormorant Garamond", serif;
  font-size: 28px;
  font-weight: 600;
  color: var(--green-deep);
  margin: 0 0 6px;
  line-height: 1.15;
}

.card-sub {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.pin-input,
.search-input {
  width: 100%;
  padding: 14px 16px;
  font-size: 17px;
  border: 1.5px solid rgba(26, 36, 19, 0.12);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink);
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
}

.pin-input {
  text-align: center;
  letter-spacing: 0.6em;
  font-size: 22px;
  font-weight: 600;
}

.pin-input:focus,
.search-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(215, 164, 94, 0.18);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.1s, background 0.15s, box-shadow 0.15s;
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--green);
  color: var(--gold-light);
  box-shadow: 0 4px 12px rgba(26, 36, 19, 0.2);
}

.btn-primary:hover {
  background: var(--green-deep);
}

.btn-primary:active {
  transform: translateY(1px);
}

#login-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.search-row {
  display: flex;
  gap: 10px;
}

.search-row .search-input {
  flex: 1;
}

.search-row .btn {
  flex-shrink: 0;
}

.notice {
  margin: 16px 0 0;
  padding: 12px 14px;
  background: rgba(215, 164, 94, 0.12);
  border-left: 3px solid var(--gold);
  border-radius: 6px;
  font-size: 13px;
  color: var(--green-deep);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.45;
}

.notice-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--gold);
  color: white;
  font-size: 12px;
  font-weight: 700;
  display: grid;
  place-items: center;
  margin-top: 1px;
}

.error {
  color: var(--danger);
  font-size: 14px;
  margin: 0;
  text-align: center;
}

.hidden {
  display: none !important;
}

.result-card {
  background: white;
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(26, 36, 19, 0.06);
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.result-card + .result-card {
  margin-top: 12px;
}

.result-card.is-member {
  border-top: 4px solid var(--gold);
}

.result-card.not-member {
  border-top: 4px solid var(--danger);
  background: linear-gradient(180deg, #fff 0%, rgba(162, 59, 42, 0.04) 100%);
}

.result-card.on-hold {
  border-top: 4px solid var(--danger);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.badge-active {
  background: rgba(78, 104, 64, 0.14);
  color: var(--green-deep);
}

.badge-hold {
  background: rgba(162, 59, 42, 0.12);
  color: var(--danger);
}

.badge-pickup {
  background: rgba(215, 164, 94, 0.18);
  color: var(--gold-dark);
}

.badge-ship {
  background: rgba(26, 36, 19, 0.08);
  color: var(--green-deep);
}

.result-name {
  font-family: "Cormorant Garamond", serif;
  font-size: 26px;
  font-weight: 600;
  color: var(--green-deep);
  margin: 10px 0 4px;
  line-height: 1.1;
}

.result-since {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 18px;
}

.result-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(26, 36, 19, 0.08);
}

@media (min-width: 480px) {
  .result-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.field-label {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.field-value {
  font-size: 15px;
  color: var(--ink);
  word-break: break-word;
}

.field-value.empty {
  color: var(--muted);
  font-style: italic;
}

.badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}

.not-member-icon {
  font-size: 36px;
  margin-bottom: 8px;
}

.not-member-title {
  font-family: "Cormorant Garamond", serif;
  font-size: 24px;
  color: var(--danger);
  margin: 0 0 6px;
  font-weight: 600;
}

.not-member-text {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.status-bar {
  margin-top: auto;
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}

.link-btn {
  background: none;
  border: none;
  color: var(--green-light);
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  text-decoration: underline;
  padding: 0;
}

.spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@media (max-width: 480px) {
  .search-row {
    flex-direction: column;
  }
  .card {
    padding: 22px 18px;
  }
  .card-title {
    font-size: 24px;
  }
}
