/* pi-cac.xyz — Ribbon Ledger (manga-panel editorial system) */
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;700;900&family=M+PLUS+Rounded+1c:wght@700;800&display=swap");

:root {
  --ink: #1f1520;
  --ink-soft: #4a3550;
  --muted: #7a647f;
  --rose: #f01d73;
  --rose-deep: #c4125a;
  --wine: #7a0f3f;
  --blush: #fff0f6;
  --paper: #fff8fb;
  --panel: #ffffff;
  --mint: #14b8a6;
  --mint-deep: #0f766e;
  --line: rgba(31, 21, 32, 0.1);
  --glass: rgba(255, 248, 251, 0.9);
  --shadow: 0 14px 40px rgba(192, 18, 90, 0.12);
  --r-lg: 22px;
  --r-md: 14px;
  --nav-h: 58px;
  --max: 1040px;
  --font-display: "M PLUS Rounded 1c", "Noto Sans SC", sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(900px 420px at 8% -5%, rgba(240, 29, 115, 0.14), transparent 60%),
    radial-gradient(700px 380px at 100% 0%, rgba(20, 184, 166, 0.1), transparent 55%),
    linear-gradient(180deg, #ffe6f0 0%, var(--blush) 28%, var(--paper) 68%, #f5fffc 100%);
  line-height: 1.9;
  font-size: 16px;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.35;
  background-image: radial-gradient(circle, rgba(240, 29, 115, 0.18) 1px, transparent 1.2px);
  background-size: 14px 14px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 70%);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--rose-deep);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--mint-deep);
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.35;
  letter-spacing: 0.01em;
  color: var(--ink);
  margin: 0 0 0.7em;
}

p {
  margin: 0 0 1.05em;
}

ul,
ol {
  margin: 0 0 1.1em;
  padding-left: 1.2em;
}

li {
  margin-bottom: 0.45em;
}

.wrap {
  width: min(100% - 32px, var(--max));
  margin-inline: auto;
}

/* —— top ads —— */
.booth-top {
  background: rgba(255, 255, 255, 0.72);
  border-bottom: 1px dashed rgba(240, 29, 115, 0.22);
  padding: 8px 0 4px;
}

.ad-grid,
#ads,
#pin-ads {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 8px;
  margin: 0;
}

.ad-cell {
  width: 70px;
  text-align: center;
}

.ad-cell img {
  width: 65px;
  height: 65px;
  object-fit: cover;
  border-radius: 18px;
  box-shadow: 0 6px 16px rgba(24, 24, 24, 0.12);
  background: #fff;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.ad-cell a {
  display: inline-block;
  text-decoration: none;
}

.ad-cell img:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 10px 22px rgba(24, 24, 24, 0.16);
}

.ad-cap {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* —— header —— */
.ribbon-mast {
  position: sticky;
  top: 0;
  z-index: 120;
  min-height: var(--nav-h);
  background: var(--glass);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.mast-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  column-gap: 12px;
  row-gap: 0;
  padding: 8px 0;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
}

.brand-link img {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(240, 29, 115, 0.25);
}

.menu-toggle {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font: inherit;
  color: var(--ink);
  cursor: pointer;
  margin-left: auto;
  flex-shrink: 0;
}

.ribbon-menu {
  display: none;
  gap: 6px 14px;
  flex-wrap: wrap;
}

.ribbon-menu a {
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 6px 2px;
}

.ribbon-menu a.is-now,
.ribbon-menu a:hover {
  color: var(--rose);
}

.ribbon-menu.is-open {
  display: flex;
  flex-direction: column;
  flex: 1 0 100%;
  width: 100%;
  max-width: 100%;
  margin-top: 4px;
  padding: 10px 0 6px;
  border-top: 1px dashed var(--line);
  gap: 2px;
}

.ribbon-menu.is-open a {
  display: block;
  padding: 10px 4px;
  border-bottom: 1px solid rgba(31, 21, 32, 0.06);
}

.ribbon-menu.is-open a:last-child {
  border-bottom: 0;
}

@media (min-width: 880px) {
  .menu-toggle {
    display: none;
  }
  .mast-inner {
    flex-wrap: nowrap;
  }
  .ribbon-menu {
    display: flex;
    flex-direction: row;
    flex: 0 1 auto;
    width: auto;
    max-width: none;
    margin-top: 0;
    border: 0;
    padding: 0;
    gap: 6px 14px;
  }
  .ribbon-menu a {
    display: inline;
    padding: 6px 2px;
    border-bottom: 0;
  }
}

/* —— pin dock —— */
.pin-dock {
  position: sticky;
  top: var(--nav-h);
  z-index: 110;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(31, 21, 32, 0.06);
  transition: max-height 0.28s ease, opacity 0.22s ease, padding 0.22s ease;
}

.pin-dock.is-shown {
  max-height: 280px;
  opacity: 1;
  pointer-events: auto;
  padding: 8px 0 10px;
  overflow: auto;
}

.pin-note {
  margin: 0 0 6px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}

.pin-spacer {
  height: 0;
  transition: height 0.22s ease;
}

.pin-spacer.is-shown {
  height: 0;
}

#pin-ads .ad-cell {
  width: calc(25% - 8px);
  max-width: 78px;
}

@media (min-width: 880px) {
  #pin-ads .ad-cell {
    width: calc(12.5% - 8px);
  }
}

/* —— slash hero —— */
.slash-hero {
  position: relative;
  overflow: hidden;
  padding: 42px 0 36px;
  background:
    linear-gradient(118deg, rgba(240, 29, 115, 0.92) 0%, rgba(196, 18, 90, 0.88) 46%, rgba(15, 118, 110, 0.78) 100%);
  color: #fff;
  clip-path: polygon(0 0, 100% 0, 100% 88%, 0 100%);
}

.slash-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      -18deg,
      transparent,
      transparent 10px,
      rgba(255, 255, 255, 0.05) 10px,
      rgba(255, 255, 255, 0.05) 12px
    );
  pointer-events: none;
}

.slash-inner {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 22px;
  align-items: center;
}

@media (min-width: 840px) {
  .slash-inner {
    grid-template-columns: 1.15fr 0.85fr;
  }
}

.slash-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.slash-brand img {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.slash-brand .name {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 800;
  line-height: 1.1;
  text-shadow: 0 3px 0 rgba(122, 15, 63, 0.35);
}

.slash-brand .sub {
  font-size: 0.9rem;
  opacity: 0.9;
  letter-spacing: 0.08em;
}

.slash-hero h1 {
  color: #fff;
  font-size: clamp(1.35rem, 3.6vw, 1.85rem);
  margin-bottom: 0.55em;
}

.slash-hero p {
  margin: 0;
  max-width: 36em;
  opacity: 0.95;
  font-size: 1.02rem;
}

.slash-art {
  justify-self: center;
  width: min(100%, 280px);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
  transform: rotate(2.5deg);
  animation: float-tilt 5.5s ease-in-out infinite;
}

.slash-art img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
}

@keyframes float-tilt {
  0%,
  100% {
    transform: rotate(2.5deg) translateY(0);
  }
  50% {
    transform: rotate(1deg) translateY(-8px);
  }
}

/* —— content ledger —— */
.ledger {
  padding: 28px 0 64px;
}

.ledger-block {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 22px 18px 8px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.ledger-block::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--rose), var(--mint));
}

.mark-ribbon {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--rose-deep);
  background: rgba(240, 29, 115, 0.08);
  border-radius: 999px;
  padding: 4px 12px;
  margin-bottom: 10px;
}

.ledger-block h2 {
  font-size: clamp(1.25rem, 3vw, 1.55rem);
}

.ledger-block h3 {
  font-size: 1.08rem;
  margin-top: 1.2em;
  color: var(--wine);
}

.split-pane {
  display: grid;
  gap: 16px;
  align-items: start;
  margin: 12px 0 18px;
}

@media (min-width: 780px) {
  .split-pane {
    grid-template-columns: 1.1fr 0.9fr;
  }
  .split-pane.flip {
    grid-template-columns: 0.9fr 1.1fr;
  }
  .split-pane.flip .copy {
    order: 2;
  }
}

.shot-plate {
  margin: 0;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--blush);
  box-shadow: 0 10px 28px rgba(31, 21, 32, 0.08);
}

.shot-plate img {
  width: 100%;
  aspect-ratio: 3/4.2;
  object-fit: cover;
  object-position: top center;
}

.shot-plate figcaption {
  padding: 8px 12px 10px;
  font-size: 12px;
  color: var(--muted);
}

.tile-pack {
  display: grid;
  gap: 12px;
  margin: 14px 0 18px;
}

@media (min-width: 700px) {
  .tile-pack {
    grid-template-columns: repeat(3, 1fr);
  }
}

.tile-card {
  background: linear-gradient(160deg, #fff, var(--blush));
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 14px 14px 8px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tile-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.tile-card h3 {
  margin-top: 0;
  font-size: 1.02rem;
}

.note-soft {
  background: rgba(20, 184, 166, 0.08);
  border-left: 3px solid var(--mint);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  padding: 12px 14px;
  margin: 12px 0 18px;
  color: var(--ink-soft);
}

.mono-rail {
  columns: 1;
  gap: 24px;
}

@media (min-width: 820px) {
  .mono-rail.duo {
    columns: 2;
  }
}

.mono-rail p {
  break-inside: avoid;
}

.crumb {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 16px 0 8px;
}

.crumb a {
  color: var(--ink-soft);
  text-decoration: none;
}

.crumb a:hover {
  color: var(--rose);
}

.legal-page .ledger-block {
  padding-top: 18px;
}

.site-foot {
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.75);
  padding: 28px 0 40px;
  color: var(--muted);
  font-size: 0.92rem;
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-bottom: 12px;
}

.foot-links a {
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 500;
}

.foot-links a:hover {
  color: var(--rose);
}

.fade-rise {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.fade-rise.is-in {
  opacity: 1;
  transform: none;
}

.err-shell {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 40px 16px;
}

.err-shell h1 {
  font-size: clamp(2rem, 8vw, 3.4rem);
  color: var(--rose);
}

.err-shell p {
  max-width: 28em;
  margin-inline: auto;
}

.back-home {
  display: inline-block;
  margin-top: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--rose);
  color: #fff !important;
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(240, 29, 115, 0.3);
}

.back-home:hover {
  background: var(--rose-deep);
  color: #fff !important;
}

@media (prefers-reduced-motion: reduce) {
  .slash-art,
  .fade-rise,
  .tile-card {
    animation: none !important;
    transition: none !important;
  }
  .fade-rise {
    opacity: 1;
    transform: none;
  }
}
