.ds-lib {
  --ds-ink: #1a120b;
  --ds-muted: #3d4652;
  --ds-paper: #fffcf8;
  --ds-ivory: #faf7f2;
  --ds-sand: #f6e7c8;
  --ds-sand-2: #f3e0c4;
  --ds-line: #e5e1dc;
  --ds-clay: #6e3d28;
  --ds-terra: #8d5036;
  --ds-leaf: #1f4d38;
  --ds-garden: #426b55;
  color: var(--ds-ink);
  font-family: "Segoe UI", "Helvetica Neue", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  max-width: 1080px;
  margin: 0 auto 2rem;
  padding: 0.75rem 0 1.5rem;
  background: transparent;
  position: relative;
  z-index: auto;
}
.ds-lib *,
.ds-lib *::before,
.ds-lib *::after { box-sizing: border-box; }
.ds-lib h1,
.ds-lib h2,
.ds-lib h3,
.ds-lib .ds-panel-title,
.ds-lib .ds-brand,
.ds-lib .ds-clock {
  font-family: "Iowan Old Style", Palatino, "Palatino Linotype", Georgia, serif;
  color: var(--ds-ink);
  line-height: 1.2;
  font-weight: 700;
  margin: 0 0 0.55rem;
}
.ds-lib h1 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.02em; }
.ds-lib h2 { font-size: clamp(1.6rem, 3vw, 2rem); margin-top: 0; }
.ds-lib h3 { font-size: 1.25rem; }
.ds-lib p { margin: 0 0 0.8rem; color: var(--ds-ink); }
.ds-lib .ds-lead,
.ds-lib .ds-quick,
.ds-lib .ds-note,
.ds-lib .ds-muted { color: var(--ds-muted); }
.ds-lib a { color: var(--ds-leaf); text-underline-offset: 2px; }
.ds-lib a:hover,
.ds-lib a:focus,
.ds-lib button:hover,
.ds-lib button:focus,
.ds-lib summary:hover {
  background: var(--ds-sand) !important;
  color: var(--ds-ink) !important;
  outline: none;
}
.ds-lib .ds-btn,
.ds-lib .ds-btn:hover,
.ds-lib .ds-btn:focus,
.ds-lib .ds-day .ds-on,
.ds-lib .ds-day .ds-on:hover,
.ds-lib .ds-day .ds-on:focus {
  background: var(--ds-clay) !important;
  color: #fffaf3 !important;
}
.ds-lib .ds-day .ds-on,
.ds-lib .ds-day .ds-on:hover { background: #1c140c !important; }
.ds-lib .ds-top {
  background: rgba(250, 247, 242, 0.96);
  border: 1px solid var(--ds-line);
  border-radius: 20px;
  padding: 0.9rem 0.9rem 0.7rem;
  margin-bottom: 1.25rem;
}
.ds-lib .ds-brandline { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.75rem; }
.ds-lib .ds-mark {
  width: 40px; height: 40px; border-radius: 12px; background: #1c140c; position: relative; flex: none;
}
.ds-lib .ds-mark::before {
  content: "";
  position: absolute; left: 8px; right: 8px; top: 12px; height: 16px;
  border: 2px solid #f3e0c4; border-bottom: 0; border-radius: 14px 14px 0 0;
}
.ds-lib .ds-brand { display: block; font-size: 1.45rem; text-decoration: none; color: var(--ds-ink); line-height: 1; }
.ds-lib .ds-brand:hover { background: transparent !important; }
.ds-lib .ds-tag { display: block; margin-top: 0.2rem; color: var(--ds-muted); font-size: 0.78rem; }
.ds-lib .ds-nav {
  display: flex; gap: 0.25rem; overflow-x: auto; padding-bottom: 0.35rem; margin: 0;
}
.ds-lib .ds-nav a {
  flex: none; text-decoration: none; color: var(--ds-ink); background: transparent;
  border-radius: 10px; padding: 0.45rem 0.75rem; font-size: 0.92rem; font-weight: 700; white-space: nowrap;
}
.ds-lib .ds-nav a[aria-current="page"],
.ds-lib .ds-nav a:hover { background: var(--ds-sand-2) !important; color: var(--ds-ink) !important; }
.ds-lib .ds-search {
  margin: 1rem 0 0;
  border: 2px solid var(--ds-terra);
  background: #fffaf3;
  border-radius: 28px;
  padding: 0.85rem;
  box-shadow: 0 16px 50px rgba(141, 80, 54, 0.16);
}
.ds-lib .ds-kicker {
  margin: 0 0 0.35rem; padding: 0 0.35rem;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ds-clay);
}
.ds-lib .ds-search-row { display: flex; flex-wrap: wrap; gap: 0.7rem; align-items: center; }
.ds-lib .ds-search-field { position: relative; flex: 1 1 240px; background: #fff; border-radius: 16px; min-height: 58px; }
.ds-lib .ds-rotator {
  position: absolute; left: 1rem; right: 1rem; top: 50%; transform: translateY(-50%);
  color: #5c4030; font-size: 1.15rem; pointer-events: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ds-lib .ds-search input[type="search"] {
  width: 100%; border: 0; background: transparent; color: var(--ds-ink);
  font: inherit; font-size: 1.2rem; padding: 0.95rem 1rem; border-radius: 16px; min-height: 58px;
}
.ds-lib .ds-search input:focus { outline: 2px solid var(--ds-sand-2); }
.ds-lib .ds-btn,
.ds-lib .ds-ghost,
.ds-lib button,
.ds-lib input,
.ds-lib select,
.ds-lib textarea { font: inherit; }
.ds-lib .ds-btn {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 14px; padding: 0.75rem 1.15rem; font-weight: 700; cursor: pointer; text-decoration: none;
  min-height: 46px;
}
.ds-lib .ds-btn-lg { min-height: 56px; padding: 0.85rem 1.3rem; font-size: 1.05rem; border-radius: 16px; }
.ds-lib .ds-ghost {
  display: inline-flex; align-items: center; border: 1px solid var(--ds-line); background: var(--ds-paper);
  color: var(--ds-ink); border-radius: 14px; padding: 0.65rem 0.95rem; font-weight: 700; cursor: pointer; text-decoration: none;
}
.ds-lib .ds-actions { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0 0 0.8rem; }
.ds-lib .ds-actions .ds-btn,
.ds-lib .ds-actions .ds-ghost { min-height: 40px; padding: 0.4rem 0.8rem; font-size: 0.92rem; }
.ds-lib .ds-hero { display: grid; gap: 1.2rem; align-items: end; margin-bottom: 1.2rem; }
.ds-lib .ds-panel {
  background: var(--ds-paper); border: 1px solid var(--ds-line); border-radius: 24px; padding: 1.1rem 1.15rem;
}
.ds-lib .ds-panel-title { font-size: 1.7rem; }
.ds-lib .ds-chips { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0.9rem 0 0.2rem; }
.ds-lib .ds-chips a {
  text-decoration: none; color: var(--ds-ink); background: var(--ds-paper);
  border: 1px solid var(--ds-line); border-radius: 999px; padding: 0.45rem 0.8rem; font-size: 0.92rem;
}
.ds-lib .ds-section { position: static; width: auto; height: auto; margin-top: 2.4rem; clear: both; background: transparent; }
.ds-lib .ds-explore { margin-top: 0.9rem; }
.ds-lib ul.ds-list,
.ds-lib ul.ds-grid {
  list-style: none !important;
  margin: 0.8rem 0 0 !important;
  padding: 0 !important;
  display: grid !important;
  gap: 0.75rem;
  width: 100%;
  position: static;
}
.ds-lib ul.ds-grid { grid-template-columns: 1fr; }
.ds-lib .ds-list > li,
.ds-lib .ds-grid > li {
  float: none !important;
  width: auto !important;
  min-width: 0;
  margin: 0 !important;
  position: static;
}
.ds-lib .ds-list a,
.ds-lib .ds-grid a {
  display: block; height: 100%; text-decoration: none; color: var(--ds-ink) !important;
  background: var(--ds-paper); border: 1px solid var(--ds-line); border-radius: 18px; padding: 1rem 1.05rem;
  position: relative; z-index: 1; pointer-events: auto;
  overflow-wrap: anywhere;
}
.ds-lib .ds-list a:hover,
.ds-lib .ds-grid a:hover { border-color: var(--ds-terra); background: #fffaf3 !important; color: var(--ds-ink) !important; }
.ds-lib .ds-list strong,
.ds-lib .ds-grid strong { display: block; font-family: "Iowan Old Style", Palatino, Georgia, serif; font-size: 1.35rem; font-weight: 700; }
.ds-lib .ds-list span,
.ds-lib .ds-grid span { display: block; margin-top: 0.35rem; color: var(--ds-muted); font-weight: 400; font-size: 0.95rem; }
.ds-lib .ds-day[data-day] {
  margin-top: 1.4rem; overflow: hidden; border-radius: 24px; border: 1px solid #e5d5c0; background: #1c140c; color: #fffaf3;
}
.ds-lib .ds-plan { margin: 1rem 0; padding: 0.2rem 0; position: static; width: auto; height: auto; background: transparent; color: var(--ds-ink); overflow: visible; }
.ds-lib .ds-day-stage { position: relative; min-height: 280px; }
.ds-lib .ds-day-sky { position: relative; min-height: 280px; overflow: hidden; }
.ds-lib .ds-sky-dawn { background: linear-gradient(#f2c9a0, #f7e7cf 45%, #8ea4c5); }
.ds-lib .ds-sky-lane { background: linear-gradient(#f6d7a8, #f3e6cf 50%, #d7c4a4); }
.ds-lib .ds-sky-metro { background: linear-gradient(#9eb6d4, #d5e2ef 48%, #f4efe6); }
.ds-lib .ds-sky-garden { background: linear-gradient(#87b08a, #d7e3cf 46%, #f6f1e6); }
.ds-lib .ds-sky-evening { background: linear-gradient(#1d3354, #c47a4a 58%, #f0d2a8); }
.ds-lib .ds-sky-night { background: linear-gradient(#141a2a, #3a2a22 55%, #e0b15a); }
.ds-lib .ds-skyline { position: absolute; inset: auto 0 0 0; height: 120px; }
.ds-lib .ds-skyline .ds-dome,
.ds-lib .ds-skyline .ds-skyblock,
.ds-lib .ds-skyline .ds-gate,
.ds-lib .ds-skyline .ds-wheel,
.ds-lib .ds-skyline .ds-road,
.ds-lib .ds-skyline .ds-train {
  position: absolute; display: block;
}
.ds-lib .ds-dome { left: 8%; bottom: 28px; width: 64px; height: 96px; background: #1c140c; border-radius: 40px 40px 0 0; }
.ds-lib .ds-skyblock { left: 18%; bottom: 28px; width: 40px; height: 64px; background: #24180f; }
.ds-lib .ds-gate { left: 46%; bottom: 28px; width: 80px; height: 112px; background: #1c140c; }
.ds-lib .ds-gate::after { content: ""; position: absolute; left: 26px; top: 24px; width: 24px; height: 40px; border: 4px solid #f3e0c4; }
.ds-lib .ds-wheel { right: 12%; bottom: 36px; width: 80px; height: 80px; border: 10px solid #1c140c; border-radius: 50%; }
.ds-lib .ds-road { left: 0; right: 0; bottom: 18px; height: 12px; background: #3a2414; }
.ds-lib .ds-train {
  left: -15%; bottom: 30px; width: 96px; height: 32px; border-radius: 8px; background: #8d5036;
  animation: ds-drift 14s linear infinite;
}
.ds-lib .ds-train i { display: inline-block; width: 12px; height: 16px; margin: 6px 0 0 10px; background: #f6e7c8; }
.ds-lib .ds-scene-card {
  position: absolute; left: 16px; right: 16px; top: 16px; border-radius: 18px;
  background: rgba(28, 20, 12, 0.82); color: #fffaf3; padding: 1rem 1.05rem;
  animation: ds-fade 5.5s ease infinite;
}
.ds-lib .ds-scene-card h2,
.ds-lib .ds-scene-card p { color: #fffaf3; }
.ds-lib .ds-scene-card .ds-kicker { color: #f3e0c4; padding: 0; }
.ds-lib .ds-day-bar { display: flex; flex-wrap: wrap; gap: 0.45rem; align-items: center; padding: 0.9rem; }
.ds-lib .ds-day-btn {
  border: 0; border-radius: 999px; background: #3a2414; color: #fffaf3; font-weight: 700; padding: 0.45rem 0.75rem; cursor: pointer;
}
.ds-lib .ds-day-btn:hover,
.ds-lib .ds-day-btn:focus { background: #3a2414 !important; color: #fffaf3 !important; }
.ds-lib .ds-day .ds-ghost { background: #fffaf3; color: #1a120b; border-color: #f3e0c4; }
.ds-lib .ds-day .ds-btn { background: #8d5036 !important; }
.ds-lib .ds-crumbs { margin: 0 0 0.6rem; font-size: 0.92rem; }
.ds-lib .ds-crumbs ol { display: flex; flex-wrap: wrap; gap: 0.35rem; list-style: none; margin: 0; padding: 0; }
.ds-lib .ds-crumbs li::after { content: "/"; margin-left: 0.35rem; color: #8a8176; }
.ds-lib .ds-crumbs li:last-child::after { content: ""; }
.ds-lib .ds-body { padding: 0.2rem 0.15rem 0; }
.ds-lib .ds-foot {
  margin-top: 2rem; border-top: 1px solid var(--ds-line); background: var(--ds-paper);
  border-radius: 18px; padding: 1.1rem 1.15rem; color: var(--ds-muted); font-size: 0.95rem;
}
.ds-lib .ds-foot .ds-brand { font-size: 1.25rem; margin-bottom: 0.3rem; }
.ds-lib .ds-facts, .ds-lib .ds-lines { margin: 0.8rem 0; }
.ds-lib .ds-facts div, .ds-lib .ds-lines div {
  display: grid; grid-template-columns: minmax(120px, 34%) 1fr; gap: 0.5rem;
  padding: 0.55rem 0; border-bottom: 1px solid var(--ds-line);
}
.ds-lib dt { font-weight: 700; }
.ds-lib dd { margin: 0; }
.ds-lib .ds-steps, .ds-lib .ds-bullets, .ds-lib .ds-review { margin: 0.4rem 0 1rem; padding-left: 1.2rem; }
.ds-lib .ds-review { list-style: none; padding: 0; display: grid; gap: 0.75rem; }
.ds-lib .ds-review li { background: var(--ds-paper); border: 1px solid var(--ds-line); border-radius: 16px; padding: 0.9rem 1rem; }
.ds-lib .ds-review .is-right { border-color: #b7d4c4; }
.ds-lib .ds-review .is-wrong { border-color: #e7c3b4; }
.ds-lib .ds-q-prompt { font-size: 1.2rem; font-weight: 700; margin-bottom: 0.7rem; }
.ds-lib .ds-clock { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: 0.8rem 0; }
.ds-lib .ds-clock-sep { color: var(--ds-terra); }
.ds-lib .ds-qcard { margin-top: 0.4rem; }
.ds-lib .ds-q { border: 0; margin: 0; padding: 0; min-width: 0; }
.ds-lib .ds-quiz.is-step .ds-q { display: none; }
.ds-lib .ds-quiz.is-step .ds-q.is-on { display: block; }
.ds-lib .ds-choice {
  display: flex; align-items: flex-start; gap: 0.7rem; min-height: 48px;
  border: 1px solid var(--ds-line); border-radius: 14px; padding: 0.75rem 0.85rem; margin: 0 0 0.5rem; background: #fff;
}
.ds-lib .ds-choice:hover { background: var(--ds-sand) !important; color: var(--ds-ink) !important; }
.ds-lib .ds-form, .ds-lib .ds-filter { margin: 0.8rem 0 1rem; }
.ds-lib .ds-fields { display: grid; gap: 0.75rem; }
.ds-lib label span, .ds-lib .ds-filter label { display: block; font-weight: 700; margin-bottom: 0.25rem; }
.ds-lib input, .ds-lib select, .ds-lib textarea {
  width: 100%; color: var(--ds-ink); background: #fff; border: 1px solid #c9b89a; border-radius: 12px; padding: 0.65rem 0.75rem;
}
.ds-lib textarea { min-height: 8rem; }
.ds-lib .ds-result, .ds-lib .ds-score { margin-top: 0.8rem; }
.ds-lib .ds-error { color: #8c2f2f; font-weight: 700; }
.ds-lib .ds-pager { display: flex; gap: 0.6rem; align-items: center; margin-top: 1rem; }
.ds-lib .ds-pager a { font-weight: 700; }
.ds-lib .ds-check { list-style: none; margin: 0.6rem 0; padding: 0; display: grid; gap: 0.45rem; }
.ds-lib .ds-check label {
  display: flex; gap: 0.7rem; align-items: flex-start; background: var(--ds-paper);
  border: 1px solid var(--ds-line); border-radius: 14px; padding: 0.75rem 0.85rem;
}
.ds-lib .ds-check input { width: auto; margin-top: 0.25rem; }
.ds-lib .ds-time { border-left: 3px solid var(--ds-terra); margin: 0.5rem 0 1rem; padding-left: 1rem; }
.ds-lib .ds-letter-out, .ds-lib pre {
  white-space: pre-wrap; overflow-wrap: anywhere; background: var(--ds-paper);
  border: 1px solid var(--ds-line); border-radius: 16px; padding: 1rem;
}
.ds-lib .ds-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.ds-lib [hidden] { display: none !important; }
.ds-lib .ds-print-url { display: none; }
@media (min-width: 720px) {
  .ds-lib .ds-hero { grid-template-columns: 1.2fr 0.8fr; }
  .ds-lib ul.ds-grid { grid-template-columns: 1fr 1fr; }
  .ds-lib .ds-fields.ds-2 { grid-template-columns: 1fr 1fr; }
  .ds-lib .ds-scene-card { left: auto; width: min(440px, 70%); right: 16px; }
}
@media (min-width: 980px) {
  .ds-lib ul.ds-grid { grid-template-columns: 1fr 1fr 1fr; }
}
@keyframes ds-drift { from { left: -15%; } to { left: 105%; } }
@keyframes ds-fade {
  0% { opacity: 0; transform: translateY(6px); }
  12% { opacity: 1; transform: translateY(0); }
  80% { opacity: 1; }
  100% { opacity: 0.35; }
}
@media (prefers-reduced-motion: reduce) {
  .ds-lib .ds-train, .ds-lib .ds-scene-card { animation: none; }
}
@media print {
  .ds-lib .ds-nav, .ds-lib .ds-search, .ds-lib .ds-actions, .ds-lib .ds-day-bar, .ds-lib .ds-noprint { display: none !important; }
  .ds-lib .ds-print-url { display: block; }
}
