/* The marketing site: a newspaper's car-classifieds page. Specimen for #549. */

@font-face {
  font-family: "Bitter";
  font-weight: 400 900;
  font-display: swap;
  src: url(fonts/bitter-cyrillic-305ea448.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Bitter";
  font-weight: 400 900;
  font-display: swap;
  src: url(fonts/bitter-latin-261cfc4d.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "PT Serif";
  font-weight: 400;
  font-display: swap;
  src: url(fonts/ptserif-cyrillic-a60d74d7.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "PT Serif";
  font-weight: 400;
  font-display: swap;
  src: url(fonts/ptserif-latin-202b8aa6.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "PT Serif";
  font-weight: 700;
  font-display: swap;
  src: url(fonts/ptserif-bold-cyrillic-8e7689d8.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "PT Serif";
  font-weight: 700;
  font-display: swap;
  src: url(fonts/ptserif-bold-latin-57d3ae6c.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --newsprint: #e1e3e5;
  --ink: #141414;
  --ink-soft: #44474b;
  --spot: #b4005a;
  --on-spot: #ffffff;
  --coupon: #fbfcfd;
  --field: #eef0f2;
  --rule: #141414;
  --hairline: #93979c;
  --slab: "Bitter", "Rockwell", Georgia, serif;
  --serif: "PT Serif", Georgia, "Times New Roman", serif;
  --gutter: 16px;
  --col-gap: clamp(16px, 2vw, 28px);
  --measure: 66ch;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: light dark;
}

/* The dark paper: a night edition of the same page. Ground and ink trade places, so every reversed bar
   (ink ground, newsprint text) stays reversed. The spot colour lightens to hold 4.5:1 on the dark grounds,
   and the text on it turns dark. COLOURS_DARK in src/marketing-specimen.ts checks these values. */
@media (prefers-color-scheme: dark) {
  :root {
    --newsprint: #121315;
    --ink: #eceef0;
    --ink-soft: #b6bac0;
    --spot: #ff6fae;
    --on-spot: #141414;
    --coupon: #1c1e21;
    --field: #1a1c1f;
    --rule: #eceef0;
    --hairline: #4d5156;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--newsprint);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.5;
  font-kerning: normal;
  font-variant-numeric: lining-nums;
}

::selection {
  background: var(--spot);
  color: var(--on-spot);
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

h1,
h2,
h3 {
  font-family: var(--slab);
  text-wrap: balance;
}

p,
li,
dd {
  text-wrap: pretty;
}

a {
  color: var(--ink);
  text-decoration-line: underline;
  text-decoration-color: var(--spot);
  text-decoration-thickness: 0.14em;
  text-underline-offset: 0.18em;
  transition:
    background-color 120ms var(--ease),
    color 120ms var(--ease);
}

/* Links invert to the spot colour, as a reversed rubric head does. */
a:hover {
  background: var(--spot);
  color: var(--on-spot);
  text-decoration-color: var(--on-spot);
}

:focus-visible {
  outline: 3px solid var(--spot);
  outline-offset: 3px;
}

a:focus-visible {
  background: var(--spot);
  color: var(--on-spot);
  text-decoration-color: var(--on-spot);
  outline-color: var(--ink);
}

.skip {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 2;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--newsprint);
  font-family: var(--slab);
  font-weight: 700;
}

.skip:focus-visible {
  top: 8px;
}

.page {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Masthead: the paper's nameplate in the spot colour, then the rubric index on a black bar. */

.masthead {
  background: var(--spot);
  color: var(--on-spot);
}

.masthead .page {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 8px 24px;
  padding-top: 14px;
  padding-bottom: 12px;
}

.nameplate {
  font-family: var(--slab);
  font-weight: 900;
  font-size: clamp(2.5rem, 1.2rem + 6vw, 6rem);
  line-height: 0.9;
  letter-spacing: -0.035em;
  color: var(--on-spot);
  text-decoration: none;
}

.nameplate:hover,
.nameplate:focus-visible {
  background: var(--ink);
}

.dateline {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 16px;
  border-top: 2px solid var(--on-spot);
  padding-top: 8px;
  font-family: var(--slab);
  font-size: 0.9375rem;
  font-weight: 600;
}

.langs {
  display: flex;
  gap: 2px;
  list-style: none;
  padding: 0;
  font-family: var(--slab);
  font-weight: 700;
  font-size: 0.9375rem;
  align-self: start;
}

.langs a,
.langs span {
  display: block;
  min-width: 44px;
  min-height: 44px;
  padding: 11px 6px;
  text-align: center;
  color: var(--on-spot);
  text-decoration: none;
}

.langs .soon {
  font-weight: 500;
  outline: 1px dashed var(--on-spot);
  outline-offset: -8px;
}

.langs .soon-note {
  align-self: center;
  padding-left: 4px;
  font-weight: 600;
  font-size: 0.875rem;
}

.langs [aria-current] {
  background: var(--on-spot);
  color: var(--spot);
}

.langs a:hover,
.langs a:focus-visible {
  background: var(--ink);
  color: var(--on-spot);
}

.rubrics {
  background: var(--ink);
}

.rubrics ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 4px;
  list-style: none;
  margin: 0 auto;
  padding: 0 calc(var(--gutter) - 10px);
  max-width: 1400px;
}

.rubrics a {
  display: block;
  padding: 12px 10px;
  color: var(--newsprint);
  font-family: var(--slab);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
}

.rubrics a[aria-current] {
  box-shadow: inset 0 -5px 0 var(--spot);
}

.rubrics a:hover,
.rubrics a:focus-visible {
  background: var(--spot);
  color: var(--on-spot);
  outline-color: var(--newsprint);
  outline-offset: -3px;
}

/* Rubric heads: a reversed black bar across the column, like the paper's section heads. */

.rubric {
  margin-top: clamp(48px, 6vw, 88px);
}

.rubric-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  background: var(--ink);
  color: var(--newsprint);
  padding: 8px 12px 9px;
  font-family: var(--slab);
  font-weight: 800;
  font-size: clamp(1.25rem, 1rem + 1vw, 1.75rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.rubric-head small {
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 0;
  text-transform: none;
}

.rubric-intro {
  max-width: var(--measure);
  margin-top: 16px;
  font-size: 1.1875rem;
}

/* The lead: the paper's front of the section, the headline ad and the coupon. */

.lead {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 32px;
  padding-top: clamp(28px, 4vw, 56px);
}

.lead-ad {
  grid-column: 1 / span 7;
  border-top: 6px solid var(--rule);
  padding-top: 18px;
}

.lead-ad h1 {
  font-weight: 900;
  font-size: clamp(2.75rem, 1.4rem + 5.2vw, 6rem);
  line-height: 0.96;
  letter-spacing: -0.035em;
}

.lead-ad h1 em {
  font-style: normal;
  color: var(--spot);
}

.lead-ad p {
  max-width: 36ch;
  margin-top: 22px;
  font-size: clamp(1.1875rem, 1.05rem + 0.5vw, 1.4375rem);
  line-height: 1.45;
}

.lead-ad .lead-note {
  margin-top: 14px;
  font-size: 1.0625rem;
  color: var(--ink-soft);
}

/* The coupon: the one calm panel on the page, cut out along a dashed line. */

.coupon {
  position: relative;
  grid-column: 8 / span 5;
  align-self: start;
  background: var(--coupon);
  border: 3px dashed var(--spot);
  padding: 30px clamp(18px, 2vw, 28px) 24px;
  z-index: 1;
  transition:
    border-color 120ms var(--ease),
    translate 120ms var(--ease);
}

/* On desktop the home coupon's top sits level with the headline's top rule, not 64 px below it. */
.lead .coupon {
  top: 0;
}

.coupon:focus-within {
  border-style: solid;
  translate: 0 -6px;
}

.scissors {
  position: absolute;
  top: -15px;
  left: 14px;
  width: 30px;
  height: 26px;
  padding: 0 2px;
  background: var(--newsprint);
  color: var(--spot);
  transition: left 700ms var(--ease);
}

.coupon:focus-within .scissors {
  left: calc(100% - 46px);
}

.coupon h2 {
  font-weight: 900;
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.375rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
}

.coupon > p {
  margin-top: 10px;
}

.coupon form {
  margin-top: 20px;
}

.coupon .after {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--hairline);
  font-size: 0.96875rem;
  color: var(--ink-soft);
}

.coupon .after p + p {
  margin-top: 8px;
}

.free {
  display: inline-block;
  margin-top: 6px;
  background: var(--spot);
  color: var(--on-spot);
  padding: 2px 8px 3px;
  font-family: var(--slab);
  font-weight: 800;
  font-size: 0.9375rem;
}

/* Forms: filled in on the coupon, as in ink on a ruled line. */

.field {
  display: grid;
  gap: 6px;
}

.field + .field {
  margin-top: 16px;
}

label {
  font-family: var(--slab);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.3;
}

.hint {
  font-size: 0.9375rem;
  color: var(--ink-soft);
}

input[type="url"],
input[type="text"],
input[type="tel"],
input[type="email"],
textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 2px solid var(--ink);
  border-radius: 0;
  background: var(--newsprint);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  caret-color: var(--spot);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: var(--ink-soft);
  opacity: 1;
}

input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--spot);
  outline-offset: 0;
  border-bottom-color: var(--spot);
}

.check {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 10px;
  align-items: start;
  margin-top: 16px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 0.96875rem;
}

.check input {
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--spot);
}

button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  margin-top: 18px;
  padding: 12px 22px;
  border: 0;
  border-radius: 0;
  background: var(--spot);
  color: var(--on-spot);
  font-family: var(--slab);
  font-weight: 800;
  font-size: 1.125rem;
  cursor: pointer;
  transition:
    background-color 120ms var(--ease),
    color 120ms var(--ease);
}

button:hover {
  background: var(--ink);
}

button:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

button.wide {
  width: 100%;
}

/* Ad columns: boxed ads set in newspaper columns with a rule between them. */

.ads {
  columns: 4 15rem;
  column-gap: var(--col-gap);
  column-rule: 1px solid var(--hairline);
  margin-top: 20px;
}

/* The sample site: a dealer's crawled ads, labelled as invented. */

.sample {
  margin-top: 40px;
  position: relative;
  border-top: 6px solid var(--rule);
}

.sample-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px 16px;
  padding: 10px 0 0;
  font-family: var(--slab);
}

.sample-head strong {
  font-weight: 800;
  font-size: 1.25rem;
  overflow-wrap: anywhere;
}

.sample-head span {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--ink-soft);
}

.car {
  break-inside: avoid;
  margin-bottom: var(--col-gap);
  border: 1px solid var(--ink);
  padding: 10px 10px 12px;
}

.car .year {
  display: block;
  margin-top: 8px;
  font-family: var(--slab);
  font-weight: 900;
  font-size: 2.25rem;
  line-height: 1;
  letter-spacing: -0.03em;
}

.car h3 {
  font-weight: 800;
  font-size: 1.1875rem;
  line-height: 1.15;
}

.car p {
  margin-top: 4px;
  font-size: 0.96875rem;
}

.car .from {
  margin-top: 8px;
  font-family: var(--slab);
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--spot);
}

/* Steps: the claim in order, as numbered run-in lines in one ruled column. */

.steps {
  list-style: none;
  padding: 0;
  border-top: 3px solid var(--ink);
}

.steps li {
  display: grid;
  grid-template-columns: 3.25rem 1fr;
  column-gap: 14px;
  padding: 16px 0 18px;
  border-bottom: 1px solid var(--hairline);
}

.steps .n {
  grid-row: span 2;
  font-family: var(--slab);
  font-weight: 900;
  font-size: 3.5rem;
  line-height: 0.9;
  color: var(--spot);
}

.steps h3 {
  font-weight: 800;
  font-size: 1.375rem;
  line-height: 1.15;
}

.steps p {
  margin-top: 6px;
  max-width: 52ch;
}

/* Classified matter: a display ad beside a column of run-in line ads, at unequal widths. */

.classified {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 24px;
  margin-top: 20px;
  align-items: start;
}

.flip > .display {
  order: 2;
}

.span-4 { grid-column: span 4; }
.span-5 { grid-column: span 5; }
.span-7 { grid-column: span 7; }
.span-8 { grid-column: span 8; }

.display {
  border: 3px solid var(--ink);
  padding: 18px 20px 22px;
}

.display h3 {
  font-weight: 900;
  font-size: clamp(1.625rem, 1.2rem + 1.4vw, 2.5rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
}

.display p {
  margin-top: 10px;
  font-size: 1.125rem;
  max-width: 44ch;
}

.display .figure {
  display: block;
  margin-top: 4px;
  font-family: var(--slab);
  font-weight: 900;
  font-size: clamp(3.5rem, 2.5rem + 4vw, 6rem);
  line-height: 0.9;
  letter-spacing: -0.035em;
}

.display.reversed {
  background: var(--ink);
  color: var(--newsprint);
}

.display.reversed a {
  color: var(--newsprint);
}

.display.spot {
  background: var(--spot);
  border-color: var(--spot);
  color: var(--on-spot);
}

.display.spot a {
  color: var(--on-spot);
  text-decoration-color: var(--on-spot);
}

.display.spot a:hover,
.display.spot a:focus-visible {
  background: var(--ink);
  outline-color: var(--on-spot);
}

.lines {
  columns: 2 15rem;
  column-gap: var(--col-gap);
  column-rule: 1px solid var(--hairline);
  border-top: 3px solid var(--ink);
  padding-top: 12px;
}

.lines.one {
  columns: 1;
}

.line {
  break-inside: avoid;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
  font-size: 1rem;
  line-height: 1.45;
}

.line b {
  font-family: var(--slab);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}

/* Two coupons on the claim page. */

.coupons {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 40px;
  margin-top: 28px;
}

.coupons .coupon {
  grid-column: span 6;
}

/* A reply box: a ruled ad with a form in it, not a coupon. */
.reply {
  grid-column: span 6;
  align-self: start;
  border: 3px solid var(--ink);
  padding: 24px clamp(18px, 2vw, 28px);
}

.reply h2 {
  font-weight: 900;
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.375rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
}

.reply > p {
  margin-top: 10px;
}

.reply form {
  margin-top: 16px;
}

.reply input,
.reply textarea {
  background: var(--field);
}

.page-title {
  padding-top: clamp(28px, 4vw, 56px);
  border-bottom: 6px solid var(--rule);
  padding-bottom: 16px;
}

.page-title h1 {
  font-weight: 900;
  font-size: clamp(2.5rem, 1.5rem + 4vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
}

.page-title p {
  max-width: 48ch;
  margin-top: 14px;
  font-size: clamp(1.125rem, 1.05rem + 0.4vw, 1.3125rem);
}

/* The not-found page (#1790): the way out, under the headline. */

.not-found-links {
  margin-top: 28px;
  font-family: var(--slab);
  font-weight: 700;
  font-size: 1.25rem;
}

.not-found-links a {
  text-underline-offset: 0.2em;
}

/* Reading pages: privacy and terms in two newspaper columns. */

.reading {
  columns: 2 22rem;
  column-gap: calc(var(--col-gap) * 2);
  column-rule: 1px solid var(--hairline);
  margin-top: 28px;
}

.reading section {
  break-inside: avoid-column;
  margin-bottom: 26px;
}

.reading h2 {
  font-weight: 800;
  font-size: 1.375rem;
  line-height: 1.2;
}

.reading p,
.reading ul,
.reading ol {
  margin-top: 8px;
  max-width: var(--measure);
}

.reading ul,
.reading ol {
  padding-left: 1.25em;
}

.reading li + li {
  margin-top: 6px;
}

.draft {
  margin-top: 22px;
  border: 3px solid var(--spot);
  padding: 12px 14px;
  max-width: 70ch;
  font-family: var(--slab);
  font-weight: 600;
}

/* Slots: a fact only the owner can give, left visibly empty. */

.slot {
  display: inline-block;
  padding: 1px 8px 2px;
  background: var(--ink);
  color: var(--newsprint);
  font-family: var(--slab);
  font-weight: 700;
  font-size: 0.9375em;
  line-height: 1.35;
}

.slot.block {
  display: block;
  padding: 14px 16px;
}

/* Contact: the company's box and the message form. */

.contact {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 32px;
  margin-top: 28px;
}

.contact .imprint {
  grid-column: 1 / span 5;
}

.contact .reply {
  grid-column: 7 / span 6;
}

/* The demonstration page's side column: what is shown, then the two notes under it. */
.contact .aside {
  grid-column: 1 / span 5;
}

.aside .lines {
  margin-top: 20px;
}

.imprint dl {
  border-top: 3px solid var(--ink);
}

.imprint div {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: 4px 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--hairline);
}

.imprint dt {
  font-family: var(--slab);
  font-weight: 700;
}

/* Footer: the paper's imprint. */

.imprint-foot {
  margin-top: clamp(56px, 8vw, 112px);
  background: var(--ink);
  color: var(--newsprint);
}

.imprint-foot .page {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 24px;
  padding-top: 32px;
  padding-bottom: 40px;
}

.imprint-foot .mark {
  grid-column: 1 / span 4;
  font-family: var(--slab);
  font-weight: 900;
  font-size: 2rem;
  line-height: 1;
  letter-spacing: -0.03em;
}

.imprint-foot .mark p {
  margin-top: 10px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 0.96875rem;
  letter-spacing: 0;
  line-height: 1.5;
}

.imprint-foot nav {
  grid-column: 5 / span 4;
}

.imprint-foot .company {
  grid-column: 9 / span 4;
  font-size: 0.96875rem;
}

/* Two links to a row where they fit; a word longer than half the row ("Nutzungsbedingungen" at 390 px) takes a row of
   its own instead of running past the page. */
.imprint-foot ul {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  column-gap: 16px;
}

.imprint-foot li {
  flex: 1 1 9rem;
}

.imprint-foot a {
  display: inline-block;
  padding: 6px 0;
  color: var(--newsprint);
  font-family: var(--slab);
  font-weight: 600;
}

.imprint-foot a:hover,
.imprint-foot a:focus-visible {
  background: var(--spot);
  color: var(--on-spot);
  outline-color: var(--newsprint);
}

.imprint-foot .slot {
  margin-top: 6px;
  background: var(--newsprint);
  color: var(--ink);
}

.imprint-foot h2 {
  font-size: 0.9375rem;
  font-weight: 800;
  text-transform: uppercase;
  margin-bottom: 8px;
}

/* Phone. */

@media (max-width: 860px) {
  .lead-ad,
  .coupon,
  .coupons .coupon,
  .reply,
  .contact .imprint,
  .contact .reply,
  .contact .aside,
  .classified > *,
  .imprint-foot .mark,
  .imprint-foot nav,
  .imprint-foot .company {
    grid-column: 1 / -1;
  }

  .lead .coupon {
    top: 0;
  }

  .flip > .display {
    order: 0;
  }

  /* On a phone the demonstration's form comes first, and what is shown follows it. */
  .contact .aside {
    order: 1;
  }

  .imprint div {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .masthead .page {
    grid-template-columns: 1fr;
  }

  .langs {
    order: -1;
    justify-self: end;
    margin-bottom: -6px;
  }

  .rubrics a {
    padding: 12px 8px;
    font-size: 0.9375rem;
  }
}

/* The consent notice (#1883): printed at the foot of the page, with the site's one button twice. Both answers look alike:
   the same fill, size and type. Rendered only when a tag is configured, hidden until the script shows it. */

.consent {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 3;
  padding: 14px 0 18px;
  border-top: 3px solid var(--rule);
  background: var(--coupon);
  color: var(--ink);
}

.consent[hidden],
button[hidden] {
  display: none;
}

.consent h2 {
  font-size: 1.125rem;
  font-weight: 800;
  line-height: 1.2;
}

.consent p {
  max-width: var(--measure);
  margin-top: 6px;
  font-size: 0.9375rem;
  line-height: 1.45;
}

.consent-answers {
  display: flex;
  gap: 12px;
  margin-top: 12px;
}

/* Both answers take equal shares even when one word is long ("Отказываюсь" at 390 px), and the narrower side padding
   keeps that word inside its button. */
.consent-answers button {
  flex: 1 1 0;
  min-width: 0;
  max-width: 15rem;
  margin-top: 0;
  padding-inline: 12px;
}

/* The end of the page and its footer clear the notice while it shows. */
body {
  padding-bottom: var(--consent-h, 0px);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }

  .coupon:focus-within {
    translate: none;
  }
}

.car img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  margin-bottom: 10px;
  filter: grayscale(1) contrast(1.08);
  mix-blend-mode: multiply;
}

.form-note {
  margin-top: 14px;
}

/* A form's answer, set like a correction notice: a spot-ruled box, and each field's problem in spot ink under it. */
.form-alert {
  margin-top: 16px;
  border: 3px solid var(--spot);
  padding: 10px 14px;
  font-family: var(--slab);
  font-weight: 700;
}

.field-error {
  font-family: var(--slab);
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--spot);
}

.field [aria-invalid="true"] {
  border-bottom-color: var(--spot);
}

.sent > p {
  margin-top: 10px;
}

.sent .back {
  display: inline-block;
  margin-top: 18px;
  font-family: var(--slab);
  font-weight: 800;
}

/* The field only a robot fills in: off the page, out of the tab order and hidden from assistive technology. */
.trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.rubric-head a {
  color: var(--newsprint);
}

.rubric-head a:hover,
.rubric-head a:focus-visible {
  color: var(--on-spot);
  outline-color: var(--newsprint);
}

/* The search (#1877): the buyers' finder in a reply box, and the cars found as boxed ads in rows. */

select {
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 0;
  border-bottom: 2px solid var(--ink);
  border-radius: 0;
  background: var(--newsprint);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
}

select:focus-visible {
  outline: 3px solid var(--spot);
  outline-offset: 0;
  border-bottom-color: var(--spot);
}

.reply select {
  background: var(--field);
}

.finder-box {
  margin-top: 28px;
}

.finder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 16px var(--col-gap);
}

.finder-grid .field {
  align-content: start;
}

.finder-grid .field + .field {
  margin-top: 0;
}

/* The words take the whole row; the rest sit in as many columns as fit. */
.finder-grid .field:first-child {
  grid-column: 1 / -1;
}

.finder .options {
  margin: 22px 0 0;
  padding: 0;
  border: 0;
  min-inline-size: 0;
}

.finder legend {
  padding: 0;
  margin-bottom: 4px;
  font-family: var(--slab);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.3;
}

.option-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  column-gap: var(--col-gap);
}

.finder .check {
  min-height: 44px;
  margin-top: 0;
  align-items: center;
}

.finder-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 24px;
  margin-top: 22px;
}

.finder-actions button {
  min-width: 12rem;
  margin-top: 0;
}

.finder-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-family: var(--slab);
  font-weight: 700;
}

/* On the results the finder folds into a ruled strip, so the cars come first on a phone. */
.refine {
  margin-top: 24px;
  border: 3px solid var(--ink);
}

.refine summary {
  min-height: 52px;
  padding: 12px 18px;
  font-family: var(--slab);
  font-weight: 800;
  font-size: 1.125rem;
  cursor: pointer;
}

.refine summary::marker {
  color: var(--spot);
}

.refine summary:hover {
  background: var(--spot);
  color: var(--on-spot);
}

.refine summary:hover::marker {
  color: var(--on-spot);
}

.refine[open] summary {
  border-bottom: 3px solid var(--ink);
}

.refine .reply {
  border: 0;
  padding-top: 8px;
}

.refine .reply form {
  margin-top: 8px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.chips a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 6px 12px;
  border: 1px solid var(--ink);
  font-family: var(--slab);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.chip-remove {
  white-space: pre;
  color: var(--spot);
}

.chips a:hover .chip-remove,
.chips a:focus-visible .chip-remove {
  color: inherit;
}

.found {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: var(--col-gap);
  margin-top: 20px;
}

.found .car {
  position: relative;
  margin: 0;
}

/* The whole box opens the car: the title's link spreads over it, so there is one link, not three, for each car. */
.car h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.car .price {
  margin-top: 8px;
  font-family: var(--slab);
  font-weight: 800;
  font-size: 1.25rem;
}

.car .no-photo {
  display: grid;
  place-items: center;
  aspect-ratio: 3 / 2;
  margin: 0 0 10px;
  border: 1px solid var(--hairline);
  font-family: var(--slab);
  font-weight: 600;
  color: var(--ink-soft);
}

.pager {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
}

.pager a {
  display: inline-flex;
  align-items: center;
  min-height: 52px;
  padding: 12px 22px;
  border: 3px solid var(--ink);
  font-family: var(--slab);
  font-weight: 800;
  font-size: 1.125rem;
  text-decoration: none;
}

.none .back {
  display: inline-block;
  margin-top: 18px;
  font-family: var(--slab);
  font-weight: 800;
}

/* On the dark paper a multiplied photo would sink into the ground, so it is drawn plainly and dimmed. */
@media (prefers-color-scheme: dark) {
  .car img {
    mix-blend-mode: normal;
    filter: grayscale(1) contrast(1.08) brightness(0.82);
  }
}
