:root {
  color-scheme: light;
  --bg: #f6f8f6;
  --ink: #172a25;
  --muted: #53665d;
  --green: #1a563f;
  --border: #e0e8e1;
  --paper: #fff;
  --radius: 17px;
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--bg); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
svg { flex: none; vertical-align: middle; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #498169; outline-offset: 4px; }

.site-header { border-bottom: 1px solid var(--border); background: var(--paper); }
.header-inner, .shell { width: min(1100px, calc(100% - 48px)); margin-inline: auto; }
.header-inner { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 750; letter-spacing: .02em; }
.brand span { display: grid; place-items: center; width: 39px; height: 39px; color: #e5f8b3; background: #194c39; border-radius: 11px; }
.local-label { display: flex; align-items: center; gap: 7px; font-size: 13px; color: #426252; }
.shell { padding-block: 34px 32px; min-height: calc(100vh - 138px); }
.hero {
  position: relative; overflow: hidden; display: flex; align-items: center; isolation: isolate;
  padding: 40px 39px; min-height: 184px; margin-bottom: 26px; border-radius: 22px; color: #f7fff4;
  background: radial-gradient(ellipse at 84% 8%, #377152, transparent 52%), #1a4838;
}
.hero::after { content: ''; position: absolute; inset: 0 0 0 53%; z-index: -1; opacity: .15; background-image: radial-gradient(#d5ecc4 1px, transparent 1px); background-size: 17px 17px; mask-image: linear-gradient(90deg, transparent, black 50%); }
h1, p { margin: 0; }
.hero h1 { font-size: clamp(29px, 4.6vw, 48px); font-weight: 780; letter-spacing: -.025em; line-height: 1.22; }
.hero p { margin-top: 12px; color: #d2e8d9; font-size: clamp(13px, 1.9vw, 16px); line-height: 1.6; }
.hero-art { position: absolute; right: 61px; top: 26px; width: 186px; height: 142px; pointer-events: none; }
.art-sheet { position: absolute; width: 86px; height: 110px; border-radius: 11px; border: 1px solid #d7edce; }
.art-back { left: 64px; top: 14px; transform: rotate(17deg); background: #8ab49a; opacity: .7; }
.art-front { left: 43px; top: 10px; background: #eef8df; transform: rotate(-12deg); padding: 25px 13px 12px; box-shadow: 0 9px 26px #0b332f50; }
.art-front i { height: 4px; border-radius: 5px; display: block; margin-bottom: 8px; background: #9fbea1; }
.art-front i:nth-child(1) { width: 27px; height: 11px; background: #4c8063; }
.art-front i:nth-child(4) { width: 37px; }
.art-check { width: 40px; height: 40px; position: absolute; top: 83px; left: 109px; display: grid; place-items: center; color: #214a37; border-radius: 14px; box-shadow: 0 6px 20px #10372931; background: #d5f09a; transform: rotate(8deg); }

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.card {
  position: relative; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; min-height: 129px;
  padding: 17px 19px 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--paper);
  box-shadow: 0 2px 4px #22352a05;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.card:hover { border-color: #9ebead; transform: translateY(-2px); box-shadow: 0 6px 15px #294b3a0e; }
.card-mint { --chip: #e6f4ea; --chip-ink: #286044; }
.card-sky { --chip: #e8f1fb; --chip-ink: #2c5d86; }
.card-violet { --chip: #efecf8; --chip-ink: #66529d; }
.card-peach { --chip: #f8efe6; --chip-ink: #8b562f; }
.tool-icon { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border-radius: 11px; color: var(--chip-ink); background: var(--chip); }
.card-arrow { position: absolute; right: 15px; top: 15px; color: #73887b; }
.card-title { margin-top: 11px; font-size: 16px; font-weight: 720; line-height: 1.45; }
.card-summary { margin-top: 4px; color: var(--muted); font-size: 13px; line-height: 1.6; }

.tool-shell { max-width: 850px; padding-top: 24px; }
.back-link { display: inline-flex; align-items: center; gap: 6px; padding-block: 6px; color: var(--green); font-size: 14px; font-weight: 650; }
.tool-heading { display: flex; gap: 15px; align-items: center; margin-block: 19px 20px; }
.tool-heading .tool-icon { width: 54px; height: 54px; border-radius: 15px; }
.tool-heading h1 { font-size: clamp(24px, 4vw, 34px); line-height: 1.2; }
.tool-heading p { margin-top: 5px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.tool-tabs { display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 13px; }
.tool-tabs a { padding: 8px 12px; border: 1px solid #d8e4db; border-radius: 8px; color: var(--green); background: #fff; font-size: 14px; font-weight: 650; }
.tool-tabs a:hover { border-color: #86b09a; }
.tool-tabs [aria-current="page"] { background: #1e573e; border-color: #1e573e; color: #fff; }
.tool-panel { background: var(--paper); border: 1px solid var(--border); border-radius: var(--radius); padding: 23px; }
.filebox, .options, .result { margin-top: 20px; }
.filebox:first-child { margin-top: 0; }
.dropzone { padding: 24px 14px; text-align: center; background: #f6faf6; border: 1.5px dashed #a4bfae; border-radius: 13px; }
.dropzone.dragging { background: #e1f3e7; border-color: var(--green); }
.drop-icon { color: var(--green); margin-bottom: 7px; }
.drop-hint, .hint { color: var(--muted); font-size: 13px; line-height: 1.6; }
.drop-hint { margin: 3px 0 12px; }
.file-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.button, .action {
  border-radius: 9px; box-shadow: none; min-height: 42px; padding: 9px 14px; display: inline-flex;
  align-items: center; justify-content: center; gap: 7px; font-weight: 650; line-height: 1.45;
}
.button { color: var(--green); background: #fff; border: 1px solid #c5d8cc; }
.button:hover { background: #edf5ef; }
.action { color: #fff; background: #205941; border: 1px solid #205941; }
.action:hover { background: #184632; }
.action:disabled, .button:disabled { opacity: .55; cursor: default; }
.file-list { display: grid; gap: 7px; margin: 12px 0 0; padding: 0; list-style: none; }
.file-row { min-width: 0; display: flex; align-items: center; gap: 5px; background: #f6f8f6; padding: 5px 8px 5px 11px; border-radius: 8px; }
.file-row span { flex: 1; min-width: 0; color: var(--ink); font-size: 13px; overflow-wrap: anywhere; }
.icon-button { border: 0; background: transparent; color: #4b6656; padding: 6px; min-width: 31px; min-height: 32px; border-radius: 7px; }
.icon-button:hover { background: #e3ede5; }
.icon-button:disabled { opacity: .35; cursor: default; }
.options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px 16px; }
.options:empty { display: none; }
.field { display: flex; min-width: 0; flex-direction: column; gap: 5px; font-size: 14px; font-weight: 650; }
.field.wide, .note, .layer-list, .preview-area { grid-column: 1 / -1; }
.note { color: var(--muted); background: #f2f7f3; padding: 9px 12px; border-radius: 9px; font-size: 13px; line-height: 1.6; }
.field select, .field input:not([type="checkbox"]), .field textarea {
  display: block; width: 100%; border: 1px solid #ccd8cf; border-radius: 8px; color: var(--ink); background: #fff; padding: 9px 10px; font-weight: 400;
}
.field textarea { min-height: 97px; resize: vertical; }
.field.check-field { flex-direction: row; align-items: center; gap: 8px; min-height: 33px; }
.field.check-field input, .layer-list input { accent-color: var(--green); width: 17px; height: 17px; }
.form-actions { display: flex; align-items: center; gap: 10px; margin-top: 21px; }
.status { color: var(--muted); line-height: 1.6; font-size: 13px; overflow-wrap: anywhere; }
.status.error { color: #9b2f25; }
.result { background: #eef8ef; border-radius: 12px; padding: 14px; display: grid; justify-items: start; gap: 8px; }
.result h2 { margin: 0; font-size: 16px; }
.result-meta { font-size: 13px; color: #3a6450; line-height: 1.6; overflow-wrap: anywhere; }
.result-warning { color: #884919; font-size: 13px; }
.result-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.result-failures { padding-inline-start: 20px; max-height: 190px; overflow: auto; margin: 1px 0 5px; font-size: 13px; line-height: 1.65; overflow-wrap: anywhere; }
.layer-list { margin: 0; min-width: 0; padding: 10px 13px 13px; border: 1px solid var(--border); border-radius: 9px; }
.layer-list legend { font-size: 14px; font-weight: 650; padding: 0 5px; }
.layer-list label { display: flex; gap: 7px; align-items: center; color: var(--ink); font-size: 14px; min-height: 32px; overflow-wrap: anywhere; }
.preview-area { display: grid; justify-items: start; gap: 9px; min-width: 0; }
.preview-area img { max-width: 100%; max-height: 285px; object-fit: contain; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.artwork-ratios { display: flex; flex-wrap: wrap; gap: 3px 15px; }
.artwork-ratios label { padding: 2px 0; }
.field input[type="range"] { accent-color: var(--green); width: 100%; padding: 0; }
.invoice-review { display: grid; gap: 10px; }
.invoice-record { background: #f6f8f6; padding: 12px; border-radius: 10px; border: 1px solid var(--border); }
.invoice-record-heading, .invoice-include { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 650; overflow-wrap: anywhere; }
.invoice-record-heading { justify-content: space-between; margin-bottom: 6px; }
.invoice-record-heading .button { flex: none; min-height: 35px; padding: 5px 9px; }
.invoice-include input { accent-color: var(--green); width: 17px; height: 17px; flex: none; }
.invoice-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; margin-top: 10px; }
@media (max-width: 680px) {
  .header-inner, .shell { width: calc(100% - 30px); }
  .header-inner { min-height: 59px; }
  .shell { padding-block: 22px; }
  .hero { min-height: 148px; padding: 24px 20px; margin-bottom: 17px; border-radius: 16px; }
  .hero-art { right: -14px; top: 12px; transform: scale(.7); }
  .hero-copy { max-width: 76%; }
  .cards { gap: 9px; }
  .card { min-height: 116px; padding: 12px 10px 10px; border-radius: 12px; }
  .card-title { font-size: 14px; margin-top: 8px; }
  .card-summary { font-size: 11px; }
  .card-arrow { top: 10px; right: 9px; }
  .card-arrow svg { width: 14px; height: 14px; }
  .tool-icon { width: 34px; height: 34px; border-radius: 9px; }
  .tool-icon svg { width: 21px; height: 21px; }
  .tool-panel { padding: 16px; }
  .options { gap: 10px; }
}
@media (max-width: 420px) {
  .hero-art { right: -48px; opacity: .67; }
  .card { min-height: 95px; }
  .card-summary, .card-arrow { display: none; }
  .options { grid-template-columns: 1fr; }
  .form-actions { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .card { transition: none; }
  .card:hover { transform: none; }
}
