/* Styles for consistency.html: the three prompt cards, the data rule box and the practice files.
   Builds on styles.css (tokens, nav, hero, footer, buttons) and paper.css (sections, body copy,
   badge, ghost button, toast). Additive: changes nothing in either. */

.skip-link { position: absolute; left: 24px; top: -100px; z-index: 50; background: var(--ink); color: var(--page); padding: 14px; }
.skip-link:focus { top: 16px; }

/* Coral buttons carry dark text here: cream on coral is too faint at this size. */
.consistency-page .button-primary,
.consistency-page .nav-cta-primary,
.consistency-page .nav-cta-primary:hover { color:var(--ink)!important; }

/* ---------- hero: shorter than the other detail pages, because this one is opened on a phone ---------- */
.consistency-page .detail-hero { min-height: auto; }
.consistency-page .detail-hero-inner { padding: 104px 0 88px; }
.consistency-page .detail-hero .hero-lede { max-width: 600px; }
.jump-row { display: flex; flex-wrap: wrap; gap: 6px 28px; margin-top: 36px; }
.jump-row .text-link { padding: 10px 0; }
.jump-row .text-link span { color:var(--label); }

/* ---------- the cards ---------- */
.prompt-card {
  background: var(--panel); border: 1px solid var(--line); border-top: 2px solid var(--rule);
  padding: 28px 28px 24px; scroll-margin-top: 24px;
}
.paper-body > .prompt-card { margin-top: 34px; }
.prompt-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 14px; }
.prompt-index { font: 12px 'IBM Plex Mono', monospace; color:var(--label); }
.paper-body .prompt-card h3 { margin-top: 0; font-size: 26px; line-height: 1.15; }
.prompt-head .badge { margin-left: auto; align-self: center; }
.paper-body .prompt-tag { margin-top: 8px; color: var(--ink); font-size: 17px; line-height: 1.5; }

.prompt-io { margin-top: 20px; border-top: 1px solid var(--line); }
.prompt-io > div { display: grid; grid-template-columns: 112px 1fr; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.prompt-io dt { font: 11px 'IBM Plex Mono', monospace; text-transform: uppercase; letter-spacing: .07em; color:var(--label); padding-top: 5px; }
.prompt-io dd { color: var(--muted); font-size: 15.5px; line-height: 1.65; }

.prompt-text { margin-top: 22px; background: var(--page); border: 1px solid var(--line); border-left: 2px solid var(--rule); padding: 20px 22px; }
.paper-body .prompt-text p { color: var(--ink); font-size: 15.5px; line-height: 1.7; }
.prompt-text p + p { margin-top: 14px; }
.prompt-text .fill { color:var(--label); }

.prompt-actions { margin-top: 18px; }
.copy-button[hidden] { display: none; }
.button-row .toast { flex: 1 1 200px; min-height: 0; line-height: 1.6; }
.paper-body .prompt-note { margin-top: 18px; font-size: 14.5px; line-height: 1.7; }

/* ---------- the data rule ---------- */
.data-rule { border: 2px solid var(--rule); background: rgba(23,23,23,.045); padding: 30px 30px 28px; scroll-margin-top: 24px; }
.paper-body .data-rule h2 { font-size: clamp(28px, 3.4vw, 40px); }
.paper-body .data-rule p { color: var(--ink); font-size: 17px; line-height: 1.6; margin-top: 14px; }

/* ---------- practice files ---------- */
.paper-body .file-list { list-style: none; padding: 0; gap: 0; border-top: 1px solid var(--line); margin-top: 30px; }
.file-item { padding: 26px 0; border-bottom: 1px solid var(--line); }
.paper-body .file-item h3 { margin-top: 0; color: var(--ink); }
.paper-body .file-name { font: 12px/1.6 'IBM Plex Mono', monospace; color:var(--label); margin-top: 6px; overflow-wrap: anywhere; }
.paper-body .file-item p { font-size: 15.5px; line-height: 1.7; }
.paper-body .file-item p:not(.file-name) { margin-top: 10px; }
.file-actions { margin-top: 18px; }
.paper-body .practice-note { font-size: 15px; }

/* ---------- closing ---------- */
.consistency-page .detail-cta h2 { font-size: clamp(32px, 4.4vw, 56px); max-width: 820px; }
.talk-body { margin-top: 28px; }
.talk-actions { margin-top: 34px; }

/* ---------- between phone width and the 1280px column ----------
   The shared sections have no side margin of their own, so on a tablet or a small laptop they run
   to the edge of the screen. Here they keep the same gutter as the hero. */
@media (min-width: 761px) {
  .consistency-page .paper-section,
  .consistency-page .detail-cta,
  .consistency-page .footer { width: calc(100% - 2 * clamp(24px, 6vw, 96px)); }
}

/* ---------- small screens ---------- */
@media (max-width: 760px) {
  .consistency-page .detail-hero-inner { padding: 64px 0 56px; }
  .consistency-page .detail-hero h1 { font-size: clamp(34px, 10.4vw, 60px); }
  .jump-row { margin-top: 28px; }
  .prompt-card { padding: 22px 16px 20px; }
  .prompt-io > div { grid-template-columns: 1fr; gap: 2px; }
  .prompt-io dt { padding-top: 0; }
  .prompt-text { padding: 16px 14px; }
  .prompt-actions .button, .file-actions .button, .talk-actions .button { width: 100%; justify-content: space-between; }
  .button-row .toast { flex-basis: 100%; }
  .data-rule { padding: 24px 18px 22px; }
  .paper-body .data-rule p { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

@media print {
  .jump-row, .copy-button, .file-actions, .skip-link { display: none !important; }
  .prompt-card, .prompt-text, .data-rule { background: #fff; border-color: #999; break-inside: avoid; }
  .consistency-page .paper-body p, .consistency-page .paper-body h2, .consistency-page .paper-body h3,
  .prompt-io dd, .prompt-io dt, .prompt-text .fill { color: #111 !important; }
}
