/* Escuela BEES — PoC mobile. Tokens alineados al landing Club B. */

:root {
  --bees-yellow: #ffff00;
  --text: #141414;
  --text-secondary: #4a4a4a;
  --info: #006edb;
  --surface-page: #f4f4f4;
  --surface-card: #ffffff;
  --black-bg: #141414;
  --line: rgba(20, 20, 20, 0.12);
  --radius-pill: 512px;
  --radius-card: 8px;
  --shadow-soft: 0 2px 8px rgba(20, 20, 20, 0.08);
  --font-title: "Barlow", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Work Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --page-max: 480px;
  --space: 16px;
}

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

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  color: var(--text);
  background: var(--surface-page);
}

[hidden] {
  display: none !important;
}

.page-shell {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  min-height: 100dvh;
  background: var(--surface-card);
  display: flex;
  flex-direction: column;
}

.page-shell main {
  flex: 1 1 auto;
  min-width: 0;
}

.skip-link {
  position: absolute;
  left: var(--space);
  top: -48px;
  z-index: 40;
  padding: 8px 12px;
  background: var(--black-bg);
  color: var(--bees-yellow);
  border-radius: var(--radius-card);
  font-family: var(--font-title);
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: calc(8px + env(safe-area-inset-top, 0px));
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(56px + env(safe-area-inset-top, 0px));
  padding: calc(6px + env(safe-area-inset-top, 0px)) var(--space) 6px;
  background: var(--bees-yellow);
  color: var(--text);
}

.app-header__title {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  margin: 0;
  color: inherit;
  text-align: center;
  text-decoration: none;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1.375rem;
  line-height: 1.2;
}

.banner {
  display: block;
  background: var(--black-bg);
}

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

h1,
h2 {
  font-family: var(--font-title);
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
}

h1 {
  font-size: clamp(1.5rem, 1.2rem + 1.4vw, 1.75rem);
}

h2 {
  font-size: 1.25rem;
}

.intro {
  padding: 16px var(--space) 12px;
}

.intro h1 {
  margin-bottom: 6px;
}

.lead {
  margin: 4px 0 0;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.search {
  padding: 0 var(--space) 16px;
}

.search__field {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 14px;
  border: 2px solid var(--text);
  border-radius: var(--radius-pill);
  background: var(--surface-card);
}

.search__icon {
  width: 22px;
  height: 22px;
  flex: none;
}

.search__input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 48px;
  border: 0;
  margin: 0;
  padding: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 16px;
}

.search__input:focus {
  outline: none;
}

.search__input::placeholder {
  color: #5c5c5c;
  opacity: 1;
}

.search__field:focus-within {
  outline: 2px solid var(--info);
  outline-offset: 2px;
}

.empieza {
  position: relative;
  overflow: hidden;
  padding: 18px var(--space) 20px;
  background:
    radial-gradient(circle at 100% 0, rgba(20, 20, 20, 0.06), transparent 42%),
    var(--bees-yellow);
}

.empieza h2,
.empieza .lead,
.empieza .tlist {
  position: relative;
  z-index: 1;
}

.empieza .lead {
  color: var(--text);
  max-width: 28ch;
}

.empieza__accent {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 72px;
  height: 72px;
  pointer-events: none;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  padding: 16px var(--space) 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 8px 14px;
  border: 2px solid var(--text);
  border-radius: var(--radius-pill);
  background: var(--surface-card);
  color: var(--text);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1.2;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.chip .icon {
  width: 22px;
  height: 22px;
  flex: none;
}

.chip[aria-current="true"] {
  background: var(--black-bg);
  color: var(--bees-yellow);
  border-color: var(--black-bg);
}

.chip--off,
.chip--off:disabled {
  background: #f3f3f3;
  color: #3a3a3a;
  border-color: #8d8d8d;
  opacity: 1;
  cursor: not-allowed;
}

.chip__tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--bees-yellow);
  color: var(--text);
  font-size: 0.75rem;
}

.block {
  min-width: 0;
  padding: 8px var(--space) 20px;
}

.tlist {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.tlist li {
  min-width: 0;
}

.trow {
  display: grid;
  grid-template-columns: minmax(7.25rem, 38%) minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 48px;
  padding: 10px;
  border-radius: var(--radius-card);
  background: var(--surface-card);
  box-shadow: var(--shadow-soft);
  color: inherit;
  text-decoration: none;
}

.trow__media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
  background: var(--black-bg);
}

.trow__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.trow__time {
  position: absolute;
  right: 4px;
  bottom: 4px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--black-bg);
  color: #fff;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.75rem;
  line-height: 1.2;
}

.trow__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.trow__desc {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
  margin-top: 4px;
  color: var(--text-secondary);
  font-size: 0.8125rem;
  line-height: 1.3;
}

.tutorial {
  min-width: 0;
  padding: 16px var(--space) 8px;
}

.kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 8px;
}

.kicker__tema {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  background: var(--bees-yellow);
  color: var(--text);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.8125rem;
}

.kicker__time {
  color: var(--text-secondary);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.875rem;
}

.tutorial h1 {
  margin-bottom: 8px;
  overflow-wrap: anywhere;
}

.tutorial .lead {
  margin-bottom: 14px;
}

.player__stage {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-card);
  background: var(--black-bg);
}

.player__hit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: inherit;
  overflow: hidden;
  background: var(--black-bg);
  color: inherit;
  cursor: pointer;
}

.player__hit img,
.player__stage iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

.player__play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 48px;
  min-height: 48px;
  padding: 0 16px 0 12px;
  border: 2px solid var(--bees-yellow);
  border-radius: var(--radius-pill);
  background: var(--black-bg);
  color: var(--bees-yellow);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1;
  pointer-events: none;
}

.player__play svg {
  width: 22px;
  height: 22px;
  flex: none;
}

.player__label--short {
  display: none;
}

.yt-fallback {
  margin: 4px 0 0;
}

.yt-fallback a {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  color: var(--text);
  font-weight: 600;
  text-underline-offset: 3px;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 20px;
  border: 2px solid transparent;
  border-radius: var(--radius-pill);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.btn--block {
  width: 100%;
}

.btn--primary {
  background: var(--bees-yellow);
  color: var(--text);
  border-color: var(--text);
}

.btn--inverse {
  background: var(--surface-card);
  color: var(--text);
  border-color: var(--text);
}

.ayuda {
  margin-top: auto;
  padding: 24px var(--space) calc(20px + env(safe-area-inset-bottom, 0px));
  background: var(--black-bg);
  color: #fff;
}

.ayuda h2 {
  margin-bottom: 6px;
  color: #fff;
}

.ayuda .lead {
  margin: 0 0 16px;
  color: #f2f2f2;
}

.ayuda__icon {
  width: 20px;
  height: 20px;
  flex: none;
}

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 12px 8px 8px;
}

.empty svg {
  width: min(160px, 70%);
  height: auto;
}

.empty h2 {
  margin-top: 4px;
}

.empty .lead {
  max-width: 32ch;
}

.soon {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  margin-top: 8px;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  background: var(--bees-yellow);
  color: var(--text);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.8125rem;
}

.load-error,
.noscript {
  margin: 0;
  padding: 24px var(--space);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

a:focus-visible,
button:focus-visible,
.player__hit:focus-visible,
.skip-link:focus {
  outline: 2px solid var(--info);
  outline-offset: 2px;
}

@media (max-width: 360px) {
  .player__label--full {
    display: none;
  }

  .player__label--short {
    display: inline;
  }
}

@media (hover: hover) {
  .btn:hover,
  .trow:hover,
  .chip:hover {
    box-shadow: var(--shadow-soft);
  }

  .chip--off:hover {
    box-shadow: none;
  }
}

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