:root {
        --paypal: #0a5ea8;
        --momo: #a50064;
      }

      * {
        box-sizing: border-box;
      }

      html {
        scroll-behavior: smooth;
      }

      body {
        margin: 0;
        background: var(--bg);
        color: var(--fg);
        font: 15px/1.6 Roboto, Arial, sans-serif;
      }

      svg {
        width: 18px;
        height: 18px;
        fill: none;
        stroke: currentColor;
        stroke-width: 2;
        stroke-linecap: round;
        stroke-linejoin: round;
        flex: none;
      }

      /* ------------------------------------------------------------ header */

      .hero {
        border-bottom: 1px solid var(--line);
        background: var(--surface);
      }

      .hero-inner {
        display: flex;
        align-items: center;
        gap: 16px;
        max-width: 1000px;
        margin: 0 auto;
        padding: 36px 24px 32px;
      }

      .mark {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 52px;
        height: 52px;
        border-radius: 14px;
        background: var(--accent);
        color: #fff;
        flex: none;
      }

      .mark svg {
        width: 28px;
        height: 28px;
        stroke-width: 2.4;
      }

      h1 {
        margin: 0;
        font-size: 26px;
        font-weight: 800;
        letter-spacing: -0.2px;
      }

      .tagline {
        margin: 2px 0 0;
        color: var(--muted);
      }

      /* ------------------------------------------------------------ layout */

      .layout {
        max-width: 1000px;
        margin: 0 auto;
        padding: 0 24px 72px;
      }

      .toc-label {
        margin: 0 0 8px;
        color: var(--muted);
        font-size: 11px;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
      }

      .toc ol {
        margin: 0;
        padding: 0;
        list-style: none;
      }

      .toc a {
        display: block;
        color: var(--muted);
        font-size: 13.5px;
        text-decoration: none;
      }

      .toc a:hover {
        color: var(--fg);
      }

      .toc a.current {
        color: var(--accent-text);
        font-weight: 600;
      }

      /* Narrow tabs: the contents are a row of chips above the first section. */
      .toc {
        padding: 20px 0 4px;
      }

      .toc ol {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
      }

      .toc a {
        padding: 4px 12px;
        border: 1px solid var(--line);
        border-radius: 999px;
      }

      .toc a.current {
        border-color: var(--accent);
      }

      /* Wide tabs: a sticky list beside the reading column. */
      @media (min-width: 900px) {
        .layout {
          display: grid;
          grid-template-columns: 200px minmax(0, 720px);
          gap: 48px;
        }

        .toc {
          position: sticky;
          top: 0;
          align-self: start;
          padding: 36px 0 0;
        }

        .toc ol {
          display: block;
          border-left: 1px solid var(--line);
        }

        .toc a {
          margin-left: -1px;
          padding: 5px 0 5px 14px;
          border: none;
          border-left: 2px solid transparent;
          border-radius: 0;
        }

        .toc a.current {
          border-left-color: var(--accent);
        }
      }

      main {
        min-width: 0;
      }

      /* Room below the last section, so it too can scroll to the top and be marked in the contents. */
      main::after {
        content: '';
        display: block;
        height: 50vh;
      }

      /* ---------------------------------------------------------- sections */

      section {
        padding: 36px 0 8px;
        scroll-margin-top: 12px;
      }

      section + section {
        border-top: 1px solid var(--line);
      }

      h2 {
        display: flex;
        align-items: center;
        gap: 12px;
        margin: 0 0 16px;
        font-size: 20px;
        font-weight: 700;
      }

      .icon {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        border-radius: 9px;
        background: var(--accent);
        color: #fff;
        flex: none;
      }

      h3 {
        margin: 0 0 4px;
        font-size: 15px;
        font-weight: 700;
      }

      p {
        margin: 0 0 14px;
      }

      .muted {
        color: var(--muted);
      }

      .grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
        gap: 12px;
        margin-bottom: 18px;
      }

      .card {
        padding: 16px;
        border: 1px solid var(--line);
        border-radius: 12px;
        background: var(--surface);
      }

      .card p {
        margin: 0;
        color: var(--muted);
        font-size: 14px;
      }

      .card .num {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 24px;
        height: 24px;
        margin-bottom: 8px;
        border-radius: 50%;
        background: var(--accent-soft);
        color: var(--accent-text);
        font-size: 13px;
        font-weight: 700;
      }

      .best {
        margin-top: 10px !important;
        color: var(--fg) !important;
      }

      .best b {
        color: var(--accent-text);
      }

      ul.steps {
        margin: 0 0 18px;
        padding: 0;
        list-style: none;
      }

      ul.steps li {
        position: relative;
        margin-bottom: 10px;
        padding-left: 22px;
      }

      ul.steps li::before {
        content: '';
        position: absolute;
        top: 0.62em;
        left: 4px;
        width: 7px;
        height: 7px;
        border-radius: 50%;
        background: var(--accent);
      }

      .tip {
        display: flex;
        gap: 10px;
        margin: 0 0 18px;
        padding: 12px 14px;
        border: 1px solid var(--accent);
        border-radius: 10px;
        background: var(--accent-soft);
        font-size: 14px;
      }

      .tip svg {
        margin-top: 2px;
        color: var(--accent-text);
      }

      /* --------------------------------------------------- troubleshooting */

      details {
        border: 1px solid var(--line);
        border-radius: 10px;
        margin-bottom: 8px;
      }

      summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 12px 14px;
        font-weight: 600;
        cursor: pointer;
        list-style: none;
      }

      summary::-webkit-details-marker {
        display: none;
      }

      summary:hover {
        color: var(--accent-text);
      }

      summary svg {
        transition: transform 0.15s;
        color: var(--muted);
      }

      details[open] summary svg {
        transform: rotate(180deg);
      }

      details p {
        margin: 0;
        padding: 0 14px 14px;
        color: var(--muted);
      }

      /* ----------------------------------------------------------- buttons */

      .button {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 8px 18px;
        border-radius: 18px;
        background: var(--accent);
        color: #fff;
        font-weight: 600;
        font-size: 14px;
        text-decoration: none;
      }

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

      .button svg {
        width: 16px;
        height: 16px;
      }

      /* ------------------------------------------------------------ donate */

      .donate-blocks {
        display: flex;
        flex-wrap: wrap;
        gap: 16px;
        margin-bottom: 18px;
      }

      .donate-card {
        flex: 1 1 220px;
        padding: 16px;
        border: 1px solid var(--line);
        border-radius: 12px;
        background: var(--surface);
        text-align: center;
      }

      .donate-badge {
        display: inline-block;
        margin-bottom: 12px;
        padding: 4px 14px;
        border-radius: 999px;
        color: #fff;
        font-weight: 700;
        font-size: 13px;
      }

      .donate-badge.paypal {
        background: var(--paypal);
      }

      .donate-badge.momo {
        background: var(--momo);
      }

      .donate-card img {
        display: block;
        width: 140px;
        height: 140px;
        margin: 0 auto 12px;
        border-radius: 6px;
        background: #fff;
      }

      .donate-destination-label {
        margin: 0;
        color: var(--muted);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.03em;
      }

      .donate-destination-value {
        margin: 2px 0 12px;
        font-weight: 600;
        word-break: break-all;
      }

      .copy-btn {
        width: 100%;
        height: 30px;
        border: 1px solid var(--line);
        border-radius: 15px;
        background: var(--field);
        color: var(--fg);
        font: 600 12px Roboto, Arial, sans-serif;
        cursor: pointer;
      }

      .copy-btn:hover {
        border-color: var(--accent);
      }

      .copy-btn[data-copied="true"] {
        border-color: var(--ok);
        color: var(--ok);
      }

      /* ----------------------------------------------------------- welcome */

      /* Shown only on the tab opened at first install (support.html?welcome=1). */
      .welcome[hidden],
      .pin-tip[hidden] {
        display: none;
      }

      .welcome {
        max-width: 1000px;
        margin: 24px auto 0;
        padding: 0 24px;
      }

      .welcome-box {
        padding: 22px 22px 20px;
        border: 1px solid var(--accent);
        border-radius: 14px;
        background: var(--accent-soft);
      }

      .welcome h2 {
        margin-bottom: 14px;
      }

      .welcome ol {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
        gap: 10px;
        margin: 0 0 18px;
        padding: 0;
        list-style: none;
        counter-reset: step;
      }

      .welcome li {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 12px 14px;
        border-radius: 10px;
        background: var(--surface);
        font-weight: 500;
        counter-increment: step;
      }

      .welcome li::before {
        content: counter(step);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 24px;
        height: 24px;
        border-radius: 50%;
        background: var(--accent);
        color: #fff;
        font-size: 13px;
        font-weight: 700;
        flex: none;
      }

      .welcome .button {
        border: none;
        font: inherit;
        font-weight: 600;
        cursor: pointer;
      }

      .pin-tip {
        margin: 16px 0 0;
        background: var(--surface);
      }

      .pin-tip p {
        margin: 0;
      }

      @media (max-width: 480px) {
        .hero-inner {
          padding: 28px 16px 24px;
        }

        .layout {
          padding: 0 16px 56px;
        }

        .welcome {
          padding: 0 16px;
        }
      }