/* Myslite — tokens from brand/myslite/web-concept-05/START-HERE.md.
   Petrol blocks, white everywhere else, Fraunces for headings only,
   Arial/Helvetica for everything else, black-and-white buttons. */

@font-face {
  font-family: "Fraunces Heading";
  src: url("/assets/fonts/fraunces-heading.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --petrol: #163c40;
  --white: #ffffff;
  --ink: #222522;
  --muted: #565b56;
  --numeral: #6b716b;
  --line: #d9dcd9;
  --slot: #e8eae8;
  --on-dark-muted: rgba(255, 255, 255, 0.82);

  --serif: "Fraunces Heading", Georgia, "Times New Roman", serif;
  --sans: Arial, Helvetica, sans-serif;

  --max: 1280px;
  --gutter: clamp(20px, 5.56vw, 80px);
  --section: clamp(64px, 9vw, 128px);
}

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

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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font: 400 18px/28px var(--sans);
  -webkit-font-smoothing: antialiased;
}

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

ol,
ul {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* A light button's own colour is ink, invisible as a ring on petrol. */
.button-light:focus-visible {
  outline-color: var(--white);
}

[id] {
  scroll-margin-top: 24px;
}

.wrap {
  width: min(var(--max), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 10;
  padding: 12px 16px;
  background: var(--white);
  color: var(--ink);
  font-weight: 700;
}

.skip-link:focus {
  top: 12px;
}

/* ---------- Type ---------- */

h1,
h2 {
  font-family: var(--serif);
  font-weight: 520;
  letter-spacing: -0.005em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(36px, calc(3.1vw + 26px), 72px);
  line-height: 1.1;
  text-wrap: wrap;
}

h2 {
  font-size: clamp(32px, 3.4vw, 44px);
  line-height: 1.14;
}

h3 {
  font-size: 18px;
  line-height: 26px;
  font-weight: 700;
}

.lede {
  font-size: clamp(18px, 1.6vw, 22px);
  line-height: 1.45;
  text-wrap: pretty;
}

.intro {
  margin-top: 20px;
  color: var(--muted);
  max-width: 36rem;
  text-wrap: pretty;
}

.eyebrow {
  font-size: 13px;
  line-height: 20px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ---------- Buttons and links ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 24px;
  border-radius: 3px;
  font: 700 16px/1.2 var(--sans);
  text-decoration: none;
  white-space: nowrap;
}

.button-light {
  background: var(--white);
  color: var(--ink);
}

.button-dark {
  background: var(--ink);
  color: var(--white);
}

.button-large {
  min-height: 56px;
  padding-inline: 32px;
  font-size: 17px;
}

.button:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.button.is-pending {
  opacity: 0.55;
  cursor: not-allowed;
  text-decoration: none;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  font-size: 16px;
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1px;
}

.icon {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Header ---------- */

.site-header {
  position: relative;
  z-index: 5;
  background: var(--petrol);
  color: var(--white);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: 88px;
}

.brand {
  display: block;
  flex: none;
  width: 124px;
  padding-block: 8px;
}

.wordmark {
  display: block;
  width: 100%;
  height: auto;
}

.nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: space-between;
  gap: 32px;
}

.nav-links {
  display: flex;
  gap: 36px;
  margin-left: clamp(24px, 6vw, 96px);
}

.nav-links a {
  font-size: 16px;
  white-space: nowrap;
  text-decoration: none;
  padding-block: 12px;
}

.nav-links a:hover {
  text-decoration: underline;
  text-underline-offset: 6px;
}

.menu {
  display: none;
}

/* ---------- Hero ---------- */

.hero {
  background: var(--petrol);
  color: var(--white);
  padding-block: clamp(40px, 5vw, 72px) clamp(64px, 8vw, 112px);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 46fr) minmax(0, 54fr);
  gap: 48px;
  align-items: center;
}

.hero .eyebrow {
  margin-bottom: 20px;
}

.hero h1 {
  max-width: 12ch;
}

.hero .lede {
  margin-top: 24px;
  max-width: 34rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 32px;
  margin-top: 40px;
}

/* The two handouts: real text, typeset as paper. Rotation and shadow are
   allowed here and nowhere else (START-HERE). */
.papers {
  position: relative;
}

.paper-stack {
  position: relative;
  min-height: 540px;
}

.paper {
  background: var(--white);
  color: var(--ink);
  padding: 26px 26px 28px;
  font-size: 13px;
  line-height: 19px;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.18),
    0 18px 40px rgba(0, 0, 0, 0.28);
}

/* The front paper may cover only the back paper's right margin, never text. */
.paper-data {
  position: relative;
  width: 60%;
  padding-right: 72px;
  transform: rotate(-3.5deg);
  transform-origin: 30% 20%;
}

.paper-check {
  position: absolute;
  left: calc(60% - 30px);
  bottom: 0;
  width: calc(40% + 30px);
  transform: rotate(2.5deg);
}

.paper-label {
  margin-bottom: 18px;
  color: var(--petrol);
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.paper ol {
  display: grid;
  gap: 14px;
}

.paper li {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 6px;
}

.paper-n {
  font-weight: 700;
}

.paper-title {
  margin-bottom: 2px;
  font-size: 14px;
  font-weight: 700;
}

.paper p + p {
  color: #3d413d;
}

.papers figcaption {
  margin-top: 28px;
  color: var(--on-dark-muted);
  font-size: 14px;
  line-height: 20px;
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--section);
}

.dark {
  background: var(--petrol);
  color: var(--white);
}

.dark .intro {
  color: var(--on-dark-muted);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: start;
}

.numbered {
  display: grid;
  gap: 28px;
}

.numbered li {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 8px;
}

.nowrap {
  white-space: nowrap;
}

.num {
  font-family: var(--serif);
  font-size: 24px;
  line-height: 26px;
  font-weight: 400;
  color: var(--numeral);
}

.numbered p {
  color: var(--muted);
}

.method h2 {
  margin-bottom: 40px;
}

.method-list {
  max-width: 48rem;
}

/* Lecturers */

.lecturers {
  padding-top: 0;
}

.lecturers h2 {
  margin-bottom: 40px;
}

.people {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 420px));
  gap: 64px;
}

.photo {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  margin-bottom: 18px;
}

.photo-placeholder {
  display: grid;
  place-items: center;
  background: var(--slot);
  color: var(--muted);
  font-size: 16px;
}

.person-name {
  font-weight: 700;
}

.person-role {
  color: var(--muted);
}

.person-bio {
  margin-top: 12px;
  max-width: 34rem;
  color: var(--muted);
  font-size: 16px;
  line-height: 26px;
  text-wrap: pretty;
}

.method {
  padding-top: 0;
}

/* Limits */

.limits h2 {
  max-width: 16ch;
}

.limit-lines {
  display: grid;
  gap: 20px;
  margin-top: 40px;
  font-size: clamp(21px, 2vw, 26px);
  line-height: 1.3;
  font-weight: 700;
}

.limits-explanation {
  margin-top: 40px;
  max-width: 34rem;
  color: var(--on-dark-muted);
}

.limits-note {
  margin-top: 24px;
  max-width: 34rem;
  color: var(--on-dark-muted);
  font-size: 15px;
  line-height: 23px;
}

.evidence {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px 48px;
  margin-top: 40px;
  max-width: 64rem;
}

.evidence li {
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.28);
}

.evidence-source {
  margin-top: 1px;
  color: var(--on-dark-muted);
  font-size: 15px;
  line-height: 23px;
}

/* The whole "Zdroj: …" line is the link: one 44px tap target that wraps. */
.evidence-source a {
  display: inline-block;
  padding-block: 11px;
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Comparison and FAQ continue the white section before them. */

.comparison,
.faq {
  padding-top: 0;
}

/* Comparison */

.compare {
  width: 100%;
  max-width: 64rem;
  margin-top: 40px;
  border-collapse: collapse;
  text-align: left;
}

.compare th,
.compare td {
  padding: 16px 24px 16px 0;
  border-top: 1px solid var(--line);
  vertical-align: top;
}

.compare thead th,
.compare thead td {
  border-top: 0;
  font-weight: 700;
}

.compare thead th:last-child {
  color: var(--petrol);
}

.compare tbody th {
  width: 22%;
  color: var(--muted);
  font-weight: 400;
}

.compare tbody td:first-of-type {
  width: 36%;
  color: var(--muted);
}

/* FAQ */

.faq-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 64px;
  margin-top: 40px;
  max-width: 64rem;
}

.faq-item p {
  margin-top: 8px;
  color: var(--muted);
}

/* Audience */

.audience-list {
  display: grid;
  gap: 24px;
  margin-top: 40px;
  max-width: 48rem;
}

.audience-list p {
  color: var(--muted);
}

/* Contact */

.contact {
  padding-block: clamp(88px, 11vw, 160px);
}

.contact h2 {
  max-width: none;
}

.contact .lede {
  margin-top: 24px;
  max-width: 36rem;
  color: var(--on-dark-muted);
}

.contact-actions,
.pending {
  margin-top: 40px;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 32px;
}

.contact-address {
  color: var(--on-dark-muted);
}

.contact-address a {
  display: inline-block;
  padding-block: 11px;
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 4px;
  user-select: all;
}

.contact-note {
  margin-top: 24px;
  color: var(--on-dark-muted);
  font-size: 15px;
}

.pending {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
}

.pending-note {
  color: var(--on-dark-muted);
  font-size: 15px;
}

/* Footer */

.site-footer {
  padding-block: 56px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-footer .brand {
  width: 112px;
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 32px;
  color: var(--muted);
  font-size: 15px;
  line-height: 22px;
}

/* 404 */

.hero-short {
  padding-block: clamp(64px, 10vw, 140px);
}

.hero-short h1 {
  max-width: 16ch;
}

.hero-short .lede {
  margin-top: 24px;
  max-width: 34rem;
}

/* ---------- Up to 1199px: one straight paper under the hero copy ---------- */

@media (max-width: 1199px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 0;
  }

  .hero h1 {
    max-width: none;
  }

  .paper-stack {
    min-height: 0;
  }

  .paper-data {
    display: none;
  }

  .paper-check {
    position: static;
    width: 100%;
    max-width: 560px;
    transform: none;
    box-shadow: none;
    border: 1px solid var(--line);
    padding: 24px;
    font-size: 16px;
    line-height: 24px;
  }

  .paper-check .paper-title {
    font-size: 18px;
    line-height: 26px;
  }

  .paper-check .paper-label {
    font-size: 13px;
  }

  .paper li {
    grid-template-columns: 32px minmax(0, 1fr);
  }

  /* The paper straddles the petrol/white edge: a white band starts a fixed
     distance below the paper's top, so only its label sits on petrol. */
  .hero {
    padding-bottom: 0;
  }

  .papers {
    position: relative;
    isolation: isolate;
    margin-top: 40px;
  }

  .papers::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: 72px;
    bottom: 0;
    left: calc(-1 * var(--gutter));
    right: calc(-1 * var(--gutter));
    background: var(--white);
  }

  .papers figcaption {
    margin-top: 16px;
    color: var(--muted);
  }
}

/* Narrow split columns: a slimmer numeral column saves a wrapped line. */
@media (max-width: 1279px) {
  .numbered li {
    grid-template-columns: 72px minmax(0, 1fr);
  }
}

/* ---------- Up to 1023px: sections go single column ---------- */

@media (max-width: 1023px) {
  .evidence,
  .faq-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .split {
    grid-template-columns: minmax(0, 1fr);
  }

  .services {
    padding-top: 48px;
  }

  .numbered li {
    grid-template-columns: 64px minmax(0, 1fr);
  }
}

/* ---------- Menu instead of inline nav ---------- */

@media (max-width: 899px) {
  .nav {
    display: none;
  }

  .menu {
    display: block;
  }

  .menu summary {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-right: -12px;
    cursor: pointer;
    list-style: none;
  }

  .menu summary::-webkit-details-marker {
    display: none;
  }

  .menu-icon,
  .menu-icon::before,
  .menu-icon::after {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
  }

  .menu-icon {
    position: relative;
  }

  .menu-icon::before,
  .menu-icon::after {
    content: "";
    position: absolute;
    left: 0;
  }

  .menu-icon::before {
    top: -8px;
  }

  .menu-icon::after {
    top: 8px;
  }

  .menu[open] .menu-icon {
    background: transparent;
  }

  .menu[open] .menu-icon::before {
    top: 0;
    transform: rotate(45deg);
  }

  .menu[open] .menu-icon::after {
    top: 0;
    transform: rotate(-45deg);
  }

  .menu-panel {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--petrol);
    padding: 8px var(--gutter) 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
  }

  .menu-panel a {
    display: block;
    padding-block: 12px;
    font-size: 20px;
    line-height: 28px;
    text-decoration: none;
  }

}

/* ---------- Phone ---------- */

@media (max-width: 359px) {
  .eyebrow {
    font-size: 12px;
    letter-spacing: 0.06em;
  }
}

@media (max-width: 759px) {
  body {
    font-size: 17px;
    line-height: 26px;
  }

  /* The comparison stacks: row label on top, both formats labelled below. */
  .compare thead {
    display: none;
  }

  .compare tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    padding-block: 16px;
    border-top: 1px solid var(--line);
  }

  .compare th,
  .compare td {
    width: auto;
    padding: 0;
    border-top: 0;
  }

  .compare tbody th {
    width: auto;
    color: var(--ink);
    font-weight: 700;
  }

  .compare tbody td:first-of-type {
    width: auto;
  }

  .compare td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
  }

  .compare td:last-child::before {
    color: var(--petrol);
  }

  .header-inner {
    min-height: 72px;
  }

  .brand {
    width: 112px;
  }

  .hero {
    padding-top: 24px;
  }

  .papers {
    margin-top: 32px;
  }

  .hero h1 {
    max-width: none;
  }

  .actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    margin-top: 32px;
  }

  .hero .button {
    padding-inline: 28px;
  }

  .paper-check {
    padding: 20px;
  }

  .numbered li {
    grid-template-columns: 48px minmax(0, 1fr);
  }

  .num {
    font-size: 22px;
  }

  .people {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .people .person {
    max-width: 420px;
  }

  .contact .button {
    width: 100%;
    max-width: 360px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-meta {
    flex-direction: column;
  }
}

.intro.format {
  margin-top: 12px;
}
