/* ==========================================================================
   markuswenz.de — Editorial Dossier preset
   Display: Playfair Display 900 / Body: Public Sans 400/600 / Mono: IBM Plex Mono 500
   ========================================================================== */

:root {
  --page: #FFFFFF;
  --panel: #FAF7F0;
  --olive: #3E4A26;
  --ink: #111111;
  --orange: #D2601A;
  --action: #1B5FCB;
  --action-dark: #14479A;
  --body-grey: #4A4238;
  --shadow: 6px 6px 0 0 var(--ink);
  --radius: 0;

  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Public Sans', -apple-system, Segoe UI, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body { margin: 0; background: var(--page); color: var(--body-grey); font-family: var(--font-body); font-size: 16px; line-height: 1.6; }
img { max-width: 100%; display: block; }
a { color: var(--action); }
.container { max-width: 1180px; margin-inline: auto; padding-inline: 1.5rem; }

h1, h2, h3 { font-family: var(--font-display); color: var(--ink); font-weight: 900; line-height: 1.12; margin: 0 0 0.6em; }
h1 { font-size: clamp(2rem, 4.6vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.3rem); }
p { margin: 0 0 1em; max-width: 68ch; }
.mono { font-family: var(--font-mono); }

.box-shadow { box-shadow: var(--shadow); }

/* Header */
.site-header { background: var(--page); border-bottom: 2px solid var(--ink); position: relative; z-index: 30; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding-block: 0.85rem; }
.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--ink); }
.brand img { width: 40px; height: 40px; }
.brand-name { font-family: var(--font-display); font-size: 1.5rem; font-weight: 900; }
.brand-name .accent { color: var(--orange); }

.nav-toggle { position: absolute; clip: rect(0 0 0 0); clip-path: inset(50%); height: 1px; width: 1px; overflow: hidden; white-space: nowrap; }
.nav-btn { display: none; align-items: center; gap: 0.5rem; background: var(--ink); color: #fff; border: none; padding: 0.6rem 0.9rem; font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.05em; cursor: pointer; }
.nav-toggle:focus-visible + .nav-btn { outline: 3px solid var(--orange); outline-offset: 2px; }
.hamburger { position: relative; width: 18px; height: 2px; background: #fff; }
.hamburger::before, .hamburger::after { content: ""; position: absolute; left: 0; width: 18px; height: 2px; background: #fff; }
.hamburger::before { top: -6px; }
.hamburger::after { top: 6px; }
.nav-btn .label-close { display: none; }
.nav-toggle:checked ~ .nav-btn .label-open { display: none; }
.nav-toggle:checked ~ .nav-btn .label-close { display: inline; }

.site-nav ul { list-style: none; display: flex; gap: 1.7rem; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; color: var(--ink); font-family: var(--font-mono); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; padding: 0.4rem 0; border-bottom: 2px solid transparent; }
.site-nav a:hover, .site-nav a:focus-visible { border-bottom-color: var(--orange); }

@media (max-width: 900px) {
  .nav-btn { display: inline-flex; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--page); border-bottom: 2px solid var(--ink); }
  .nav-toggle:checked ~ .site-nav { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 0.5rem 1.5rem 1rem; }
  .site-nav a { display: flex; align-items: center; padding: 0.75rem 0; min-height: 44px; border-bottom: 1px solid rgba(17,17,17,0.1); }
}

/* Hero */
.hero { padding-block: 1.4rem 0.7rem; }
@media (max-width: 700px) { .hero { padding-block: 0.9rem 0.6rem; } }
.hero-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 2.2rem; align-items: start; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }
.hero-copy { text-align: left; }
.hero-lede { font-size: 1.05rem; max-width: 62ch; }

.hero-more { margin: 0 0 0.9rem; max-width: 62ch; }
.hero-more summary { cursor: pointer; font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--orange); font-weight: 700; list-style: none; display: inline-flex; align-items: center; gap: 0.35rem; min-height: 32px; }
.hero-more summary::-webkit-details-marker { display: none; }
.hero-more summary::after { content: "+"; font-size: 1rem; }
.hero-more[open] summary::after { content: "\2212"; }
.hero-more p { margin-top: 0.6rem; font-size: 0.92rem; }

.byline-row { display: flex; align-items: center; gap: 0.9rem; margin-top: 0.7rem; padding: 0.55rem 0.9rem; background: var(--panel); border: 1px solid var(--ink); max-width: 560px; }
.byline-row img { width: 52px; height: 52px; object-fit: cover; border: 1px solid var(--ink); }
.byline-text { line-height: 1.25; }
.byline-name { font-weight: 700; color: var(--ink); white-space: nowrap; }
.byline-role-long { display: inline; font-size: 0.85rem; }
.byline-role-short { display: none; font-size: 0.85rem; }
.byline-stats { margin-left: auto; display: flex; gap: 0.9rem; border-left: 1px solid var(--ink); padding-left: 0.9rem; font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; color: var(--body-grey); white-space: nowrap; }
.byline-stats strong { display: block; color: var(--orange); font-family: var(--font-display); font-size: 1rem; }

@media (max-width: 700px) {
  .byline-row { gap: 0.6rem; padding: 0.55rem 0.7rem; }
  .byline-row img { width: 40px; height: 40px; }
  .byline-role-long { display: none; }
  .byline-role-short { display: inline; }
  .byline-stats { gap: 0.6rem; padding-left: 0.6rem; font-size: 0.6rem; }
  .byline-stats strong { font-size: 0.85rem; }
}
@media (max-width: 360px) { .byline-row { padding: 0.45rem 0.55rem; } .byline-name { font-size: 0.9rem; } .byline-stats { gap: 0.4rem; } }

/* Hero widget: tier ladder replacing editor's choice */
.tier-widget { position: relative; border: 2px solid var(--ink); background: var(--page); padding: 1.1rem; box-shadow: var(--shadow); }
@media (max-width: 900px) { .tier-widget { display: none; } }
.tier-widget-kicker { font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--orange); display: block; margin-bottom: 0.6rem; }
.tier-ladder { list-style: none; margin: 0 0 0.9rem; padding: 0; display: grid; gap: 0.4rem; }
.tier-ladder li { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 0.82rem; padding: 0.3rem 0.5rem; border: 1px solid rgba(17,17,17,0.15); }
.tier-ladder li.win { background: var(--ink); color: #fff; font-weight: 700; border-color: var(--ink); }
.tier-brand { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.7rem; padding-top: 0.7rem; border-top: 1px dashed rgba(17,17,17,0.25); }
.tier-brand img { width: 40px; height: 40px; object-fit: contain; }
.tier-brand strong { font-family: var(--font-display); font-size: 1.1rem; }
.tier-offer { background: var(--panel); border-left: 3px solid var(--orange); padding: 0.6rem 0.7rem; font-size: 0.88rem; margin-bottom: 0.8rem; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; background: var(--action); color: #fff; text-decoration: none; font-family: var(--font-body); font-weight: 700; font-size: 0.88rem; padding: 0.72rem 1.1rem; border: none; cursor: pointer; min-height: 44px; }
.btn:hover, .btn:focus-visible { background: var(--action-dark); }
.btn.full { width: 100%; }

/* Ranked list — table mode */
.ranked-section { padding-block: 0.6rem 2rem; }
.table-wrap { overflow-x: auto; margin-top: 1rem; border: 2px solid var(--ink); }
table.rank-table { width: 100%; border-collapse: collapse; table-layout: fixed; background: var(--page); }
table.rank-table thead th { background: var(--ink); color: #fff; font-family: var(--font-mono); text-transform: uppercase; font-size: 0.7rem; letter-spacing: 0.05em; padding: 0.7rem 0.6rem; text-align: left; }
table.rank-table td { padding: 0.8rem 0.6rem; border-bottom: 1px solid rgba(17,17,17,0.12); vertical-align: middle; font-size: 0.9rem; }
table.rank-table tbody tr.is-top td { background: var(--panel); }
.cell-operator { min-width: 0; }
.cell-operator-inner { display: flex; align-items: center; gap: 0.6rem; }
.cell-operator img { width: 36px; height: 36px; object-fit: contain; background: #fff; border: 1px solid rgba(17,17,17,0.15); padding: 2px; flex-shrink: 0; }
.cell-operator-name { font-family: var(--font-display); font-size: 1rem; color: var(--ink); font-weight: 900; }
.top-tag { display: block; font-family: var(--font-mono); font-size: 0.62rem; text-transform: uppercase; color: var(--orange); }
.cell-metric { font-family: var(--font-mono); font-weight: 700; color: var(--ink); white-space: nowrap; }
.cell-offer strong { color: var(--orange); display: block; font-size: 1.08rem; font-weight: 800; }
.cell-offer .op-terms { font-family: var(--font-mono); font-size: 0.72rem; color: var(--body-grey); }
.cell-action .btn { width: 100%; }

@media (max-width: 700px) {
  .table-wrap { border: none; overflow: visible; }
  table.rank-table thead { position: absolute; clip: rect(0 0 0 0); clip-path: inset(50%); height: 1px; width: 1px; overflow: hidden; }
  table.rank-table, table.rank-table tbody { display: block; width: 100%; }
  table.rank-table tr {
    display: block;
    position: relative;
    background: var(--panel);
    border: 1px solid rgba(17,17,17,0.15);
    border-radius: 0;
    padding: 1.4rem 1rem 1rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow);
  }
  table.rank-table tr.is-top { border: 2px solid var(--orange); }
  table.rank-table td { display: block; border: none; padding: 0.35rem 0; }
  table.rank-table td::before { content: attr(data-label); display: block; font-family: var(--font-mono); font-size: 0.65rem; text-transform: uppercase; color: var(--body-grey); margin-bottom: 0.15rem; }
  .cell-operator-inner { display: flex; align-items: center; gap: 0.6rem; padding-top: 0.2rem; }
  .cell-operator img { width: 40px; height: 40px; }
  .cell-offer { background: var(--panel); border-left: 3px solid var(--orange); padding: 0.7rem 0.8rem; margin-top: 0.2rem; }
  .cell-action { padding-top: 0.7rem !important; }
  .cell-action .btn { width: 100%; }
  .cell-action { padding-top: 0.6rem !important; }
}

.compliance-line { font-size: 0.82rem; color: var(--body-grey); margin-top: 1.2rem; max-width: none; }
.rank-method-link { text-decoration: underline; color: var(--ink); }

/* Comparison table */
.compare-section { padding-block: 1rem 2rem; }
.table-scroll { overflow-x: auto; border: 1px solid rgba(17,17,17,0.15); }
table.compare-table { width: 100%; border-collapse: collapse; min-width: 720px; background: var(--page); }
.compare-table th, .compare-table td { padding: 0.7rem 0.9rem; text-align: left; border-bottom: 1px solid rgba(17,17,17,0.1); font-size: 0.88rem; }
.compare-table thead th { background: var(--ink); color: #fff; font-family: var(--font-mono); text-transform: uppercase; font-size: 0.7rem; letter-spacing: 0.05em; }
.compare-table tbody tr:nth-child(even) { background: var(--panel); }
.table-note { font-size: 0.78rem; color: var(--body-grey); margin-top: 0.7rem; max-width: none; }

/* Method */
.method-section { padding-block: 1.4rem 2rem; background: var(--panel); }
.method-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-top: 1.4rem; justify-content: center; }
@media (max-width: 980px) and (min-width: 561px) { .method-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .method-grid { grid-template-columns: 1fr; } }
.method-card { background: var(--page); border: 1px solid var(--ink); border-top: 3px solid var(--olive); padding: 1.1rem; box-shadow: var(--shadow); }
.method-card .num { font-family: var(--font-mono); color: var(--orange); font-size: 0.8rem; }
.method-more { text-align: center; margin-top: 1.4rem; }

/* Article */
.article-section { padding-block: 1.6rem 2rem; }
.article-head { margin-inline: 0; max-width: 100%; }
.article-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
@media (min-width: 1100px) { .article-grid { grid-template-columns: minmax(0, 1fr) 260px; } }
.article-toc { display: none; }
@media (min-width: 1100px) { .article-toc { display: block; position: sticky; top: 1.5rem; align-self: start; background: var(--panel); border: 1px solid var(--ink); padding: 1.1rem; } }
.article-toc h3 { font-size: 1rem; margin-bottom: 0.7rem; }
.article-toc ol { counter-reset: toc; list-style: none; margin: 0; padding: 0; font-size: 0.85rem; }
.article-toc li { counter-increment: toc; margin-bottom: 0.5rem; }
.article-toc li::before { content: counter(toc) ". "; font-family: var(--font-mono); color: var(--orange); }
.article-toc a { text-decoration: none; color: var(--body-grey); }
.article-toc a:hover { color: var(--ink); }
.article-body h3 { margin-top: 1.8rem; }
.byline-mini { font-family: var(--font-mono); font-size: 0.8rem; color: var(--body-grey); margin-bottom: 1.2rem; }

/* FAQ */
.faq-section { padding-block: 1.6rem 2rem; }
.faq-list { max-width: 780px; margin-top: 1.3rem; }
details.faq-item { border: 1px solid var(--ink); background: var(--page); margin-bottom: 0.7rem; }
details.faq-item summary { cursor: pointer; padding: 0.9rem 1.1rem; font-weight: 700; color: var(--ink); list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 44px; }
details.faq-item summary::-webkit-details-marker { display: none; }
details.faq-item summary::after { content: "+"; font-family: var(--font-mono); color: var(--orange); font-size: 1.3rem; flex-shrink: 0; }
details.faq-item[open] summary::after { content: "\2212"; }
details.faq-item .faq-answer { padding: 0 1.1rem 1.1rem; font-size: 0.95rem; }

.section-kicker { font-family: var(--font-mono); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--orange); display: block; margin-bottom: 0.4rem; }
section.tinted { background: var(--panel); }

/* Simple pages */
.page-hero { padding-block: 2rem 1rem; }
.page-body { padding-block: 0.5rem 3rem; }
.page-body h2 { margin-top: 1.6rem; }
.page-body ul, .page-body ol { max-width: 68ch; }

/* Footer */
.site-footer { background: var(--ink); color: #E5E1D6; padding-block: 2.4rem; margin-top: 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 2rem; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; } }
.site-footer h4 { font-family: var(--font-display); color: #fff; font-size: 1rem; margin-bottom: 0.8rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.5rem; }
.site-footer a { color: #E5E1D6; text-decoration: none; font-size: 0.9rem; }
.site-footer a:hover { color: var(--orange); text-decoration: underline; }
.footer-note { font-size: 0.8rem; color: #A9A290; margin-top: 1.6rem; border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1.2rem; max-width: none; }

/* Back to top */
.to-top { position: fixed; right: 16px; bottom: 16px; width: 42px; height: 42px; background: var(--ink); border: none; cursor: pointer; z-index: 40; opacity: 0; visibility: hidden; }
.to-top .arrow { display: block; width: 10px; height: 10px; border-top: 2px solid #fff; border-left: 2px solid #fff; transform: rotate(45deg); margin: 15px auto 0; }
@supports (animation-timeline: scroll()) { .to-top { animation: to-top-reveal linear both; animation-timeline: scroll(root); animation-range: 300px 700px; } }
@keyframes to-top-reveal { from { opacity: 0; visibility: hidden; } to { opacity: 1; visibility: visible; } }
.to-top.is-visible { opacity: 1; visibility: visible; }
@media (prefers-reduced-motion: reduce) { .to-top { animation: none !important; } }

.visually-hidden { position: absolute; clip: rect(0 0 0 0); clip-path: inset(50%); height: 1px; width: 1px; overflow: hidden; white-space: nowrap; }
