* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, 'Segoe UI', Arial, sans-serif; background: #F5F0E6; color: #3A2E20; }
.serif { font-family: 'Cormorant Garamond', serif; }
.wrap { max-width: 480px; margin: 0 auto; padding: 2.5rem 1.25rem; min-height: 100vh; }
.wrap.wide { max-width: 760px; }
.card { background: #FDFBF7; border-radius: 12px; border: 0.5px solid #E4DDD0; padding: 2rem 1.75rem; }
.card + .card { margin-top: 1rem; }
.brand { text-align: center; margin-bottom: 1.5rem; }
.brand .icon { width: 56px; height: 56px; margin: 0 auto 1rem; border-radius: 50%; background: #4A3527; display: flex; align-items: center; justify-content: center; color: #D9A94E; font-size: 24px; }
.brand img.logo { max-width: 160px; max-height: 70px; margin: 1.25rem auto 0; display: block; }
.brand h1 { font-size: 28px; color: #4A3527; margin: 0; letter-spacing: 0.5px; }
.brand p { font-size: 16px; color: #8A7A63; margin: 4px 0 0; }
label { display: block; font-size: 13px; color: #6B5D4A; margin-bottom: 6px; }
input, select, textarea {
  width: 100%; border: 0.5px solid #D8CFBE; border-radius: 8px; padding: 0 14px;
  font-size: 15px; background: #FFFFFF; color: #3A2E20; font-family: inherit;
}
input, select { height: 44px; }
textarea { padding: 10px 14px; resize: vertical; }
button.primary {
  width: 100%; height: 44px; border: none; border-radius: 8px; background: #4A3527;
  color: #F2E9D8; font-size: 14px; font-weight: 500; cursor: pointer;
}
button.primary:disabled { opacity: 0.5; cursor: default; }
button.secondary {
  height: 38px; padding: 0 16px; border: 0.5px solid #D8CFBE; border-radius: 8px;
  background: #FDFBF7; color: #4A3527; font-size: 13px; cursor: pointer;
}
.hint { font-size: 12px; color: #9C8D77; margin-top: 6px; }
.divider { height: 1px; background: #E4DDD0; margin: 1.5rem 0; }
.row { display: flex; justify-content: space-between; align-items: center; }
.pill { font-size: 11px; padding: 2px 8px; border-radius: 6px; }
.pill-gold { background: #F2E4B8; color: #7A5A0E; }
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px,1fr)); gap: 12px; margin-bottom: 1.5rem; }
.metric { background: #FFFFFF; border: 0.5px solid #E4DDD0; border-radius: 10px; padding: 12px; }
.metric p:first-child { font-size: 12px; color: #9C8D77; margin: 0 0 4px; }
.metric p:last-child { font-size: 22px; font-weight: 500; margin: 0; }
table { width: 100%; font-size: 13px; border-collapse: collapse; }
table th { text-align: left; color: #9C8D77; font-weight: 400; padding: 4px 6px; }
table td { padding: 6px; border-top: 0.5px solid #EFE9DC; }
.error { color: #A32D2D; font-size: 13px; margin-top: 10px; }
.success { color: #3B6D11; font-size: 13px; margin-top: 10px; }
.badge-num { width: 22px; height: 22px; border-radius: 50%; color: #4A3527; font-size: 12px; font-weight: 500; display: inline-flex; align-items: center; justify-content: center; background: #D9A94E; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: #4A3527; display: flex; align-items: center; justify-content: center; font-size: 13px; color: #D9A94E; font-weight: 500; }
a.link { color: #A67C2E; cursor: pointer; text-decoration: none; }
.hidden { display: none !important; }
.autocomplete { position: relative; }
.autocomplete-results {
  position: absolute; z-index: 20; left: 0; right: 0; top: 46px;
  background: #FFFFFF; border: 0.5px solid #D8CFBE; border-radius: 8px;
  max-height: 220px; overflow-y: auto; box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.autocomplete-item { padding: 10px 14px; font-size: 14px; cursor: pointer; }
.autocomplete-item:hover, .autocomplete-item.active { background: #F5F0E6; }
.autocomplete-empty { padding: 10px 14px; font-size: 13px; color: #9C8D77; }
