.toracles-v2 .section-shell,
.toracles-v2 .section-detail,
.toracles-v2 .section-grid,
.toracles-v2 .section-footer-nav {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.toracles-v2 .section-shell {
  padding: clamp(34px, 6vw, 76px) 0 28px;
}

.toracles-v2 .breadcrumbs {
  margin: 0 0 18px;
  color: var(--muted);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.toracles-v2 .breadcrumbs a {
  color: var(--text);
}

.toracles-v2 .section-title {
  max-width: 860px;
  margin: 0;
  color: var(--ivory);
  font-family: "Instrument Serif", "Toracles Fell", Georgia, serif;
  font-size: clamp(2.7rem, 6.2vw, 6.2rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: 0;
}

.toracles-v2 .section-intro {
  max-width: 720px;
  margin: 18px 0 0;
  color: rgba(228, 220, 205, 0.82);
  font-size: 1.08rem;
}

.toracles-v2 .source-note {
  max-width: 760px;
  margin: 20px 0 0;
  color: var(--muted);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.72rem;
}

.toracles-v2 .section-tools {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(2, minmax(170px, 0.45fr)) auto;
  gap: 12px;
  align-items: end;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 24px;
  padding: 18px;
  border: 1px solid var(--line);
  background: rgba(19, 19, 24, 0.78);
}

.toracles-v2 .field {
  display: grid;
  gap: 7px;
}

.toracles-v2 .field span {
  color: var(--gold);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.toracles-v2 .field input,
.toracles-v2 .field select {
  min-height: 44px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: #09090b;
  color: var(--ivory);
  padding: 0 12px;
  font: 1rem/1.2 "Source Serif 4", Georgia, serif;
}

.toracles-v2 .section-tools button,
.toracles-v2 .copy-export button,
.toracles-v2 .priority-selector button,
.toracles-v2 .deck-view-toggle button {
  padding: 0 1rem;
}

.toracles-v2 .section-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding-bottom: clamp(34px, 5vw, 64px);
}

.toracles-v2 .archive-card {
  display: grid;
  gap: 12px;
  min-height: 100%;
  border: 1px solid var(--line);
  background: rgba(19, 19, 24, 0.84);
  padding: clamp(18px, 3vw, 26px);
}

.toracles-v2 .archive-card[hidden],
.toracles-v2 .editorial-card[hidden],
.toracles-v2 [data-archive-card][hidden] {
  display: none !important;
}

.toracles-v2 .archive-card h2,
.toracles-v2 .detail-block h2,
.toracles-v2 .detail-block h3,
.toracles-v2 .deck-list h2 {
  margin: 0;
  color: var(--ivory);
  font-family: "Instrument Serif", "Toracles Fell", Georgia, serif;
  font-weight: 400;
  line-height: 1.05;
}

.toracles-v2 .archive-card h2 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
}

.toracles-v2 .archive-card p {
  margin: 0;
}

.toracles-v2 .meta-row,
.toracles-v2 .tag-row,
.toracles-v2 .derived-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.toracles-v2 .meta-row span,
.toracles-v2 .tag-row span,
.toracles-v2 .derived-counts span {
  border: 1px solid rgba(205, 176, 122, 0.24);
  color: var(--muted);
  padding: 0.3rem 0.48rem;
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.68rem;
}

.toracles-v2 .archive-card .button {
  justify-self: start;
  margin-top: auto;
}

.toracles-v2 .section-empty {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto clamp(34px, 5vw, 64px);
  border: 1px solid var(--line);
  padding: 24px;
  background: rgba(19, 19, 24, 0.84);
}

.toracles-v2 .section-empty[hidden] {
  display: none;
}

.toracles-v2 .section-detail {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(22px, 5vw, 64px);
  padding: 0 0 clamp(42px, 6vw, 82px);
}

.toracles-v2 .detail-index {
  position: sticky;
  top: 92px;
  align-self: start;
  border: 1px solid var(--line);
  background: rgba(19, 19, 24, 0.84);
  padding: 18px;
}

.toracles-v2 .detail-index h2 {
  margin: 0 0 10px;
  color: var(--gold);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.toracles-v2 .detail-index a {
  display: block;
  min-height: 44px;
  padding: 9px 0;
  color: var(--text);
}

.toracles-v2 .detail-stack {
  display: grid;
  gap: 18px;
}

.toracles-v2 .detail-block,
.toracles-v2 .deck-list {
  border: 1px solid var(--line);
  background: rgba(19, 19, 24, 0.84);
  padding: clamp(18px, 3vw, 28px);
}

.toracles-v2 .detail-block h2,
.toracles-v2 .deck-list h2 {
  font-size: clamp(2rem, 3.6vw, 3.4rem);
}

.toracles-v2 .detail-block h3 {
  font-size: 1.65rem;
}

.toracles-v2 .priority-selector,
.toracles-v2 .deck-controls {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.toracles-v2 .priority-selector [aria-pressed="true"],
.toracles-v2 .deck-view-toggle [aria-pressed="true"] {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--bg);
}

.toracles-v2 .recommendation-box,
.toracles-v2 .copy-status {
  border-left: 2px solid var(--gold);
  padding-left: 14px;
  color: rgba(228, 220, 205, 0.86);
}

.toracles-v2 .deck-groups {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.toracles-v2 .deck-group {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.toracles-v2 .deck-group h3 {
  margin: 0 0 8px;
  color: var(--gold);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.toracles-v2 .card-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.toracles-v2 [data-deck-detail].is-enhanced > .detail-stack .deck-list > .card-list {
  display: none;
}

.toracles-v2 .card-list li {
  display: grid;
  grid-template-columns: 3.4rem minmax(0, 1fr) auto;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(205, 176, 122, 0.13);
}

.toracles-v2 .card-list small {
  color: var(--muted);
  font-family: "Toracles Mono", ui-monospace, monospace;
  font-size: 0.68rem;
}

.toracles-v2 .copy-export {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.toracles-v2 .fallback-export {
  width: 100%;
  min-height: 160px;
  border: 1px solid var(--line);
  background: #09090b;
  color: var(--ivory);
  padding: 12px;
  font: 0.82rem/1.45 "Toracles Mono", ui-monospace, monospace;
}

.toracles-v2 .fallback-export[hidden] {
  display: none;
}

.toracles-v2 .section-footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 0 0 44px;
}

@media (max-width: 900px) {
  .toracles-v2 .section-tools,
  .toracles-v2 .section-grid,
  .toracles-v2 .section-detail {
    grid-template-columns: 1fr;
  }

  .toracles-v2 .detail-index {
    position: static;
  }
}

@media (max-width: 430px) {
  .toracles-v2 .section-shell,
  .toracles-v2 .section-detail,
  .toracles-v2 .section-grid,
  .toracles-v2 .section-footer-nav,
  .toracles-v2 .section-tools,
  .toracles-v2 .section-empty {
    width: min(100% - 24px, 1180px);
  }

  .toracles-v2 .card-list li {
    grid-template-columns: 2.6rem minmax(0, 1fr);
  }

  .toracles-v2 .card-list small {
    grid-column: 2;
  }
}

/* ASTRA section pages: align Commander/Combos/Mazos with #disector canon */
.toracles-v2 .site-container > .section-shell.section-heading {
  width: 100%;
  margin: 0;
  padding: 88px 0;
}

.toracles-v2 .section-shell.section-heading .section-label {
  margin: 0 0 13px;
  color: var(--gold);
  font-family: "Toracles Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.72rem;
  line-height: 1.58;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.toracles-v2 .section-shell.section-heading .section-title {
  max-width: 760px;
  margin: 0;
  color: var(--ivory);
  font-family: "Instrument Serif", "Toracles Fell", Georgia, serif;
  font-size: clamp(3rem, 4.25vw, 3.16rem);
  font-weight: 400;
  line-height: 1.03;
  letter-spacing: 0;
}

.toracles-v2 .section-shell.section-heading .section-lead-motto,
.toracles-v2 .section-shell.section-heading .archive-description {
  max-width: 760px;
  margin: 17px 0 0;
  color: var(--muted);
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  font-size: 1rem;
  line-height: 1.58;
}

.toracles-v2 .section-shell.section-heading .archive-description p {
  margin: 0;
}
