/* Sierra Nevada Appraisal Group palette. Gold and sage are accents;
   forest, charcoal, and slate carry text for legibility on light surfaces. */
:root {
  --forest: #19372d;
  --gold: #a9956c;
  --slate: #5d625e;
  --charcoal: #262c29;
  --sage: #9aa79c;
  --ivory: #f6f4ee;
  --paper: #fff;
  --forest-hover: #244e40;
  --sage-wash: #eef1eb;
  --rule: #dcded6;
  --error: #8b3434;
  --error-wash: #fbf0ee;
  --error-rule: #debdb7;
  --warning: #695127;
  --warning-wash: #f7f1e5;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: Arial, Helvetica, sans-serif;
  background: var(--ivory);
  color: var(--charcoal);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button, a, summary { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--forest);
  outline-offset: 4px;
}
header {
  background: var(--paper);
  border-top: 4px solid var(--forest);
  border-bottom: 1px solid var(--rule);
  padding: 18px clamp(20px, 5vw, 72px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.logo-icon { width: 40px; height: 40px; flex-shrink: 0; }
.logo-text {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 29px;
  font-weight: 700;
  color: var(--forest);
  letter-spacing: -1.1px;
}
.logo-text span { font-weight: 400; }
.brand-attribution { padding-left: 20px; border-left: 1px solid var(--gold); color: var(--slate); }
.brand-attribution span { display: block; font-size: 10px; letter-spacing: 1.6px; text-transform: uppercase; margin-bottom: 5px; }
.brand-attribution strong { display: block; font-family: Georgia, 'Times New Roman', serif; color: var(--forest); font-size: 13px; font-weight: 400; }
main { flex: 1; display: flex; flex-direction: column; align-items: center; padding: 44px 24px 36px; gap: 28px; }
.hero { text-align: center; max-width: 620px; }
.eyebrow { color: var(--slate); font-size: 10px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 14px; }
.hero h1 { font-family: Georgia, 'Times New Roman', serif; font-size: clamp(34px, 4vw, 46px); font-weight: 400; color: var(--forest); line-height: 1.12; margin-bottom: 16px; letter-spacing: -1.2px; }
.hero h1 span { font-style: italic; }
.hero p { font-size: 15px; color: var(--slate); line-height: 1.65; max-width: 445px; margin: 0 auto; }
.card { background: var(--paper); border: 1px solid var(--rule); border-top: 3px solid var(--gold); border-radius: 10px; box-shadow: 0 10px 30px rgba(25,55,45,.05); padding: 32px; width: 100%; max-width: 560px; }
.drop-zone { border: 1.5px dashed var(--sage); border-radius: 6px; background: var(--ivory); padding: 29px 20px; text-align: center; cursor: pointer; transition: border-color .2s, background .2s; position: relative; }
.drop-zone:hover, .drop-zone.dragover { border-color: var(--forest); background: var(--sage-wash); }
.drop-zone:focus-within { outline: 2px solid var(--forest); outline-offset: 4px; }
.drop-zone input[type='file'] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.drop-zone input:disabled { cursor: wait; }
.drop-icon { width: 44px; height: 44px; color: var(--forest); margin: 0 auto 16px; display: block; }
.drop-zone h3 { font-family: Georgia, 'Times New Roman', serif; font-size: 21px; font-weight: 400; color: var(--forest); margin-bottom: 7px; }
.drop-zone p { font-size: 13px; color: var(--slate); line-height: 1.55; }
#uploadHelp { margin-top: 13px; font-size: 12px; }
.file-badge { display: none; align-items: center; gap: 12px; background: var(--sage-wash); border: 1px solid var(--sage); border-radius: 6px; padding: 14px; margin-top: 16px; }
.file-badge.show { display: flex; }
.badge-icon { width: 27px; height: 27px; color: var(--forest); flex-shrink: 0; }
.badge-info { flex: 1; min-width: 0; text-align: left; }
.badge-name { font-size: 13px; font-weight: 700; color: var(--charcoal); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.badge-size { font-size: 12px; color: var(--slate); margin-top: 4px; }
.btn-remove { background: none; border: none; cursor: pointer; color: var(--slate); font-size: 22px; line-height: 1; min-width: 36px; min-height: 36px; border-radius: 4px; flex-shrink: 0; transition: color .15s, background .15s; }
.btn-remove:hover { color: var(--error); background: var(--error-wash); }
.btn-remove:disabled { cursor: not-allowed; opacity: .5; }
.progress-wrap { display: none; flex-direction: column; align-items: center; gap: 10px; margin-top: 20px; }
.progress-wrap.show { display: flex; }
.progress-track { width: 100%; height: 5px; background: var(--sage-wash); border-radius: 3px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--forest), var(--gold)); border-radius: 3px; width: 0%; transition: width .5s ease; animation: shimmer 1.6s ease-in-out infinite; }
@keyframes shimmer { 0%, 100% { opacity: 1; } 50% { opacity: .65; } }
.progress-label { font-size: 13px; color: var(--slate); text-align: center; line-height: 1.5; }
.status-msg { display: none; align-items: center; gap: 10px; padding: 14px 16px; border-radius: 6px; font-size: 13px; font-weight: 600; line-height: 1.5; margin-top: 16px; overflow-wrap: anywhere; }
.status-msg.show { display: flex; }
.status-msg.success { background: var(--sage-wash); color: var(--forest); border: 1px solid var(--sage); }
.status-msg.error { background: var(--error-wash); color: var(--error); border: 1px solid var(--error-rule); }
.status-msg.warning { background: var(--warning-wash); color: var(--warning); border: 1px solid var(--gold); }
.btn-convert { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 50px; margin-top: 22px; padding: 14px; background: var(--forest); color: var(--ivory); border: 1px solid var(--forest); border-radius: 6px; font-size: 15px; font-weight: 700; cursor: pointer; transition: background .2s, box-shadow .2s; }
.btn-convert svg { width: 18px; height: 18px; }
.btn-convert:hover:not(:disabled) { background: var(--forest-hover); box-shadow: 0 4px 12px rgba(25,55,45,.14); }
.btn-convert:disabled { background: var(--rule); border-color: var(--rule); color: var(--slate); cursor: not-allowed; }
.download-link { display: inline-block; margin-top: 16px; color: var(--forest); font-size: 14px; font-weight: 700; text-underline-offset: 4px; }
.download-link[hidden] { display: none; }
#issueList { margin-top: 12px; padding-left: 22px; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
#issueList:empty { display: none; }
.steps { width: 100%; max-width: 560px; }
.help { color: var(--slate); font-size: 13px; line-height: 1.65; border-bottom: 1px solid var(--rule); padding: 0 0 20px; }
.help summary { cursor: pointer; font-weight: 700; color: var(--forest); width: fit-content; }
.help summary::marker { color: var(--forest); }
.help p { margin-top: 12px; }
.steps-label { text-align: center; font-size: 10px; font-weight: 700; color: var(--slate); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 20px; }
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step { text-align: center; }
.step-num { width: 28px; height: 28px; border: 1px solid var(--gold); color: var(--forest); border-radius: 50%; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; }
.step h3 { font-size: 12px; font-weight: 700; color: var(--charcoal); margin-bottom: 7px; }
.step p { font-size: 12px; color: var(--slate); line-height: 1.6; }
footer { text-align: center; padding: 22px 24px; border-top: 1px solid var(--rule); font-size: 11px; line-height: 1.7; color: var(--slate); }
footer strong { color: var(--forest); font-weight: 400; }
@media (max-width: 600px) {
  header { gap: 15px; padding: 16px 20px; }
  .logo-text { font-size: 25px; }
  .logo-icon { width: 34px; height: 34px; }
  .brand-attribution { max-width: 158px; padding-left: 14px; }
  .brand-attribution strong { font-size: 11px; line-height: 1.4; }
  .brand-attribution span { font-size: 9px; letter-spacing: 1px; }
  main { padding: 32px 20px; gap: 24px; }
  .hero h1 { font-size: 37px; }
  .hero p { font-size: 14px; }
  .card { padding: 24px; }
  .drop-zone { padding: 27px 12px; }
  .steps-grid { gap: 14px; }
}
@media (max-width: 400px) {
  header { gap: 12px; padding: 14px 16px; }
  .logo { gap: 7px; }
  .logo-text { font-size: 23px; }
  .logo-icon { width: 30px; height: 30px; }
  .brand-attribution { max-width: 125px; padding-left: 12px; }
  .brand-attribution span { display: none; }
  main { padding-right: 16px; padding-left: 16px; }
  .hero h1 { font-size: 33px; }
  .card { padding: 20px; }
  #uploadHelp { max-width: 200px; margin-left: auto; margin-right: auto; }
  .steps-grid { grid-template-columns: 1fr; gap: 20px; }
  .step { position: relative; padding-left: 42px; text-align: left; }
  .step-num { position: absolute; left: 0; top: 0; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
