/**
 * Yalla Shoot Pro Sports - Additional Theme Styles
 */

/* Animations */
@keyframes ysPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.9;
  }
}

.ys-live-pill {
  animation: ysPulse 2s infinite ease-in-out;
}

/* Smooth Scrollbar */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 999px;
}

/* --------------------------------------------------------------------------
   Responsive layout system
   -------------------------------------------------------------------------- */

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

body {
  overflow-x: hidden;
}

img,
svg,
video,
iframe {
  max-width: 100%;
}

img {
  height: auto;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid #60a5fa;
  outline-offset: 3px;
}

.ys-menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 9px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #f8fafc;
  color: #1e293b;
  cursor: pointer;
}

.ys-menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 3px auto;
  border-radius: 999px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.ys-menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

.ys-menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.ys-menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}

.ys-champ-filters {
  scrollbar-width: thin;
  scrollbar-color: #94a3b8 transparent;
}

.ys-champ-filter,
.ys-live-toggle {
  flex: 0 0 auto;
  white-space: nowrap;
  min-height: 34px;
}

.ys-table-scroll {
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.ys-standings-table {
  min-width: 620px;
}

.ys-news-card {
  min-width: 0;
}

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

.ys-breadcrumb {
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
}

.ys-breadcrumb::-webkit-scrollbar {
  display: none;
}

.ys-scoreboard-team,
.ys-modal-team {
  min-width: 0;
}

.ys-scoreboard-team-name,
.ys-modal-team-name {
  overflow-wrap: anywhere;
}

.ys-scoreboard-logo,
.ys-modal-team-logo {
  display: block;
  max-width: 100%;
  object-fit: contain;
}

.ys-scoreboard-score,
.ys-modal-score {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.ys-player-frame {
  min-height: 180px;
}

.ys-embed-wrapper,
.ys-embed-wrapper iframe {
  display: block;
  width: 100%;
  height: 100%;
}

.ys-footer a,
.ys-match-copy,
.ys-match-meta,
.ys-modal-dialog {
  overflow-wrap: anywhere;
}

@media (max-width: 1024px) {
  .ys-container {
    max-width: 960px;
    padding-right: 20px;
    padding-left: 20px;
  }

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

  .ys-nav-links {
    gap: 14px;
    font-size: 14px;
  }

  .ys-brand-btn {
    font-size: 20px;
    padding: 9px 22px;
  }

  .ys-schedule-box {
    padding: 20px;
  }

  .ys-footer {
    margin-top: 36px !important;
  }
}

@media (max-width: 767px) {
  body {
    line-height: 1.55;
  }

  .ys-container {
    width: 100%;
    padding-right: 14px;
    padding-left: 14px;
  }

  .ys-header {
    position: sticky;
  }

  .ys-header-inner {
    position: relative;
    height: 64px;
  }

  .ys-nav-left {
    gap: 8px;
  }

  .ys-menu-toggle {
    display: inline-block;
  }

  .ys-nav-links {
    position: absolute;
    z-index: 110;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.15);
    font-size: 14px;
  }

  .ys-nav-links.is-open {
    display: flex;
  }

  .ys-nav-links a {
    padding: 10px 12px;
    border-radius: 8px;
  }

  .ys-nav-links a:hover,
  .ys-nav-links a:focus-visible {
    background: #eff6ff;
  }

  .ys-nav-links span {
    display: none;
  }

  .ys-brand-btn {
    border-radius: 10px;
    font-size: 17px;
    padding: 8px 14px;
  }

  .ys-schedule-box {
    padding: 16px;
    margin-top: 16px;
    margin-bottom: 20px;
    border-radius: 16px;
  }

  .ys-schedule-header {
    gap: 14px;
    margin-bottom: 18px;
  }

  .ys-date-filters {
    width: 100%;
  }

  .ys-date-btn-group {
    width: 100%;
  }

  .ys-date-btn {
    flex: 1 1 0;
    min-height: 38px;
    padding: 8px 6px;
    font-size: 12px;
  }

  .ys-champ-filters {
    margin-right: -2px;
    margin-left: -2px;
    padding-right: 2px;
    padding-left: 2px;
    scroll-padding-inline: 2px;
    scroll-snap-type: inline proximity;
  }

  .ys-champ-filter,
  .ys-live-toggle {
    scroll-snap-align: start;
  }

  .ys-live-toggle {
    margin-right: 0 !important;
  }

  .ys-match-body {
    padding: 14px 10px;
    gap: 8px;
  }

  .ys-match-center {
    min-width: 78px;
  }

  .ys-match-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px;
  }

  .ys-match-footer-item {
    min-width: 0;
    overflow: hidden;
  }

  .ys-match-footer-item > span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .ys-match-footer-item:last-child {
    grid-column: 1 / -1;
    justify-content: space-between;
  }

  .ys-watch-btn {
    flex: 0 0 auto;
  }

  .ys-section-heading,
  .ys-news-heading {
    margin-bottom: 16px !important;
  }

  .ys-section-heading-content h2,
  .ys-news-heading h2 {
    font-size: 16px !important;
    line-height: 1.45;
  }

  .ys-standings-table {
    min-width: 600px;
    font-size: 12px !important;
  }

  .ys-standings-table th,
  .ys-standings-table td {
    padding: 9px 7px !important;
  }

  .ys-news-grid {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  .ys-news-image {
    height: auto !important;
    aspect-ratio: 16 / 8.5;
  }

  .ys-news-content {
    padding: 14px !important;
  }

  .ys-footer {
    margin-top: 28px !important;
    padding: 30px 0 20px !important;
  }

  .ys-footer-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
    margin-bottom: 26px !important;
  }

  .ys-footer-seo {
    padding: 16px !important;
  }

  .ys-footer-legal-links {
    flex-wrap: wrap;
    column-gap: 8px !important;
    row-gap: 3px !important;
  }

  .ys-keyword-tags {
    gap: 5px !important;
  }

  .ys-footer-bottom {
    align-items: flex-start !important;
    gap: 8px;
    padding-top: 16px !important;
  }

  .ys-match-page {
    padding-top: 14px !important;
    padding-bottom: 24px !important;
  }

  .ys-breadcrumb {
    margin-bottom: 12px !important;
  }

  .ys-match-hero {
    border-radius: 16px;
  }

  .ys-match-ribbon {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 5px;
    padding: 10px 14px !important;
    font-size: 12px !important;
  }

  .ys-scoreboard {
    padding: 22px 10px !important;
  }

  .ys-scoreboard-grid {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .ys-scoreboard-logo {
    width: 52px !important;
    height: 52px !important;
    margin-bottom: 8px !important;
  }

  .ys-scoreboard-team-name {
    font-size: 14px !important;
    line-height: 1.35;
  }

  .ys-scoreboard-score {
    font-size: 27px !important;
    letter-spacing: 1px !important;
  }

  .ys-scoreboard-score span {
    font-size: 20px !important;
  }

  .ys-match-meta {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 12px 14px !important;
    font-size: 12px !important;
  }

  .ys-player-section {
    padding: 14px !important;
  }

  .ys-player-heading {
    align-items: flex-start !important;
    margin-bottom: 12px !important;
  }

  .ys-player-heading h3 {
    font-size: 14px !important;
    line-height: 1.45;
  }

  .ys-player-frame {
    min-height: 0;
    border-radius: 12px !important;
  }

  .ys-player-frame h4 {
    font-size: 15px !important;
  }

  .ys-player-frame p {
    font-size: 12px !important;
  }

  .ys-player-frame [style*="font-family:monospace"] {
    max-width: 100%;
    overflow-x: auto;
    white-space: nowrap;
  }

  .ys-server-grid {
    grid-template-columns: 1fr !important;
  }

  .ys-server-btn {
    min-height: 42px;
  }

  .ys-match-copy {
    padding: 16px !important;
  }

  .ys-match-copy h2 {
    font-size: 16px !important;
    line-height: 1.5;
  }

  .ys-match-facts {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }

  .ys-match-facts > div {
    padding: 10px !important;
  }

  #ysMatchModal {
    align-items: flex-end !important;
    padding: 0 !important;
  }

  .ys-modal-dialog {
    width: 100% !important;
    max-height: min(88dvh, 760px) !important;
    border-radius: 20px 20px 0 0 !important;
  }

  .ys-modal-topbar {
    padding: 14px 16px !important;
  }

  .ys-modal-hero {
    padding: 18px 12px !important;
  }

  .ys-modal-scoreboard {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  .ys-modal-team-logo {
    width: 48px !important;
    height: 48px !important;
  }

  .ys-modal-team-name {
    font-size: 13px !important;
    line-height: 1.35;
  }

  .ys-modal-score {
    font-size: 25px !important;
  }

  .ys-modal-broadcast-info {
    flex-direction: column;
    gap: 5px;
    padding: 10px 16px !important;
  }

  .ys-modal-servers {
    padding: 16px !important;
  }
}

@media (max-width: 420px) {
  .ys-container {
    padding-right: 10px;
    padding-left: 10px;
  }

  .ys-header-inner {
    height: 60px;
  }

  .ys-brand-btn {
    font-size: 15px;
    padding: 8px 10px;
  }

  .ys-menu-toggle {
    width: 36px;
    height: 36px;
  }

  .ys-schedule-box {
    padding: 12px;
  }

  .ys-schedule-title-badge {
    font-size: 14px;
  }

  .ys-match-body {
    padding: 12px 8px;
    gap: 4px;
  }

  .ys-team {
    gap: 5px;
  }

  .ys-team-logo {
    width: 30px;
    height: 30px;
    padding: 2px;
  }

  .ys-team-name {
    font-size: 11px;
  }

  .ys-match-center {
    min-width: 66px;
  }

  .ys-score {
    font-size: 18px;
  }

  .ys-live-pill,
  .ys-upcoming-pill,
  .ys-finished-pill {
    font-size: 8px;
  }

  .ys-match-footer {
    grid-template-columns: 1fr;
  }

  .ys-match-footer-item:last-child {
    grid-column: auto;
  }

  .ys-match-facts {
    grid-template-columns: 1fr !important;
  }

  .ys-scoreboard-logo {
    width: 44px !important;
    height: 44px !important;
  }

  .ys-scoreboard-team-name {
    font-size: 12px !important;
  }

  .ys-scoreboard-score {
    font-size: 22px !important;
  }

  .ys-scoreboard .ys-live-pill,
  .ys-scoreboard .ys-upcoming-pill,
  .ys-scoreboard .ys-finished-pill {
    padding-right: 7px !important;
    padding-left: 7px !important;
  }
}

/* Match card: compact scoreboard layout */
.ys-match-card {
  overflow: hidden;
  margin-bottom: 16px;
  border: 1px solid #e1e5eb;
  border-radius: 12px;
  background: #f8f9fb;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05);
}

.ys-match-card:hover {
  border-color: #c6d3e2;
  box-shadow: 0 7px 20px rgba(15, 23, 42, 0.09);
}

.ys-match-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px minmax(0, 1fr);
  align-items: center;
  min-height: 112px;
  padding: 14px 18px;
  gap: 18px;
}

.ys-team {
  min-width: 0;
  gap: 12px;
  direction: ltr;
}

.ys-team-home {
  justify-content: flex-end;
}

.ys-team-away {
  justify-content: flex-start;
}

.ys-team-name {
  color: #070b12;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.45;
  direction: rtl;
}

.ys-team-logo {
  width: 72px;
  height: 72px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  object-fit: contain;
}

.ys-match-center {
  min-width: 0;
  gap: 5px;
}

.ys-score {
  margin: 0;
  color: #05080d;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.2px;
  line-height: 1.3;
}

.ys-score > span {
  font-size: inherit !important;
}

.ys-live-pill,
.ys-upcoming-pill,
.ys-finished-pill {
  padding: 5px 13px;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.25;
}

.ys-upcoming-pill {
  background: #233e5d;
  color: #ffffff;
}

.ys-finished-pill {
  background: #e1e6ec;
  color: #344255;
}

.ys-match-footer {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: center;
  min-height: 41px;
  padding: 7px 18px;
  border-top: 1px solid #dfe4ea;
  background: #f0f2f5;
  color: #0f172a;
  font-size: 15px;
  font-weight: 800;
}

.ys-match-footer-item,
.ys-match-footer-item:last-child {
  display: inline-flex !important;
  min-width: 0;
  justify-content: center;
  gap: 7px !important;
  overflow: visible;
  white-space: nowrap;
}

.ys-match-footer-item > span:last-child {
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}

.ys-match-footer .ys-watch-btn {
  display: none !important;
}

@media (max-width: 767px) {
  .ys-match-body {
    grid-template-columns: minmax(0, 1fr) 112px minmax(0, 1fr);
    min-height: 112px;
    padding: 14px 12px;
    gap: 8px;
  }

  .ys-team {
    gap: 8px;
  }

  .ys-team-logo {
    width: 70px;
    height: 70px;
  }

  .ys-team-name {
    font-size: 17px;
  }

  .ys-score {
    font-size: 18px;
  }

  .ys-live-pill,
  .ys-upcoming-pill,
  .ys-finished-pill {
    padding: 5px 11px;
    font-size: 13px;
  }

  .ys-match-footer {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
    min-height: 39px;
    padding: 7px 8px;
    font-size: 13px;
  }

  .ys-match-footer-item:last-child {
    grid-column: auto;
  }
}

@media (max-width: 420px) {
  .ys-match-body {
    grid-template-columns: minmax(0, 1fr) 86px minmax(0, 1fr);
    min-height: 92px;
    padding: 10px 8px;
    gap: 5px;
  }

  .ys-team {
    gap: 5px;
  }

  .ys-team-logo {
    width: 46px;
    height: 46px;
  }

  .ys-team-name {
    font-size: 12px;
  }

  .ys-score {
    font-size: 15px;
  }

  .ys-live-pill,
  .ys-upcoming-pill,
  .ys-finished-pill {
    padding: 4px 7px;
    font-size: 10px;
  }

  .ys-match-footer {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 6px 3px;
    font-size: 10px;
  }

  .ys-match-footer-item {
    gap: 3px !important;
  }
}
