/* ============================================================
   onefootball-matches — a static study rebuild of the
   onefootball.com/en/matches landing page in plain HTML + CSS.
   No framework, no JavaScript.

   Colours, radii and sizes were read off the live site's own
   computed styles.
   ============================================================ */

:root {
  /* surfaces */
  --page: #000000;
  --surface: #1a1a1a;      /* match cards, social tiles, footer */
  --surface-2: #222222;    /* hover                             */
  --line: #2b2b2b;

  /* ink */
  --ink: #f3f4f5;
  --ink-dim: #a7a9ac;
  --ink-faint: #76797d;

  /* accent */
  --lime: #e1ff57;

  /* geometry */
  --radius: 8px;
  --shell: 1320px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
}

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

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

body {
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.3;
  -webkit-font-smoothing: antialiased;
}

svg {
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

ul {
  list-style: none;
}

h1,
h2,
h3 {
  font-weight: 700;
}

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: 20px;
}

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

/* ------------------------------------------------ generic crest ----
   The live site shows club and competition badges. Those belong to
   their owners, so this rebuild draws its own neutral mark: a tinted
   disc carrying the club's initials. */
.crest {
  display: grid;
  place-items: center;
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--crest, #3a3a3a);
  color: #fff;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.crest--lg {
  width: 52px;
  height: 52px;
  font-size: 15px;
}

/* ===================== HEADER ===================== */

.masthead {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--page);
  border-bottom: 1px solid var(--line);
}

.masthead__row {
  display: flex;
  align-items: center;
  gap: 18px;
  height: 80px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: none;
  margin-right: 14px;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.wordmark__mark {
  display: block;
  width: 22px;
  height: 22px;
  background: var(--ink);
  clip-path: polygon(0 62%, 62% 0, 100% 0, 100% 38%, 38% 100%, 0 100%);
}

.wordmark--sm {
  font-size: 17px;
}

.mainnav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.mainnav a {
  position: relative;
  padding-block: 28px;
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
}

.mainnav a:hover {
  color: var(--lime);
}

.mainnav a[aria-current="page"] {
  color: var(--lime);
}

.mainnav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 3px;
  background: var(--lime);
}

.pillbtn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  height: 44px;
  padding-inline: 16px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 600;
}

.pillbtn:hover {
  background: var(--surface);
}

.masthead__right {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-left: auto;
}

.circlebtn {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
}

.circlebtn:hover {
  background: var(--surface-2);
}

.divider-v {
  width: 1px;
  height: 28px;
  background: var(--line);
}

.btn-ghost {
  display: inline-grid;
  place-items: center;
  height: 44px;
  padding-inline: 20px;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 500;
}

.btn-ghost:hover {
  background: var(--surface);
}

.btn-solid {
  display: inline-grid;
  place-items: center;
  height: 46px;
  padding-inline: 24px;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--page);
  font-size: 16px;
  font-weight: 600;
}

.btn-solid:hover {
  background: #fff;
}

/* ===================== CALENDAR BAR ===================== */

.calendar {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  padding-block: 24px 20px;
  border-bottom: 1px solid var(--line);
}

@media (min-width: 1100px) {
  .calendar {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

.calendar__label {
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 700;
}

.calendar__label span {
  font-weight: 500;
  color: var(--ink-dim);
}

.daystrip {
  display: flex;
  align-items: center;
  gap: 10px;
}

.daystrip__rail {
  display: flex;
  gap: 10px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.arrow {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: var(--ink);
}

.arrow:hover {
  background: var(--surface);
}

.day {
  display: grid;
  place-items: center;
  flex: none;
  min-width: 80px;
  height: 52px;
  padding-inline: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.day:hover {
  border-color: var(--ink-faint);
}

.day[aria-current="date"] {
  border-color: var(--lime);
  color: var(--lime);
  font-weight: 700;
}

.typefilter {
  display: flex;
  gap: 10px;
}

.type {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 52px;
  padding-inline: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.type:hover {
  border-color: var(--ink-faint);
}

.type[aria-pressed="true"] {
  border-color: var(--lime);
  color: var(--lime);
}

.type__play {
  width: 0;
  height: 0;
  border-left: 9px solid #ff4d8d;
  border-block: 6px solid transparent;
}

/* ===================== TOP GAMES RAIL ===================== */

.section {
  padding-block: 28px;
  border-bottom: 1px solid var(--line);
}

.section__title {
  margin-bottom: 20px;
  font-size: 20px;
}

.section__title--caps {
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.rail {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rail__track {
  display: flex;
  gap: 20px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

/* -- match card -- */

.match {
  display: flex;
  align-items: stretch;
  flex: none;
  width: 400px;
  padding: 16px 14px;
  background: var(--surface);
  border-radius: var(--radius);
}

.match:hover {
  background: var(--surface-2);
}

.match--block {
  width: 400px;
  max-width: 100%;
}

.match__teams {
  display: grid;
  gap: 14px;
  flex: 1;
  min-width: 0;
  padding-right: 14px;
}

.match__team {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  font-size: 15px;
}

.match__team span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match__team b {
  margin-left: auto;
  padding-left: 12px;
  font-size: 15px;
  font-weight: 700;
}

.match__status {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 4px;
  flex: none;
  width: 120px;
  border-left: 1px solid var(--line);
  font-size: 14px;
  font-weight: 700;
  text-align: center;
}

.match__status span {
  color: var(--ink-dim);
  font-weight: 500;
}

/* ===================== TEAM / COMPETITION TILES ===================== */

.tiles {
  display: flex;
  gap: 20px;
  overflow: hidden;
}

.tile {
  display: grid;
  place-items: center;
  gap: 12px;
  flex: none;
  width: 240px;
  padding: 24px 16px;
  background: var(--surface);
  border-radius: var(--radius);
  text-align: center;
}

.tile:hover {
  background: var(--surface-2);
}

.tile__name {
  font-size: 15px;
  font-weight: 600;
}

.tile__kind {
  color: var(--ink-faint);
  font-size: 13px;
}

/* ===================== MATCH LIST ===================== */

.list {
  padding-block: 32px 56px;
}

.list h1 {
  font-size: 22px;
}

.list__date {
  margin-top: 8px;
  color: var(--ink-dim);
  font-size: 15px;
}

.comp {
  margin-top: 36px;
}

.comp__head {
  display: flex;
  align-items: center;
  gap: 16px;
}

.comp__name {
  font-size: 18px;
}

.comp__matchday {
  margin-top: 6px;
  color: var(--ink-dim);
  font-size: 15px;
}

.comp__fixtures {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.comp__more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  font-size: 15px;
  font-weight: 500;
}

.comp__more:hover {
  color: var(--lime);
}

/* ===================== FOOTER ===================== */

.footer {
  background: var(--surface);
  padding-block: 40px 28px;
}

.footer h2 {
  margin-bottom: 20px;
  font-size: 20px;
}

.socials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
}

.social {
  display: grid;
  gap: 10px;
  padding: 16px;
  background: #2a2a2a;
  border-radius: 2px;
}

.social:hover {
  background: #333;
}

.social__icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--page);
  font-size: 11px;
  font-weight: 800;
}

.social__name {
  color: var(--ink-dim);
  font-size: 13px;
}

.social__handle {
  font-size: 14px;
  font-weight: 700;
}

.footer__rule {
  height: 1px;
  margin-block: 32px;
  background: #343434;
}

.footer__cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 28px;
  margin-top: 28px;
}

.footer__cols h3 {
  margin-bottom: 16px;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.footer__cols li + li {
  margin-top: 12px;
}

.footer__cols a {
  color: var(--ink-dim);
  font-size: 15px;
}

.footer__cols a:hover {
  color: var(--ink);
}

.footer__copy {
  margin-top: 36px;
  color: var(--ink-dim);
  font-size: 14px;
}

.footnote {
  padding-block: 24px 40px;
  color: var(--ink-faint);
  font-size: 12px;
  line-height: 1.7;
}

.footnote strong {
  color: var(--ink-dim);
}

/* ===================== BACK TO TOP ===================== */

.backtotop {
  position: fixed;
  bottom: 24px;
  left: 50%;
  translate: -50% 0;
  z-index: 25;
  padding: 14px 24px;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--page);
  font-size: 15px;
  font-weight: 500;
  box-shadow: 0 6px 24px rgb(0 0 0 / 0.6);
}

.backtotop:hover {
  background: #fff;
}

/* ===================== RESPONSIVE ===================== */

@media (max-width: 1099px) {
  .masthead__row {
    gap: 12px;
  }

  .pillbtn span {
    display: none;
  }
}

@media (max-width: 859px) {
  .mainnav,
  .divider-v,
  .btn-ghost {
    display: none;
  }

  .match {
    width: 320px;
  }

  .backtotop {
    display: none;
  }
}
