﻿:root {
  --page: #f6f8fb;
  --panel: #ffffff;
  --panel-soft: #eef7f3;
  --ink: #202124;
  --muted: #65717f;
  --line: #dce3ea;
  --primary: #1677ff;
  --primary-strong: #0958d9;
  --green: #13a36b;
  --yellow: #f2b705;
  --red: #df4b5f;
  --cyan: #0ca6b8;
  --shadow: 0 18px 42px rgba(34, 42, 53, 0.1);
  --container: min(1240px, calc(100vw - 32px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(180deg, #ffffff 0%, var(--page) 72%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 0.78rem 0.85rem;
  outline: none;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(22, 119, 255, 0.14);
}

textarea {
  min-height: 132px;
  resize: vertical;
}

pre,
code {
  font-family: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
}

pre {
  white-space: pre-wrap;
  word-break: break-word;
}

.app-shell {
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.header-inner,
.section-inner,
.footer-inner {
  width: var(--container);
  margin: 0 auto;
}

.header-inner {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 0.85rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--green));
  font-weight: 900;
  letter-spacing: 0;
}

.brand strong,
.section-title h2,
.tool-title,
.output-title,
.metric strong {
  font-family: "Segoe UI", Inter, ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0;
}

.brand span {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.header-search {
  position: relative;
}

.header-search input {
  padding-left: 2.55rem;
  background: #f9fbfd;
}

.header-search::before {
  content: "";
  position: absolute;
  left: 0.88rem;
  top: 50%;
  width: 15px;
  height: 15px;
  border: 2px solid var(--muted);
  border-radius: 50%;
  transform: translateY(-50%);
}

.header-search::after {
  content: "";
  position: absolute;
  left: 1.82rem;
  top: 58%;
  width: 8px;
  height: 2px;
  background: var(--muted);
  transform: rotate(45deg);
}

.header-actions {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  justify-content: flex-end;
}

.button,
.secondary,
.ghost,
.icon-button,
.tool-chip,
.download-link {
  border-radius: 8px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-weight: 750;
  letter-spacing: 0;
}

.button {
  background: var(--primary);
  color: #fff;
  padding: 0.72rem 1rem;
  box-shadow: 0 10px 22px rgba(22, 119, 255, 0.22);
}

.button:hover {
  background: var(--primary-strong);
}

.secondary,
.download-link {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 0.7rem 0.95rem;
}

.ghost {
  background: transparent;
  color: var(--muted);
  padding: 0.7rem 0.8rem;
}

.icon-button {
  width: 42px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}

.site-main {
  padding-bottom: 4rem;
}

.workbench {
  background: linear-gradient(120deg, #ffffff 0%, #f3f9ff 54%, #eefaf5 100%);
  border-bottom: 1px solid var(--line);
}

.workbench-inner {
  width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 370px);
  gap: 1.4rem;
  align-items: center;
  padding: 1.35rem 0;
}

.workbench-copy {
  min-width: 0;
}

.kicker {
  display: inline-flex;
  color: #0b6b4d;
  background: #dff6eb;
  border: 1px solid #bce7d1;
  border-radius: 8px;
  padding: 0.38rem 0.6rem;
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0;
  margin-bottom: 0.8rem;
}

.workbench h1 {
  margin: 0;
  font-size: 3.6rem;
  line-height: 1.02;
  max-width: 12ch;
  letter-spacing: 0;
}

.workbench p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.7;
  max-width: 68ch;
  margin: 0.9rem 0 1.1rem;
}

.stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.metric {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.76);
  border-radius: 8px;
  padding: 0.7rem 0.85rem;
  min-width: 118px;
}

.metric strong {
  display: block;
  font-size: 1.1rem;
}

.metric span {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
}

.visual-wrap {
  min-width: 0;
}

.visual-wrap img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  background: #fff;
}

.quick-nav {
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.quick-nav-inner {
  width: var(--container);
  margin: 0 auto;
  display: flex;
  gap: 0.55rem;
  overflow-x: auto;
  padding: 0.78rem 0;
}

.quick-nav-inner a,
.tool-chip {
  white-space: nowrap;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--muted);
  padding: 0.58rem 0.72rem;
}

.quick-nav-inner a.active,
.tool-chip.active {
  background: #eaf3ff;
  border-color: #bdd8ff;
  color: #0958d9;
}

.section {
  padding: 1.45rem 0;
}

.section:nth-of-type(even) {
  background: rgba(255, 255, 255, 0.58);
}

.section-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.section-title h2 {
  margin: 0;
  font-size: 2rem;
}

.section-title p {
  color: var(--muted);
  margin: 0.25rem 0 0;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.75rem;
}

.tool-card {
  min-height: 132px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.9rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 10px 24px rgba(34, 42, 53, 0.06);
  text-align: left;
  color: var(--ink);
}

.tool-card:hover,
.tool-card.active {
  border-color: var(--primary);
  box-shadow: 0 18px 34px rgba(22, 119, 255, 0.14);
  transform: translateY(-1px);
}

.tool-card strong {
  font-size: 0.98rem;
  line-height: 1.35;
}

.tool-card span {
  color: var(--muted);
  font-size: 0.8rem;
}

.tool-card b {
  align-self: flex-start;
  color: #0b6b4d;
  background: #e6f8ef;
  border-radius: 8px;
  padding: 0.24rem 0.45rem;
  font-size: 0.72rem;
}

.runner-band {
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.runner {
  width: var(--container);
  margin: 0 auto;
  padding: 1rem 0 1.25rem;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

.breadcrumbs a,
.breadcrumbs button {
  color: var(--primary-strong);
  background: transparent;
  padding: 0;
  min-height: auto;
  font-weight: 750;
}

.tool-page-title {
  margin: 0 0 0.95rem;
  max-width: 840px;
}

.tool-page-title h1 {
  margin: 0;
  font-size: 2.2rem;
  line-height: 1.12;
  letter-spacing: 0;
}

.tool-page-title p {
  color: var(--muted);
  line-height: 1.65;
  margin: 0.45rem 0 0;
}

.runner-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.78fr);
  gap: 1rem;
  align-items: start;
}

.tool-form,
.tool-output {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(34, 42, 53, 0.08);
  padding: 1rem;
}

.tool-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.85rem;
}

.tool-title {
  margin: 0;
  font-size: 1.35rem;
}

.tool-subtitle {
  color: var(--muted);
  margin: 0.25rem 0 0;
  line-height: 1.55;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.form-grid .wide,
.field.wide {
  grid-column: 1 / -1;
}

.field label {
  display: block;
  font-weight: 750;
  margin-bottom: 0.35rem;
  color: #30343a;
  font-size: 0.86rem;
}

.field small {
  display: block;
  color: var(--muted);
  margin-top: 0.28rem;
  line-height: 1.45;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.9rem;
}

.output-title {
  margin: 0 0 0.7rem;
  font-size: 1rem;
}

.output-box {
  border: 1px solid var(--line);
  background: #f8fafc;
  border-radius: 8px;
  padding: 0.85rem;
  min-height: 188px;
  overflow: auto;
}

.ad-slot {
  width: var(--container);
  margin: 1rem auto;
  border: 1px dashed #b8c5d4;
  background: #fbfdff;
  border-radius: 8px;
  min-height: 92px;
  display: grid;
  place-items: center;
  gap: 0.15rem;
  text-align: center;
  color: var(--muted);
  padding: 0.8rem;
}

.ad-slot span {
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
}

.ad-slot strong {
  color: var(--ink);
}

.ad-slot small {
  line-height: 1.4;
}

.tool-output .ad-slot,
.content-aside .ad-slot {
  width: 100%;
  margin: 1rem 0 0;
}

.result-list {
  display: grid;
  gap: 0.55rem;
}

.result-item {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  border-bottom: 1px solid var(--line);
  padding: 0.45rem 0;
}

.result-item:last-child {
  border-bottom: 0;
}

.result-item span:first-child {
  color: var(--muted);
}

.result-item span:last-child {
  font-weight: 800;
  text-align: right;
}

.copy-target,
.code-output {
  margin: 0;
  line-height: 1.55;
}

.preview-image {
  max-height: 420px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  margin-top: 0.75rem;
}

.color-swatch-row,
.download-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.7rem;
}

.color-swatch {
  width: 68px;
  height: 68px;
  border-radius: 8px;
  border: 1px solid var(--line);
  display: grid;
  place-items: end center;
  padding-bottom: 0.22rem;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.55);
  font-size: 0.68rem;
  font-weight: 800;
}

.empty {
  color: var(--muted);
  line-height: 1.65;
}

.content-section {
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 1.6rem 0;
}

.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 1.4rem;
  align-items: start;
}

.seo-article {
  max-width: 880px;
}

.seo-article h2 {
  margin: 1.3rem 0 0.55rem;
  font-size: 1.45rem;
}

.seo-article h2:first-child {
  margin-top: 0;
}

.seo-article p,
.seo-article li,
.mini-panel p {
  color: var(--muted);
  line-height: 1.72;
}

.steps-list {
  padding-left: 1.2rem;
}

.related-grid,
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.75rem;
}

.related-link,
.blog-card,
.mini-panel,
.faq-list details {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
}

.related-link {
  min-height: 54px;
  color: var(--primary-strong);
  font-weight: 800;
  text-align: left;
  padding: 0.75rem;
}

.blog-card {
  display: grid;
  gap: 0.45rem;
  padding: 0.95rem;
  min-height: 132px;
}

.blog-card strong {
  line-height: 1.35;
}

.blog-card span {
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.9rem;
}

.faq-list {
  display: grid;
  gap: 0.65rem;
}

.faq-list details {
  padding: 0.85rem 0.95rem;
}

.faq-list summary {
  cursor: pointer;
  font-weight: 800;
}

.faq-list p {
  margin-bottom: 0;
}

.content-aside {
  position: sticky;
  top: 88px;
}

.mini-panel {
  margin-top: 1rem;
  padding: 0.95rem;
}

.mini-panel strong,
.mini-panel span {
  display: block;
}

.mini-panel span {
  margin-top: 0.25rem;
  color: var(--primary-strong);
  font-weight: 800;
}

.legal-shell {
  width: var(--container);
  margin: 0 auto;
  padding: 2rem 0 4rem;
}

.legal-article {
  max-width: 900px;
}

.legal-article h1 {
  margin: 0 0 0.75rem;
  font-size: 2.4rem;
  line-height: 1.1;
}

.legal-article h2 {
  margin: 1.4rem 0 0.55rem;
  font-size: 1.35rem;
}

.legal-article p,
.legal-article li {
  color: var(--muted);
  line-height: 1.75;
}

.legal-nav {
  width: var(--container);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  padding: 1rem 0;
}

.legal-nav a {
  color: var(--primary-strong);
  font-weight: 800;
}

.toast-wrap {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 100;
  display: grid;
  gap: 0.5rem;
}

.toast {
  background: #202124;
  color: #fff;
  border-radius: 8px;
  padding: 0.75rem 0.9rem;
  box-shadow: var(--shadow);
}

.footer {
  border-top: 1px solid var(--line);
  background: #fff;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem 0;
  color: var(--muted);
}

.footer strong {
  color: var(--ink);
}

.footer-inner div {
  display: grid;
  gap: 0.25rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.footer-links a {
  color: var(--primary-strong);
  font-weight: 750;
}

.hidden {
  display: none !important;
}

@media (max-width: 900px) {
  .header-inner,
  .workbench-inner,
  .runner-panel,
  .content-layout {
    grid-template-columns: 1fr;
  }

  .header-actions {
    justify-content: start;
  }

  .workbench h1 {
    max-width: 100%;
    font-size: 2.7rem;
  }

  .visual-wrap {
    max-width: 520px;
  }

  .content-aside {
    position: static;
  }
}

@media (max-width: 620px) {
  .header-inner,
  .section-inner,
  .footer-inner,
  .quick-nav-inner,
  .runner,
  .workbench-inner {
    width: min(100% - 22px, 1240px);
  }

  .form-grid,
  .tool-grid {
    grid-template-columns: 1fr;
  }

  .workbench h1 {
    font-size: 2rem;
  }

  .section-title h2,
  .tool-page-title h1,
  .legal-article h1 {
    font-size: 1.55rem;
  }

  .tool-heading,
  .section-title,
  .result-item {
    align-items: start;
    flex-direction: column;
  }

  .result-item span:last-child {
    text-align: left;
  }
}
