:root {
  color-scheme: light;
  --ink: #16261e;
  --muted: #4f6055;
  --dark: #153c31;
  --green: #267757;
  --line: #d8e2d8;
  --paper: #f4f6f0;
  --white: #fff;
  --accent: #ddefa4;
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font-size: 1rem; line-height: 1.55; }
h1, h2, p { margin: 0; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, canvas:focus-visible {
  outline: 3px solid #298057;
  outline-offset: 3px;
}
button { cursor: pointer; }
button:disabled { cursor: default; }
.wrap { width: min(1160px, calc(100% - 56px)); margin-inline: auto; }
.skip { position: absolute; left: 1rem; top: 1rem; z-index: 3; transform: translateY(-180%); background: white; padding: .75rem; }
.skip:focus { transform: translateY(0); }
.top { background: #fff; border-bottom: 1px solid var(--line); }
.top-inner { min-height: 70px; display: flex; align-items: center; gap: 32px; }
.brand { display: inline-flex; gap: .63rem; align-items: center; font-size: 1.25rem; font-weight: 780; text-decoration: none; }
.brand-icon { width: 32px; aspect-ratio: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 3px; background: var(--dark); padding: 6px; border-radius: 8px; }
.brand-icon i { background: #e3f1aa; border-radius: 2px; }
.brand-icon i:last-child { background: #7fb997; }
.top nav a { font-weight: 620; text-decoration: none; }
.top nav a:hover { color: var(--green); }
.local-label { margin-left: auto; display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: .875rem; white-space: nowrap; }
.local-label span { width: 8px; height: 8px; border-radius: 50%; background: #3a986f; }
.landing { padding-top: 29px; }
.hero {
  display: grid; grid-template-columns: 1fr .73fr; align-items: center; gap: 2rem;
  min-height: 420px; background: var(--dark); color: #fff;
  padding: clamp(32px, 6vw, 78px); border-radius: 22px; overflow: hidden;
}
.hero h1 { font-size: clamp(2.6rem, 5.6vw, 4.5rem); letter-spacing: -.07em; line-height: 1.12; font-weight: 820; }
.hero p { max-width: 440px; margin-top: 20px; color: #d6e8de; }
.action {
  background: var(--dark); color: #fff; min-height: 46px; display: inline-grid; place-items: center;
  padding: 10px 20px; border-radius: 9px; font-weight: 710; border: 1px solid transparent; text-decoration: none;
}
.action:hover:not(:disabled) { background: #235742; }
.hero .action { margin-top: 26px; background: var(--accent); color: #173229; }
.hero .action:hover { background: #eef9c0; }
.hero-art { position: relative; width: min(90%, 292px); margin-inline: auto; isolation: isolate; transform: rotate(-7deg); }
.hero-sample, .art-sheet { width: 100%; aspect-ratio: 10 / 11; border-radius: 12px; display: block; }
.hero-sample { height: auto; position: relative; z-index: 1; box-shadow: 0 14px 36px #0a211f56; }
.art-sheet { position: absolute; inset: 0; }
.sheet-back { background: #86b59e; transform: translate(31px, -17px) rotate(17deg); }
.sheet-mid { background: #d5ead4; transform: translate(19px, -7px) rotate(9deg); }
.art-corner { position: absolute; z-index: 2; width: 14px; height: 14px; border: 2px solid #f3f9e7; }
.top-left { inset: -7px auto auto -7px; border-bottom: 0; border-right: 0; }
.top-right { inset: -7px -7px auto auto; border-bottom: 0; border-left: 0; }
.bottom-left { inset: auto auto -7px -7px; border-top: 0; border-right: 0; }
.bottom-right { inset: auto -7px -7px auto; border-top: 0; border-left: 0; }
.catalog { padding-top: 29px; }
.catalog > h2 { margin-bottom: 14px; font-size: 1.4rem; }
.tool-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; }
.tool-card { display: flex; flex-direction: column; align-items: flex-start; min-height: 210px; border: 1px solid var(--line); border-radius: 13px; padding: 20px; background: white; text-decoration: none; }
.tool-card:hover { border-color: #5b9a7c; }
.tool-mark { display: inline-grid; place-content: center; flex-shrink: 0; width: 44px; height: 44px; border-radius: 10px; font-size: 1.16rem; font-weight: 790; color: #29523c; background: #ddecce; }
.tool-mark.batch-resize { color: #275d49; background: #d9efe2; }
.tool-mark.compress { color: #435585; background: #e3eafa; }
.tool-mark.jpg-to-webp { color: #5d4621; background: #f3ead1; }
.tool-card h2 { margin-top: 12px; font-size: 1.06rem; }
.tool-card p { margin-top: 6px; color: var(--muted); font-size: .93rem; }
.file-kind { padding-top: 12px; margin-top: auto; font-size: .79rem; font-weight: 700; color: #3b5947; }
.footer { display: flex; justify-content: space-between; gap: 14px; color: var(--muted); margin-top: 38px; padding: 18px 0 22px; border-top: 1px solid var(--line); font-size: .875rem; }
.workspace { padding-top: 24px; }
.crumb { display: flex; gap: 10px; color: var(--muted); font-size: .875rem; margin-bottom: 19px; }
.crumb a { text-underline-offset: 3px; }
.tool-heading { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 24px; }
.tool-heading .tool-mark { width: 52px; height: 52px; margin-top: 3px; }
.tool-heading h1 { font-size: clamp(1.65rem, 4vw, 2.65rem); line-height: 1.2; letter-spacing: -.045em; }
.tool-heading p { color: var(--muted); margin-top: 6px; }
.work-grid { display: grid; grid-template-columns: minmax(0, 1.48fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.panel { border: 1px solid var(--line); border-radius: 14px; background: #fff; padding: clamp(16px, 3vw, 25px); }
.panel-heading, .result-heading { display: flex; justify-content: space-between; align-items: center; gap: .75rem; margin-bottom: 14px; }
.panel h2 { font-size: 1.125rem; }
.plain { padding: 5px 8px; color: var(--dark); background: transparent; border: 0; border-radius: 5px; font-weight: 690; font-size: .875rem; }
.plain:hover { background: #e8f0e6; }
.drop { display: grid; place-items: center; gap: 7px; position: relative; min-height: 157px; text-align: center; background: #f0f6ec; border: 1px dashed #84a894; border-radius: 10px; padding: 16px; cursor: pointer; }
.drop:hover, .drop.drag { background: #e6f1df; border-color: var(--green); }
.drop:focus-within { outline: 3px solid #298057; outline-offset: 3px; }
.drop > span:last-of-type { color: var(--muted); font-size: .875rem; }
.upload-icon { display: grid; place-items: center; width: 33px; height: 33px; border-radius: 8px; background: #dcebd7; font-weight: 760; font-size: 1.3rem; line-height: 1; }
.drop > input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.hint, .status { color: var(--muted); font-size: .875rem; margin-top: 8px; }
.status:empty { display: none; }
.status[data-error="true"], .failed { color: #a1382a; }
fieldset { min-width: 0; border: 0; margin: 0; padding: 0; }
fieldset fieldset { margin-top: 14px; }
legend { padding: 0; font-weight: 700; font-size: .875rem; }
label:not(.drop) { display: grid; gap: 5px; min-width: 0; font-size: .875rem; font-weight: 670; }
#editable > label, #editable > .fields, #preview-region { margin-top: 12px; }
#editable > label:first-child { margin-top: 0; }
input:not([type="range"]), select {
  min-height: 41px; min-width: 0; width: 100%; padding: 7px 9px; border-radius: 7px; border: 1px solid #a9b9ae; background: #fff;
}
input[type="file"] { padding: 4px 6px; }
input::file-selector-button { border: 0; border-radius: 5px; padding: 4px 6px; background: #e6eee3; margin-right: 6px; font: inherit; cursor: pointer; }
input[type="color"] { padding: 3px; cursor: pointer; }
input[type="range"] { width: 100%; accent-color: var(--green); }
.fields, .bounds { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bounds { grid-template-columns: repeat(4, 1fr); }
.bounds input { padding: 6px; }
.preview-stage { display: grid; place-items: center; margin-top: 10px; padding: 10px; min-height: 170px; border-radius: 9px; background: #eff3ed; }
canvas { max-width: 100%; max-height: 400px; object-fit: contain; display: block; width: auto; height: auto; border-radius: 3px; }
[data-tool="batch-price-editor"] canvas { cursor: crosshair; touch-action: none; }
.full { width: 100%; margin-top: 16px; }
.action:disabled { background: #e0e8e0; color: #43574b; }
#results { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
#result-list { padding: 0; margin: 0; list-style: none; max-height: 220px; overflow: auto; }
#result-list li { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid #edf1eb; font-size: .875rem; overflow-wrap: anywhere; }
#result-list button { flex-shrink: 0; }
.related { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 18px; font-size: .875rem; color: var(--dark); }
.related a { text-underline-offset: 3px; }
@media (max-width: 850px) {
  .tool-grid { grid-template-columns: repeat(2, 1fr); }
  .hero { padding-inline: 38px; }
  .hero-art { width: min(84%, 250px); }
}
@media (max-width: 650px) {
  .wrap { width: calc(100% - 28px); }
  .top-inner { min-height: 59px; gap: 14px; flex-wrap: wrap; }
  .brand { font-size: 1rem; gap: 6px; }
  .brand-icon { width: 26px; padding: 5px; gap: 2px; }
  .top nav { font-size: .875rem; }
  .local-label { font-size: .8rem; }
  .work-grid { grid-template-columns: 1fr; }
  .hero { grid-template-columns: 1fr; padding: 29px; gap: 34px; }
  .hero h1 { font-size: clamp(2.3rem, 9.5vw, 3.4rem); }
  .hero-art { width: min(52%, 216px); margin-bottom: 9px; }
  .tool-card { padding: 14px; }
  .footer { flex-wrap: wrap; }
}
@media (max-width: 345px) {
  .local-label { display: none; }
  .tool-grid { grid-template-columns: 1fr; }
}

.language-list { position: relative; flex: none; font-size: .875rem; }
.language-list summary {
  cursor: pointer; list-style: none; color: var(--dark); font-weight: 670;
  padding: 7px 26px 7px 9px; border: 1px solid var(--line); border-radius: 7px;
}
.language-list summary::-webkit-details-marker { display: none; }
.language-list summary::after {
  content: ""; position: absolute; inset: 13px 10px auto auto; width: 6px; height: 6px;
  border-bottom: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg);
}
.language-list summary:focus-visible { outline: 3px solid #298057; outline-offset: 2px; }
.language-list ul {
  position: absolute; z-index: 5; right: 0; top: 100%; list-style: none;
  padding: 5px; margin: 5px 0 0; min-width: 11rem; background: #fff;
  border: 1px solid var(--line); border-radius: 9px; box-shadow: 0 10px 22px #15261d21;
}
.language-list a { display: block; padding: 5px 9px; border-radius: 4px; text-decoration: none; }
.language-list a:hover, .language-list [aria-current="page"] { background: var(--paper); color: var(--dark); }
.language-list [aria-current="page"] { font-weight: 720; }
.hero h1 { max-width: 670px; overflow-wrap: anywhere; }
:lang(de) .hero h1, :lang(fr) .hero h1, :lang(es) .hero h1, :lang(pt-BR) .hero h1 {
  font-size: clamp(2.15rem, 4.65vw, 4rem); letter-spacing: -.04em;
}
.tool-card h2, .tool-heading h1 { overflow-wrap: anywhere; }
select {
  appearance: none; padding-right: 30px;
  background: white url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAHCAYAAAAcc3wzAAAARElEQVR4nGOU1OL5z8DAwMCOzoGh4B8DITFRF6cYDAXUXPx/IMdyZJehSiJGBhyQxSgCjNiEGLBJAgMxiSMbAAARWxQdA+n8ygAAAABJRU5ErkJggg==") no-repeat right 11px center;
}
label.check {
  display: flex; align-items: baseline; gap: 7px; line-height: 1.35;
}
label.check input[type="checkbox"] {
  min-height: 0; min-width: auto; width: auto; accent-color: var(--green);
}
.preview-controls { display: flex; align-items: end; gap: 11px; justify-content: space-between; flex-wrap: wrap; }
.preview-controls > label:first-child { flex: 1 1 10rem; }
.preview-controls > .check { padding: 0 0 8px; white-space: nowrap; }
.region-settings .hint { margin-block: 3px 8px; }
.bounds label { overflow-wrap: anywhere; }
#editable > .fields:first-child { margin-top: 0; }
.footer > a { text-decoration: none; }
@media (max-width: 720px) {
  .top-inner { gap: 14px; }
  .local-label { display: none; }
  .language-list { margin-left: auto; }
}
@media (max-width: 365px) {
  .top nav { display: none; }
}
