/* Today Old Man: a cousin of hafta.io.
   Shared with Hafta: the #040a07 background, Orbitron and Exo 2, cut-corner buttons,
   small labels with a glowing line, thin vertical light lines.
   Its own: amber accent, warm text, the TOM badge. Teal belongs to Hafta only. */

@font-face {
  font-family: "Orbitron";
  src: url("fonts/orbitron.woff2") format("woff2");
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: "Exo 2";
  src: url("fonts/exo-2.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #040a07;
  --amber: #f0a24a;
  --amber-hi: #ffc27a;
  --text: #efe6d8;
  --text-2: #d6cbb9;
  --muted: #b3a38c;
  --white: #f6eee2;
  --teal: #00e5a0;
  --display: "Orbitron", system-ui, sans-serif;
  --body: "Exo 2", system-ui, sans-serif;
  --cut: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 0 100%);
  --pad: clamp(20px, 4vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); }
h1, h2, h3, p, ul { margin: 0; }

a { color: var(--amber); }
a:hover { color: var(--amber-hi); }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  clip-path: none; /* a cut corner would hide the focus ring */
}

.page {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: linear-gradient(170deg, #0b0906 0%, #040a07 40%, #020605 100%);
  color: var(--text);
  font-family: var(--body);
  font-weight: 300;
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: 0.02em;
}

/* ─── Light lines ───────────────────────────────────── */

.beam {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  pointer-events: none;
}
.beam--teal  { left: 14%; background: linear-gradient(to bottom, transparent, rgba(0, 229, 160, 0.12) 10%, rgba(0, 229, 160, 0.12) 90%, transparent); }
.beam--amber { left: 86%; background: linear-gradient(to bottom, transparent, rgba(240, 162, 74, 0.14) 10%, rgba(240, 162, 74, 0.14) 90%, transparent); }
@media (max-width: 700px) {
  .beam--teal  { left: 6px; }
  .beam--amber { left: auto; right: 6px; }
}

.beam__pulse {
  position: absolute;
  left: -2px;
  top: -130px;
  width: 5px;
  height: 120px;
  filter: blur(1px);
  opacity: 0;
}
.beam--teal .beam__pulse  { background: linear-gradient(to bottom, transparent, #00ffb3, transparent); box-shadow: 0 0 14px rgba(0, 229, 160, 0.7); }
.beam--amber .beam__pulse { background: linear-gradient(to bottom, transparent, var(--amber-hi), transparent); box-shadow: 0 0 14px rgba(240, 162, 74, 0.7); }

@media (prefers-reduced-motion: no-preference) {
  .beam__pulse { animation: flow 16s linear infinite; }
  .beam--amber .beam__pulse { animation-delay: 5s; }
}
@keyframes flow {
  0%   { top: -130px; opacity: 0; }
  8%   { opacity: 0.85; }
  92%  { opacity: 0.85; }
  100% { top: 100%; opacity: 0; }
}

/* ─── Shared pieces ─────────────────────────────────── */

.label {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--amber);
}
.label::before {
  content: "";
  flex: none;
  width: 24px;
  height: 1px;
  background: var(--amber);
  box-shadow: 0 0 6px var(--amber);
}

.headline {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(26px, 4.4vw, 56px);
  line-height: 1.08;
  letter-spacing: 0.06em;
  color: var(--white);
}

.badge {
  display: inline-block;
  padding: 7px 10px 6px;
  background: var(--amber);
  color: var(--bg);
  font-family: var(--display);
  font-weight: 900;
  font-size: 13px;
  line-height: 1;
  letter-spacing: 0.12em;
  clip-path: var(--cut);
}
.badge--small {
  padding: 5px 8px 4px;
  font-size: 11px;
  clip-path: polygon(0 0, calc(100% - 6px) 0, 100% 6px, 100% 100%, 0 100%);
}

.btn {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 32px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn--solid { background: var(--amber); color: var(--bg); clip-path: var(--cut); }
.btn--solid:hover { background: var(--amber-hi); color: var(--bg); }
.btn--line { border: 1px solid rgba(240, 162, 74, 0.35); color: var(--amber); }
.btn--line:hover { border-color: var(--amber); }
.btn--teal { border: 1px solid rgba(0, 229, 160, 0.35); color: var(--teal); }
.btn--teal:hover { border-color: var(--teal); color: var(--teal); }
.btn--teal:focus-visible { outline-color: var(--teal); }

.artist {
  font-family: var(--display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--teal);
}
.artist--small { font-size: 10px; }

.meta {
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ─── Header ────────────────────────────────────────── */

.top {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 32px;
  padding: 18px var(--pad);
  border-bottom: 1px solid rgba(240, 162, 74, 0.06);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  text-decoration: none;
}
.brand__name {
  font-family: var(--display);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 32px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.nav a {
  display: inline-block;
  padding: 14px 0;
  color: var(--muted);
  text-decoration: none;
}
.nav a:hover { color: var(--amber); }
@media (max-width: 520px) {
  .nav { gap: 0 20px; letter-spacing: 0.16em; }
}

/* ─── Hero ──────────────────────────────────────────── */

.hero {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  padding: clamp(96px, 16vh, 150px) var(--pad) clamp(96px, 14vh, 140px);
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 40%, rgba(240, 162, 74, 0.10) 0%, transparent 55%),
    repeating-linear-gradient(0deg, transparent, transparent 38px, rgba(240, 162, 74, 0.025) 39px);
}

/* Each letter sits in a 0.9em cell. TODAY OLD MAN is 13 cells (spaces included),
   TY MALDONADO is 12. main.js moves each letter from its cell in one to the other. */
.anagram {
  position: relative;
  width: 100%;
  max-width: 1140px;
  height: 1.3em;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(24px, 7vw, 88px);
  line-height: 1.3;
  color: var(--white);
  text-shadow: 0 0 30px rgba(240, 162, 74, 0.25), 0 0 80px rgba(240, 162, 74, 0.08);
}
.anagram span {
  position: absolute;
  top: 0;
  width: 0.9em;
  text-align: center;
  left: calc(50% + var(--x, 0em));
}
/* With JavaScript, the name stays hidden until main.js has scrambled it, so it never
   flashes in place first. If the script never runs, it shows anyway after 3 seconds. */
.js .anagram { opacity: 0; animation: show 0s 3s forwards; }
.js .anagram.is-ready { opacity: 1; animation: none; }
@keyframes show { to { opacity: 1; } }

.anagram.is-moving span {
  transition: left 1.3s cubic-bezier(0.65, 0, 0.25, 1) var(--d, 0s);
}

.hero__caption {
  max-width: 560px;
  font-size: 18px;
  color: var(--text-2);
  transition: opacity 0.8s ease 0.9s;
}
.hero.is-scrambled .hero__caption { opacity: 0; transition: none; }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 8px;
}

.replay {
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: var(--display);
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  cursor: pointer;
}
.replay:hover { color: var(--amber); }

/* ─── Sections ──────────────────────────────────────── */

.section {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 28px;
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(64px, 9vw, 96px) var(--pad);
}
.section--last { padding-bottom: clamp(80px, 11vw, 120px); }

/* Latest */
.latest {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 32px 56px;
  padding: clamp(20px, 3vw, 32px);
  background: rgba(240, 162, 74, 0.035);
  border: 1px solid rgba(240, 162, 74, 0.15);
}
.latest__cover {
  display: block;
  flex: 1 1 300px;
  min-width: 0;
  max-width: 460px;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}
.latest__body {
  flex: 999 1 340px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}
.latest__title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.05;
  letter-spacing: 0.04em;
  color: var(--white);
}
.latest__text { max-width: 520px; color: var(--text-2); }
.latest__body .btn { margin-top: 6px; }

/* Catalog */
.catalog {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 32px 28px;
  margin-top: 12px;
  padding: 0;
  list-style: none;
}
@media (max-width: 520px) {
  .catalog { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; }
}
.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--text);
  text-decoration: none;
}
.card:hover { color: var(--text); }
.card__art {
  display: block;
  overflow: hidden;
  margin-bottom: 4px;
  border: 1px solid rgba(240, 162, 74, 0.15);
}
.card__art img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}
@media (prefers-reduced-motion: no-preference) {
  .card__art img { transition: transform 0.4s ease; }
  .card:hover .card__art img { transform: scale(1.03); }
}
.card__title { font-weight: 500; font-size: 19px; line-height: 1.3; }
.card:hover .card__title { color: var(--amber-hi); }
.card__meta { font-size: 14px; color: var(--muted); }
@media (max-width: 520px) {
  .card__title { font-size: 16px; }
}

/* Artists */
.artist-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px 56px;
  padding: clamp(28px, 4vw, 44px) clamp(24px, 4vw, 40px);
  background: rgba(0, 229, 160, 0.03);
  border: 1px solid rgba(0, 229, 160, 0.15);
}
.artist-card__body {
  flex: 999 1 380px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.artist-card__body p { max-width: 560px; color: var(--text-2); }
.hafta-logo {
  display: block;
  align-self: flex-start; /* keep it at its own width, left-aligned */
  height: 44px;
  aspect-ratio: 1068 / 198;
  background: var(--teal);
  -webkit-mask: url("images/hafta-logo.png") no-repeat center / contain;
  mask: url("images/hafta-logo.png") no-repeat center / contain;
}

/* Licensing */
.licensing__text { max-width: 620px; color: var(--text-2); }
.licensing__email {
  align-self: flex-start;
  padding: 8px 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(17px, 2.4vw, 28px);
  letter-spacing: 0.08em;
  text-underline-offset: 8px;
  overflow-wrap: anywhere;
}

/* ─── Footer ────────────────────────────────────────── */

.foot {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 32px;
  padding: 36px var(--pad);
  border-top: 1px solid rgba(240, 162, 74, 0.12);
  font-family: var(--display);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.foot__mark { display: flex; align-items: center; gap: 14px; }
.foot__hafta { display: inline-block; padding: 12px 0; color: var(--teal); text-decoration: none; }
.foot__hafta:hover { color: var(--teal); text-decoration: underline; }
.foot__hafta:focus-visible { outline-color: var(--teal); }
