    :root {
      --cream: #fdf8f2;
      --pink: #f2b8c6;
      --blush: #fce4ec;
      --rose: #d9748a;
      --wine: #8b3a52;
      --mauve: #b8879e;
      --ink: #3f2a32;
    }

    * { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; }

    body {
      background-color: var(--cream);
      color: var(--ink);
      font-family: Garamond, "EB Garamond", serif;
      min-height: 100vh;
      overflow-x: hidden;
      line-height: 1.8;
    }

    /* ——— BLUR ——— */
    #blur-protection {
      position: fixed; inset: 0;
      backdrop-filter: blur(20px);
      background: rgba(0,0,0,0.4);
      z-index: 999999;
      pointer-events: none;
      opacity: 0;
      transition: opacity 0.2s ease;
    }

    /* ——— PAPER TEXTURE ——— */
    body::before {
      content: '';
      position: fixed; inset: 0;
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='400' height='400' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
      pointer-events: none; z-index: 9999;
    }

    /* ——— GRID BG ——— */
    .bg-pattern {
      position: fixed; inset: 0; z-index: 0; pointer-events: none;
      background-image:
        repeating-linear-gradient(0deg, transparent, transparent 39px, rgba(242,184,198,0.13) 39px, rgba(242,184,198,0.13) 40px),
        repeating-linear-gradient(90deg, transparent, transparent 39px, rgba(242,184,198,0.07) 39px, rgba(242,184,198,0.07) 40px);
    }

    /* ——— FLOATING PETALS ——— */
    .petal {
      position: fixed; pointer-events: none; z-index: 1;
      opacity: 0; animation: drift linear infinite;
    }
    @keyframes drift {
      0%   { opacity: 0; transform: translateY(-20px) rotate(0deg) scale(1); }
      10%  { opacity: 0.55; }
      90%  { opacity: 0.35; }
      100% { opacity: 0; transform: translateY(110vh) rotate(360deg) scale(0.8); }
    }

    /* ——— NAV ——— */
    nav {
      position: sticky; top: 0; z-index: 100;
      display: flex; justify-content: center; align-items: center;
      background: rgba(253,248,242,0.93);
      backdrop-filter: blur(10px);
      border-bottom: 2px solid var(--pink);
    }
    .nav-deco { font-size: 16px; padding: 0 14px; color: var(--rose); user-select: none; }
    nav a {
      font-family: "Shippori Mincho", serif;
      font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
      color: var(--wine); text-decoration: none;
      padding: 15px 18px; border-right: 1px solid var(--pink);
      transition: all 0.25s; position: relative;
    }
    nav a:first-of-type { border-left: 1px solid var(--pink); }
    nav a::after {
      content: ''; position: absolute; bottom: 0; left: 50%; right: 50%;
      height: 2px; background: var(--rose); transition: left 0.25s, right 0.25s;
    }
    nav a:hover { color: var(--rose); background: rgba(242,184,198,0.12); }
    nav a:hover::after { left: 0; right: 0; }
    nav a.active { color: var(--rose); background: rgba(242,184,198,0.12); }
    nav a.active::after { left: 0; right: 0; }

    /* ——— PAGE ——— */
    .page {
      position: relative; z-index: 2;
      max-width: 760px; margin: 0 auto;
      padding: 52px 28px 100px;
    }

    @keyframes riseIn {
      from { opacity: 0; transform: translateY(18px); }
      to   { opacity: 1; transform: translateY(0); }
    }
    .anim { animation: riseIn 0.6s cubic-bezier(.16,1,.3,1) both; }
    .a1{animation-delay:.05s} .a2{animation-delay:.13s} .a3{animation-delay:.22s}

    /* ——— BREADCRUMB ——— */
    .breadcrumb {
      display: flex; align-items: center; gap: 8px;
      font-family: "Shippori Mincho", serif; font-size: 11px;
      letter-spacing: 0.1em; color: var(--mauve);
      margin-bottom: 48px;
    }
    .breadcrumb a { color: var(--mauve); text-decoration: none; transition: color 0.2s; }
    .breadcrumb a:hover { color: var(--rose); }
    .breadcrumb-sep { color: var(--pink); font-size: 10px; }

    /* ——— CHAPTER HEADER ——— */
    .chapter-header { text-align: center; margin-bottom: 52px; }
    .ch-eyebrow {
      font-family: "Shippori Mincho", serif;
      font-size: 10px; letter-spacing: 0.34em; text-transform: uppercase;
      color: var(--mauve); margin-bottom: 10px;
      display: flex; align-items: center; justify-content: center; gap: 10px;
    }
    .ch-eyebrow::before, .ch-eyebrow::after {
      content: ''; display: inline-block; width: 36px; height: 1px;
      background: linear-gradient(to right, transparent, var(--pink));
    }
    .ch-eyebrow::after { background: linear-gradient(to left, transparent, var(--pink)); }
    .ch-num-label {
      font-family: "Shippori Mincho", serif;
      font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase;
      color: var(--pink); margin-bottom: 8px;
    }
    .ch-title {
      font-family: "Shippori Mincho", serif;
      font-size: 32px; font-weight: 800;
      color: var(--wine); line-height: 1.1;
      letter-spacing: -0.01em; margin-bottom: 18px;
    }
    .ch-divider {
      display: flex; align-items: center; justify-content: center;
      gap: 10px; color: var(--pink); font-size: 13px; letter-spacing: 6px;
    }

    /* ——— CHAPTER CONTENT ——— */
    .chapter-content {
      max-width: 660px; margin: 0 auto; padding: 0 8px;
      font-size: 15.5px; line-height: 2; color: var(--ink);
    }
    .chapter-content p { margin-bottom: 1.7em; text-shadow: 0 0 28px rgba(253,248,242,0.9), 0 0 8px rgba(253,248,242,1); }
    .chapter-content p:last-child { margin-bottom: 0; }

    /* scene break */
    .scene-break { text-align: center; margin: 2.4em 0; font-size: 14px; letter-spacing: 8px; color: var(--pink); user-select: none; }

    /* author's / translator's note label */
    .author-note { text-align: center; margin: 2.4em 0; font-size: 14px; letter-spacing: 8px; color: var(--rose); user-select: none; }

    /* ——— PROGRESS BAR ——— */
    .reading-progress {
      position: fixed; top: 0; left: 0; height: 3px;
      background: linear-gradient(to right, var(--rose), var(--mauve));
      z-index: 200; width: 0%; transition: width 0.1s linear;
    }

    /* ——— QUICK NAV SIDEBAR ——— */
    .quick-nav {
      position: fixed; right: 20px; top: 50%;
      transform: translateY(-50%);
      z-index: 50;
      display: flex; flex-direction: column; gap: 6px;
    }
    .qn-btn {
      width: 36px; height: 36px;
      display: flex; align-items: center; justify-content: center;
      background: rgba(253,248,242,0.9);
      border: 1.5px solid var(--pink); border-radius: 50%;
      color: var(--wine); font-size: 14px;
      text-decoration: none;
      transition: all 0.22s cubic-bezier(.16,1,.3,1);
      backdrop-filter: blur(6px);
      font-family: "Shippori Mincho", serif;
    }
    .qn-btn:hover { background: var(--wine); color: #fff; border-color: var(--wine); transform: scale(1.12); }
    .qn-btn.toc { font-size: 11px; letter-spacing: 0.05em; }
    .qn-label { font-family: "Shippori Mincho", serif; font-size: 8px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--mauve); text-align: center; }
    .qn-divider { height: 1px; background: var(--pink); margin: 2px 4px; }
    .qn-btn { position: relative; }
    .qn-btn::before {
      content: attr(data-tip);
      position: absolute; right: calc(100% + 10px);
      background: var(--wine); color: #fff;
      font-family: "Shippori Mincho", serif;
      font-size: 10px; letter-spacing: 0.1em; white-space: nowrap;
      padding: 4px 10px; border-radius: 3px;
      opacity: 0; pointer-events: none; transition: opacity 0.18s;
    }
    .qn-btn:hover::before { opacity: 1; }

    /* ——— CHAPTER DRAWER (TOC popup) ——— */
    .drawer-overlay {
      position: fixed; inset: 0;
      background: rgba(30,18,24,0.35); backdrop-filter: blur(3px);
      z-index: 210; opacity: 0; pointer-events: none;
      transition: opacity 0.32s cubic-bezier(.16,1,.3,1);
    }
    .drawer-overlay.open { opacity: 1; pointer-events: all; }
    .drawer {
      position: fixed; right: 0; top: 0; bottom: 0;
      width: 300px; background: var(--cream);
      border-left: 2px solid var(--pink); z-index: 220;
      transform: translateX(110%); transition: transform 0.36s cubic-bezier(.16,1,.3,1);
      overflow-y: auto; display: flex; flex-direction: column;
    }
    .drawer.open { transform: translateX(0); }
    .drawer-head {
      padding: 20px 20px 14px; border-bottom: 1.5px solid var(--pink);
      display: flex; align-items: center; justify-content: space-between;
      position: sticky; top: 0; background: var(--cream); z-index: 1;
    }
    .drawer-head-title { font-family: "Shippori Mincho", serif; font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--wine); }
    .drawer-close { background: none; border: none; font-size: 18px; color: var(--mauve); padding: 4px 8px; border-radius: 3px; transition: color 0.18s; cursor: pointer; }
    .drawer-close:hover { color: var(--rose); }
    .drawer-ch-list { padding: 10px 0 20px; }
    .drawer-ch-item {
      display: flex; align-items: center; gap: 12px;
      padding: 11px 20px; text-decoration: none; color: var(--ink);
      font-family: "Shippori Mincho", serif; font-size: 13px;
      border-bottom: 1px solid rgba(242,184,198,0.3); transition: background 0.15s;
    }
    .drawer-ch-item:hover { background: var(--blush); }
    .drawer-ch-item.current { background: rgba(217,116,138,0.1); border-left: 3px solid var(--rose); }
    .drawer-ch-item.current .d-ch-num { color: var(--rose); }
    .d-ch-num { font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--mauve); min-width: 44px; flex-shrink: 0; }
    .d-ch-title { font-size: 12px; color: #5a3a44; line-height: 1.3; }

    /* ——— CHAPTER BOTTOM NAV ——— */
    .chapter-nav {
      display: flex; justify-content: space-between; align-items: center;
      max-width: 660px; margin: 64px auto 0; gap: 12px;
    }
    .chapter-nav a {
      font-family: "Shippori Mincho", serif; font-size: 11px;
      letter-spacing: 0.14em; text-transform: uppercase;
      color: var(--wine); text-decoration: none;
      padding: 13px 22px; border: 1.5px solid var(--pink); border-radius: 3px; transition: all 0.22s;
    }
    .chapter-nav a:hover { background: var(--blush); border-color: var(--rose); transform: translateY(-2px); }
    .chapter-nav .next { background: var(--wine); color: #fff; border-color: var(--wine); }
    .chapter-nav .next:hover { background: var(--rose); border-color: var(--rose); }
    .chapter-nav .prev { background: var(--wine); color: #fff; border-color: var(--wine); }
    .chapter-nav .prev:hover { background: var(--rose); border-color: var(--rose); }
    .chapter-nav .toc-link { background: transparent; color: var(--mauve); border-color: var(--blush); font-size: 10px; }
    .chapter-nav .toc-link:hover { color: var(--rose); }

    /* ——— CLICK SPARKLE ——— */
    .sparkle {
      position: fixed; pointer-events: none; z-index: 99999;
      font-size: 16px; animation: sparkle-pop 0.7s ease forwards; user-select: none;
    }
    @keyframes sparkle-pop {
      0%   { opacity: 1; transform: translate(-50%, -50%) scale(0.5) rotate(0deg); }
      60%  { opacity: 1; transform: translate(-50%, -50%) scale(1.2) rotate(20deg); }
      100% { opacity: 0; transform: translate(-50%, -80%) scale(0.8) rotate(40deg); }
    }

    /* ——— CONTENT PROTECTION ——— */
    .chapter-content, .chapter-header {
      -webkit-user-select: none; -moz-user-select: none; user-select: none;
    }

    /* themed toast */
    .protect-toast {
      position: fixed; bottom: 32px; left: 50%; z-index: 99998;
      transform: translateX(-50%) translateY(16px); opacity: 0;
      background: rgba(139,58,82,0.95); color: #fdf8f2;
      font-family: "Shippori Mincho", serif;
      font-size: 12px; letter-spacing: 0.14em;
      padding: 12px 24px; border-radius: 3px;
      border: 1px solid rgba(242,184,198,0.3);
      box-shadow: 0 4px 18px rgba(139,58,82,0.25);
      transition: opacity 0.3s ease, transform 0.3s cubic-bezier(.16,1,.3,1);
      pointer-events: none; white-space: nowrap;
    }
    .protect-toast.pt-show { opacity: 1; transform: translateX(-50%) translateY(0); }
    .pt-deco { color: var(--pink); font-size: 10px; }

    /* ——— FOOTER ——— */
    footer {
      position: relative; z-index: 2; text-align: center;
      padding: 28px 24px; border-top: 1px solid var(--pink);
      font-family: "Shippori Mincho", serif; font-size: 11px;
      letter-spacing: 0.14em; color: var(--mauve);
    }
    .footer-hearts { font-size: 16px; display: block; margin-bottom: 6px; letter-spacing: 4px; }

    /* ——— DARK MODE ——— */
    body.dark-mode {
      --cream: #1a1014; --pink: #7a3d52; --blush: #2a1620;
      --rose: #c0607a; --wine: #e8a0b4; --mauve: #9a6070; --ink: #e8d8dc;
    }
    body.dark-mode nav { background: rgba(26,16,20,0.95); border-bottom-color: #4a2535; }
    body.dark-mode .drawer, body.dark-mode .drawer-head { background: #1e1218; border-color: #4a2535; }
    body.dark-mode .drawer-ch-item:hover, body.dark-mode .drawer-ch-item.current { background: #2a1620; }
    body.dark-mode .chapter-content p { text-shadow: 0 0 28px rgba(26,16,20,0.95), 0 0 8px rgba(26,16,20,1); }
    body.dark-mode .qn-btn { background: rgba(26,16,20,0.92); border-color: #4a2535; }
    body.dark-mode .bg-pattern {
      background-image:
        repeating-linear-gradient(0deg, transparent, transparent 39px, rgba(122,61,82,0.1) 39px, rgba(122,61,82,0.1) 40px),
        repeating-linear-gradient(90deg, transparent, transparent 39px, rgba(122,61,82,0.06) 39px, rgba(122,61,82,0.06) 40px);
    }
    body.dark-mode .tl-tip .tl-tip-box { background: #1e1218; border-color: #4a2535; color: #c8a8b4; }
    body.dark-mode .tl-tip .tl-tip-box::before { border-top-color: #4a2535; }
    body.dark-mode .tl-tip .tl-tip-box::after  { border-top-color: #1e1218; }
    body.dark-mode .tl-tip .tl-tip-box.below::before { border-bottom-color: #4a2535; border-top-color: transparent; }
    body.dark-mode .tl-tip .tl-tip-box.below::after  { border-bottom-color: #1e1218; border-top-color: transparent; }
    body, nav, .drawer, .drawer-head, .chapter-content, .qn-btn, .bg-pattern, .chapter-header, .breadcrumb, .chapter-nav, .scene-break, .author-note {
      transition: background-color 0.35s ease, color 0.35s ease, border-color 0.35s ease, background 0.35s ease;
    }
    .qn-btn.dm-toggle { font-size: 15px; }

    /* ——— RESPONSIVE ——— */
    @media (max-width: 860px) { .quick-nav { display: none; } }

    body::after {
      content: "Protected Content"; position: fixed; inset: 0; opacity: 0.08;
      font-size: 40px; display: flex; align-items: center; justify-content: center; pointer-events: none;
    }

    /* ——— CUSTOMISATION PANEL ——— */
    @media (max-width: 860px) { .custom-tab, .custom-panel { display: none; } }
    .custom-tab {
      position: fixed; left: 0; top: 50%; transform: translateY(-50%);
      z-index: 200; width: 24px; height: 80px;
      background: rgba(253,248,242,0.94); border: 1.5px solid var(--pink);
      border-left: none; border-radius: 0 6px 6px 0;
      display: flex; align-items: center; justify-content: center;
      cursor: pointer; backdrop-filter: blur(8px);
      transition: background 0.2s, border-color 0.2s, transform 0.2s;
      writing-mode: vertical-rl; font-family: "Shippori Mincho", serif;
      font-size: 7.5px; letter-spacing: 0.2em; text-transform: uppercase;
      color: var(--mauve); user-select: none;
      box-shadow: 2px 0 12px rgba(139,58,82,0.07);
    }
    .custom-tab:hover { background: var(--blush); color: var(--rose); border-color: var(--rose); }
    .custom-tab.panel-open { transform: translateY(-50%) translateX(200px); background: var(--blush); border-color: var(--rose); color: var(--rose); }
    .custom-panel {
      position: fixed; left: 0; top: 50%;
      transform: translateY(-50%) translateX(-110%);
      z-index: 199; width: 200px;
      background: rgba(253,248,242,0.98); border: 1.5px solid var(--pink);
      border-left: none; border-radius: 0 12px 12px 0;
      padding: 22px 18px 22px 16px;
      box-shadow: 4px 0 24px rgba(139,58,82,0.10);
      backdrop-filter: blur(12px);
      transition: transform 0.32s cubic-bezier(.16,1,.3,1);
      display: flex; flex-direction: column; gap: 16px;
    }
    .custom-panel.open { transform: translateY(-50%) translateX(0); }
    body.dark-mode .custom-panel { background: rgba(30,18,24,0.98); border-color: #4a2535; }
    body.dark-mode .custom-tab { background: rgba(26,16,20,0.94); border-color: #4a2535; }
    .cp-head { font-family: "Shippori Mincho", serif; font-size: 9px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--mauve); padding-bottom: 12px; border-bottom: 1px solid var(--blush); }
    .cp-section { display: flex; flex-direction: column; gap: 7px; }
    .cp-label { font-family: "Shippori Mincho", serif; font-size: 8px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mauve); }
    .cp-select-wrap { position: relative; }
    .cp-select-wrap::after { content: '▾'; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-size: 10px; color: var(--mauve); pointer-events: none; }
    .cp-select { width: 100%; -webkit-appearance: none; appearance: none; background: #fff; border: 1.5px solid var(--pink); border-radius: 4px; padding: 6px 24px 6px 9px; font-size: 12px; color: var(--wine); font-family: "Shippori Mincho", serif; cursor: pointer; outline: none; transition: border-color 0.18s; }
    .cp-select:hover, .cp-select:focus { border-color: var(--rose); }
    body.dark-mode .cp-select { background: #2a1620; color: var(--wine); border-color: #4a2535; }
    .cp-presets { display: flex; flex-wrap: wrap; gap: 5px; }
    .cp-preset { font-family: "Shippori Mincho", serif; font-size: 9px; letter-spacing: 0.1em; padding: 3px 8px; border: 1.5px solid var(--pink); border-radius: 20px; background: none; color: var(--wine); cursor: pointer; transition: all 0.16s; white-space: nowrap; }
    .cp-preset:hover { background: var(--blush); border-color: var(--rose); }
    .cp-preset.active { background: var(--wine); color: #fff; border-color: var(--wine); }
    .cp-slider-row { display: flex; align-items: center; gap: 8px; }
    .cp-slider-val { font-family: "Shippori Mincho", serif; font-size: 10px; color: var(--mauve); min-width: 30px; text-align: right; flex-shrink: 0; }
    .cp-slider { flex: 1; -webkit-appearance: none; appearance: none; height: 3px; border-radius: 2px; outline: none; border: none; cursor: pointer; }
    .cp-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 13px; height: 13px; border-radius: 50%; background: #fff; border: 2px solid var(--rose); cursor: pointer; box-shadow: 0 1px 4px rgba(139,58,82,0.2); }
    .cp-slider::-moz-range-thumb { width: 13px; height: 13px; border-radius: 50%; background: #fff; border: 2px solid var(--rose); cursor: pointer; }
    .cp-divider { height: 1px; background: var(--blush); }
    .cp-btn-row { display: flex; gap: 6px; align-items: center; }
    .cp-reset, .cp-petals { font-family: "Shippori Mincho", serif; font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--mauve); background: none; border: 1.5px solid var(--blush); border-radius: 3px; padding: 5px 10px; cursor: pointer; transition: all 0.18s; }
    .cp-reset:hover, .cp-petals:hover { border-color: var(--rose); color: var(--rose); }
    .cp-petals.active { border-color: var(--mauve); color: var(--wine); background: var(--blush); }

    /* ——— TRANSLATOR NOTE TOOLTIPS ——— */
    .tl-tip {
      display: inline; position: relative;
      border-bottom: 1.5px dotted var(--rose);
      color: inherit; cursor: help;
    }
    .tl-tip .tl-tip-box {
      display: none; position: absolute;
      bottom: calc(100% + 8px); left: 50%;
      transform: translateX(-50%);
      width: 270px; background: var(--cream);
      border: 1.5px solid var(--pink); border-radius: 6px;
      padding: 10px 13px;
      box-shadow: 3px 4px 0 var(--pink);
      font-family: "Shippori Mincho", serif;
      font-size: 12px; line-height: 1.65; color: #6b4a5a;
      text-align: left; white-space: normal; z-index: 500; pointer-events: none;
    }
    .tl-tip .tl-tip-box::before {
      content: ''; position: absolute; top: 100%; left: 50%;
      transform: translateX(-50%);
      border: 6px solid transparent; border-top-color: var(--pink);
    }
    .tl-tip .tl-tip-box::after {
      content: ''; position: absolute; top: 100%; left: 50%;
      transform: translateX(-50%);
      border: 5px solid transparent; border-top-color: var(--cream); margin-top: -1px;
    }
    .tl-tip .tl-tip-label { display: block; font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--rose); margin-bottom: 5px; }
    .tl-tip:hover .tl-tip-box, .tl-tip.tip-open .tl-tip-box { display: block; }
    .tl-tip .tl-tip-box.below { bottom: auto; top: calc(100% + 8px); }
    .tl-tip .tl-tip-box.below::before { border-top-color: transparent; border-bottom-color: var(--pink); top: auto; bottom: 100%; }
    .tl-tip .tl-tip-box.below::after  { border-top-color: transparent; border-bottom-color: var(--cream); top: auto; bottom: 100%; margin-top: 0; margin-bottom: -1px; }