    :root {
      --paper-bg: #faf8f3;
      --paper-dark: #f0ece3;
      --paper-shadow: #e0dbd2;
      --ink-black: #2c2c2c;
      --ink-gray: #6b6b6b;
      --pencil-blue: #4a6fa5;
      --pencil-red: #c75c5c;
      --pencil-green: #5a9a6a;
      --pencil-orange: #c9765a;
      --pencil-purple: #7a6fa5;
      --highlight: #fff8d6;
      --border-rough: #b5b0a8;
    }

    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }

    body {
      height: 100%;
      font-family: 'ZCOOL XiaoWei', 'Noto Serif SC', serif;
      overflow-x: hidden;
      overflow-y: hidden;
      background: transparent;
      color: var(--ink-black);
      min-height: 100vh;
      position: relative;
      line-height: 1.6;
      animation: bodyIn 0.4s ease-out forwards;
    }

    @keyframes bodyIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }

    body::before {
      content: '';
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-color: var(--paper-bg);
      background-image:
        repeating-linear-gradient(
          0deg,
          transparent,
          transparent 28px,
          rgba(150, 145, 135, 0.5) 28px,
          rgba(150, 145, 135, 0.5) 29px
        ),
        repeating-linear-gradient(
          90deg,
          transparent,
          transparent 28px,
          rgba(150, 145, 135, 0.35) 28px,
          rgba(150, 145, 135, 0.35) 29px
        );
      pointer-events: none;
      z-index: 0;
    }

    body::after {
      content: '';
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
      opacity: 0.015;
      pointer-events: none;
      z-index: 0;
    }

    /* 手绘装饰元素 */
    .sketch-decoration {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      pointer-events: none;
      z-index: 9999;
      opacity: 0.35;
    }

    .sketch-decoration.top-left {
      position: fixed;
      top: 30px;
      left: 30px;
      width: 150px;
      height: 150px;
    }

    .sketch-decoration.top-right {
      position: fixed;
      top: 60px;
      right: 40px;
      width: 120px;
      height: 120px;
    }

    .sketch-decoration.bottom-left {
      position: fixed;
      bottom: 100px;
      left: 40px;
      width: 130px;
      height: 130px;
    }

    .sketch-decoration.bottom-right {
      position: fixed;
      bottom: 80px;
      right: 50px;
      width: 110px;
      height: 110px;
    }

    @media (max-width: 768px) {
      .sketch-decoration.top-left,
      .sketch-decoration.top-right {
        display: none;
      }

      .sketch-decoration.bottom-left,
      .sketch-decoration.bottom-right {
        width: 80px;
        height: 80px;
        opacity: 0.25;
      }

      .sketch-decoration.bottom-left {
        bottom: 20px;
        left: 20px;
      }

      .sketch-decoration.bottom-right {
        bottom: 20px;
        right: 20px;
      }
    }

    .container {
      max-width: 700px;
      margin: 0 auto;
      padding: 30px 20px;
    }

    .page {
      position: relative;
      z-index: 1;
    }

    .header {
      text-align: center;
      margin-bottom: 24px;
      position: relative;
      padding: 20px 0;
      opacity: 0;
      animation: headerIn 0.6s ease-out 0.1s forwards;
    }

    .header::before {
      content: '';
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 220px;
      height: 70px;
      background: var(--highlight);
      opacity: 0.5;
      border-radius: 4px;
      z-index: -1;
      animation: pulse 3s ease-in-out infinite;
    }

    @keyframes headerIn {
      from { opacity: 0; transform: translateY(-20px); }
      to { opacity: 1; transform: translateY(0); }
    }

    @keyframes pulse {
      0%, 100% { opacity: 0.4; transform: translate(-50%, -50%) scale(1); }
      50% { opacity: 0.6; transform: translate(-50%, -50%) scale(1.05); }
    }

    .logo {
      font-family: 'Ma Shan Zheng', cursive;
      font-size: 3rem;
      color: var(--ink-black);
      letter-spacing: 0.1em;
      position: relative;
      display: inline-block;
      text-shadow: 2px 2px 0 var(--paper-bg);
      opacity: 0;
      animation: logoIn 0.5s ease-out 0.3s forwards;
    }

    @keyframes logoIn {
      from { opacity: 0; transform: rotate(-3deg); }
      to { opacity: 1; transform: rotate(0deg); }
    }

    .logo::after {
      content: '';
      position: absolute;
      bottom: 5px;
      left: 0;
      width: 100%;
      height: 3px;
      background: var(--pencil-blue);
      opacity: 0.8;
      transform: rotate(-1deg);
    }

    .subtitle {
      font-family: 'ZCOOL XiaoWei', serif;
      color: var(--ink-gray);
      font-size: 0.85rem;
      margin-top: 6px;
      letter-spacing: 0.2em;
      opacity: 0;
      animation: subtitleIn 0.4s ease-out 0.5s forwards;
    }

    @keyframes subtitleIn {
      from { opacity: 0; transform: translateY(-10px); }
      to { opacity: 1; transform: translateY(0); }
    }

    .quick-nav {
      padding: 16px 20px;
      border-bottom: 1px dashed var(--border-rough);
      display: flex;
      align-items: center;
      gap: 12px;
      background: linear-gradient(135deg, var(--paper-bg) 0%, var(--paper-dark) 100%);
    }

    .tool-panel-title {
      font-family: 'Noto Serif SC', serif;
      font-weight: 600;
      font-size: 1.2rem;
      letter-spacing: 0.02em;
    }

    .tool-panel-icon {
      width: 28px;
      height: 28px;
      stroke: var(--ink-black);
      stroke-width: 1.5;
      fill: none;
    }

    .tool-panel-content {
      padding: 24px 20px;
      animation: slideIn 0.3s ease-out;
    }

    .input-group {
      margin-bottom: 16px;
    }

    .input-copy-btn {
      transition: opacity 0.2s ease, transform 0.2s ease;
    }

    .input-copy-btn:hover {
      opacity: 1;
    }

    .input-copy-btn:active {
      transform: scale(0.9);
    }

    .input-label {
      display: block;
      font-size: 0.85rem;
      color: var(--ink-gray);
      margin-bottom: 6px;
    }

    .input-field {
      width: 100%;
      padding: 10px 12px;
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.95rem;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      background: #fff;
      color: var(--ink-black);
      transition: all 0.2s ease;
    }

    .input-field:focus {
      outline: none;
      border-color: var(--pencil-blue);
      box-shadow: 0 0 0 3px rgba(74, 111, 165, 0.1);
    }

    .input-field::placeholder {
      color: var(--border-rough);
    }

    textarea.input-field {
      resize: vertical;
      min-height: 100px;
    }

    select.input-field {
      cursor: pointer;
      appearance: none;
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b6b6b' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
      background-repeat: no-repeat;
      background-position: right 12px center;
      padding-right: 36px;
    }

    .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 6px;
      padding: 8px 16px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.9rem;
      border: 1.5px solid var(--ink-black);
      border-radius: 3px;
      background: transparent;
      color: var(--ink-black);
      cursor: pointer;
      transition: all 0.2s ease;
    }

    .btn:hover {
      background: var(--ink-black);
      color: var(--paper-bg);
    }

    .btn:active {
      transform: translateY(1px);
    }

    .btn-small {
      padding: 6px 12px;
      font-size: 0.8rem;
    }

    .btn-group {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      margin-top: 16px;
    }

    .result-box {
      background: #fff;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      padding: 12px;
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.9rem;
      word-break: break-all;
      position: relative;
      margin-top: 12px;
    }

    .result-label {
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.75rem;
      color: var(--ink-gray);
      margin-bottom: 6px;
    }

    .result-value {
      color: var(--ink-black);
    }

    .copy-feedback {
      position: absolute;
      top: 8px;
      right: 8px;
      font-size: 0.75rem;
      color: var(--pencil-blue);
      opacity: 0;
      transition: opacity 0.2s ease;
    }

    .copy-feedback.show {
      opacity: 1;
    }

      /* =====================
       PC 端首页工具网格：垂直滚动布局，用户自行滚动
       ===================== */
    .tool-grid {
      --tool-gap: 20px;
      display: grid;
      /* 固定 4 列，确保所有卡片宽度一致 */
      grid-template-columns: repeat(4, 1fr);
      gap: var(--tool-gap);
      padding: 16px 24px 160px;
      max-width: 1100px;
      margin: 0 auto;
    }

    /* =====================
       移动端首页工具网格：横向滚动分页
       ===================== */
    @media (max-width: 900px) {
      .tool-grid {
        --tool-gap: 14px;
        grid-template-columns: unset;
        /* 横向滚动：三行 x 两列 */
        grid-auto-flow: column;
        grid-template-rows: repeat(3, auto);
        grid-auto-columns: calc((100% - var(--tool-gap)) / 2);
        gap: var(--tool-gap);
        padding: 12px 20px 120px 20px;
        margin-left: 2px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: none;
        scrollbar-width: none;
        -ms-overflow-style: none;
      }

      .tool-grid::-webkit-scrollbar {
        height: 0;
        display: none;
      }
    }

    .tooltip {
      content: '';
      position: absolute;
      bottom: 100%;
      left: 50%;
      transform: translateX(-50%);
      border: 6px solid transparent;
      border-top-color: var(--ink-black);
      opacity: 0;
      visibility: hidden;
      transition: all 0.2s ease;
    }

    .tooltip:hover::before,
    .tooltip:hover::after {
      opacity: 1;
      visibility: visible;
    }

    .timestamp-display {
      font-family: 'JetBrains Mono', monospace;
      font-size: 2.5rem;
      text-align: center;
      padding: 28px 20px;
      background: linear-gradient(135deg, var(--highlight) 0%, #fff9e6 100%);
      border: 2px dashed var(--border-rough);
      border-radius: 4px;
      margin-bottom: 20px;
      position: relative;
      overflow: hidden;
    }

    .timestamp-display::before {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, var(--pencil-blue), transparent);
      opacity: 0.5;
    }

    .timestamp-display .label {
      font-size: 0.8rem;
      color: var(--ink-gray);
      display: block;
      margin-bottom: 6px;
      text-transform: uppercase;
      letter-spacing: 0.1em;
    }

    .timestamp-digits {
      display: inline-flex;
      gap: 1px;
      justify-content: flex-start;
    }

    .digit-flip {
      display: inline-block;
      min-width: 0.85em;
      height: 1.8em;
      background: var(--ink-black);
      color: var(--paper-bg);
      border-radius: 4px;
      text-align: center;
      line-height: 1.8em;
      font-size: 1.8rem;
      font-weight: 500;
      position: relative;
      overflow: hidden;
      flex-shrink: 0;
    }

    .digit-flip.flipping {
      animation: flipDigit 0.3s ease-in-out;
    }

    @keyframes flipDigit {
      0% { transform: rotateX(0deg); }
      50% { transform: rotateX(-90deg); }
      100% { transform: rotateX(0deg); }
    }

    .digit-separator {
      font-size: 2.2rem;
      color: var(--ink-gray);
      margin: 0 3px;
      line-height: 1.5em;
    }

    .timestamp-mode {
      display: flex;
      justify-content: center;
      gap: 12px;
      margin-bottom: 20px;
      flex-wrap: wrap;
    }

    .mode-btn {
      padding: 8px 16px;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      background: transparent;
      cursor: pointer;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.85rem;
      transition: all 0.2s ease;
    }

    .mode-btn:hover {
      background: var(--paper-dark);
      border-color: var(--pencil-blue);
    }

    .mode-btn.active {
      background: var(--pencil-blue);
      border-color: var(--pencil-blue);
      color: white;
    }

    .mode-btn:focus-visible {
      outline: 2px solid var(--pencil-blue);
      outline-offset: 2px;
    }

    .qr-container {
      display: flex;
      flex-direction: column;
      align-items: stretch;
      gap: 16px;
      width: 100%;
    }

    .qr-preview {
      background: white;
      padding: 20px;
      border: 1px dashed var(--border-rough);
      border-radius: 3px;
      min-width: 200px;
      max-width: 100%;
      min-height: 200px;
      display: flex;
      align-items: center;
      justify-content: center;
      align-self: center;
    }

    .qr-options {
      display: flex;
      gap: 16px;
      flex-wrap: wrap;
      justify-content: center;
    }

    .qr-options .input-group {
      margin-bottom: 0;
    }

    .json-container {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 12px;
      width: 100%;
      align-items: stretch;
    }

    #tool-page[data-tool="json"] .tool-content {
      max-width: 100%;
      padding: 12px;
      padding-top: 72px;
    }

    #tool-page[data-tool="json"] .tool-header {
      max-width: 100%;
    }

    @media (max-width: 768px) {
      .json-container {
        grid-template-columns: 1fr;
      }

      #tool-page[data-tool="json"] .tool-content {
        padding: 16px;
      }
    }

    .json-input, .json-output {
      display: flex;
      flex-direction: column;
      min-height: 400px;
    }

    .json-input {
      padding: 0;
    }

    .json-input .input-group {
      flex: 1;
      display: flex;
      flex-direction: column;
      margin-bottom: 0;
    }

    #json-input {
      flex: 1;
    }

    #json-output {
      flex: 1;
      overflow: auto;
    }

    .json-output .input-label {
      margin-bottom: 0;
      flex-shrink: 0;
      font-size: 0.85rem;
      color: var(--ink-gray);
    }

    .json-output {
      display: flex;
      flex-direction: column;
      background: #fafaf8;
      overflow: auto;
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.8rem;
      line-height: 1.5;
      white-space: pre-wrap;
      padding: 0;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      height: 100%;
    }

    #json-output {
      flex: 1;
    }

    .json-tree {
      width: 100%;
      font-size: 0.85rem;
      line-height: 1.5;
      display: block;
    }

    .j-box {
      display: inline;
    }

    .j-item {
      margin: 1px 0;
      display: block;
    }

    .j-toggle {
      cursor: pointer;
      color: var(--pencil-blue);
      font-size: 10px;
      width: 14px;
      height: 14px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      margin-right: 4px;
      border-radius: 2px;
      vertical-align: middle;
    }

    .j-toggle:hover {
      background: var(--paper-dark);
    }

    .j-key {
      color: var(--pencil-green);
    }

    .j-str {
      color: var(--pencil-orange);
    }

    .j-num {
      color: var(--pencil-blue);
    }

    .j-bool {
      color: var(--pencil-purple);
    }

    .j-null {
      color: var(--pencil-red);
    }

    .j-bracket {
      color: var(--ink-gray);
    }

    .j-comma {
      color: var(--ink-gray);
    }

    .j-colon {
      color: var(--ink-gray);
    }

    .j-children {
      display: block;
      margin-left: 28px;
      border-left: 1px dashed var(--border-rough);
      padding-left: 12px;
    }

    .j-hidden {
      display: none;
    }

    .json-error {
      color: var(--pencil-red);
      font-size: 0.85rem;
      padding: 8px;
      background: rgba(199, 92, 92, 0.1);
      border-radius: 3px;
      margin-top: 12px;
      display: none;
    }

    .color-container {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 16px;
    }

    .color-preview-box {
      width: 100%;
      max-width: 400px;
      border: 1.5px dashed var(--border-rough);
      border-radius: 3px;
      overflow: hidden;
      position: relative;
    }

    .color-preview-box img {
      display: block;
      width: 100%;
      height: auto;
      cursor: crosshair;
    }

    .color-info {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;
      width: 100%;
    }

    .color-swatch {
      padding: 12px;
      border: 1px solid var(--border-rough);
      border-radius: 3px;
      text-align: center;
    }

    .color-swatch .label {
      font-size: 0.75rem;
      color: var(--ink-gray);
      margin-bottom: 4px;
    }

    .color-swatch .value {
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.85rem;
    }

    .recent-colors {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
    }

    .recent-color {
      width: 32px;
      height: 32px;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      cursor: pointer;
      transition: transform 0.2s ease;
    }

    .recent-color:hover {
      transform: scale(1.1);
    }

    /* Resize Tool */
    .resize-preview-container {
      display: flex;
      gap: 16px;
      justify-content: center;
      flex-wrap: wrap;
    }

    .resize-preview-item {
      flex: 1;
      min-width: 200px;
      max-width: 300px;
    }

    .resize-preview-label {
      font-size: 0.85rem;
      color: var(--ink-gray);
      margin-bottom: 8px;
      text-align: center;
    }

    .resize-preview-box {
      border: 1.5px dashed var(--border-rough);
      border-radius: 3px;
      overflow: hidden;
      display: flex;
      align-items: center;
      justify-content: center;
      background: #fafafa;
      min-height: 150px;
    }

    .resize-preview-box img,
    .resize-preview-box canvas {
      max-width: 100%;
      max-height: 250px;
      display: block;
    }

    .resize-original-info,
    .resize-preview-info {
      font-size: 0.75rem;
      color: var(--ink-gray);
      text-align: center;
      margin-top: 4px;
      font-family: 'JetBrains Mono', monospace;
    }

    .resize-controls {
      max-width: 500px;
      margin: 0 auto;
    }

    .resize-dimensions {
      display: flex;
      align-items: center;
      gap: 12px;
      flex-wrap: wrap;
    }

    .resize-dimension-input {
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .resize-dimension-input input {
      width: 80px;
    }

    .resize-scale {
      display: flex;
      align-items: center;
      gap: 12px;
    }

    .resize-scale input[type="range"] {
      flex: 1;
    }

    .resize-scale span {
      min-width: 45px;
      text-align: right;
    }

    .resize-options {
      display: flex;
      align-items: center;
      gap: 16px;
      flex-wrap: wrap;
    }

    .resize-options select {
      width: auto;
    }

    .resize-quality {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .resize-quality input[type="range"] {
      width: 100px;
    }

    .resize-quality span {
      min-width: 40px;
    }

    .file-upload {
      border: 2px dashed var(--border-rough);
      border-radius: 3px;
      padding: 30px;
      text-align: center;
      cursor: pointer;
      transition: all 0.2s ease;
      background: #fff;
    }

    .file-upload:hover {
      border-color: var(--pencil-blue);
      background: rgba(74, 111, 165, 0.05);
    }

    .file-upload input {
      display: none;
    }

    .file-upload {
      cursor: pointer;
    }

    .file-upload label {
      cursor: pointer;
      display: block;
    }

    .file-upload-icon {
      width: 40px;
      height: 40px;
      stroke: var(--ink-gray);
      stroke-width: 1.5;
      fill: none;
      margin-bottom: 10px;
    }

    .footer {
      text-align: center;
      margin-top: 40px;
      padding: 20px;
      border-top: 1px dashed var(--border-rough);
      color: var(--ink-gray);
      font-size: 0.85rem;
      opacity: 0;
      animation: footerIn 0.5s ease-out 1.2s forwards;
    }

    @keyframes footerIn {
      from { opacity: 0; transform: translateY(10px); }
      to { opacity: 1; transform: translateY(0); }
    }

    .footer a {
      color: var(--pencil-blue);
      text-decoration: none;
    }

    .footer a:hover {
      text-decoration: underline;
    }

    .toast {
      position: fixed;
      top: 30px;
      left: 50%;
      transform: translateX(-50%) translateY(-100px);
      background: var(--ink-black);
      color: var(--paper-bg);
      padding: 12px 24px;
      border-radius: 8px;
      font-size: 0.9rem;
      opacity: 0;
      transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
      z-index: 1000;
      box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .toast.show {
      transform: translateX(-50%) translateY(0);
      opacity: 1;
    }

    .toast::before {
      content: '✓';
      display: inline-block;
      width: 20px;
      height: 20px;
      background: var(--pencil-blue);
      border-radius: 50%;
      text-align: center;
      line-height: 20px;
      font-size: 12px;
    }

    .md5-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 12px;
    }

    @media (max-width: 500px) {
      .md5-grid {
        grid-template-columns: 1fr;
      }
    }

    .md5-item {
      background: #fff;
      border: 1px solid var(--border-rough);
      border-radius: 3px;
      padding: 10px 12px 10px 12px;
    }

    .md5-item .value {
      padding-right: 20px;
    }

    .md5-item .label {
      font-size: 0.75rem;
      color: var(--ink-gray);
      margin-bottom: 4px;
    }

    .md5-item .value {
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.85rem;
      word-break: break-all;
    }

    ::-webkit-scrollbar {
      width: 8px;
      height: 8px;
    }

    ::-webkit-scrollbar-track {
      background: var(--paper-dark);
    }

    ::-webkit-scrollbar-thumb {
      background: var(--border-rough);
      border-radius: 4px;
    }

    ::-webkit-scrollbar-thumb:hover {
      background: var(--ink-gray);
    }

    @media (prefers-reduced-motion: reduce) {
      *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
      }
    }

    /* Page Transition Styles */
    .page {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: var(--paper-bg);
      transition: transform 0.3s ease, opacity 0.3s ease;
      -webkit-transition: -webkit-transform 0.3s ease, opacity 0.3s ease;
      overflow-y: auto;
      -webkit-overflow-scrolling: touch;
      z-index: 1;
      -webkit-backface-visibility: hidden;
      backface-visibility: hidden;
    }

    #home-page {
      z-index: 2;
    }

    #home-page.hidden {
      transform: translateX(100%);
      -webkit-transform: translateX(100%);
    }

    /* Home Page Styles */
    .home-header {
      text-align: center;
      padding: 40px 20px 0px;
      position: relative;
    }

    .home-header .logo {
      font-family: 'Ma Shan Zheng', cursive;
      font-size: 3.5rem;
      color: var(--ink-black);
      letter-spacing: 0.1em;
      position: relative;
      display: inline-block;
      text-shadow: 2px 2px 0 var(--paper-bg);
      cursor: default;
    }

    .home-header .logo::before {
      content: '';
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 280px;
      height: 80px;
      background: var(--highlight);
      opacity: 0.4;
      border-radius: 8px;
      z-index: -1;
      animation: logoPulse 3s ease-in-out infinite;
    }

    @keyframes logoPulse {
      0%, 100% { opacity: 0.3; transform: translate(-50%, -50%) scale(1); }
      50% { opacity: 0.5; transform: translate(-50%, -50%) scale(1.05); }
    }

    .home-subtitle {
      font-family: 'Noto Serif SC', serif;
      font-size: 0.9rem;
      color: var(--ink-gray);
      margin-top: 10px;
      letter-spacing: 0.15em;
      opacity: 0;
      animation: subtitleFadeIn 0.5s ease-out 0.4s forwards;
    }

    /* 搜索栏 */
    .search-bar {
      max-width: 700px;
      margin: 16px auto 0;
      padding: 0 20px;
      display: flex;
      justify-content: center;
      position: relative;
    }

    .search-bar::before {
      content: '';
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 100%;
      max-width: 660px;
      height: 50px;
      background: var(--highlight);
      opacity: 0.3;
      border-radius: 8px;
      z-index: -1;
    }

    .search-input {
      width: 100%;
      max-width: 640px;
      padding: 12px 16px 12px 44px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 1rem;
      border: 2px dashed var(--border-rough);
      border-radius: 8px;
      background: #fff;
      color: var(--ink-black);
      transition: all 0.2s ease;
      box-shadow: 3px 3px 0 var(--paper-shadow);
    }

    .search-input::placeholder {
      color: var(--ink-gray);
      font-style: italic;
    }

    .search-input:focus {
      outline: none;
      border-color: var(--pencil-blue);
      border-style: solid;
      box-shadow: 4px 4px 0 var(--paper-shadow);
    }

    .search-bar::after {
      content: '';
      position: absolute;
      left: calc(50% - 300px);
      top: 50%;
      transform: translateY(-50%);
      width: 20px;
      height: 20px;
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b6b6b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.35-4.35'/%3E%3C/svg%3E");
      background-size: contain;
      background-repeat: no-repeat;
      opacity: 0.6;
      pointer-events: none;
    }

    .no-results {
      padding: 28px 12px;
      text-align: center;
      color: var(--ink-gray);
      font-size: 0.95rem;
    }

    @keyframes subtitleFadeIn {
      from { opacity: 0; transform: translateY(-8px); }
      to { opacity: 0.8; transform: translateY(0); }
    }

    .home-subtitle.time-tick {
      animation: timePulse 1s ease-in-out infinite;
    }

    @keyframes timePulse {
      0%, 100% { opacity: 0.8; }
      50% { opacity: 0.5; }
    }

    .home-subtitle .digit {
      display: inline-block;
      transition: transform 0.15s ease-out, color 0.15s ease;
    }

    .home-subtitle .digit.space {
      width: 0.4em;
    }

    .home-subtitle .digit.tick {
      animation: digitTick 0.3s ease-out;
    }

    @keyframes digitTick {
      0% { transform: translateY(0); }
      50% { transform: translateY(-2px); color: var(--accent); }
      100% { transform: translateY(0); }
    }

    .home-header .logo::after {
      content: '';
      position: absolute;
      bottom: 8px;
      left: 0;
      width: 100%;
      height: 4px;
      background: var(--pencil-blue);
      opacity: 0.7;
      transform: rotate(-1deg);
      border-radius: 2px;
    }

    .quick-nav {
      display: flex;
      gap: 10px;
      margin-top: 28px;
      margin-bottom: 28px;
      padding: 16px 24px;
      border-bottom: 1px dashed var(--border-rough);
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
      scrollbar-width: none;
      justify-content: center;
      background: linear-gradient(180deg, transparent 0%, rgba(232, 228, 219, 0.3) 100%);
      border-radius: 12px;
      max-width: 500px;
      margin-left: auto;
      margin-right: auto;
    }

    .quick-nav::-webkit-scrollbar {
      display: none;
    }

    .home-footer {
      text-align: center;
      padding: 30px 20px 40px;
      margin-top: 20px;
      opacity: 0;
      animation: footerFadeIn 0.5s ease-out 0.8s forwards;
    }

    @keyframes footerFadeIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }

    .home-footer p {
      font-family: 'Noto Serif SC', serif;
      font-size: 0.85rem;
      color: var(--ink-gray);
      letter-spacing: 0.05em;
    }

    .home-footer a {
      color: var(--pencil-blue);
      text-decoration: none;
      transition: color 0.2s ease;
    }

    .home-footer a:hover {
      color: var(--ink-black);
    }

    .tool-card {
      background: linear-gradient(145deg, #fff 0%, var(--paper-bg) 100%);
      border: 1.5px solid var(--border-rough);
      border-radius: 12px;
      padding: 24px 18px;
      text-align: center;
      cursor: pointer;
      transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
      box-shadow: 4px 4px 0 var(--paper-shadow);
      opacity: 0;
      transform: translateY(20px);
      animation: cardIn 0.5s ease forwards;
      position: relative;
      overflow: hidden;
      /* 使卡片在横向滚动容器中对齐为分页起点 */
      scroll-snap-align: start;
      /* 不使用强制 stop，以免首次加载时触发强制 snap */
      user-select: none;
      -webkit-tap-highlight-color: transparent;
      width: 100%;
      min-width: 0;
      box-sizing: border-box;
    }

    .tool-card::before {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 3px;
      background: linear-gradient(90deg, var(--pencil-blue), var(--pencil-red));
      opacity: 0;
      transition: opacity 0.25s ease;
    }

    .tool-card:nth-child(1) { animation-delay: 0.05s; }
    .tool-card:nth-child(2) { animation-delay: 0.1s; }
    .tool-card:nth-child(3) { animation-delay: 0.15s; }
    .tool-card:nth-child(4) { animation-delay: 0.2s; }
    .tool-card:nth-child(5) { animation-delay: 0.25s; }
    .tool-card:nth-child(6) { animation-delay: 0.3s; }
    .tool-card:nth-child(7) { animation-delay: 0.35s; }

    @keyframes cardIn {
      from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
      }
      to {
        opacity: 1;
        transform: translateY(0) scale(1);
      }
    }

    .tool-card:hover {
      transform: translateY(-4px) scale(1.02);
      box-shadow: 6px 8px 0 var(--paper-shadow);
      border-color: var(--pencil-blue);
    }

    .tool-card:hover::before {
      opacity: 1;
    }

    .tool-card:active {
      transform: translateY(-1px) scale(0.99);
      box-shadow: 2px 2px 0 var(--paper-shadow);
    }

    .tool-card-icon {
      width: 40px;
      height: 40px;
      margin: 0 auto 12px;
      stroke: var(--ink-black);
      stroke-width: 1.5;
      fill: none;
      transition: transform 0.25s ease;
    }

    .tool-card:hover .tool-card-icon {
      transform: scale(1.1);
    }

    .tool-card-name {
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 1rem;
      color: var(--ink-black);
      margin-bottom: 4px;
    }

    .tool-card-desc {
      font-size: 0.8rem;
      color: var(--ink-gray);
      margin-top: 2px;
      line-height: 1.4;
    }

    .quick-nav-item {
      width: 44px;
      height: 44px;
      border: 1.5px solid var(--border-rough);
      border-radius: 12px;
      background: var(--paper-bg);
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
      flex-shrink: 0;
      padding: 0;
      opacity: 0;
      animation: navItemIn 0.3s ease forwards;
      box-shadow: 2px 2px 0 var(--paper-shadow);
    }

    @keyframes navItemIn {
      to { opacity: 1; }
    }

    .quick-nav-item svg {
      width: 22px;
      height: 22px;
      stroke: var(--ink-black);
      stroke-width: 1.5;
      fill: none;
    }

    .quick-nav-item:hover {
      background: var(--paper-dark);
      border-color: var(--pencil-blue);
      transform: translateY(-2px);
      box-shadow: 3px 4px 0 var(--paper-shadow);
    }

    .quick-nav-item:active {
      transform: translateY(0);
      box-shadow: 1px 1px 0 var(--paper-shadow);
    }

    /* Tool Page Styles */
    .tool-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      padding: 16px 20px;
      background: linear-gradient(135deg, var(--paper-bg) 0%, var(--paper-dark) 100%);
      border-bottom: 1px dashed var(--border-rough);
      position: sticky;
      top: 0;
      z-index: 10;
    }

    .tool-select {
      padding: 6px 28px 6px 10px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.85rem;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      background: var(--paper-bg);
      color: var(--ink-black);
      cursor: pointer;
      appearance: none;
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b6b6b' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
      background-repeat: no-repeat;
      background-position: right 8px center;
      min-width: 100px;
    }

    .tool-dropdown {
      position: relative;
    }

    .tool-dropdown-btn {
      display: flex;
      align-items: center;
      gap: 6px;
      padding: 6px 10px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.85rem;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      background: var(--paper-bg);
      color: var(--ink-black);
      cursor: pointer;
      transition: all 0.2s ease;
    }

    .tool-dropdown-btn:hover {
      border-color: var(--pencil-blue);
      background: var(--paper-dark);
    }

    .tool-dropdown-current {
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .tool-dropdown-current svg {
      width: 16px;
      height: 16px;
      stroke: var(--ink-black);
      stroke-width: 1.5;
      fill: none;
    }

    .tool-dropdown-arrow {
      width: 14px;
      height: 14px;
      stroke: var(--ink-gray);
      stroke-width: 2;
      fill: none;
      transition: transform 0.2s ease;
    }

    .tool-dropdown.open .tool-dropdown-arrow {
      transform: rotate(180deg);
    }

    .tool-dropdown-menu {
      position: absolute;
      top: 100%;
      right: 0;
      margin-top: 4px;
      min-width: 160px;
      background: var(--paper-bg);
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      box-shadow: 0 4px 12px rgba(0,0,0,0.1);
      z-index: 100;
      display: none;
      overflow: hidden;
    }

    .tool-dropdown.open .tool-dropdown-menu {
      display: block;
    }

    .tool-dropdown-item {
      display: flex;
      align-items: center;
      gap: 8px;
      padding: 10px 12px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.9rem;
      color: var(--ink-black);
      cursor: pointer;
      transition: background 0.2s ease;
    }

    .tool-dropdown-item:hover {
      background: var(--paper-dark);
    }

    .tool-dropdown-item.active {
      background: var(--ink-black);
      color: var(--paper-bg);
    }

    .tool-dropdown-item svg {
      width: 18px;
      height: 18px;
      stroke: currentColor;
      stroke-width: 1.5;
      fill: none;
      flex-shrink: 0;
    }

    .back-btn {
      display: flex;
      align-items: center;
      gap: 6px;
      padding: 8px 12px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.9rem;
      border: 1.5px solid var(--border-rough);
      border-radius: 3px;
      background: transparent;
      color: var(--ink-black);
      cursor: pointer;
      transition: all 0.2s ease;
    }

    .back-btn:hover {
      background: var(--paper-dark);
      border-color: var(--pencil-blue);
    }

    .back-btn svg {
      width: 18px;
      height: 18px;
      stroke: currentColor;
      stroke-width: 1.5;
      fill: none;
    }

    .tool-title {
      font-family: 'Noto Serif SC', serif;
      font-weight: 600;
      font-size: 1.1rem;
      letter-spacing: 0.02em;
    }

    .tool-content {
      padding: 24px 20px;
      max-width: 700px;
      margin: 0 auto;
    }

    /* Desktop: 固定工具页顶部栏，避免随内容滚动（与移动端行为一致） */
    @media (min-width: 900px) {
      #tool-page .tool-header {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 120;
        width: 100%;
        box-shadow: 0 4px 18px rgba(0,0,0,0.06);
      }
      /* 给工具内容预留顶部空间，避免被固定头遮挡（与 .tool-header 的高度保持一致） */
      #tool-page .tool-content {
        padding-top: 72px;
      }
      /* 当工具页不是激活态时，隐藏其固定头，避免在页面切换时残留在视口上 */
      #tool-page:not(.active) .tool-header {
        display: none;
      }
    }

    /* Mobile Responsive */
    @media (max-width: 480px) {
      .container {
        padding: 20px 12px;
      }

      .logo {
        font-size: 2.2rem;
      }

      .header {
        padding: 16px 0;
        margin-bottom: 16px;
      }

      .header::before {
        width: 180px;
        height: 60px;
      }

      .quick-nav {
        padding: 16px 12px;
      }

      /* 缩小卡片以便露出邻近卡片边缘作为滑动提示 */
      .tool-card {
        padding: 12px 10px;
        border-radius: 10px;
      }

      .tool-card-icon {
        width: 32px;
        height: 32px;
        margin-bottom: 8px;
      }

      .tool-card-name {
        font-size: 0.92rem;
      }

      .tool-card-desc {
        font-size: 0.72rem;
      }

      /* 活泼主题移动端 Logo 上移 */
      body.theme-lively .header {
        padding: 6px 0;
        margin-bottom: 6px;
      }

      body.theme-lively .home-header .logo {
        font-size: 1.6rem;
      }

      /* 活泼主题移动端卡片调整 */
      body.theme-lively .tool-card {
        padding: 5px 4px;
        border-radius: 8px;
        box-shadow: 1px 1px 0 var(--ink-black), inset 0 -1px rgba(0, 0, 0, 0.1);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
      }

      body.theme-lively .tool-card-icon {
        width: 16px;
        height: 16px;
        margin-bottom: 2px;
        padding: 3px;
        border-radius: 5px;
      }

      body.theme-lively .tool-card-name {
        font-size: 0.65rem;
        margin-bottom: 1px;
        line-height: 1.2;
      }

      body.theme-lively .tool-card-desc {
        font-size: 0.55rem;
        line-height: 1.2;
        margin-top: 0;
      }

      .search-bar {
        margin: 10px auto 0;
        padding: 0 12px;
      }

      .search-bar::before {
        display: none;
      }

      .search-input {
        padding: 10px 12px 10px 40px;
        font-size: 0.9rem;
      }

      .search-bar::after {
        left: 20px;
        width: 18px;
        height: 18px;
        transform: translateY(-50%);
      }
    }

    /* =====================
       PC 端首页 Footer：固定在底部
       ===================== */
    #home-page.active ~ .home-footer {
      position: fixed;
      left: 50%;
      transform: translateX(-50%);
      width: fit-content;
      max-width: 90%;
      bottom: 20px;
      z-index: 60;
      background: transparent;
      border: none;
      box-shadow: none;
      padding: 0;
      margin: 0;
      opacity: 1 !important;
    }

    #home-page.active ~ .home-footer p { margin: 0; text-align: center; }

    /* =====================
       移动端首页 Footer：固定在底部
       ===================== */
    @media (max-width: 900px) {
      .home-footer { display: none !important; }
      #home-page.active ~ .home-footer {
        display: flex !important;
        justify-content: center;
        position: fixed;
        left: 50%;
        transform: translateX(-50%);
        width: fit-content;
        max-width: 95%;
        bottom: calc(env(safe-area-inset-bottom, 0px) + 12px);
        padding: 0;
        z-index: 60;
        background: transparent;
        border: none;
        box-shadow: none;
        margin: 0;
        opacity: 1 !important;
        white-space: nowrap;
      }

      #home-page.active ~ .home-footer p { margin: 0; text-align: center; }
    }

    .quick-nav-item {
        width: 40px;
        height: 40px;
        border-radius: 10px;
      }

      .quick-nav {
        padding: 12px 16px;
        margin-top: 20px;
        margin-bottom: 20px;
      }

      .home-header .logo {
        font-size: 2.5rem;
      }

      .home-header .logo::before {
        width: 200px;
        height: 60px;
      }

      .home-subtitle {
        font-size: 0.8rem;
        margin-top: 6px;
      }

      .tool-header {
        padding: 12px 16px;
      }

      .back-btn {
        padding: 8px 12px;
        font-size: 0.9rem;
      }

      .tool-title {
        font-size: 1rem;
      }

      .tool-dropdown-btn {
        padding: 4px 8px;
        font-size: 0.8rem;
      }

      .tool-dropdown-current svg {
        width: 14px;
        height: 14px;
      }

      .tool-dropdown-menu {
        min-width: 140px;
      }

      .tool-dropdown-item {
        padding: 8px 10px;
        font-size: 0.85rem;
      }

      .tool-dropdown-item svg {
        width: 16px;
        height: 16px;
      }

      .timestamp-display {
        font-size: 1.8rem;
        padding: 18px 14px;
      }

      .digit-flip {
        min-width: 0.7em;
        height: 1.5em;
        font-size: 1.4rem;
      }

      .timestamp-mode {
        gap: 8px;
      }

      .input-field {
        font-size: 0.9rem;
        padding: 10px 10px;
      }

      .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
      }

      .qr-container {
        gap: 12px;
      }

      .qr-preview {
        padding: 12px;
        min-width: 150px;
        min-height: 150px;
      }

      .color-info {
        grid-template-columns: 1fr;
        gap: 8px;
      }

      .color-swatch {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 12px;
      }

      .color-swatch .label {
        margin-bottom: 0;
      }

      .toast {
        top: 16px;
        padding: 10px 16px;
        font-size: 0.85rem;
        left: 10px;
        right: 10px;
        transform: translateX(0) translateY(-100px);
        width: auto;
      }

.toast.show {
        transform: translateX(0) translateY(0);
      }

      .md5-grid {
        grid-template-columns: 1fr;
      }

      .icon-sizes-grid {
        grid-template-columns: repeat(2, 1fr);
      }
    }

    /* Icon Tool Styles */
    .icon-original-preview {
      text-align: center;
    }

    .icon-original-preview img {
      max-width: 200px;
      max-height: 200px;
      border: 1px dashed var(--border-rough);
      border-radius: 3px;
    }

    .icon-sizes-container {
      width: 100%;
    }

    .icon-sizes-grid {
      display: grid;
      /* 小屏幕也保留横向滚动：三行 x 两列 的分页式网格布局 */
      --tool-gap: 14px;
      display: grid;
      grid-auto-flow: column;
      grid-template-rows: repeat(3, auto);
      grid-auto-columns: calc((100% - var(--tool-gap)) / 2);
      gap: var(--tool-gap);
      padding: 12px;
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
      scroll-snap-type: x proximity;
    }

    @media (max-width: 500px) {
      .icon-sizes-grid {
        grid-template-columns: repeat(2, 1fr);
      }
    }

    .icon-size-card {
      display: flex;
      flex-direction: column;
      align-items: center;
      padding: 12px 8px;
      background: #fff;
      border: 2px solid var(--border-rough);
      border-radius: 6px;
      cursor: pointer;
      transition: all 0.2s ease;
      position: relative;
    }

    .icon-size-card:hover {
      border-color: var(--pencil-blue);
      transform: translateY(-2px);
      box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }

    .icon-size-card.selected {
      border-color: var(--pencil-blue);
      background: rgba(74, 111, 165, 0.05);
    }

    .icon-size-card.selected .icon-size-check {
      display: flex;
    }

    .icon-size-preview {
      width: 48px;
      height: 48px;
      display: flex;
      align-items: center;
      justify-content: center;
      margin-bottom: 8px;
    }

    .icon-size-preview canvas {
      max-width: 100%;
      max-height: 100%;
      image-rendering: pixelated;
    }

    .icon-size-label {
      font-size: 0.75rem;
      color: var(--ink-gray);
      font-family: 'JetBrains Mono', monospace;
    }

    .icon-size-check {
      position: absolute;
      top: 4px;
      right: 4px;
      width: 18px;
      height: 18px;
      background: var(--pencil-blue);
      border-radius: 50%;
      display: none;
      align-items: center;
      justify-content: center;
      color: white;
      font-size: 10px;
    }

    .icon-actions {
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding-top: 12px;
      border-top: 1px dashed var(--border-rough);
    }

    #icon-selected-count {
      font-size: 0.85rem;
      color: var(--ink-gray);
    }

    .icon-hint {
      font-size: 0.8rem;
      color: var(--ink-gray);
      text-align: center;
      margin-bottom: 12px;
    }

    /* ==========================================
       Theme Switcher - 主题切换按钮
       ========================================== */
    .theme-switcher {
      display: flex;
      justify-content: center;
    }

    .theme-btn {
      display: flex;
      align-items: center;
      gap: 6px;
      padding: 8px 16px;
      font-family: 'ZCOOL XiaoWei', serif;
      font-size: 0.85rem;
      border: 2px solid var(--border-rough);
      border-radius: 20px;
      background: var(--paper-bg);
      color: var(--ink-black);
      cursor: pointer;
      transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
      box-shadow: 3px 3px 0 var(--paper-shadow);
    }

    .theme-btn:hover {
      transform: translateY(-2px);
      box-shadow: 4px 5px 0 var(--paper-shadow);
      border-color: var(--pencil-blue);
    }

    .theme-btn:active {
      transform: translateY(0);
      box-shadow: 2px 2px 0 var(--paper-shadow);
    }

    .theme-btn:focus-visible {
      outline: 2px solid var(--pencil-blue);
      outline-offset: 2px;
    }

    .theme-icon {
      width: 18px;
      height: 18px;
      stroke: var(--ink-black);
      stroke-width: 2;
      fill: none;
    }

    .theme-label {
      letter-spacing: 0.1em;
    }

    /* ==========================================
       Claymorphism Theme - 黏土拟态风格
       ========================================== */
    body.theme-clay {
      --paper-bg: #FAF7F2;
      --paper-dark: #F0EBE3;
      --paper-shadow: #D4C4B5;
      --ink-black: #3D3D3D;
      --ink-gray: #8B7B6B;
      --pencil-blue: #7EB5B0;
      --pencil-red: #FF8A7A;
      --pencil-green: #7EDAD2;
      --pencil-orange: #FFB347;
      --pencil-purple: #B8A9C9;
      --highlight: #FFF5E6;
      --border-rough: #E0D6C8;
    }

    /* Claymorphism 背景 - 温暖的米白色 */
    body.theme-clay::before {
      background-color: #FAF7F2;
      background-image: none;
    }

    body.theme-clay::after {
      opacity: 0.02;
    }

    /* Claymorphism 字体 */
    body.theme-clay {
      font-family: 'ZCOOL XiaoWei', 'Noto Serif SC', serif;
    }

    body.theme-clay .tool-card-name,
    body.theme-clay .home-header .logo {
      font-family: 'Ma Shan Zheng', cursive;
    }

    /* Claymorphism 卡片 - 软糯圆润 + 暖色调阴影 */
    body.theme-clay .tool-card {
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      border: none;
      border-radius: 28px;
      padding: 24px 18px;
      box-shadow:
        8px 8px 20px rgba(212, 196, 181, 0.5),
        -8px -8px 20px rgba(255, 255, 255, 0.9),
        inset 2px 2px 6px rgba(255, 255, 255, 0.9),
        inset -1px -1px 4px rgba(212, 196, 181, 0.15);
      transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    body.theme-clay .tool-card::before {
      display: none;
    }

    body.theme-clay .tool-card:hover {
      transform: translateY(-6px) scale(1.02);
      box-shadow:
        12px 14px 28px rgba(212, 196, 181, 0.55),
        -8px -8px 20px rgba(255, 255, 255, 0.95),
        inset 3px 3px 8px rgba(255, 255, 255, 0.9),
        inset -2px -2px 5px rgba(212, 196, 181, 0.1);
    }

    body.theme-clay .tool-card:active {
      transform: translateY(-2px) scale(0.99);
      box-shadow:
        6px 6px 16px rgba(212, 196, 181, 0.45),
        -6px -6px 16px rgba(255, 255, 255, 0.85),
        inset 2px 2px 5px rgba(212, 196, 181, 0.12),
        inset -2px -2px 4px rgba(255, 255, 255, 0.8);
    }

    /* Claymorphism 图标容器 - 温暖的珊瑚色/薄荷绿/薰衣草紫 */
    body.theme-clay .tool-card-icon {
      width: 40px;
      height: 40px;
      margin: 0 auto 12px;
      padding: 8px;
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
      border-radius: 18px;
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.45),
        -3px -3px 8px rgba(255, 255, 255, 0.9);
      stroke: #E07A5F;
      transition: transform 0.3s ease;
    }

    body.theme-clay .tool-card:hover .tool-card-icon {
      transform: scale(1.1) rotate(5deg);
    }

    /* Claymorphism 文字 */
    body.theme-clay .tool-card-name {
      font-size: 1rem;
      color: #3D3D3D;
      letter-spacing: 0.05em;
    }

    body.theme-clay .tool-card-desc {
      font-size: 0.8rem;
      color: #8B7B6B;
      margin-top: 6px;
    }

    /* Claymorphism Logo */
    body.theme-clay .home-header .logo {
      font-size: 3.5rem;
      color: #3D3D3D;
      text-shadow: 3px 3px 0 rgba(212, 196, 181, 0.4);
    }

    body.theme-clay .home-header .logo::before {
      background: linear-gradient(145deg, #FFF5E6 0%, #FFE8CC 100%);
      border-radius: 20px;
      box-shadow:
        6px 6px 14px rgba(212, 196, 181, 0.35),
        -3px -3px 10px rgba(255, 255, 255, 0.9);
    }

    body.theme-clay .home-header .logo::after {
      background: linear-gradient(90deg, #FF8A7A, #FFB347);
      height: 5px;
      border-radius: 3px;
    }

    /* Claymorphism 搜索框 */
    body.theme-clay .search-input {
      border: none;
      border-radius: 20px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        6px 6px 14px rgba(212, 196, 181, 0.4),
        -4px -4px 10px rgba(255, 255, 255, 0.95),
        inset 1px 1px 3px rgba(255, 255, 255, 0.9);
      padding: 14px 20px 14px 48px;
      font-family: 'ZCOOL XiaoWei', serif;
    }

    body.theme-clay .search-input:focus {
      box-shadow:
        8px 8px 18px rgba(212, 196, 181, 0.5),
        -5px -5px 14px rgba(255, 255, 255, 0.98),
        inset 2px 2px 4px rgba(255, 255, 255, 0.9);
    }

    body.theme-clay .search-bar::before {
      display: none;
    }

    body.theme-clay .search-bar::after {
      left: calc(50% - 300px);
      width: 22px;
      height: 22px;
      opacity: 0.5;
    }

    /* ==========================================
       Lively Theme - 粘土风格（与演示站配色、按钮、字体风格相近）
       ========================================== */
    body.theme-lively {
      --paper-bg: #FFFFFF;
      --paper-dark: #FFF9F5;
      --paper-shadow: #2D3748;
      --ink-black: #2D3748;
      --ink-gray: #64748B;
      --pencil-blue: #ADD8E6;
      --pencil-red: #FDBCB4;
      --pencil-green: #22C55E;
      --pencil-orange: #F5A69D;
      --pencil-purple: #E6E6FA;
      --highlight: #98FF98;
      --border-rough: #2D3748;
    }

    body.theme-lively::before {
      background-color: var(--paper-dark);
      background-image: none;
    }

    body.theme-lively::after {
      opacity: 0.02;
    }

    body.theme-lively {
      font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    }

    body.theme-lively .tool-card {
      background: #ffffff;
      border: 3px solid var(--ink-black);
      border-radius: 24px;
      padding: 16px 12px;
      box-shadow: 6px 6px 0 var(--ink-black), inset 0 -4px rgba(0, 0, 0, 0.1);
      transition: all 0.2s ease;
    }

    body.theme-lively .tool-card:hover {
      transform: translate(2px, 2px);
      box-shadow: 4px 4px 0 var(--ink-black), inset 0 -4px rgba(0, 0, 0, 0.1);
      border-color: var(--ink-black);
    }

    body.theme-lively .tool-card-icon {
      width: 48px;
      height: 48px;
      margin: 0 auto 12px;
      padding: 12px;
      background: var(--pencil-blue);
      border: 3px solid var(--ink-black);
      border-radius: 16px;
      box-shadow: none;
      stroke: var(--ink-black);
      transition: transform 0.2s ease;
    }

    body.theme-lively .tool-card:hover .tool-card-icon {
      transform: scale(1.08);
    }

    body.theme-lively .tool-card-name {
      font-size: 1.05rem;
      color: var(--ink-black);
      font-family: 'Fredoka', sans-serif;
      font-weight: 700;
    }

    body.theme-lively .tool-card-desc {
      color: var(--ink-gray);
    }

    body.theme-lively .home-header .logo {
      font-family: 'Fredoka', sans-serif;
      font-weight: 700;
      font-size: 3rem;
      color: var(--ink-black);
      text-shadow: none;
    }

    /* Buttons for lively theme: filled primary style */
    body.theme-lively .btn,
    body.theme-lively .theme-btn,
    body.theme-lively .back-btn,
    body.theme-lively .tool-dropdown-btn {
      background: var(--pencil-green);
      color: #fff;
      border: 3px solid var(--ink-black);
      border-radius: 16px;
      box-shadow: 4px 4px 0 var(--ink-black);
      font-family: 'Nunito', sans-serif;
      font-weight: 700;
      transition: all 0.15s ease;
    }

    body.theme-lively .btn:hover,
    body.theme-lively .theme-btn:hover,
    body.theme-lively .back-btn:hover,
    body.theme-lively .tool-dropdown-btn:hover {
      background: #16A34A;
      transform: translate(2px, 2px);
      box-shadow: 2px 2px 0 var(--ink-black);
      color: #fff;
    }

    body.theme-lively .theme-icon,
    body.theme-lively .back-btn svg,
    body.theme-lively .tool-dropdown-btn svg {
      stroke: currentColor;
    }

    body.theme-lively .search-input {
      border-radius: 16px;
      padding: 12px 18px 12px 48px;
      background: #fff;
      border: 3px solid var(--ink-black);
      box-shadow: 4px 4px 0 var(--ink-black);
      font-family: 'Nunito', sans-serif;
      font-weight: 600;
    }

    body.theme-lively .input-field {
      border-radius: 16px;
      padding: 12px 18px;
      background-color: #fff;
      border: 3px solid var(--ink-black);
      box-shadow: 4px 4px 0 var(--ink-black);
      color: var(--ink-black);
      font-family: 'Nunito', sans-serif;
      font-weight: 600;
      transition: all 0.15s ease;
    }

    body.theme-lively textarea.input-field {
      line-height: 1.55;
    }

    body.theme-lively select.input-field {
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%232D3748' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
      background-position: right 16px center;
      padding-right: 42px;
    }

    body.theme-lively .search-input:focus,
    body.theme-lively .input-field:focus {
      outline: none;
      border-color: var(--ink-black);
      box-shadow: 2px 2px 0 var(--ink-black), 0 0 0 4px rgba(173, 216, 230, 0.45);
      transform: translate(2px, 2px);
    }

    body.theme-lively .search-input::placeholder,
    body.theme-lively .input-field::placeholder {
      color: var(--ink-gray);
      opacity: 0.7;
      font-style: normal;
    }

    body.theme-lively .json-output,
    body.theme-lively .result-box {
      background: #fff;
      border: 3px solid var(--ink-black);
      border-radius: 16px;
      box-shadow: 4px 4px 0 var(--ink-black);
      color: var(--ink-black);
      font-family: 'Nunito', sans-serif;
    }

    body.theme-lively .json-tree,
    body.theme-lively #json-output {
      font-family: 'Nunito', sans-serif;
    }

    body.theme-lively .mode-btn.active {
      background: var(--pencil-green);
      color: white;
      border-color: var(--ink-black);
    }

    /* ensure focus outlines remain accessible */
    body.theme-lively .btn:focus-visible,
    body.theme-lively .mode-btn:focus-visible {
      outline: 2px solid rgba(37,99,235,0.18);
      outline-offset: 2px;
    }


    /* Claymorphism 快捷导航 */
    body.theme-clay .quick-nav-item {
      width: 48px;
      height: 48px;
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.4),
        -3px -3px 8px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .quick-nav-item:hover {
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
      transform: translateY(-3px);
      box-shadow:
        6px 8px 14px rgba(212, 196, 181, 0.45),
        -3px -3px 10px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .quick-nav-item:active {
      transform: translateY(0);
      box-shadow:
        3px 3px 6px rgba(212, 196, 181, 0.35),
        -2px -2px 5px rgba(255, 255, 255, 0.9);
    }

    body.theme-clay .quick-nav-item svg {
      stroke: #E07A5F;
    }

    /* Claymorphism 底部导航 */
    body.theme-clay #home-page.active ~ .home-footer {
      background: transparent;
      border: none;
      box-shadow: none;
    }

    /* Claymorphism 主题切换按钮 */
    body.theme-clay .theme-btn {
      border: none;
      border-radius: 20px;
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
      color: #3D3D3D;
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.45),
        -3px -3px 8px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .theme-btn:hover {
      background: linear-gradient(145deg, #7EDAD2 0%, #5FC7C0 100%);
      color: white;
      box-shadow:
        6px 8px 14px rgba(212, 196, 181, 0.5),
        -3px -3px 10px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .theme-btn:hover .theme-icon {
      stroke: white;
    }

    body.theme-clay .theme-icon {
      stroke: #E07A5F;
    }

    /* Claymorphism Toast */
    body.theme-clay .toast {
      background: linear-gradient(145deg, #3D3D3D 0%, #2D2D2D 100%);
      border-radius: 16px;
      box-shadow:
        6px 6px 16px rgba(212, 196, 181, 0.4),
        -4px -4px 12px rgba(255, 255, 255, 0.1);
    }

    /* Claymorphism 输入框 */
    body.theme-clay .input-field {
      border: none;
      border-radius: 14px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        inset 3px 3px 6px rgba(212, 196, 181, 0.2),
        inset -2px -2px 4px rgba(255, 255, 255, 0.9);
      font-family: 'ZCOOL XiaoWei', serif;
    }

    body.theme-clay .input-field:focus {
      box-shadow:
        inset 3px 3px 6px rgba(212, 196, 181, 0.2),
        inset -2px -2px 4px rgba(255, 255, 255, 0.9),
        0 0 0 3px rgba(224, 122, 95, 0.15);
    }

    /* Claymorphism 按钮 - 温暖的珊瑚色/薄荷绿/薰衣草 */
    body.theme-clay .btn {
      border: none;
      border-radius: 14px;
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
      color: #3D3D3D;
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.4),
        -3px -3px 8px rgba(255, 255, 255, 0.95);
      font-family: 'ZCOOL XiaoWei', serif;
    }

    body.theme-clay .btn:hover {
      background: linear-gradient(145deg, #7EDAD2 0%, #5FC7C0 100%);
      color: white;
    }

    body.theme-clay .btn:active {
      box-shadow:
        2px 2px 5px rgba(212, 196, 181, 0.35),
        -2px -2px 4px rgba(255, 255, 255, 0.9);
      transform: translateY(1px);
    }

    /* Claymorphism 时间戳显示 */
    body.theme-clay .timestamp-display {
      background: linear-gradient(145deg, #FFF5E6 0%, #FFE8CC 100%);
      border: none;
      border-radius: 20px;
      box-shadow:
        6px 6px 14px rgba(212, 196, 181, 0.35),
        -4px -4px 10px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .digit-flip {
      background: linear-gradient(145deg, #3D3D3D 0%, #2D2D2D 100%);
      border-radius: 8px;
      box-shadow:
        3px 3px 6px rgba(61, 61, 61, 0.3),
        -2px -2px 4px rgba(100, 100, 100, 0.2);
    }

    /* Claymorphism Mode 按钮 */
    body.theme-clay .mode-btn {
      border: none;
      border-radius: 12px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        3px 3px 6px rgba(212, 196, 181, 0.35),
        -2px -2px 5px rgba(255, 255, 255, 0.9);
    }

    body.theme-clay .mode-btn:hover {
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
    }

    body.theme-clay .mode-btn.active {
      background: linear-gradient(145deg, #FF8A7A 0%, #E07A5F 100%);
      color: white;
    }

    /* Claymorphism 二维码预览 */
    body.theme-clay .qr-preview {
      border: none;
      border-radius: 20px;
      background: white;
      box-shadow:
        inset 4px 4px 8px rgba(212, 196, 181, 0.15),
        4px 4px 10px rgba(212, 196, 181, 0.25);
    }

    /* Claymorphism 文件上传区 */
    body.theme-clay .file-upload {
      border: none;
      border-radius: 20px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        6px 6px 14px rgba(212, 196, 181, 0.35),
        -4px -4px 10px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .file-upload:hover {
      background: linear-gradient(145deg, #B8A9C9 0%, #A090B5 100%);
    }

    body.theme-clay .file-upload:hover svg {
      stroke: white;
    }

    /* Claymorphism 颜色选择器 */
    body.theme-clay .color-preview-box {
      border: none;
      border-radius: 20px;
      box-shadow:
        inset 4px 4px 8px rgba(212, 196, 181, 0.15),
        4px 4px 12px rgba(212, 196, 181, 0.25);
    }

    body.theme-clay .color-swatch {
      border: none;
      border-radius: 14px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        3px 3px 8px rgba(212, 196, 181, 0.3),
        -2px -2px 6px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .recent-color {
      border: none;
      border-radius: 10px;
      box-shadow:
        2px 2px 5px rgba(212, 196, 181, 0.35),
        -1px -1px 3px rgba(255, 255, 255, 0.9);
    }

    /* Claymorphism JSON 树 */
    body.theme-clay .json-output {
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        inset 3px 3px 8px rgba(212, 196, 181, 0.15),
        3px 3px 6px rgba(212, 196, 181, 0.15);
    }

    body.theme-clay .j-toggle:hover {
      background: rgba(224, 122, 95, 0.1);
      border-radius: 4px;
    }

    /* Claymorphism MD5 项目 */
    body.theme-clay .md5-item {
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.3),
        -3px -3px 8px rgba(255, 255, 255, 0.95);
    }

    /* Claymorphism Icon 尺寸卡片 */
    body.theme-clay .icon-size-card {
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        4px 4px 10px rgba(212, 196, 181, 0.3),
        -3px -3px 8px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .icon-size-card:hover {
      transform: translateY(-3px);
      box-shadow:
        6px 8px 14px rgba(212, 196, 181, 0.4),
        -3px -3px 10px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .icon-size-card.selected {
      background: linear-gradient(145deg, #7EDAD2 0%, #5FC7C0 100%);
    }

    body.theme-clay .icon-size-card.selected .icon-size-check {
      background: white;
      color: #5FC7C0;
    }

    /* Claymorphism 工具页头部 */
    body.theme-clay .tool-header {
      background: linear-gradient(145deg, rgba(255,255,255,0.98) 0%, rgba(253,252,250,0.98) 100%);
      border: none;
      box-shadow: 0 4px 16px rgba(212, 196, 181, 0.2);
    }

    body.theme-clay .back-btn {
      border: none;
      border-radius: 14px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        3px 3px 8px rgba(212, 196, 181, 0.35),
        -2px -2px 6px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .back-btn:hover {
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
    }

    body.theme-clay .tool-dropdown-btn {
      border: none;
      border-radius: 14px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        3px 3px 6px rgba(212, 196, 181, 0.3),
        -2px -2px 5px rgba(255, 255, 255, 0.9);
    }

    body.theme-clay .tool-dropdown-btn:hover {
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
    }

    body.theme-clay .tool-dropdown-menu {
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        8px 8px 20px rgba(212, 196, 181, 0.35),
        -5px -5px 14px rgba(255, 255, 255, 0.95);
    }

    body.theme-clay .tool-dropdown-item:hover {
      background: linear-gradient(145deg, #FFE5DC 0%, #FFCFC5 100%);
    }

    body.theme-clay .tool-dropdown-item.active {
      background: linear-gradient(145deg, #7EDAD2 0%, #5FC7C0 100%);
      color: white;
    }

    /* Claymorphism 滚动条 */
    body.theme-clay ::-webkit-scrollbar-track {
      background: rgba(212, 196, 181, 0.15);
      border-radius: 10px;
    }

    body.theme-clay ::-webkit-scrollbar-thumb {
      background: linear-gradient(145deg, #D4C4B5 0%, #C4B4A5 100%);
      border-radius: 10px;
    }

    body.theme-clay ::-webkit-scrollbar-thumb:hover {
      background: linear-gradient(145deg, #B8A9C9 0%, #A090B5 100%);
    }

    /* Claymorphism 调整大小预览框 */
    body.theme-clay .resize-preview-box {
      border: none;
      border-radius: 20px;
      background: white;
      box-shadow:
        inset 4px 4px 8px rgba(212, 196, 181, 0.15),
        4px 4px 10px rgba(212, 196, 181, 0.2);
    }

    /* Claymorphism 结果框 */
    body.theme-clay .result-box {
      border: none;
      border-radius: 16px;
      background: linear-gradient(145deg, #ffffff 0%, #FDFCFA 100%);
      box-shadow:
        inset 3px 3px 6px rgba(212, 196, 181, 0.12),
        2px 2px 4px rgba(212, 196, 181, 0.1);
    }

    /* Claymorphism 移动端适配 */
    @media (max-width: 480px) {
      body.theme-clay .home-header .logo {
        font-size: 2.5rem;
      }

      body.theme-clay .tool-card {
        padding: 12px 10px;
        border-radius: 22px;
      }

      body.theme-clay .tool-card-icon {
        width: 32px;
        height: 32px;
        padding: 6px;
        border-radius: 14px;
      }

      body.theme-clay .search-input {
        padding: 12px 16px 12px 44px;
        border-radius: 16px;
      }

      body.theme-clay .search-bar::after {
        left: 22px;
        width: 18px;
        height: 18px;
      }

      body.theme-clay .quick-nav-item {
        width: 42px;
        height: 42px;
        border-radius: 14px;
      }

      body.theme-clay .theme-btn {
        padding: 6px 14px;
        font-size: 0.8rem;
      }
    }
