/* StreamLeaf — Cover Site Stylesheet */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg-dark: #0b1215;
  --bg-card: #131e24;
  --bg-surface: #1a2a32;
  --bg-nav: rgba(11, 18, 21, 0.95);
  --accent: #2dd4a8;
  --accent-dim: #1a8f6e;
  --accent-glow: rgba(45, 212, 168, 0.15);
  --text: #e8efed;
  --text-muted: #7a9590;
  --text-dim: #4d6660;
  --border: #1e3330;
  --radius: 10px;
  --radius-lg: 16px;
}

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  background: var(--bg-dark);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: #5eedc7; }
a.sl-card { color: var(--text); }
a.sl-card:hover { color: var(--text); }

/* --- Navigation --- */
.sl-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: var(--bg-nav); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem; height: 64px;
  display: flex; align-items: center; justify-content: space-between;
}
.sl-logo { font-size: 1.4rem; font-weight: 700; color: var(--accent); letter-spacing: -0.5px; }
.sl-logo span { color: var(--text); }
.sl-nav-links { display: flex; gap: 1.8rem; align-items: center; }
.sl-nav-links a { color: var(--text-muted); font-size: .95rem; font-weight: 500; }
.sl-nav-links a:hover, .sl-nav-links a.active { color: var(--text); }
.sl-nav-btn {
  background: var(--accent); color: var(--bg-dark); font-weight: 600;
  padding: .5rem 1.2rem; border-radius: 6px; font-size: .85rem; border: none; cursor: pointer;
}
.sl-nav-btn:hover { background: #5eedc7; }

/* Mobile nav toggle */
.sl-nav-toggle { display: none; background: none; border: none; color: var(--text); font-size: 1.5rem; cursor: pointer; }

/* --- Hero --- */
.sl-hero {
  padding: 0; text-align: center;
  position: relative; overflow: hidden;
  min-height: 85vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.sl-hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background-size: cover; background-position: center;
}
.sl-hero-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg,
    rgba(11,18,21,0.3) 0%,
    rgba(11,18,21,0.6) 50%,
    rgba(11,18,21,1) 100%);
}
.sl-hero h1 { font-size: 3.5rem; font-weight: 800; line-height: 1.1; margin-bottom: 1rem; position: relative; z-index: 1; text-shadow: 0 4px 30px rgba(0,0,0,0.5); }
.sl-hero h1 em { font-style: normal; color: var(--accent); }
.sl-hero p { font-size: 1.2rem; color: #c0d0cc; max-width: 560px; margin: 0 auto 2rem; position: relative; z-index: 1; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }
.sl-hero-btn {
  display: inline-block; background: var(--accent); color: var(--bg-dark); font-weight: 700;
  padding: .85rem 2.4rem; border-radius: 8px; font-size: 1.05rem;
  transition: transform .2s, box-shadow .2s; position: relative; z-index: 1;
}
.sl-hero-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(45,212,168,0.35); color: var(--bg-dark); }

/* Featured hero card */
.sl-hero-featured {
  position: relative; z-index: 1; margin-top: 2rem;
  display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center;
}
.sl-hero-tag {
  background: rgba(255,255,255,0.1); backdrop-filter: blur(8px);
  padding: .35rem .8rem; border-radius: 20px; font-size: .8rem;
  color: rgba(255,255,255,0.8); border: 1px solid rgba(255,255,255,0.1);
}

/* --- Section --- */
.sl-section { padding: 3rem 2rem 2rem; max-width: 1280px; margin: 0 auto; }
.sl-section-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 1.2rem; }

/* --- Horizontal Scroll Row --- */
.sl-row {
  display: flex; gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory;
  padding-bottom: 1rem; scrollbar-width: thin; scrollbar-color: var(--border) transparent;
}
.sl-row::-webkit-scrollbar { height: 6px; }
.sl-row::-webkit-scrollbar-track { background: transparent; }
.sl-row::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
.sl-row > .sl-card { flex: 0 0 180px; min-width: 180px; max-width: 180px; scroll-snap-align: start; }

/* --- Content Grid --- */
.sl-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(185px, 1fr));
  gap: 1.2rem;
}
.sl-card {
  border-radius: var(--radius); overflow: hidden; position: relative;
  aspect-ratio: 2/3; cursor: pointer; transition: transform .25s, box-shadow .25s;
  background: var(--bg-card);
}
.sl-card:hover { transform: translateY(-6px) scale(1.03); box-shadow: 0 12px 40px rgba(0,0,0,0.5); z-index: 2; }
.sl-card img {
  width: 100%; height: 100%; object-fit: cover;
  display: block; transition: opacity .3s;
}
.sl-card-info {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 2.5rem .8rem .8rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.9));
}
.sl-card-title { font-size: .88rem; font-weight: 600; }
.sl-card-meta { font-size: .72rem; color: var(--text-muted); margin-top: .2rem; }
.sl-badge {
  position: absolute; top: .6rem; left: .6rem; z-index: 1;
  background: var(--accent); color: var(--bg-dark); font-size: .65rem;
  font-weight: 700; padding: .2rem .5rem; border-radius: 4px;
}

/* Play overlay on hover */
.sl-card::after {
  content: '\25B6'; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.5rem; color: white; opacity: 0;
  background: rgba(0,0,0,0.3); transition: opacity .25s;
  pointer-events: none;
}
.sl-card:hover::after { opacity: 1; }

/* Poster gradient fallback palette (behind images) */
.sl-poster-1 { background: linear-gradient(135deg, #1a3a4a, #0d4035, #1a5040); }
.sl-poster-2 { background: linear-gradient(135deg, #2a1a3a, #3a1a4a, #1a2040); }
.sl-poster-3 { background: linear-gradient(135deg, #3a2a1a, #4a3510, #2a1a00); }
.sl-poster-4 { background: linear-gradient(135deg, #1a2a3a, #10354a, #0a2540); }
.sl-poster-5 { background: linear-gradient(135deg, #3a1a2a, #4a1035, #301020); }
.sl-poster-6 { background: linear-gradient(135deg, #1a3a2a, #104a20, #0a3020); }
.sl-poster-7 { background: linear-gradient(135deg, #2a2a3a, #35354a, #202040); }
.sl-poster-8 { background: linear-gradient(135deg, #3a3a1a, #4a4510, #303000); }

/* --- Category pills --- */
.sl-filters { display: flex; gap: .6rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.sl-pill {
  background: var(--bg-surface); color: var(--text-muted); border: 1px solid var(--border);
  padding: .4rem 1rem; border-radius: 20px; font-size: .82rem; cursor: pointer;
  transition: all .2s; font-weight: 500;
}
.sl-pill:hover, .sl-pill.active { background: var(--accent-glow); border-color: var(--accent-dim); color: var(--accent); }

/* --- Title Detail Page --- */
.sl-detail-hero {
  padding: 0; position: relative; min-height: 80vh;
  display: flex; align-items: flex-end;
  margin-top: 64px; /* below fixed nav */
}
.sl-detail-bg {
  position: absolute; inset: 0; z-index: 0;
  background-size: cover; background-position: center 20%;
}
.sl-detail-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(0deg, var(--bg-dark) 5%, rgba(11,18,21,0.85) 40%, rgba(11,18,21,0.4) 100%);
}
.sl-detail-content {
  position: relative; z-index: 1; padding: 3rem 3rem 4rem;
  max-width: 720px;
}
.sl-detail-content h1 { font-size: 3rem; font-weight: 800; margin-bottom: .8rem; text-shadow: 0 2px 20px rgba(0,0,0,0.6); }
.sl-detail-tags { display: flex; gap: .6rem; margin-bottom: 1.2rem; flex-wrap: wrap; }
.sl-detail-tags span {
  background: rgba(255,255,255,0.12); padding: .35rem .8rem;
  border-radius: 4px; font-size: .82rem; color: var(--text-muted);
  border: 1px solid rgba(255,255,255,0.08);
}
.sl-detail-desc { color: var(--text-muted); font-size: 1rem; line-height: 1.7; margin-bottom: 1.5rem; }
.sl-play-btn {
  display: inline-flex; align-items: center; gap: .6rem;
  background: var(--accent); color: var(--bg-dark); font-weight: 700;
  padding: .8rem 2rem; border-radius: 8px; font-size: 1rem;
  border: none; cursor: pointer; transition: transform .2s, box-shadow .2s;
}
.sl-play-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(45,212,168,0.3); color: var(--bg-dark); }
.sl-secondary-btn {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(255,255,255,0.1); color: var(--text);
  padding: .8rem 1.5rem; border-radius: 8px; font-size: 1rem;
  border: 1px solid rgba(255,255,255,0.15); cursor: pointer;
  margin-left: .8rem; transition: background .2s;
}
.sl-secondary-btn:hover { background: rgba(255,255,255,0.15); color: var(--text); }

/* Video player page */
.sl-player-wrap {
  padding-top: 64px; background: #000; min-height: 100vh;
  display: flex; flex-direction: column;
}
.sl-video-container {
  width: 100%; aspect-ratio: 16/9; background: #000;
  max-height: 75vh;
}
.sl-video-container video, .sl-video-container iframe {
  width: 100%; height: 100%; border: none; display: block;
}
.sl-player-info {
  max-width: 900px; margin: 0 auto; padding: 2rem 2rem;
  background: var(--bg-dark);
}
.sl-player-info h1 { font-size: 1.8rem; margin-bottom: .4rem; }
.sl-player-info p { color: var(--text-muted); font-size: .95rem; }

/* --- Footer --- */
.sl-footer {
  border-top: 1px solid var(--border); padding: 3rem 2rem 2rem;
  margin-top: 4rem; color: var(--text-dim); font-size: .82rem;
}
.sl-footer-inner { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 2rem; }
.sl-footer-col h4 { color: var(--text-muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .6rem; }
.sl-footer-col a { display: block; color: var(--text-dim); margin-bottom: .35rem; font-size: .82rem; }
.sl-footer-col a:hover { color: var(--accent); }
.sl-footer-copy { text-align: center; padding-top: 2rem; border-top: 1px solid var(--border); margin-top: 2rem; font-size: .78rem; }

/* --- Legal pages --- */
.sl-legal { max-width: 800px; margin: 0 auto; padding: 7rem 2rem 4rem; }
.sl-legal h1 { font-size: 2rem; margin-bottom: .5rem; }
.sl-legal .sl-date { color: var(--text-muted); font-size: .85rem; margin-bottom: 2rem; }
.sl-legal h2 { font-size: 1.15rem; color: var(--accent); margin: 2rem 0 .6rem; }
.sl-legal p, .sl-legal li { color: var(--text-muted); font-size: .92rem; margin-bottom: .8rem; }
.sl-legal ul { padding-left: 1.4rem; }

/* --- About page --- */
.sl-about-hero { padding: 8rem 2rem 3rem; text-align: center; position: relative; overflow: hidden; }
.sl-about-hero::before {
  content: ''; position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(180deg, #0f1f1a, var(--bg-dark));
}
.sl-about-hero > * { position: relative; z-index: 1; }
.sl-about-hero h1 { font-size: 2.5rem; font-weight: 800; margin-bottom: .8rem; }
.sl-about-hero p { color: var(--text-muted); max-width: 600px; margin: 0 auto; font-size: 1.05rem; }
.sl-values { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; margin-top: 2rem; }
.sl-value-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 2rem; text-align: center;
}
.sl-value-icon { font-size: 2rem; margin-bottom: .8rem; }
.sl-value-card h3 { font-size: 1.05rem; margin-bottom: .5rem; }
.sl-value-card p { color: var(--text-muted); font-size: .88rem; }
.sl-team { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.2rem; margin-top: 2rem; }
.sl-member {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.5rem; text-align: center;
}
.sl-avatar {
  width: 80px; height: 80px; border-radius: 50%; margin: 0 auto .8rem;
  object-fit: cover;
}
.sl-member h4 { font-size: .95rem; }
.sl-member p { color: var(--text-muted); font-size: .8rem; }

/* --- Browse page --- */
.sl-browse-header { padding: 6rem 2rem 2rem; max-width: 1280px; margin: 0 auto; }
.sl-browse-header h1 { font-size: 2rem; font-weight: 700; margin-bottom: .5rem; }
.sl-browse-header p { color: var(--text-muted); }

/* --- Responsive --- */
@media (max-width: 768px) {
  .sl-hero h1 { font-size: 2.2rem; }
  .sl-hero { min-height: 70vh; }
  .sl-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .8rem; }
  .sl-row > .sl-card { flex: 0 0 140px; min-width: 140px; max-width: 140px; }
  .sl-nav-links { display: none; }
  .sl-nav-toggle { display: block; }
  .sl-nav-links.open {
    display: flex; flex-direction: column; position: absolute;
    top: 64px; left: 0; right: 0; background: var(--bg-nav);
    padding: 1rem 2rem; border-bottom: 1px solid var(--border);
  }
  .sl-footer-inner { flex-direction: column; }
  .sl-legal { padding: 6rem 1.2rem 3rem; }
  .sl-detail-content h1 { font-size: 2rem; }
}
