:root {
      --bg: #0c0a08;
      --bg-raise: #161310;
      --bg-card: rgba(28, 24, 18, 0.78);
      --cream: #f3ebdd;
      --cream-soft: #d9cbb6;
      --muted: #bcb09c;
      --muted-dim: #9a8e7b;
      --line: rgba(243, 235, 221, 0.1);
      --line-strong: rgba(243, 235, 221, 0.16);
      --amber: #e8a54b;
      --amber-hot: #ffc36a;
      --amber-deep: #c4842e;
      --amber-glow: rgba(232, 165, 75, 0.22);
      --amber-soft: rgba(232, 165, 75, 0.12);
      --good: #c6d4a8;
      --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
      --radius: 22px;
      --radius-sm: 14px;
      --font-bn: "Hind Siliguri", "Noto Sans Bengali", sans-serif;
      --font-hi: "Hind", "Noto Sans Devanagari", "Hind Siliguri", sans-serif;
      --font-en: "Syne", "Hind Siliguri", sans-serif;
      --space: 8px;
      --content: 720px;
      --header-h: 72px;
    }

    * { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; scroll-padding-top: 84px; }
    body {
      min-height: 100vh;
      font-family: var(--font-bn);
      background: var(--bg);
      color: var(--cream);
      line-height: 1.6;
      -webkit-font-smoothing: antialiased;
      text-rendering: optimizeLegibility;
      overflow-x: hidden;
    }
    body::before {
      content: "";
      position: fixed;
      inset: 0;
      pointer-events: none;
      z-index: 0;
      background:
        radial-gradient(900px 520px at 50% -8%, rgba(232, 165, 75, 0.16), transparent 60%),
        radial-gradient(700px 400px at 110% 20%, rgba(232, 165, 75, 0.05), transparent 50%),
        radial-gradient(600px 500px at -10% 80%, rgba(90, 60, 20, 0.2), transparent 55%);
    }
    body::after {
      content: "";
      position: fixed;
      inset: 0;
      pointer-events: none;
      z-index: 1;
      opacity: 0.09;
      background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
      mix-blend-mode: overlay;
    }

    .wrap {
      position: relative;
      z-index: 2;
      width: min(var(--content), calc(100% - 40px));
      margin: 0 auto;
    }

    /* Header */
    header {
      position: sticky;
      top: 0;
      z-index: 20;
      backdrop-filter: blur(18px);
      -webkit-backdrop-filter: blur(18px);
      background: #0c0a08;
      border-bottom: 1px solid transparent;
    }
    header.scrolled { border-bottom-color: var(--line); }
    .header-inner {
      width: min(var(--content), calc(100% - 40px));
      margin: 0 auto;
      min-height: var(--header-h);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
    }
    .brand {
      display: flex;
      align-items: center;
      gap: 10px;
      color: inherit;
      text-decoration: none;
    }
    .mark {
      width: 36px;
      height: 36px;
      flex: none;
    }
    .wordmark {
      font-family: var(--font-en);
      font-weight: 700;
      font-size: 1.2rem;
      letter-spacing: -0.04em;
      line-height: 1;
    }
    .wordmark span { color: var(--amber); }

    .header-actions { display: flex; align-items: center; gap: 10px; }
    .lang-switch { position: relative; }
    .lang-switch-btn {
      appearance: none;
      display: inline-flex;
      align-items: center;
      gap: 8px;
      background: rgba(243, 235, 221, 0.05);
      border: 1px solid var(--line-strong);
      border-radius: 999px;
      color: var(--cream);
      font-family: var(--font-en);
      font-weight: 650;
      font-size: 0.78rem;
      letter-spacing: 0.02em;
      padding: 7px 12px 7px 14px;
      cursor: pointer;
      min-height: 36px;
    }
    .lang-switch-btn .chevron { opacity: 0.7; transition: transform 0.18s ease; }
    .lang-switch.open .lang-switch-btn { border-color: var(--amber); background: var(--amber-soft); }
    .lang-switch.open .lang-switch-btn .chevron { transform: rotate(180deg); }
    .lang-menu {
      position: absolute;
      right: 0;
      top: calc(100% + 8px);
      min-width: 168px;
      margin: 0;
      padding: 6px;
      list-style: none;
      background: #161310;
      border: 1px solid var(--line-strong);
      border-radius: 16px;
      box-shadow: var(--shadow);
      z-index: 30;
    }
    .lang-menu[hidden] { display: none; }
    .lang-menu button {
      appearance: none;
      width: 100%;
      text-align: left;
      border: 0;
      background: transparent;
      color: var(--cream-soft);
      font-family: var(--font-en);
      font-weight: 600;
      font-size: 0.88rem;
      padding: 8px 12px;
      border-radius: 10px;
      cursor: pointer;
    }
    .lang-menu li[aria-selected="true"] button,
    .lang-menu button[aria-pressed="true"] {
      background: var(--cream);
      color: #1a140c;
    }
    .lang-menu button:hover { background: rgba(243, 235, 221, 0.08); }
    .lang-menu li[aria-selected="true"] button:hover { background: var(--cream); }
    html[lang="bn"] .lang-switch-btn, html[lang="bn"] .lang-menu button[data-lang-btn="bn"] { font-family: var(--font-bn); }
    html[lang="hi"] .lang-switch-btn, html[lang="hi"] .lang-menu button[data-lang-btn="hi"] { font-family: var(--font-hi); }

    html[lang="hi"] body { font-family: var(--font-hi); }
    html[lang="hi"] h1, html[lang="hi"] h2, html[lang="hi"] h3, html[lang="hi"] .section-title {
      font-family: var(--font-hi);
    }

    /* Hero */
    .hero {
      padding: 36px 0 28px;
      text-align: center;
    }
    .kicker {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      font-size: 0.8rem;
      font-weight: 600;
      color: var(--amber);
      letter-spacing: 0.04em;
      margin-bottom: 18px;
    }
    .kicker i {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: var(--amber-hot);
      box-shadow: 0 0 0 0 rgba(255, 195, 106, 0.7);
      animation: tally 1.8s ease-out infinite;
    }
    @keyframes tally {
      0% { box-shadow: 0 0 0 0 rgba(255, 195, 106, 0.65); }
      70% { box-shadow: 0 0 0 10px rgba(255, 195, 106, 0); }
      100% { box-shadow: 0 0 0 0 rgba(255, 195, 106, 0); }
    }
    h1 {
      font-weight: 700;
      font-size: clamp(2rem, 6.2vw, 3.05rem);
      line-height: 1.12;
      letter-spacing: -0.03em;
      margin: 0 0 16px;
      color: var(--cream);
      text-wrap: balance;
    }
    html[lang="en"] h1, html[lang="es"] h1, html[lang="pt"] h1,
    html[lang="en"] .wordmark, html[lang="es"] .wordmark, html[lang="pt"] .wordmark,
    html[lang="en"] .feat h3, html[lang="es"] .feat h3, html[lang="pt"] .feat h3,
    html[lang="en"] .section-title, html[lang="es"] .section-title, html[lang="pt"] .section-title {
      font-family: var(--font-en);
    }
    html[lang="bn"] h1, html[lang="hi"] h1 { letter-spacing: -0.02em; line-height: 1.22; }
    .lede {
      font-size: 1.05rem;
      color: var(--cream-soft);
      max-width: 40em;
      margin: 0 auto 28px;
      text-wrap: pretty;
      font-weight: 400;
    }
    html[lang="bn"] .lede { font-size: 1.12rem; line-height: 1.75; }

    /* Paste dock */
    .dock {
      text-align: left;
      background: var(--bg-card);
      border: 1px solid var(--line-strong);
      border-radius: var(--radius);
      padding: 10px;
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      box-shadow: var(--shadow), inset 0 1px 0 rgba(243, 235, 221, 0.05);
      transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
    }
    .dock:focus-within {
      border-color: rgba(232, 165, 75, 0.55);
      box-shadow: var(--shadow), 0 0 0 6px var(--amber-glow);
      transform: translateY(-2px);
    }
    .dock-row {
      display: flex;
      align-items: stretch;
      gap: 8px;
    }
    .field {
      flex: 1;
      min-width: 0;
      position: relative;
    }
    .field input {
      width: 100%;
      height: 56px;
      border: 0;
      background: transparent;
      color: var(--cream);
      font-family: inherit;
      font-size: 1rem;
      padding: 0 8px 0 16px;
      outline: none;
    }
    .field input::placeholder { color: var(--muted-dim); }
    .btn {
      appearance: none;
      border: 0;
      cursor: pointer;
      font-family: inherit;
      font-weight: 600;
      border-radius: 14px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      transition: transform 0.15s, background 0.15s, color 0.15s, border-color 0.15s;
      white-space: nowrap;
    }
    .btn:active { transform: translateY(1px) scale(0.98); }
    .btn-ghost {
      background: rgba(243, 235, 221, 0.06);
      color: var(--cream-soft);
      border: 1px solid var(--line);
      height: 56px;
      padding: 0 16px;
      font-size: 0.95rem;
    }
    .btn-ghost:hover { background: rgba(243, 235, 221, 0.1); }
    .btn-primary {
      background: linear-gradient(180deg, var(--amber-hot) 0%, var(--amber) 100%);
      color: #1a140c;
      height: 56px;
      padding: 0 22px;
      font-size: 1rem;
      box-shadow: 0 8px 24px rgba(232, 165, 75, 0.25);
    }
    .btn-primary:hover { filter: brightness(1.05); }
    .btn-primary.busy { pointer-events: none; opacity: 0.85; }
    .dock-foot {
      padding: 10px 8px 4px 16px;
      color: var(--muted);
      font-size: 0.86rem;
      text-align: left;
    }
    .demo-link {
      display: inline-flex;
      margin-top: 16px;
      appearance: none;
      border: 0;
      background: none;
      color: var(--amber);
      font-family: inherit;
      font-weight: 600;
      cursor: pointer;
      font-size: 0.92rem;
      text-decoration: underline;
      text-underline-offset: 3px;
      text-underline-offset: 4px;
    }
    .demo-link:hover { color: var(--amber-hot); }

    /* Result */
    .result {
      display: none;
      margin-top: 18px;
      background: var(--bg-card);
      border: 1px solid var(--line-strong);
      border-radius: var(--radius);
      overflow: hidden;
      box-shadow: var(--shadow);
      backdrop-filter: blur(20px);
      animation: rise 0.45s ease both;
    }
    .result.show { display: block; }
    @keyframes rise {
      from { opacity: 0; transform: translateY(14px); }
      to { opacity: 1; transform: none; }
    }
    .result-top {
      display: grid;
      grid-template-columns: 168px 1fr;
      gap: 0;
    }
    .thumb {
      position: relative;
      min-height: 168px;
      background:
        linear-gradient(180deg, rgba(12,10,8,0.15), rgba(12,10,8,0.55)),
        linear-gradient(135deg, #3a2a16 0%, #1a140e 40%, #2a2010 70%, #4a3518 100%);
      display: flex;
      align-items: center;
      justify-content: center;
      overflow: hidden;
    }
    .thumb::before, .thumb::after {
      content: "";
      position: absolute;
      top: 0;
      bottom: 0;
      width: 14px;
      background-image: repeating-linear-gradient(
        to bottom,
        #0c0a08 0 8px,
        transparent 8px 16px,
        #0c0a08 16px 22px
      );
      opacity: 0.7;
    }
    .thumb::before { left: 0; }
    .thumb::after { right: 0; }
    .thumb .sun {
      width: 54px;
      height: 54px;
      border-radius: 50%;
      background: radial-gradient(circle at 35% 35%, #ffdFA0, #e8a54b 55%, #8a5a18 100%);
      box-shadow: 0 0 40px rgba(232, 165, 75, 0.45);
      transform: translate(18px, -16px);
    }
    .demo-pill {
      position: absolute;
      top: 10px;
      left: 22px;
      z-index: 2;
      font-family: var(--font-en);
      font-size: 0.65rem;
      font-weight: 700;
      letter-spacing: 0.14em;
      background: rgba(12, 10, 8, 0.75);
      color: var(--amber-hot);
      border: 1px solid rgba(232, 165, 75, 0.45);
      padding: 4px 8px;
      border-radius: 999px;
    }
    .play {
      position: absolute;
      width: 46px;
      height: 46px;
      border-radius: 50%;
      background: rgba(12, 10, 8, 0.55);
      border: 1px solid rgba(243, 235, 221, 0.25);
      display: grid;
      place-items: center;
    }
    .play svg { margin-left: 2px; }
    .meta { padding: 18px 20px 16px; text-align: left; }
    .meta h2 {
      font-size: 1.15rem;
      font-weight: 700;
      letter-spacing: -0.02em;
      line-height: 1.3;
      margin-bottom: 6px;
    }
    .meta p { color: var(--muted); font-size: 0.9rem; }
    .filename {
      margin-top: 12px;
      display: inline-block;
      font-size: 0.75rem;
      color: var(--cream-soft);
      background: rgba(243, 235, 221, 0.05);
      border: 1px solid var(--line);
      padding: 4px 8px;
      border-radius: 8px;
      font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
      letter-spacing: -0.02em;
      word-break: break-all;
    }
    .qualities {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 8px;
      padding: 0 16px 16px;
    }
    .q {
      text-align: left;
      background: rgba(243, 235, 221, 0.04);
      border: 1px solid var(--line);
      color: var(--cream);
      border-radius: 14px;
      padding: 12px 14px;
      cursor: pointer;
      font-family: inherit;
      transition: border-color 0.15s, background 0.15s;
    }
    .q:last-child:nth-child(odd) { grid-column: 1 / -1; }
    .q strong { display: block; font-size: 0.95rem; font-weight: 650; }
    .q span { display: block; font-size: 0.78rem; color: var(--muted); margin-top: 2px; }
    .q[aria-pressed="true"] {
      border-color: var(--amber);
      background: var(--amber-soft);
    }
    .q[aria-pressed="true"] strong { color: var(--amber-hot); }
    .demo-note {
      margin: 0 16px 16px;
      padding: 10px 12px;
      border-radius: 12px;
      background: rgba(232, 165, 75, 0.08);
      border: 1px dashed rgba(232, 165, 75, 0.35);
      color: var(--cream-soft);
      font-size: 0.86rem;
      text-align: left;
    }
    .result .btn-primary { width: calc(100% - 32px); margin: 0 16px 16px; height: 50px; }

    /* Sections */
    section { padding: 28px 0; }
    .section-title {
      font-size: 1.45rem;
      font-weight: 700;
      letter-spacing: -0.03em;
      margin-bottom: 18px;
      text-align: center;
    }
    html[lang="bn"] .section-title { font-size: 1.55rem; }

    .steps {
      display: grid;
      gap: 12px;
    }
    .step {
      display: grid;
      grid-template-columns: 52px 1fr;
      gap: 14px;
      align-items: start;
      padding: 18px 18px 18px 16px;
      background: rgba(243, 235, 221, 0.03);
      border: 1px solid var(--line);
      border-radius: 18px;
    }
    .step-num {
      width: 52px;
      height: 52px;
      border-radius: 16px;
      display: grid;
      place-items: center;
      font-family: var(--font-hi);
      font-weight: 700;
      font-size: 1.25rem;
      font-variant-numeric: lining-nums;
      color: #1a140c;
      background: linear-gradient(180deg, var(--amber-hot), var(--amber));
    }
    .step h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 4px; }
    .step p { color: var(--muted); font-size: 0.94rem; }

    .features {
      display: grid;
      gap: 12px;
    }
    .feat {
      padding: 20px 18px;
      border-radius: 18px;
      border: 1px solid var(--line);
      background: rgba(243, 235, 221, 0.03);
    }
    .feat .icon {
      width: 36px;
      height: 36px;
      border-radius: 10px;
      background: var(--amber-soft);
      color: var(--amber);
      display: grid;
      place-items: center;
      margin-bottom: 12px;
    }
    .feat h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 6px; }
    .feat p { color: var(--muted); font-size: 0.94rem; }

    /* FAQ */
    .faq { display: grid; gap: 8px; }
    .faq-item {
      border: 1px solid var(--line);
      border-radius: 16px;
      background: rgba(243, 235, 221, 0.03);
      overflow: hidden;
    }
    .faq-item button {
      width: 100%;
      text-align: left;
      background: none;
      border: 0;
      color: var(--cream);
      font-family: inherit;
      font-size: 1rem;
      font-weight: 650;
      padding: 16px 48px 16px 18px;
      cursor: pointer;
      position: relative;
    }
    .faq-item button::after {
      content: "";
      position: absolute;
      right: 18px;
      top: 50%;
      width: 10px;
      height: 10px;
      border-right: 1.5px solid var(--muted);
      border-bottom: 1.5px solid var(--muted);
      transform: translateY(-70%) rotate(45deg);
      transition: transform 0.2s;
    }
    .faq-item.open button::after { transform: translateY(-30%) rotate(225deg); }
    .faq-item .ans {
      display: none;
      padding: 0 18px 16px;
      color: var(--muted);
      font-size: 0.95rem;
    }
    .faq-item.open .ans { display: block; }

    footer {
      border-top: 1px solid var(--line);
      padding: 36px 0 48px;
      margin-top: 20px;
      color: var(--muted);
      font-size: 0.9rem;
    }
    .foot-brand {
      display: flex;
      align-items: center;
      gap: 10px;
      margin-bottom: 10px;
      color: var(--cream);
    }
    .foot-brand .wordmark { font-size: 1.05rem; }
    .legal {
      display: flex;
      flex-wrap: wrap;
      gap: 8px 18px;
      margin: 18px 0;
    }
    .legal a { color: var(--cream-soft); text-decoration: none; }
    .legal a:hover { color: var(--amber); text-decoration: underline; text-underline-offset: 3px; }
    .copy { color: var(--muted-dim); font-size: 0.82rem; }

    .toast {
      position: fixed;
      left: 50%;
      bottom: 24px;
      transform: translateX(-50%) translateY(20px);
      background: var(--cream);
      color: #1a140c;
      padding: 12px 16px;
      border-radius: 12px;
      font-weight: 600;
      font-size: 0.9rem;
      opacity: 0;
      pointer-events: none;
      z-index: 40;
      transition: opacity 0.25s, transform 0.25s;
      box-shadow: var(--shadow);
      max-width: calc(100% - 32px);
      text-align: center;
    }
    .toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

    .spin {
      width: 16px;
      height: 16px;
      border: 2px solid rgba(26, 20, 12, 0.25);
      border-top-color: #1a140c;
      border-radius: 50%;
      animation: spin 0.7s linear infinite;
    }
    @keyframes spin { to { transform: rotate(360deg); } }

    @media (min-width: 720px) {
      .hero { padding: 40px 0 32px; }
      .dock { padding: 12px; }
      .field input { height: 64px; font-size: 1.08rem; }
      .btn-ghost, .btn-primary { height: 64px; padding: 0 24px; }
      .steps { grid-template-columns: 1fr; }
      .features { grid-template-columns: 1fr 1fr; }
      .lede { font-size: 1.12rem; }
      section { padding: 40px 0; }
    }
    @media (min-width: 640px) {
      .result-top { grid-template-columns: 220px 1fr; }
      .thumb { min-height: 200px; }
      .qualities { grid-template-columns: 1fr 1fr; padding: 0 20px 16px; }
      .demo-note, .result .btn-primary { margin-left: 20px; margin-right: 20px; }
      .result .btn-primary { width: calc(100% - 40px); }
    }
    @media (max-width: 520px) {
      .dock-row { flex-wrap: wrap; }
      .field { flex: 1 1 100%; }
      .field input { height: 52px; padding-left: 12px; }
      .btn-ghost { flex: 1; height: 48px; }
      .btn-primary { flex: 1.4; height: 48px; }
      .dock-foot { padding: 8px 8px 4px 12px; }
      .result-top { grid-template-columns: 1fr; }
      .thumb { min-height: 180px; }
      .qualities { grid-template-columns: 1fr 1fr; }
      h1 { font-size: clamp(1.85rem, 9vw, 2.4rem); }
      .tool-links { flex-direction: column; align-items: center; gap: 10px; }
      .tool-links span { display: none; }
    }
    @media (prefers-reduced-motion: reduce) {
      *, *::before, *::after {
        animation: none !important;
        transition: none !important;
      }
    }

    /* MVP additions — same visual language */
    .error-banner {
      display: none;
      margin-top: 16px;
      padding: 12px 14px;
      border-radius: 14px;
      background: rgba(160, 60, 40, 0.16);
      border: 1px solid rgba(220, 120, 90, 0.4);
      color: #f0c8b4;
      text-align: left;
      font-size: 0.95rem;
    }
    .error-banner.show { display: block; }
    .thumb img {
      position: absolute;
      inset: 0;
      width: 100%;
      height: 100%;
      object-fit: cover;
      z-index: 1;
    }
    .thumb .sun, .thumb .play, .thumb .demo-pill { z-index: 2; }
    .thumb.has-image .sun { display: none; }
    .result.live .demo-pill { display: none; }
    .result.live .demo-note { border-style: solid; }
    .legal-page { padding: 40px 0 64px; }
    .legal-page h1 {
      font-size: clamp(1.8rem, 5vw, 2.6rem);
      margin-bottom: 8px;
    }
    .legal-page .lead { color: var(--muted); margin-bottom: 28px; }
    .legal-page h2 {
      font-size: 1.15rem;
      margin: 28px 0 8px;
      font-weight: 700;
    }
    .legal-page p, .legal-page li { color: var(--cream-soft); margin-bottom: 10px; }
    .legal-page ul { padding-left: 1.2em; margin-bottom: 16px; }
    .legal-page a { color: var(--amber); }
    .status-line {
      margin-top: 12px;
      color: var(--muted);
      font-size: 0.9rem;
      min-height: 1.2em;
    }



    .works-with {
      margin: 14px auto 0;
      max-width: 36em;
      font-size: 0.86rem;
      color: var(--muted);
      line-height: 1.55;
    }
    .platform-badge {
      display: inline-flex;
      align-items: center;
      font-family: var(--font-en);
      font-size: 0.66rem;
      font-weight: 700;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--amber);
      border: 1px solid rgba(232, 165, 75, 0.45);
      background: var(--amber-soft);
      border-radius: 999px;
      padding: 3px 9px;
      margin-bottom: 8px;
    }
    .platform-badge[hidden] { display: none !important; }
    .seo-landing {
      text-align: left;
      margin: 8px 0 28px;
      padding: 20px 22px;
      border: 1px solid var(--line);
      border-radius: var(--radius-sm);
      background: rgba(243, 235, 221, 0.03);
    }
    .seo-landing[hidden] { display: none; }
    .seo-landing h2 {
      font-family: var(--font-en);
      font-size: 1.15rem;
      letter-spacing: -0.03em;
      margin-bottom: 8px;
    }
    html[lang="bn"] .seo-landing h2 { font-family: var(--font-bn); }
    html[lang="hi"] .seo-landing h2 { font-family: var(--font-hi); }
    .seo-landing p { color: var(--cream-soft); font-size: 0.95rem; }
    .tool-links {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 8px 12px;
      margin: 0 0 36px;
      font-size: 0.88rem;
    }
    .tool-links a {
      color: var(--amber);
      text-decoration: none;
      border-bottom: 1px solid rgba(232, 165, 75, 0.35);
    }
    .tool-links a:hover { color: var(--amber-hot); }
    .tool-links span { color: var(--muted-dim); }

    /* Disclaimer shown once (under the input); hide the repeat in live results */
    .result.live .demo-note { display: none; }

    /* Download progress (button states + panel) */
    .result .btn-primary[disabled] { cursor: progress; }
    .btn-primary.is-working {
      opacity: 1;
      background: linear-gradient(180deg, rgba(255, 195, 106, 0.9) 0%, rgba(232, 165, 75, 0.9) 100%);
      box-shadow: 0 0 0 4px var(--amber-glow), 0 8px 24px rgba(232, 165, 75, 0.2);
      animation: dl-pulse 1.6s ease-in-out infinite;
    }
    .btn-primary.is-done {
      background: linear-gradient(180deg, #d9e6b8 0%, var(--good) 100%);
      box-shadow: 0 8px 24px rgba(198, 212, 168, 0.22);
    }
    .btn-primary.is-error { background: rgba(243, 235, 221, 0.08); color: var(--cream); border: 1px solid var(--amber); box-shadow: none; }
    @keyframes dl-pulse { 50% { box-shadow: 0 0 0 7px rgba(232, 165, 75, 0.1), 0 8px 24px rgba(232, 165, 75, 0.2); } }
    .qualities.locked { opacity: 0.55; pointer-events: none; }
    .dl-panel {
      margin: -4px 16px 16px;
      padding: 12px 14px;
      border-radius: 14px;
      background: rgba(243, 235, 221, 0.04);
      border: 1px solid var(--line);
      text-align: left;
    }
    .dl-panel[hidden] { display: none; }
    .dl-bar {
      position: relative;
      height: 8px;
      border-radius: 99px;
      background: rgba(243, 235, 221, 0.1);
      overflow: hidden;
    }
    .dl-fill {
      position: absolute;
      left: 0; top: 0; bottom: 0;
      width: 0;
      border-radius: inherit;
      background: linear-gradient(90deg, var(--amber-deep), var(--amber-hot));
      transition: width 0.45s ease;
    }
    .dl-bar.indeterminate .dl-fill {
      width: 38%;
      transition: none;
      animation: dl-slide 1.25s ease-in-out infinite;
    }
    @keyframes dl-slide { 0% { left: -38%; } 100% { left: 100%; } }
    .dl-panel.is-done .dl-fill { background: var(--good); }
    .dl-row {
      display: flex;
      justify-content: space-between;
      gap: 12px;
      margin-top: 10px;
      font-size: 0.92rem;
      color: var(--cream);
      font-weight: 600;
    }
    .dl-bytes { color: var(--amber-hot); font-variant-numeric: tabular-nums; white-space: nowrap; }
    .dl-panel.is-done .dl-bytes { color: var(--good); }
    .dl-hint:empty { display: none; }
    .dl-hint { margin: 4px 0 0; font-size: 0.85rem; color: var(--muted); }
    .dl-panel.is-error { border-color: rgba(220, 120, 90, 0.4); background: rgba(160, 60, 40, 0.14); }
    .dl-panel.is-error .dl-bar, .dl-panel.is-error .dl-row { display: none; }
    .dl-panel.is-error .dl-hint { margin: 0; color: #f0c8b4; font-size: 0.92rem; }
    .dl-manual { display: inline-block; margin-top: 8px; color: var(--amber); font-size: 0.88rem; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
    .dl-manual[hidden] { display: none; }
    @media (min-width: 720px) { .dl-panel { margin-left: 20px; margin-right: 20px; } }
    @media (prefers-reduced-motion: reduce) {
      .btn-primary.is-working { animation: none; }
      .dl-bar.indeterminate .dl-fill { animation-duration: 2.5s; }
    }

    /* Clear-link button + "Download another" */
    .field input { padding-right: 48px; }
    .clear-btn {
      position: absolute;
      right: 4px;
      top: 50%;
      transform: translateY(-50%);
      width: 44px;
      height: 44px;
      border: 0;
      border-radius: 50%;
      background: transparent;
      color: var(--muted);
      display: inline-flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      -webkit-tap-highlight-color: transparent;
    }
    .clear-btn svg { padding: 5px; width: 28px; height: 28px; border-radius: 50%; background: rgba(243, 235, 221, 0.1); transition: background 0.15s, color 0.15s; }
    .clear-btn:hover svg, .clear-btn:active svg { background: var(--amber-soft); color: var(--amber-hot); }
    .clear-btn:focus-visible { outline: 2px solid var(--amber); outline-offset: -2px; }
    .clear-btn[hidden] { display: none; }
    .another-btn { width: calc(100% - 32px); margin: -4px 16px 16px; height: 50px; color: var(--cream); border-color: var(--line-strong); }
    .another-btn span[aria-hidden] { color: var(--amber-hot); font-weight: 700; }
    .another-btn[hidden] { display: none; }
    @media (min-width: 720px) { .another-btn { width: calc(100% - 40px); margin-left: 20px; margin-right: 20px; } }

    /* Guide the eye to Paste after clearing (no keyboard pop-up) */
    #paste-btn.nudge { animation: paste-nudge 0.85s ease-in-out 3; border-color: var(--amber); color: var(--amber-hot); }
    @keyframes paste-nudge {
      0%, 100% { box-shadow: 0 0 0 0 rgba(232, 165, 75, 0); background: rgba(243, 235, 221, 0.06); }
      50% { box-shadow: 0 0 0 6px var(--amber-glow); background: var(--amber-soft); }
    }
    @media (prefers-reduced-motion: reduce) { #paste-btn.nudge { animation: none; } }

    /* Keyword landing pages */
    .kw-links { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: 0.92rem; }
    .kw-links a { color: var(--amber); text-decoration: underline; text-underline-offset: 3px; }
    .kw-links span { color: var(--muted-dim); }
    html[lang="bn"] .kw-h1 { font-family: var(--font-bn); letter-spacing: 0; line-height: 1.2; }
    @media (min-width: 720px) { .kw-steps { grid-template-columns: 1fr 1fr !important; } }
