:root {
  --bg: #0f1117;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-border: rgba(255, 255, 255, 0.08);
  --primary: #00ff88;
  --primary-dim: rgba(0, 255, 136, 0.15);
  --secondary: #ff6b2b;
  --accent: #4d9fff;
  --text: #e8ecf0;
  --text-muted: #8b949e;
  --font-sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --container-width: 1200px;
  --radius-lg: 16px;
  --radius-md: 8px;
  --radius-pill: 999px;
  --transition-speed: 0.3s;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 32px 32px;
  background-position: center top;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-speed);
}

a:hover {
  color: var(--primary);
}

img {
  max-width: 100%;
  display: block;
  object-fit: cover;
}

ul {
  list-style: none;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 40px;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 80px;
  }
}

/* Typography */
h1, h2, h3 {
  font-family: var(--font-mono);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 {
  font-size: 36px;
  margin-bottom: 16px;
  color: var(--primary);
  text-shadow: 0 0 20px rgba(0, 255, 136, 0.4);
}

@media (min-width: 768px) {
  h1 { font-size: 52px; }
}

@media (min-width: 1024px) {
  h1 { font-size: 64px; }
}

h2 {
  font-size: 28px;
  margin-bottom: 8px;
}

@media (min-width: 768px) {
  h2 { font-size: 32px; }
}

h3 {
  font-size: 18px;
  margin-bottom: 8px;
}

.subtitle {
  font-family: var(--font-mono);
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 32px;
  display: block;
}

.section-header {
  margin-bottom: 32px;
}

.section-divider {
  height: 1px;
  background-color: var(--primary);
  opacity: 0.1;
  margin: 48px 0;
}

@media (min-width: 768px) {
  .section-divider { margin: 64px 0; }
}

@media (min-width: 1024px) {
  .section-divider { margin: 96px 0; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  border: none;
  transition: all var(--transition-speed);
  font-family: var(--font-mono);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #00cc6a);
  color: var(--bg);
  box-shadow: 0 4px 15px rgba(0, 255, 136, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 255, 136, 0.5);
  color: var(--bg);
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 255, 136, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(0, 255, 136, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 255, 136, 0); }
}

.btn-text {
  background: none;
  color: var(--text);
  padding: 0;
  position: relative;
}

.btn-text::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--primary);
  transition: width var(--transition-speed);
}

.btn-text:hover::after {
  width: 100%;
}

/* Nav */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  background: rgba(15, 17, 23, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 255, 136, 0.1);
  z-index: 100;
  transition: height var(--transition-speed);
}

.nav.scrolled {
  height: 56px;
}

.nav-inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 16px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .nav-inner { padding: 0 40px; }
}

@media (min-width: 1024px) {
  .nav-inner { padding: 0 80px; }
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 18px;
}

.brand img {
  height: 32px;
  width: auto;
}

.nav-links {
  display: none;
}

@media (min-width: 1024px) {
  .nav-links {
    display: flex;
    gap: 24px;
    font-size: 14px;
    color: var(--text-muted);
  }
  .nav-links a:hover {
    color: var(--primary);
  }
}

.nav-cta {
  display: none;
}

@media (min-width: 768px) {
  .nav-cta {
    display: inline-flex;
  }
}

/* Hero */
.hero {
  padding: 120px 0 48px;
  min-height: 640px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

@media (min-width: 768px) {
  .hero {
    padding-top: 160px;
    height: 85vh;
    min-height: 700px;
  }
}

.hero-grid {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

@media (min-width: 1024px) {
  .hero-grid {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.hero-content {
  flex: 1;
}

@media (min-width: 1024px) {
  .hero-content {
    flex: 0 0 55%;
    padding-right: 40px;
  }
}

.hero-stats {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 32px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.hero-stats span.highlight {
  color: var(--primary);
  font-weight: bold;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
}

@media (min-width: 768px) {
  .hero-actions {
    flex-direction: row;
    align-items: center;
    gap: 24px;
  }
}

.hero-card {
  flex: 1;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

@media (min-width: 1024px) {
  .hero-card {
    flex: 0 0 45%;
  }
}

.hero-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  animation: scanline 3s linear infinite;
}

@keyframes scanline {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.card-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--secondary);
  background: rgba(255, 107, 43, 0.1);
  padding: 4px 8px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
}

.card-title {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 16px;
  line-height: 1.4;
}

.card-timer {
  font-family: var(--font-mono);
  font-size: 24px;
  color: var(--secondary);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-timer span {
  font-size: 14px;
  color: var(--text-muted);
}

/* Floating Countdown Bar */
.countdown-bar {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-md);
  padding: 12px 24px;
  text-align: center;
  font-family: var(--font-mono);
  margin-top: 48px;
}

.countdown-bar span {
  color: var(--secondary);
  font-weight: bold;
}

/* Section Layouts */
section {
  padding: 48px 0;
}

@media (min-width: 768px) {
  section { padding: 64px 0; }
}

@media (min-width: 1024px) {
  section { padding: 96px 0; }
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

/* Daily Topic */
.topic-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1024px) {
  .topic-grid {
    flex-direction: row;
  }
}

.topic-main {
  flex: 1;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 32px;
}

@media (min-width: 1024px) {
  .topic-main {
    flex: 0 0 60%;
  }
}

.topic-sidebar {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (min-width: 1024px) {
  .topic-sidebar {
    flex: 0 0 40%;
  }
}

.track-tab {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-speed);
}

.track-tab:hover, .track-tab.active {
  border-color: var(--primary);
  background: var(--primary-dim);
}

.track-tab .name {
  font-weight: bold;
  font-family: var(--font-mono);
}

.track-tab .count {
  font-size: 12px;
  color: var(--text-muted);
}

/* Video Grid */
.filter-bar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.filter-tag {
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-speed);
}

.filter-tag.active, .filter-tag:hover {
  background: var(--primary);
  color: var(--bg);
  border-color: var(--primary);
}

.video-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .video-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.media-card {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--transition-speed);
}

.media-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 255, 136, 0.3);
}

.media-img-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.media-img-wrap img {
  width: 100%;
  height: 100%;
  transition: transform var(--transition-speed);
}

.media-card:hover .media-img-wrap img {
  transform: scale(1.05);
}

.media-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(0, 0, 0, 0.7);
  color: var(--primary);
  font-size: 12px;
  padding: 2px 8px;
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  border: 1px solid rgba(0, 255, 136, 0.3);
}

.media-info {
  padding: 16px;
}

.media-title {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.media-meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.media-meta .score {
  color: var(--secondary);
  font-weight: bold;
}

/* Arena / Showcase */
.arena-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .arena-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .arena-grid {
    grid-template-columns: repeat(6, 1fr);
  }
  .arena-item-wide {
    grid-column: span 3;
  }
  .arena-item-tall {
    grid-column: span 2;
    aspect-ratio: 9 / 16;
  }
}

.arena-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--panel-border);
}

.arena-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-speed);
}

.arena-card:hover img {
  transform: scale(1.03);
}

.arena-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 16px 12px;
  background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
}

.arena-title {
  font-weight: bold;
  font-size: 14px;
  margin-bottom: 4px;
}

.arena-author {
  font-size: 12px;
  color: var(--text-muted);
}

/* Leaderboard */
.leaderboard-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .leaderboard-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.lb-column {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.lb-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--panel-border);
}

.lb-title {
  font-family: var(--font-mono);
  font-weight: bold;
  color: var(--primary);
}

.lb-time {
  font-size: 12px;
  color: var(--secondary);
}

.lb-list li {
  display: flex;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px dashed rgba(255,255,255,0.1);
}

.lb-list li:last-child {
  border-bottom: none;
}

.lb-rank {
  font-family: var(--font-mono);
  font-weight: bold;
  width: 24px;
  color: var(--text-muted);
}

.lb-list li:nth-child(1) .lb-rank { color: var(--secondary); }
.lb-list li:nth-child(2) .lb-rank { color: var(--primary); }
.lb-list li:nth-child(3) .lb-rank { color: var(--accent); }

.lb-info {
  flex: 1;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lb-score {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--primary);
}

/* Inspiration */
.inspiration-scroll {
  display: flex;
  overflow-x: auto;
  gap: 24px;
  padding-bottom: 16px;
  scrollbar-width: none;
}

.inspiration-scroll::-webkit-scrollbar {
  display: none;
}

.insp-card {
  flex: 0 0 280px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  aspect-ratio: 4 / 3;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--transition-speed);
}

.insp-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
}

.insp-icon {
  color: var(--accent);
  font-size: 24px;
  margin-bottom: 12px;
  font-family: var(--font-mono);
}

.insp-title {
  font-weight: bold;
  font-size: 16px;
  margin-bottom: 8px;
}

.insp-link {
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  align-self: flex-start;
}

/* Critique */
.critique-layout {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1024px) {
  .critique-layout {
    flex-direction: row;
  }
}

.critique-profile {
  flex: 1;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

@media (min-width: 1024px) {
  .critique-profile { flex: 0 0 45%; }
}

.critique-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin-bottom: 16px;
  border: 2px solid var(--primary);
  object-fit: cover;
}

.critique-name {
  font-weight: bold;
  font-family: var(--font-mono);
  margin-bottom: 4px;
}

.critique-role {
  font-size: 12px;
  color: var(--text-muted);
}

.critique-list {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.critique-item {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-md);
  padding: 20px;
}

.critique-target {
  font-weight: bold;
  margin-bottom: 8px;
}

.critique-text {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.critique-tag {
  font-size: 12px;
  color: var(--accent);
  font-family: var(--font-mono);
}

/* Tools */
.tools-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .tools-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.tool-card {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: all var(--transition-speed);
}

.tool-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--primary);
}

.tool-icon {
  font-size: 32px;
  margin-bottom: 16px;
  color: var(--primary);
}

/* Newcomer */
.newcomer-layout {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1024px) {
  .newcomer-layout {
    flex-direction: row;
  }
}

.newcomer-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.newcomer-perks {
  margin-top: 24px;
}

.newcomer-perks li {
  display: flex;
  margin-bottom: 12px;
  font-size: 14px;
}

.newcomer-perks li::before {
  content: '✓';
  color: var(--primary);
  margin-right: 8px;
  font-weight: bold;
}

.newcomer-preview {
  flex: 1;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 16px;
  position: relative;
}

.preview-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
}

.preview-img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255,255,255,0.1);
}

/* Community */
.community-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .community-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .community-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.community-card {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.community-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.community-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #333;
  object-fit: cover;
}

.community-name {
  font-size: 14px;
  font-weight: bold;
}

.community-time {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: auto;
  font-family: var(--font-mono);
}

.community-text {
  font-size: 14px;
  margin-bottom: 16px;
}

.community-footer {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* Footer */
footer {
  border-top: 1px solid rgba(0, 255, 136, 0.1);
  padding: 48px 0 24px;
  background-color: #0b0c11;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.footer-brand img {
  height: 32px;
  margin-bottom: 16px;
}

.footer-brand p {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-links h4 {
  font-family: var(--font-mono);
  font-size: 14px;
  margin-bottom: 16px;
  color: var(--text);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  font-size: 14px;
  color: var(--text-muted);
}

.footer-bottom {
  border-top: 1px solid var(--panel-border);
  padding-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-bottom a {
  color: var(--text-muted);
}

.footer-bottom a:hover {
  color: var(--primary);
}

.about-details {
  margin-top: 24px;
  font-size: 12px;
  color: var(--text-muted);
}
.about-details summary {
  cursor: pointer;
  outline: none;
  font-family: var(--font-mono);
}
.about-details summary::-webkit-details-marker {
  display: none;
}
.about-content {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.about-content a {
  color: var(--text-muted);
}