/* Home page only (loaded by / and /en/). Shared pieces (hero, kicker, desk, tablet, book, hw) are in
   site.css; this file lays out the two sentences, the four doors and the short contact block. */

/* What we do: the two sentences, large */
.about-text { margin-top: 24px; max-width: 34em; font-size: clamp(18px, 1.7vw, 21px); line-height: 1.8; color: var(--body2); }
html[lang="en"] .about-text { line-height: 1.65; }

/* Four doors: each a piece of the real material on a soft teal desk, a label, the page's name
   (the link: the whole door is its target) and two lines. */
.doors { margin-top: 40px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px 24px; }
.door { position: relative; min-width: 0; display: flex; flex-direction: column; }
/* Phones: a 4:3 desk that grows if its piece is taller (the homework panel). Two columns: one fixed
   height for all four, so the names line up across a row (the panel is about 320 px tall). */
.door-desk { flex: 0 0 auto; aspect-ratio: 4 / 3; margin: 0 0 18px; padding: 20px; }
.door-desk picture { display: flex; justify-content: center; width: 100%; }
.door-desk .tablet { width: 100%; max-width: 480px; }
.door-cover picture { height: 100%; }
.door-cover .book { width: auto; max-width: none; height: 100%; }
.door .tag { margin-top: 2px; }
.door h3 { margin-top: 6px; font-size: clamp(24px, 2.3vw, 30px); font-weight: 800; line-height: 1.3; letter-spacing: -0.025em; color: var(--ink); }
.door-link { color: inherit; text-decoration: underline; text-decoration-color: var(--rule-strong); text-decoration-thickness: 2px; text-underline-offset: 7px; }
.door-link::after { content: ""; position: absolute; inset: 0; border-radius: 24px; }
.door-link:hover { color: var(--teal-down); text-decoration-color: var(--teal); }
.door:hover .door-link { text-decoration-color: var(--teal); }
.door > p:not(.tag) { margin-top: 8px; max-width: 30em; font-size: 16.5px; line-height: 1.75; color: var(--body2); }
html[lang="en"] .door > p:not(.tag) { line-height: 1.6; }
.door-cap { margin-top: 10px; font-size: 13.5px; line-height: 1.5; color: var(--muted); text-align: center; }

/* The board strip fills the desk's width, its caption under it */
.door-board picture img { width: 100%; border-radius: 12px; }

/* The homework item, small and still: the app's own look, already marked */
.door-panel { justify-content: center; }
.hw-mini { max-width: 236px; padding: 6px; border-radius: 30px; }
.hw-mini .hw { min-height: 0; padding: 0 14px 16px; border-radius: 24px; }
.hw-mini .hw-head { margin: 0 -14px; padding: 12px 14px 10px; font-size: 11px; }
.hw-mini .hw-tag { margin: 12px 0 6px; font-size: 12.5px; line-height: 1.45; }
.hw-mini .hw-q { font-size: 19px; }
.hw-mini .hw-blank { min-width: 2.6em; }
.hw-static { margin-top: 12px; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
.hw-static span { display: flex; align-items: center; justify-content: center; min-height: 34px; border: 1.5px solid var(--rule); border-radius: 10px; font-size: 14.5px; font-weight: 600; color: var(--muted); }
.hw-static span.is-right { border-color: var(--teal); background: var(--teal-wash); color: var(--teal-down); }
.hw-mini .hw-mark { margin-top: 10px; font-size: 14.5px; }
.hw-mini .hw-ans { margin-top: 2px; font-size: 14.5px; line-height: 1.5; }

/* Phones: no type under 14 px */
@media (max-width: 599px) {
  .door-cap, .hw-mini .hw-head, .hw-mini .hw-tag { font-size: 14px; }
}
/* One column: the cover is its sizes width (46vw), so it holds its height before the file arrives (the
   desk grows to it, as it did after the load) */
@media (max-width: 719px) {
  .door-cover picture { height: auto; }
  .door-cover .book { width: 46vw; height: auto; }
}

/* Contact: the two ways beside the line */
.home-contact .text-link { margin-top: 14px; }
.home-contact .ways { margin-top: 32px; }

@media (min-width: 720px) {
  .doors { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 64px 32px; }
  .door-desk { aspect-ratio: auto; height: 380px; padding: 20px; }
}

@media (min-width: 960px) {
  .about { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: 72px; align-items: end; }
  .about-text { margin-top: 0; }
  .doors { gap: 80px 48px; }
  .home-contact { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); column-gap: 72px; align-items: end; }
  .home-contact .ways { margin-top: 0; }
}
