:root {
  color-scheme: light;
  --page-bg: #f7faff;
  --page-bg-soft: #eef6ff;
  --card-bg: #ffffff;
  --primary: #4f8cff;
  --primary-dark: #2f6fe4;
  --primary-soft: #eaf3ff;
  --success: #5cc9a7;
  --warning: #ffb35c;
  --danger: #ff6b6b;
  --danger-soft: #fff0f0;
  --title: #1f2937;
  --text: #4b5563;
  --border: #dce8fa;
  --border-soft: #eaf0fa;
  --blue: #2563eb;
  --blue-2: #38bdf8;
  --green: #10b981;
  --orange: #f59e0b;
  --purple: #7c3aed;
  --coral: #f97316;
  --ink: #101828;
  --muted: #667085;
  --subtle: #98a2b3;
  --line: #d8e4f8;
  --card: rgba(255, 255, 255, 0.86);
  --canvas: #eef6ff;
  --shadow: 0 22px 70px rgba(47, 86, 150, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes soft-float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-8px);
  }
}

@keyframes glow-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.18);
  }

  50% {
    box-shadow: 0 0 0 12px rgba(37, 99, 235, 0);
  }
}

@keyframes progress-sheen {
  from {
    transform: translateX(-120%);
  }

  to {
    transform: translateX(120%);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(37, 99, 235, 0.12) 0 18%, transparent 18% 100%),
    linear-gradient(180deg, #f2f8ff 0%, #fbfdff 52%, #ffffff 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.06) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, #000, transparent 68%);
}

.profile-body {
  background: linear-gradient(180deg, #f2f8ff 0%, #fbfdff 56%, #ffffff 100%);
}

.profile-body::before {
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
}

.images-to-pdf-page {
  background:
    linear-gradient(180deg, rgba(238, 246, 255, 0.94), rgba(247, 250, 255, 0.86) 38%, #ffffff 100%);
}

button,
input,
select {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(248, 252, 255, 0.9);
  border-bottom: 1px solid rgba(216, 228, 248, 0.82);
  backdrop-filter: blur(16px);
}

.site-nav,
.home-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.site-nav {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.site-nav .brand-name {
  font-size: 22px;
}

.site-nav .brand-subtitle {
  display: none;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  color: #475467;
  font-size: 14px;
  font-weight: 800;
}

.desktop-nav a {
  transition: color 0.16s ease;
}

.desktop-nav a:hover {
  color: var(--blue);
}

.history-summary {
  margin-bottom: 18px;
}

.history-list {
  display: grid;
  gap: 14px;
}

.history-item {
  align-items: center;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(186, 208, 243, 0.78);
  border-radius: 18px;
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(0, 1fr) auto;
  padding: 16px 18px;
}

.history-main {
  align-items: center;
  display: flex;
  gap: 14px;
  min-width: 0;
}

.history-type-icon {
  align-items: center;
  background: linear-gradient(145deg, #4f8cff, #2563eb);
  border-radius: 16px;
  box-shadow: 0 14px 26px rgba(37, 99, 235, 0.18);
  color: #fff;
  display: inline-flex;
  flex: 0 0 52px;
  font-size: 13px;
  font-weight: 950;
  height: 52px;
  justify-content: center;
  letter-spacing: 0;
  position: relative;
  width: 52px;
}

.history-type-icon::after {
  background: rgba(255, 255, 255, 0.42);
  border-radius: 0 0 0 8px;
  content: "";
  height: 14px;
  position: absolute;
  right: 0;
  top: 0;
  width: 14px;
}

.history-type-icon.is-image-pdf {
  background: linear-gradient(145deg, #38bdf8, #2563eb);
}

.history-type-icon.is-pdf-split {
  background: linear-gradient(145deg, #5cc9a7, #2563eb);
}

.history-main h3 {
  color: var(--ink);
  font-size: 18px;
  margin: 0 0 4px;
}

.history-main p,
.history-main small,
.history-meta span {
  color: var(--muted);
}

.history-main p,
.history-main small {
  display: block;
  margin: 0;
}

.history-meta {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, max-content) 72px;
}

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

.empty-history {
  border: 1px dashed rgba(37, 99, 235, 0.28);
  border-radius: 18px;
  color: var(--muted);
  padding: 28px;
  text-align: center;
}

.home-hero-section {
  padding: 44px 0 34px;
  background:
    linear-gradient(180deg, rgba(242, 248, 255, 0.94), rgba(251, 253, 255, 0.9));
}

.home-dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 22px;
  align-items: stretch;
}

.home-intro-card,
.quick-tools-panel {
  border: 1px solid #e5eaf3;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 12px 34px rgba(47, 86, 150, 0.06);
}

.home-intro-card {
  min-height: 260px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.quick-tools-panel {
  padding: 18px;
}

.hero-main-copy h2 {
  margin: 20px 0 0;
  font-size: clamp(42px, 6vw, 64px);
  line-height: 1.04;
  font-weight: 950;
  letter-spacing: 0;
  animation: fade-up 0.68s ease both;
}

.hero-main-copy p {
  max-width: 560px;
  margin: 22px 0 0;
  color: #475467;
  font-size: 17px;
  line-height: 1.9;
  animation: fade-up 0.68s ease 0.08s both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
  animation: fade-up 0.68s ease 0.16s both;
}

.home-intro-card h2 {
  margin: 18px 0 0;
  max-width: 620px;
  color: var(--ink);
  font-size: clamp(36px, 5vw, 54px);
  line-height: 1.08;
  font-weight: 950;
}

.home-intro-card p {
  max-width: 680px;
  margin: 16px 0 0;
  color: #475467;
  font-size: 16px;
  line-height: 1.75;
}

.quick-panel-head {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.quick-panel-head h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 950;
}

.quick-panel-head a {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #d8e4f8;
  border-radius: 999px;
  background: #f7fbff;
  color: var(--blue);
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  font-weight: 900;
}

.quick-tool-list {
  display: grid;
  gap: 8px;
}

.quick-tool-item {
  min-height: 64px;
  padding: 12px;
  border: 1px solid #edf2fb;
  border-radius: 16px;
  background: #f8fbff;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  transition: border-color 0.16s ease, background 0.16s ease;
}

.quick-tool-item:hover {
  border-color: #b8d4ff;
  background: #ffffff;
}

.quick-tool-item > span {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--blue);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 950;
}

.quick-tool-item:nth-child(2) > span {
  background: var(--green);
}

.quick-tool-item:nth-child(3) > span {
  background: var(--orange);
}

.quick-tool-item:nth-child(4) > span {
  background: #64748b;
}

.quick-tool-item strong,
.quick-tool-item small {
  display: block;
}

.quick-tool-item strong {
  color: var(--ink);
  font-weight: 950;
}

.quick-tool-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.module-preview {
  padding: 16px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow:
    16px 18px 0 rgba(99, 102, 241, 0.12),
    0 30px 70px rgba(47, 86, 150, 0.18);
  animation: fade-up 0.72s ease 0.12s both, soft-float 5.5s ease-in-out 1s infinite;
}

.preview-window-bar {
  display: flex;
  gap: 8px;
  height: 28px;
  align-items: center;
  padding-left: 6px;
}

.preview-window-bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #c5cedb;
}

.preview-upload {
  min-height: 164px;
  border: 2px solid #93d5e8;
  border-radius: 20px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  text-align: center;
  background: #fff;
}

.preview-plus {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--blue), var(--green));
  color: #fff;
  font-size: 36px;
  line-height: 1;
  animation: glow-pulse 2.6s ease-in-out infinite;
}

.preview-upload strong {
  font-size: 18px;
}

.preview-upload span {
  color: var(--subtle);
  font-size: 14px;
}

.preview-list {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.preview-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 12px;
  border-radius: 16px;
  background: #f6faff;
  transition: transform 0.18s ease, background 0.18s ease;
}

.preview-row:hover {
  transform: translateX(4px);
  background: #eef6ff;
}

.preview-dot {
  width: 34px;
  height: 34px;
  border-radius: 13px;
}

.preview-dot.blue { background: #dbeafe; }
.preview-dot.green { background: #dcfce7; }
.preview-dot.orange { background: #ffedd5; }

.preview-row strong,
.preview-row small {
  display: block;
}

.preview-row strong {
  font-weight: 950;
}

.preview-row small {
  margin-top: 3px;
  color: var(--subtle);
}

.feature-section {
  padding: 42px 0 48px;
}

.section-heading {
  max-width: 640px;
  margin: 0 auto 42px;
  text-align: center;
}

.section-heading span {
  color: var(--blue);
  font-weight: 950;
  font-size: 14px;
}

.section-heading h2 {
  margin: 14px 0 0;
  font-size: clamp(30px, 4vw, 42px);
  line-height: 1.12;
  font-weight: 950;
}

.section-heading p {
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.compact-heading {
  max-width: none;
  margin: 0 0 24px;
  text-align: left;
}

.compact-heading h2 {
  margin-top: 8px;
  font-size: clamp(26px, 3vw, 34px);
}

.compact-heading p {
  max-width: 720px;
  margin-top: 10px;
}

.feature-block + .feature-block {
  margin-top: 28px;
}

.feature-block-head {
  margin-bottom: 12px;
}

.feature-block-head h3 {
  margin: 0;
  font-size: 24px;
  font-weight: 950;
}

.feature-block-head p {
  margin: 9px 0 0;
  color: var(--muted);
}

.feature-grid {
  display: grid;
  gap: 14px;
}

.image-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pdf-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.feature-card {
  min-height: 190px;
  padding: 20px;
  border: 1px solid #e1eafa;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(47, 86, 150, 0.07);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  border-color: #b8d4ff;
  box-shadow: 0 16px 32px rgba(47, 86, 150, 0.1);
}

.feature-card.wide {
  min-height: 168px;
}

.home-tool-card {
  border-radius: 18px;
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 950;
}

.feature-icon.blue { background: var(--blue); }
.feature-icon.green { background: var(--green); }
.feature-icon.purple { background: var(--purple); }
.feature-icon.orange { background: var(--orange); }
.feature-icon.coral { background: #f43f5e; }
.feature-icon.cyan { background: #06b6d4; }

.feature-card h4 {
  margin: 16px 0 0;
  font-size: 20px;
  font-weight: 950;
}

.feature-card p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.65;
  flex: 1;
}

.feature-card strong {
  margin-top: 16px;
  color: var(--blue);
  font-size: 14px;
}

.advantage-section {
  padding: 42px 0 52px;
  background: #ffffff;
}

.advantage-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.advantage-card {
  min-height: 180px;
  padding: 24px;
  border: 1px solid #e1eafa;
  border-radius: 20px;
  background: #f8fbff;
  transition: transform 0.18s ease, background 0.18s ease;
}

.advantage-card:hover {
  transform: translateY(-5px);
  background: #fff;
}

.advantage-card span {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff;
  box-shadow: 0 12px 24px rgba(47, 86, 150, 0.08);
}

.advantage-card h3 {
  margin: 22px 0 0;
  font-size: 19px;
  font-weight: 950;
}

.advantage-card p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.home-rules-section {
  border-top: 1px solid #e5eaf3;
}

.usage-rule-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.usage-rule-card {
  min-height: 142px;
  padding: 20px;
  border: 1px solid #e5eaf3;
  border-radius: 18px;
  background: #f8fbff;
}

.usage-rule-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 950;
}

.usage-rule-card p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.tip-section {
  padding: 42px 0;
}

.tip-card {
  min-height: 106px;
  padding: 22px 24px;
  border: 1px solid #e5eaf3;
  border-radius: 20px;
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 12px 34px rgba(47, 86, 150, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: relative;
  overflow: hidden;
}

.tip-card::after {
  display: none;
}

.tip-card h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 950;
}

.tip-card p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.tip-action {
  min-width: 96px;
  min-height: 44px;
  border-radius: 12px;
  background: #f2f7ff;
  color: var(--blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 950;
  flex: 0 0 auto;
}

.site-footer {
  padding: 30px 0;
  background: #f7fbff;
  border-top: 1px solid #e1eafa;
  color: var(--muted);
  font-size: 14px;
}

.footer-inner,
.footer-inner nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.footer-inner {
  justify-content: space-between;
}

.shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 26px 0 54px;
}

.tool-shell {
  width: min(1180px, calc(100% - 40px));
  padding-top: 34px;
}

.topbar,
.brand-row {
  display: flex;
  align-items: center;
}

.topbar {
  min-height: 72px;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
  padding: 12px 14px 12px 16px;
  border: 1px solid rgba(216, 228, 248, 0.86);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: 0 16px 45px rgba(58, 91, 153, 0.08);
}

.brand-row {
  gap: 13px;
}

.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.25), transparent 42%),
    linear-gradient(145deg, var(--blue-2) 0%, var(--blue) 62%, #4f46e5 100%);
  box-shadow: 0 14px 26px rgba(37, 99, 235, 0.24);
  position: relative;
  flex: 0 0 auto;
}

.brand-logo::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 10px;
  width: 23px;
  height: 29px;
  border-radius: 9px;
  background: #fff;
}

.brand-logo::after {
  content: "";
  position: absolute;
  left: 19px;
  top: 20px;
  width: 12px;
  height: 4px;
  border-radius: 99px;
  background: var(--blue);
  box-shadow: 0 8px 0 -1px var(--blue-2);
}

.brand-name {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1;
  font-weight: 900;
}

.brand-subtitle {
  margin-top: 7px;
  color: var(--muted);
  font-size: 14px;
}

.home-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-pill {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: #315177;
  font-weight: 800;
  font-size: 14px;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 26px;
  align-items: stretch;
}

.hero-copy-panel,
.hero-command-panel {
  border: 1px solid rgba(216, 228, 248, 0.9);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero-copy-panel {
  min-height: 300px;
  padding: clamp(28px, 5vw, 54px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

.hero-copy-panel::after {
  content: "";
  position: absolute;
  right: -90px;
  bottom: -100px;
  width: 260px;
  height: 260px;
  border: 34px solid rgba(56, 189, 248, 0.15);
  border-radius: 50%;
}

.eyebrow {
  width: fit-content;
  min-height: 32px;
  padding: 7px 12px;
  border: 1px solid #b8ddff;
  border-radius: 999px;
  color: #175cd3;
  background: #eff8ff;
  font-size: 13px;
  font-weight: 900;
}

.home-hero h2 {
  margin: 18px 0 0;
  max-width: 760px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 0.98;
  font-weight: 950;
}

.tool-hero h1 {
  margin: 0;
  max-width: 760px;
  color: var(--ink);
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.1;
  font-weight: 950;
}

.home-hero p {
  max-width: 680px;
  margin: 18px 0 0;
  color: #475467;
  line-height: 1.85;
  font-size: 16px;
}

.tool-hero p {
  max-width: 680px;
  margin: 6px 0 0;
  color: #475467;
  line-height: 1.55;
  font-size: 15px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.hero-meta span {
  padding: 9px 12px;
  border: 1px solid #d5e7ff;
  border-radius: 999px;
  background: #fff;
  color: #315177;
  font-size: 13px;
  font-weight: 800;
}

.hero-command-panel {
  padding: 18px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 300px;
}

.command-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #315177;
  font-weight: 900;
}

.command-dots {
  display: flex;
  gap: 7px;
}

.command-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--blue);
}

.command-dots span:nth-child(2) {
  background: var(--green);
}

.command-dots span:nth-child(3) {
  background: var(--orange);
}

.workflow-stack {
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 24px 0;
}

.workflow-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid #e1ebfb;
  border-radius: 18px;
  background: linear-gradient(135deg, #ffffff, #f5fbff);
}

.workflow-icon {
  width: 38px;
  height: 38px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--blue);
  font-weight: 950;
}

.workflow-item:nth-child(2) .workflow-icon {
  background: var(--green);
}

.workflow-item:nth-child(3) .workflow-icon {
  background: var(--purple);
}

.workflow-title {
  font-weight: 950;
}

.workflow-sub {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.command-foot {
  min-height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #101828;
  color: #fff;
  font-weight: 900;
}

.section-title {
  margin: 42px 0 18px;
  font-size: 24px;
  font-weight: 950;
}

.tool-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.tool-group {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 18px 52px rgba(47, 86, 150, 0.08);
}

.tool-group.image {
  border-top: 5px solid var(--green);
}

.tool-group.pdf {
  border-top: 5px solid var(--orange);
}

.group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  margin-bottom: 14px;
  padding: 0 4px;
  font-size: 18px;
  font-weight: 950;
}

.group-head::after {
  content: "3 tools";
  color: var(--subtle);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.group-mark {
  display: none;
}

.tool-grid {
  display: grid;
  gap: 12px;
}

.tool-card {
  min-height: 112px;
  padding: 16px;
  border: 1px solid #dce7f8;
  border-radius: 18px;
  background: #fff;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 16px;
  position: relative;
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.tool-card::after {
  content: "→";
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f2f7ff;
  color: var(--blue);
  font-weight: 950;
}

.tool-card:hover {
  transform: translateY(-3px);
  border-color: #a8ccff;
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.12);
}

.theme-blue { background: linear-gradient(135deg, #ffffff, #f3f8ff); }
.theme-green { background: linear-gradient(135deg, #ffffff, #f0fdf7); }
.theme-coral { background: linear-gradient(135deg, #ffffff, #fff7ed); }
.theme-orange { background: linear-gradient(135deg, #ffffff, #fff8eb); }
.theme-purple { background: linear-gradient(135deg, #ffffff, #f7f3ff); }
.theme-light-blue { background: linear-gradient(135deg, #ffffff, #f2fbff); }

.tool-card img {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  object-fit: cover;
  box-shadow: 0 12px 24px rgba(69, 106, 171, 0.14);
}

.tool-title {
  font-size: 18px;
  font-weight: 950;
}

.tool-desc {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.privacy-note {
  margin-top: 22px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--blue);
  font-weight: 900;
}

.tool-hero {
  min-height: 104px;
  padding: 18px 22px;
  border: 1px solid #e5eaf3;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 12px 34px rgba(47, 86, 150, 0.06);
  padding-right: 86px;
  position: relative;
  overflow: hidden;
  animation: fade-up 0.56s ease both;
}

.images-pdf-hero {
  min-height: 104px;
  background: #ffffff;
}

.images-pdf-hero::after {
  display: grid;
}

.tool-hero-copy {
  position: relative;
  z-index: 1;
}

.pdf-hero-visual {
  display: none;
}

.hero-image-stack span,
.hero-pdf-file {
  position: absolute;
  display: grid;
  place-items: center;
  border: 1px solid rgba(156, 190, 242, 0.8);
  box-shadow: 0 18px 38px rgba(79, 140, 255, 0.12);
}

.hero-image-stack span {
  width: 90px;
  height: 118px;
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(234, 243, 255, 0.9)),
    linear-gradient(135deg, rgba(79, 140, 255, 0.2), rgba(92, 201, 167, 0.2));
}

.hero-image-stack span::before {
  content: "";
  width: 48px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(135deg, #99c1ff, #5cc9a7);
}

.hero-image-stack span:nth-child(1) {
  left: 8px;
  top: 22px;
  transform: rotate(-8deg);
}

.hero-image-stack span:nth-child(2) {
  left: 34px;
  top: 8px;
  transform: rotate(4deg);
}

.hero-image-stack span:nth-child(3) {
  left: 58px;
  top: 30px;
  transform: rotate(12deg);
}

.hero-arrow {
  position: absolute;
  left: 138px;
  top: 70px;
  color: var(--primary-dark);
  font-size: 32px;
  font-weight: 950;
}

.hero-pdf-file {
  right: 4px;
  top: 28px;
  width: 84px;
  height: 112px;
  border-radius: 18px;
  background: linear-gradient(160deg, #ffffff, #eaf3ff);
  color: var(--primary-dark);
  font-weight: 950;
}

.hero-pdf-file::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -1px;
  border-top: 26px solid #cfe1ff;
  border-left: 26px solid transparent;
  border-radius: 0 18px 0 8px;
}

.tool-hero::after {
  content: "DOC";
  position: absolute;
  right: 22px;
  top: 50%;
  width: 48px;
  height: 48px;
  border: 1px solid #d9e6f8;
  border-radius: 16px;
  background: #f4f8ff;
  color: var(--blue);
  display: grid;
  font-size: 13px;
  font-weight: 950;
  place-items: center;
  transform: translateY(-50%);
}

.tool-kicker {
  display: none;
}

.tool-hero-tags {
  display: none;
}

.tool-hero-tags span {
  min-height: 34px;
  padding: 8px 12px;
  border: 1px solid #d5e7ff;
  border-radius: 999px;
  background: #fff;
  color: #315177;
  font-size: 13px;
  font-weight: 900;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
  margin-top: 20px;
  animation: fade-up 0.58s ease 0.08s both;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
  padding: 20px;
  box-shadow: 0 18px 50px rgba(47, 86, 150, 0.08);
  position: relative;
}

.tool-hero + .panel {
  margin-top: 22px;
}

.workspace .panel:has(.file-list) {
  height: var(--side-panel-height, auto);
  display: flex;
  flex-direction: column;
}

.images-to-pdf-page .workspace .panel:has(.file-list) {
  height: auto;
}

.images-pdf-workspace {
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
}

.image-convert-workspace {
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
}

.image-merge-workspace {
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
}

.pdf-merge-workspace {
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
}

.pdf-split-workspace {
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
}

.images-pdf-side,
.image-convert-side,
.image-merge-side,
.pdf-merge-side,
.pdf-split-side {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 92px;
}

.images-pdf-side .side-card,
.image-convert-side .side-card,
.image-merge-side .side-card,
.pdf-merge-side .side-card,
.pdf-split-side .side-card {
  box-shadow: 0 18px 50px rgba(47, 86, 150, 0.08);
}

.images-pdf-side .side-card:first-child,
.image-convert-side .side-card:first-child,
.image-merge-side .side-card:first-child,
.pdf-merge-side .side-card:first-child,
.pdf-split-side .side-card:first-child {
  border-top: 3px solid var(--primary);
}

.images-list-panel .panel-title-row {
  margin-bottom: 16px;
}

.upload-trigger {
  min-width: 86px;
}

.format-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f3f8ff;
  color: #175cd3;
  font-size: 12px;
  font-weight: 950;
}

.panel-title-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.selection-count {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.image-merge-list-panel .panel-title-row {
  align-items: center;
  margin-bottom: 14px;
}

.image-merge-list-panel .upload-trigger {
  min-height: 34px;
  min-width: 78px;
  padding: 0 12px;
}

.pdf-merge-list-panel .panel-title-row {
  align-items: center;
  margin-bottom: 14px;
}

.pdf-split-file-panel .panel-title-row {
  align-items: center;
  margin-bottom: 14px;
}

.merge-mode-option {
  position: relative;
}

.merge-mode-option.active::after {
  content: "✓";
  position: absolute;
  right: 14px;
  top: 14px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-size: 14px;
  font-weight: 950;
}

.merge-mode-option.active .option-name {
  color: var(--blue);
}

.images-to-pdf-page .dropzone:not(.hidden) {
  min-height: 340px;
}

.images-to-pdf-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 340px;
}

.image-merge-page .dropzone:not(.hidden) {
  min-height: 340px;
}

.image-merge-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 340px;
}

.pdf-merge-page .dropzone:not(.hidden) {
  min-height: 340px;
}

.pdf-merge-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 340px;
}

.pdf-split-page .dropzone:not(.hidden) {
  min-height: 320px;
}

.pdf-split-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 320px;
}

.pdf-image-item {
  cursor: grab;
}

.merge-file-item {
  cursor: grab;
  grid-template-columns: 16px 72px minmax(0, 1fr) auto;
  min-height: 120px;
  max-height: 150px;
  padding: 14px 16px;
  border-color: #e5edf9;
}

.pdf-merge-item {
  cursor: grab;
  grid-template-columns: 28px 64px minmax(0, 1fr) auto;
  min-height: 112px;
  max-height: 140px;
  border-color: #e5edf9;
}

.pdf-split-item {
  grid-template-columns: 64px minmax(0, 1fr) auto;
  min-height: 112px;
  max-height: 140px;
  border-color: #e5edf9;
}

.pdf-order {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: #eef5ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 950;
}

.pdf-icon.small {
  width: 64px;
  height: 64px;
  margin: 0;
  border-radius: 16px;
  font-size: 14px;
}

.pdf-merge-item .file-info {
  min-width: 0;
}

.pdf-split-item .file-info {
  min-width: 0;
}

.pdf-merge-item .file-actions {
  flex-wrap: nowrap;
  gap: 6px;
}

.pdf-split-item .file-actions {
  flex-wrap: nowrap;
  gap: 6px;
}

.pdf-merge-item .icon-btn {
  min-width: 34px;
  width: 34px;
  min-height: 34px;
  padding: 0;
  border-radius: 12px;
  font-size: 18px;
  line-height: 1;
}

.pdf-split-item .icon-btn {
  min-width: 34px;
  width: 34px;
  min-height: 34px;
  padding: 0;
  border-radius: 12px;
  font-size: 18px;
  line-height: 1;
}

.range-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.range-actions .mini-btn {
  min-height: 34px;
  padding: 0 12px;
}

.drag-handle {
  color: var(--subtle);
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
}

.merge-file-item .thumb {
  width: 72px;
  height: 72px;
  border-radius: 16px;
}

.merge-file-item .file-info {
  min-width: 0;
}

.merge-file-item .file-name {
  display: block;
  max-width: 100%;
}

.merge-file-item .file-actions {
  flex-wrap: nowrap;
  gap: 6px;
}

.merge-file-item .icon-btn {
  min-width: 34px;
  width: 34px;
  min-height: 34px;
  padding: 0;
  border-radius: 12px;
  font-size: 18px;
  line-height: 1;
}

.pdf-image-item.dragging,
.merge-file-item.dragging,
.pdf-merge-item.dragging {
  opacity: 0.62;
}

.pdf-image-item.drag-over,
.merge-file-item.drag-over,
.pdf-merge-item.drag-over {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.24);
}

.image-merge-page .tool-message {
  margin: 10px 0 0;
  padding: 8px 11px;
  border-radius: 12px;
  font-size: 12px;
}

.pdf-merge-page .tool-message {
  margin: 10px 0 0;
  padding: 8px 11px;
  border-radius: 12px;
  font-size: 12px;
}

.pdf-split-page .tool-message {
  margin: 10px 0 0;
  padding: 8px 11px;
  border-radius: 12px;
  font-size: 12px;
}

.result-links {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.result-links .mini-btn {
  flex: 1;
  min-height: 36px;
}

.merge-preview-wrap {
  margin-top: 16px;
  border: 1px solid #dce7f8;
  border-radius: 18px;
  background: #f8fbff;
  padding: 12px;
}

.preview-title-row {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 950;
}

.merge-preview-wrap .preview-canvas {
  display: block;
  width: 100%;
  max-height: 360px;
  object-fit: contain;
}

.workspace > aside.panel {
  position: sticky;
  top: 92px;
  border-top: 3px solid var(--primary);
}

.panel + .panel {
  margin-top: 18px;
}

.panel-title {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 950;
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-title::before {
  content: "";
  width: 9px;
  height: 22px;
  border-radius: 99px;
  background: linear-gradient(180deg, var(--blue), var(--green));
}

.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.panel-title-row .panel-title {
  margin: 0;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.option-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.option-btn {
  min-height: 76px;
  padding: 14px;
  border: 1px solid #dce7f8;
  border-radius: 18px;
  background: #fff;
  text-align: left;
  box-shadow: inset 0 0 0 0 rgba(37, 99, 235, 0);
}

.option-btn.active {
  border-color: #86b7ff;
  background: linear-gradient(135deg, #edf6ff, #ffffff);
  color: #175cd3;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.24);
}

.option-btn:hover,
.file-item:hover {
  border-color: #b8d4ff;
}

.option-name {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-weight: 950;
}

.recommend-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #eaf3ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 950;
}

.option-desc {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.dropzone {
  display: grid;
  place-items: center;
  min-height: 340px;
  border: 2px dashed #9fc5ff;
  border-radius: 22px;
  background:
    linear-gradient(180deg, #ffffff, #f6fbff) padding-box,
    linear-gradient(135deg, rgba(37, 99, 235, 0.3), rgba(16, 185, 129, 0.28)) border-box;
  text-align: center;
  padding: 30px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.82), 0 16px 38px rgba(47, 86, 150, 0.06);
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.workspace .panel:has(.file-list) .dropzone {
  flex: 1;
  min-height: 0;
}

.dropzone.drag {
  border-color: var(--blue);
  background: #eff8ff;
}

.dropzone:hover {
  background:
    linear-gradient(#f2f8ff, #f8fffc) padding-box,
    linear-gradient(135deg, rgba(37, 99, 235, 0.45), rgba(16, 185, 129, 0.36)) border-box;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.9), 0 18px 42px rgba(37, 99, 235, 0.1);
}

.dropzone.is-compact {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 2;
  width: auto;
  min-height: 36px;
  flex: 0 0 auto !important;
  margin: 0;
  padding: 0 14px;
  border-style: solid;
  border-color: #d8e7ff;
  border-radius: 999px;
  place-items: stretch;
  text-align: left;
  background: #eef5ff;
  box-shadow: none;
}

.dropzone.is-compact > span {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}

.dropzone.is-compact .empty-icon {
  width: 22px;
  height: 22px;
  margin: 0;
  border-radius: 8px;
  box-shadow: none;
  font-size: 0;
}

.dropzone.is-compact .empty-icon::before {
  content: "+";
  color: #fff;
  font-size: 17px;
  font-weight: 950;
  line-height: 1;
}

.dropzone.is-compact .empty-main {
  color: var(--blue);
  font-size: 0;
  font-weight: 950;
}

.dropzone.is-compact .empty-main::after {
  content: "继续添加";
  font-size: 13px;
}

.dropzone.is-compact .empty-sub {
  display: none;
}

.image-compress-page .dropzone:not(.hidden) {
  min-height: 360px;
}

.image-compress-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 360px;
}

.image-convert-page .dropzone:not(.hidden) {
  min-height: 340px;
}

.image-convert-page .workspace .panel:has(.file-list) .dropzone:not(.hidden) {
  flex: 0 0 auto;
  min-height: 340px;
}

.empty-icon,
.pdf-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 14px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.22), transparent),
    linear-gradient(145deg, var(--blue-2), var(--blue));
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 950;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.22);
}

.empty-main {
  display: block;
  font-weight: 950;
  font-size: 18px;
}

.empty-sub {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.file-input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
  pointer-events: none;
}

.file-list {
  display: grid;
  gap: 12px;
  align-content: start;
  flex: 1;
  min-height: 0;
  max-height: 560px;
  overflow: auto;
  padding-right: 4px;
}

.file-item {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 100px;
  padding: 14px 16px;
  border: 1px solid #e0eafa;
  border-radius: 18px;
  background: #fff;
  transition: border-color 0.16s ease;
}

.thumb {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  object-fit: cover;
  background: #eef3fb;
}

.file-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 900;
}

.file-meta,
.file-state {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.file-state.success { color: #087f5b; }
.file-state.error { color: #d92d20; }
.file-state.processing { color: var(--blue); }

.compress-file-item {
  grid-template-columns: 64px minmax(0, 1fr) 120px;
  min-height: 100px;
}

.convert-file-item {
  grid-template-columns: 64px minmax(0, 1fr) 120px;
  min-height: 100px;
}

.compress-metrics,
.convert-metrics {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.compress-metrics strong {
  color: #087f5b;
  font-weight: 950;
}

.metric-arrow {
  color: var(--subtle);
}

.file-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.mini-btn {
  min-width: 48px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef5ff;
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.mini-btn.danger {
  color: #c24141;
  background: var(--danger-soft);
}

.tool-message {
  margin: 14px 0 0;
  padding: 11px 13px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background: #f8fbff;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
}

.tool-message[data-type="success"] {
  border-color: rgba(92, 201, 167, 0.34);
  background: rgba(92, 201, 167, 0.1);
  color: #087f5b;
}

.tool-message[data-type="warning"] {
  border-color: rgba(255, 179, 92, 0.38);
  background: rgba(255, 179, 92, 0.12);
  color: #9a5a00;
}

.tool-message[data-type="error"] {
  border-color: rgba(255, 107, 107, 0.36);
  background: var(--danger-soft);
  color: #c24141;
}

.auth-panel {
  max-width: 560px;
  margin: 80px auto;
  text-align: center;
}

.profile-page {
  width: min(1180px, calc(100% - 40px));
  padding-top: 24px;
}

.profile-titlebar {
  min-height: 104px;
  padding: 18px 22px;
  border: 1px solid #e5eaf3;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 12px 34px rgba(47, 86, 150, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.profile-titlebar h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.1;
  font-weight: 950;
}

.profile-titlebar p {
  max-width: 680px;
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.profile-title-icon {
  width: 48px;
  height: 48px;
  border: 1px solid #d9e6f8;
  border-radius: 16px;
  background: #f4f8ff;
  color: var(--blue);
  display: grid;
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 950;
  place-items: center;
}

.profile-workspace {
  align-items: start;
  grid-template-columns: minmax(0, 65fr) minmax(320px, 35fr);
  gap: 22px;
}

.profile-main-column,
.profile-side-column {
  display: grid;
  gap: 18px;
}

.profile-side-column {
  position: sticky;
  top: 92px;
}

.profile-page .panel {
  border-color: #e5eaf3;
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 12px 34px rgba(47, 86, 150, 0.06);
}

.profile-page .panel-title {
  margin-bottom: 12px;
}

.profile-page .panel-title::before {
  background: var(--blue);
}

.profile-card {
  min-height: 0;
}

.profile-head {
  display: flex;
  gap: 14px;
  align-items: center;
}

.profile-avatar {
  width: 52px;
  height: 52px;
  border: 1px solid #d9e6f8;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: #f4f8ff;
  box-shadow: none;
  position: relative;
}

.profile-avatar::before,
.profile-avatar::after {
  content: "";
  position: absolute;
  border-radius: 99px;
  background: var(--blue);
}

.profile-avatar::before {
  width: 18px;
  height: 18px;
  top: 12px;
}

.profile-avatar::after {
  width: 26px;
  height: 11px;
  bottom: 11px;
}

.device-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.device-status-item {
  min-width: 0;
  min-height: 72px;
  padding: 14px;
  border: 1px solid #edf2fb;
  border-radius: 16px;
  background: #f8fbff;
  display: grid;
  align-content: center;
  gap: 6px;
}

.device-status-item span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.device-status-item strong {
  min-width: 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 950;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-link-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
}

.profile-link-card .primary-button {
  min-height: 44px;
  border-radius: 14px;
  white-space: nowrap;
}

.profile-note-card .tips {
  margin: 0;
  line-height: 1.8;
}

.quota-progress-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.quota-progress-head strong {
  color: var(--ink);
}

.quota-progress {
  height: 10px;
  margin: 12px 0 18px;
  border-radius: 999px;
  background: #edf4ff;
  overflow: hidden;
}

.quota-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--blue-2));
  transition: width 0.2s ease;
}

.quota-big-number {
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid #edf2fb;
  border-radius: 16px;
  background: #f8fbff;
}

.quota-big-number span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.quota-big-number strong {
  display: block;
  margin-top: 4px;
  color: var(--blue);
  font-size: 34px;
  line-height: 1.15;
  font-weight: 950;
}

.stats-card .summary-row:last-child,
.quota-card .summary-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.email-login-form {
  margin-top: 22px;
}

.inline-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.inline-code-row .secondary-button {
  min-height: 44px;
  white-space: nowrap;
}

.primary-button,
.secondary-button {
  min-height: 50px;
  border-radius: 16px;
  padding: 0 20px;
  font-weight: 950;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.primary-button {
  background: linear-gradient(135deg, var(--blue) 0%, #1d4ed8 100%);
  color: #fff;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
}

.primary-button.is-download {
  background: linear-gradient(135deg, #5cc9a7, #169b79);
  box-shadow: 0 14px 28px rgba(22, 155, 121, 0.2);
}

.secondary-button {
  border: 1px solid #d8e4f8;
  background: #fff;
  color: var(--blue);
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.primary-button:hover,
.secondary-button:hover,
.tip-action:hover,
.back-link:hover,
.nav-pill:hover {
  transform: translateY(-2px);
}

.primary-button:hover {
  filter: saturate(1.08);
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.28);
}

.secondary-button:hover {
  border-color: #a8ccff;
  background: #f7fbff;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.summary-list {
  display: grid;
  gap: 10px;
}

.summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  min-height: 42px;
  padding: 0 0 10px;
  border-bottom: 1px solid #edf2fb;
}

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

.settings-grid {
  display: grid;
  gap: 14px;
}

.setting-summary-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #e1eafa;
  border-radius: 18px;
  background: linear-gradient(135deg, #ffffff, #f7fbff);
}

.setting-summary-card div {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.setting-summary-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.setting-summary-card strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 950;
}

.field {
  display: grid;
  gap: 8px;
}

.field label {
  color: var(--muted);
  font-weight: 900;
  font-size: 14px;
}

.field input,
.field select {
  min-height: 48px;
  width: 100%;
  border: 1px solid #dce7f8;
  border-radius: 16px;
  padding: 0 12px;
  background: #fff;
  color: var(--ink);
}

.select-wrap {
  position: relative;
  display: block;
}

.select-wrap::after {
  content: "";
  position: absolute;
  right: 16px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid #2563eb;
  border-bottom: 2px solid #2563eb;
  transform: translateY(-65%) rotate(45deg);
  pointer-events: none;
  transition: transform 0.16s ease, border-color 0.16s ease;
}

.select-wrap select {
  appearance: none;
  min-height: 54px;
  padding: 0 46px 0 16px;
  border: 1px solid #d7e5fb;
  border-radius: 18px;
  background:
    linear-gradient(135deg, #ffffff 0%, #f6fbff 100%);
  color: #101828;
  font-weight: 850;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 10px 22px rgba(47, 86, 150, 0.05);
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.select-wrap:hover select {
  border-color: #a9cbff;
  background:
    linear-gradient(135deg, #ffffff 0%, #eef7ff 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 12px 26px rgba(37, 99, 235, 0.09);
}

.select-wrap:focus-within select {
  border-color: #2563eb;
  box-shadow:
    0 0 0 4px rgba(37, 99, 235, 0.12),
    0 14px 28px rgba(37, 99, 235, 0.1);
}

.select-wrap:focus-within::after {
  border-color: #1d4ed8;
  transform: translateY(-35%) rotate(225deg);
}

.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.36);
  backdrop-filter: blur(10px);
  animation: fade-up 0.18s ease both;
}

.settings-modal {
  width: min(620px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid #d8e4f8;
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.22);
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 24px 24px 18px;
  border-bottom: 1px solid #edf2fb;
}

.modal-head h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 950;
}

.modal-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.modal-close {
  width: 38px;
  height: 38px;
  border-radius: 14px;
  background: #f2f6ff;
  color: #315177;
  font-size: 24px;
  line-height: 1;
}

.modal-body {
  display: grid;
  gap: 20px;
  padding: 22px 24px;
}

.setting-block {
  display: grid;
  gap: 10px;
}

.setting-label {
  color: var(--ink);
  font-size: 15px;
  font-weight: 950;
}

.setting-options {
  display: grid;
  gap: 10px;
}

.setting-options.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.setting-options.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.setting-options.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.setting-option {
  min-height: 48px;
  padding: 0 12px;
  border: 1px solid #dce7f8;
  border-radius: 16px;
  background: linear-gradient(135deg, #fff, #f8fbff);
  color: #315177;
  font-weight: 950;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.setting-option:hover {
  transform: translateY(-2px);
  border-color: #a8ccff;
}

.setting-option.active {
  border-color: #2563eb;
  background: linear-gradient(135deg, #eaf3ff, #ffffff);
  color: #175cd3;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.18);
}

.setting-option:disabled {
  background: #f2f4f7;
  color: #98a2b3;
  border-color: #e4e7ec;
  transform: none;
}

.setting-hint {
  margin: 0;
  padding: 10px 12px;
  border-radius: 14px;
  background: #f7fbff;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.modal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 18px 24px 24px;
  border-top: 1px solid #edf2fb;
}

.notice,
.tips {
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
  padding: 12px;
  border-radius: 16px;
  background: #f7fbff;
}

.preview-canvas {
  max-width: 100%;
  max-height: 420px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid #e0eafa;
}

.hidden {
  display: none !important;
}

@media (max-width: 920px) {
  .profile-page {
    width: min(100% - 24px, 680px);
    padding-top: 16px;
  }

  .profile-titlebar {
    min-height: 0;
    padding: 18px;
    align-items: flex-start;
  }

  .profile-titlebar h1 {
    font-size: 32px;
  }

  .profile-title-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;
  }

  .profile-workspace {
    grid-template-columns: 1fr;
  }

  .profile-side-column {
    position: static;
  }
}

@media (max-width: 640px) {
  .profile-titlebar,
  .profile-link-card {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .profile-titlebar {
    display: grid;
  }

  .profile-title-icon {
    display: none;
  }

  .device-status-grid {
    grid-template-columns: 1fr;
  }

  .profile-link-card .primary-button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 920px) {
  .shell {
    width: min(100% - 24px, 680px);
    padding-top: 16px;
  }

  .site-nav,
  .home-shell {
    width: min(100% - 24px, 680px);
  }

  .desktop-nav {
    gap: 14px;
    font-size: 13px;
  }

  .home-hero-section {
    padding: 48px 0 58px;
  }

  .home-dashboard,
  .hero-layout,
  .image-grid,
  .pdf-grid,
  .advantage-grid,
  .usage-rule-grid {
    grid-template-columns: 1fr;
  }

  .home-intro-card {
    min-height: 0;
    padding: 24px;
  }

  .home-intro-card h2 {
    font-size: 38px;
  }

  .quick-tool-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-tool-item {
    min-height: 62px;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 9px;
    padding: 10px;
  }

  .quick-tool-item > span {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    font-size: 12px;
  }

  .quick-tool-item strong {
    font-size: 14px;
  }

  .quick-tool-item small {
    display: none;
  }

  .hero-layout {
    gap: 28px;
  }

  .feature-section,
  .advantage-section {
    padding: 42px 0;
  }

  .tip-card,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .topbar {
    border-radius: 20px;
  }

  .home-nav {
    display: none;
  }

  .home-hero,
  .tool-groups,
  .workspace {
    grid-template-columns: 1fr;
  }

  .workspace > aside.panel {
    position: static;
  }

  .images-pdf-side,
  .image-convert-side,
  .image-merge-side,
  .pdf-merge-side,
  .pdf-split-side {
    position: static;
  }

  .workspace .panel:has(.file-list) {
    height: auto;
  }

  .workspace .panel:has(.file-list) .dropzone {
    min-height: 280px;
  }

  .hero-command-panel {
    min-height: auto;
  }

  .tool-hero::after {
    display: none;
  }

  .tool-hero {
    padding-right: 22px;
  }

  .images-pdf-hero {
    grid-template-columns: 1fr;
  }

  .pdf-hero-visual {
    display: none;
  }

  .option-grid,
  .option-grid.two {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .shell {
    width: calc(100% - 24px);
  }

  .site-nav {
    min-height: 62px;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 0;
  }

  .desktop-nav {
    width: 100%;
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding: 4px 0 2px;
    white-space: nowrap;
    scrollbar-width: none;
  }

  .desktop-nav::-webkit-scrollbar {
    display: none;
  }

  .home-hero-section {
    padding: 24px 0 26px;
  }

  .hero-main-copy h2 {
    font-size: 40px;
  }

  .home-intro-card h2 {
    font-size: 34px;
  }

  .home-intro-card p {
    font-size: 15px;
  }

  .quick-tools-panel {
    padding: 14px;
  }

  .quick-tool-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-tool-item {
    min-height: 62px;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 9px;
    padding: 10px;
  }

  .quick-tool-item > span {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    font-size: 12px;
  }

  .quick-tool-item strong {
    font-size: 14px;
  }

  .quick-tool-item small {
    display: none;
  }

  .module-preview {
    padding: 12px;
    border-radius: 22px;
  }

  .feature-card,
  .advantage-card {
    min-height: auto;
  }

  .footer-inner nav {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .setting-options.three,
  .setting-options.four {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .modal-actions {
    grid-template-columns: 1fr;
  }

  .brand-logo {
    width: 44px;
    height: 44px;
    border-radius: 15px;
  }

  .home-hero h2 {
    font-size: 38px;
  }

  .tool-hero h1 {
    font-size: 32px;
  }

  .tool-hero {
    padding: 16px 18px;
  }

  .tool-hero p {
    display: -webkit-box;
    line-height: 1.45;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .hero-copy-panel,
  .tool-hero,
  .panel,
  .tool-group {
    border-radius: 22px;
  }

  .tool-card {
    grid-template-columns: 58px minmax(0, 1fr) 28px;
    padding: 14px;
  }

  .tool-card img {
    width: 58px;
    height: 58px;
  }

  .file-item {
    grid-template-columns: 52px minmax(0, 1fr);
  }

  .file-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .images-to-pdf-page .workspace > aside.panel {
    padding-bottom: 88px;
  }

  .images-to-pdf-page .action-row {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 30;
    margin: 0;
    padding: 10px;
    border: 1px solid rgba(216, 228, 248, 0.9);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 18px 42px rgba(47, 86, 150, 0.16);
    backdrop-filter: blur(14px);
  }

  .history-item {
    grid-template-columns: 1fr;
  }

  .history-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
