/* 2026 guide pages and blog desk. All colors come from common.css tokens. */
.guide-page {
  background: var(--bg-primary);
  color: var(--text-primary);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 0.75rem 1rem;
  background: var(--gold);
  color: var(--bg-primary);
  font-weight: 800;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.guide-page :focus-visible,
.guide-page a:focus-visible,
.guide-page button:focus-visible,
.guide-page input:focus-visible,
.guide-page select:focus-visible,
.guide-page summary:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 3px;
}

.guide-nav .nav-links a {
  font-size: 0.82rem;
}

.guide-hero {
  padding-top: 1.25rem;
  padding-bottom: 2.5rem;
}

.guide-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
}

.guide-hero-copy h1 {
  margin: 0.35rem 0 0.85rem;
  max-width: 18ch;
}

.guide-hero-copy .hero-sub {
  max-width: 62ch;
}

.guide-meta {
  margin-top: 1rem;
  color: var(--text-dim);
  font-size: 0.86rem;
}

.guide-hero-media {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-elevated);
  box-shadow: var(--shadow-panel);
}
.guide-hero-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.guide-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: start;
  padding: 1.5rem 0 4rem;
}

.guide-article {
  min-width: 0;
}

.guide-answer {
  border-left: 4px solid var(--gold);
  background: var(--surface-card);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.1rem 1.25rem;
  margin-bottom: 1.5rem;
}
.guide-answer h2 {
  margin: 0.15rem 0 0.45rem;
}
.guide-answer p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1.02rem;
  line-height: 1.7;
}

.guide-section,
.guide-faq,
.guide-sources,
.guide-support,
.guide-tool {
  margin: 2.25rem 0;
}
.guide-section h2,
.guide-faq h2,
.guide-sources h2,
.guide-support h2,
.guide-tool h2 {
  margin-bottom: 0.65rem;
}
.guide-section h3 {
  margin: 1.35rem 0 0.4rem;
}
.guide-section p,
.guide-section li,
.guide-faq-answer,
.guide-sources p {
  color: var(--text-secondary);
  line-height: 1.75;
}
.guide-section p + p {
  margin-top: 0.75rem;
}
.guide-section ul,
.guide-section ol {
  margin: 0.6rem 0 0.9rem 1.2rem;
}
.guide-section li + li {
  margin-top: 0.35rem;
}

.guide-table-wrap {
  overflow-x: auto;
  margin: 1rem 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.guide-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
  font-size: 0.94rem;
}
.guide-table th,
.guide-table td {
  padding: 0.7rem 0.8rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.guide-table th {
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-weight: 800;
}
.guide-table tr:last-child td {
  border-bottom: 0;
}

.guide-toc {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-card-soft);
  padding: 1rem 1.15rem;
  margin: 1.5rem 0;
}
.guide-toc-title {
  margin: 0 0 0.5rem;
  color: var(--gold);
  font-family: var(--font-sub);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.guide-toc ol {
  margin: 0;
  padding-left: 1.2rem;
  columns: 2;
  column-gap: 2rem;
}
.guide-toc li {
  margin: 0.28rem 0;
  break-inside: avoid;
}
.guide-toc a {
  color: var(--text-secondary);
}
.guide-toc a:hover {
  color: var(--gold);
}

.guide-key-facts {
  margin: 0.5rem 0 0;
  padding-left: 1.1rem;
  color: var(--text-secondary);
}
.guide-key-facts li + li {
  margin-top: 0.45rem;
}

.guide-aside {
  position: sticky;
  top: 1rem;
  display: grid;
  gap: 1rem;
}
.guide-aside-card {
  padding: 1.1rem;
}
.guide-aside-card h2 {
  font-size: 1.05rem;
  margin: 0 0 0.45rem;
}
.guide-aside-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.guide-related-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.7rem;
}
.guide-related-list a {
  display: block;
  color: var(--gold);
  font-weight: 800;
}
.guide-related-list span {
  display: block;
  color: var(--text-dim);
  font-size: 0.82rem;
  line-height: 1.45;
}

.guide-tool {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface-strong);
  padding: clamp(1.1rem, 3vw, 1.6rem);
  box-shadow: var(--shadow-soft);
}
.guide-tool-head p {
  color: var(--text-secondary);
}
.guide-tool-note,
.guide-tool-privacy {
  color: var(--text-dim);
  font-size: 0.82rem;
  margin: 0.75rem 0 0;
}

.tool-panel {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
}
.tool-fieldset {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  margin: 0 0 0.9rem;
}
.tool-fieldset legend {
  padding: 0 0.35rem;
  color: var(--text-primary);
  font-weight: 800;
}
.tool-check {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.35rem 0;
  color: var(--text-secondary);
  cursor: pointer;
}
.tool-check input {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--gold);
}
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.85rem;
  margin-bottom: 0.9rem;
}
.tool-field {
  display: grid;
  gap: 0.3rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}
.tool-field select,
.tool-field input {
  width: 100%;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: var(--bg-primary);
  color: var(--text-primary);
  font: inherit;
}
.tool-progress {
  height: 0.55rem;
  border-radius: 999px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  overflow: hidden;
  margin: 0.4rem 0 0.7rem;
}
.tool-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--gold), var(--cyan));
  transition: width 180ms ease;
}
.tool-result {
  color: var(--text-primary);
  font-weight: 800;
  margin: 0.4rem 0;
}
.tool-next {
  color: var(--text-secondary);
  margin: 0.2rem 0 0.7rem;
}
.tool-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.7rem;
}
.tool-filter-row .is-active {
  border-color: var(--gold);
  color: var(--gold);
}
.tool-code-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem;
  text-align: center;
  background: var(--bg-primary);
}
.tool-code-label {
  color: var(--text-dim);
  margin: 0;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.tool-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.7rem;
  color: var(--gold);
  margin: 0.2rem 0 0.6rem;
  letter-spacing: 0.08em;
}
.tool-canvas {
  display: block;
  width: 100%;
  max-width: 360px;
  height: auto;
  margin: 0.9rem auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-primary);
}
.tool-fix-list {
  margin: 0.8rem 0 0 1.2rem;
  color: var(--text-secondary);
}
.tool-fix-list li + li {
  margin-top: 0.45rem;
}
.is-hidden {
  display: none !important;
}
.guide-table tr[hidden] {
  display: none;
}

.guide-faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-card-soft);
  padding: 0.85rem 1rem;
  margin: 0.55rem 0;
}
.guide-faq-item summary {
  cursor: pointer;
  color: var(--text-primary);
  font-weight: 800;
  list-style: none;
}
.guide-faq-item summary::-webkit-details-marker {
  display: none;
}
.guide-faq-item summary::after {
  content: "+";
  float: right;
  color: var(--gold);
}
.guide-faq-item[open] summary::after {
  content: "−";
}
.guide-faq-answer {
  margin-top: 0.55rem;
  font-size: 0.96rem;
}

.guide-sources {
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
}
.guide-sources p {
  font-size: 0.9rem;
}
.guide-sources a {
  color: var(--cyan);
}

.guide-support {
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  background: var(--surface-card);
  padding: 1.25rem;
}
.guide-support p {
  color: var(--text-secondary);
}

.guide-footer {
  margin-top: 2rem;
}

/* Blog desk */
.blog-desk-hero {
  padding-bottom: 1.5rem;
}
.blog-desk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.15rem;
}
.blog-desk-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
}
.blog-desk-card img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-bottom: 1px solid var(--border);
}
.blog-desk-card-body {
  padding: 1rem 1.05rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  flex: 1;
}
.blog-desk-card h3 {
  margin: 0;
}
.blog-desk-card p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 0.93rem;
}
.blog-desk-meta {
  color: var(--text-dim) !important;
  font-size: 0.8rem !important;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.blog-desk-card .btn {
  margin-top: auto;
  align-self: flex-start;
}
.blog-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.5rem;
}
.blog-filter-row button.is-active {
  border-color: var(--gold);
  color: var(--gold);
}
.blog-desk-card[hidden] {
  display: none;
}
.blog-tool-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
}

@media (max-width: 980px) {
  .guide-hero-grid,
  .guide-layout {
    grid-template-columns: 1fr;
  }
  .guide-aside {
    position: static;
  }
  .guide-hero-copy h1 {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .guide-toc ol {
    columns: 1;
  }
  .guide-table {
    min-width: 0;
  }
  .guide-table th,
  .guide-table td {
    padding: 0.55rem 0.5rem;
    font-size: 0.86rem;
  }
  .tool-code {
    font-size: 1.4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tool-progress span {
    transition: none;
  }
  .animate-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
