/* Frontend Night — Design System */
:root {
  --bg: #0B0F14;
  --bg-elevated: #11161D;
  --bg-card: #161D26;
  --text: #F5F7FA;
  --text-muted: #9BA7B4;
  --accent: #00E5A0;
  --accent-dim: rgba(0, 229, 160, 0.15);
  --violet: #7C4DFF;
  --violet-dim: rgba(124, 77, 255, 0.15);
  --border: #232B35;
  --border-light: #2E3946;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-glow: 0 0 40px rgba(0, 229, 160, 0.25);
  --shadow-card: 0 8px 30px rgba(0, 0, 0, 0.45);
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;
  --max-width: 1120px;
}

/* Fluid type scale */
html {
  font-size: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 var(--space-4);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
}

h3 {
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  margin-bottom: var(--space-3);
}

p {
  margin: 0 0 var(--space-4);
  color: var(--text-muted);
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover, a:focus-visible {
  color: #4dffc4;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

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

/* Section spacing */
.section {
  padding: var(--space-9) 0;
}

.section-alt {
  background: var(--bg-elevated);
  position: relative;
}

.section-alt::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124, 77, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 77, 255, 0.04) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: var(--space-3);
  display: block;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 2px solid transparent;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: #0B0F14;
  box-shadow: 0 0 25px rgba(0, 229, 160, 0.35);
}

.btn-primary:hover, .btn-primary:focus-visible {
  background: #4dffc4;
  color: #0B0F14;
  box-shadow: 0 0 40px rgba(0, 229, 160, 0.55);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  border-color: var(--border-light);
  color: var(--text);
}

.btn-secondary:hover, .btn-secondary:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-dim);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 15, 20, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-3) var(--space-5);
  max-width: var(--max-width);
  margin: 0 auto;
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
}

.logo-icon {
  width: 28px;
  height: 28px;
  color: var(--accent);
}

.nav-list {
  display: flex;
  gap: var(--space-5);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-list a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-list a:hover, .nav-list a:focus-visible {
  color: var(--accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: var(--space-2);
  cursor: pointer;
}

.nav-toggle svg {
  width: 22px;
  height: 22px;
  display: block;
}

/* Hero */
.hero {
  min-height: 88vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: var(--space-8) 0;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 229, 160, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 229, 160, 0.05) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
}

.hero-glow--green {
  width: 500px;
  height: 500px;
  background: rgba(0, 229, 160, 0.12);
  top: -150px;
  right: -100px;
}

.hero-glow--violet {
  width: 400px;
  height: 400px;
  background: rgba(124, 77, 255, 0.12);
  bottom: -100px;
  left: -120px;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--accent-dim);
  border: 1px solid rgba(0, 229, 160, 0.3);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: var(--space-2) var(--space-4);
  border-radius: 100px;
  margin-bottom: var(--space-5);
}

.hero-badge .dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.7); }
}

.hero-title {
  margin-bottom: var(--space-4);
}

.hero-title .accent {
  color: var(--accent);
}

.hero-title .violet {
  color: var(--violet);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.hero-meta-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.hero-meta-item svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.card:hover {
  border-color: var(--border-light);
  box-shadow: var(--shadow-card);
}

/* Schedule */
.schedule-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--border);
  position: relative;
}

.schedule-item {
  position: relative;
  padding: 0 0 var(--space-6) var(--space-6);
}

.schedule-item:last-child {
  padding-bottom: 0;
}

.schedule-item::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 6px;
  width: 12px;
  height: 12px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(0, 229, 160, 0.6);
}

.schedule-time {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  margin-bottom: var(--space-2);
  display: block;
}

.schedule-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: var(--space-1);
}

.schedule-speaker {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.schedule-speaker strong {
  color: var(--violet);
  font-weight: 600;
}

/* Venue */
.venue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
  align-items: start;
}

.venue-map {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  position: relative;
  overflow: hidden;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.venue-map::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 229, 160, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 229, 160, 0.06) 1px, transparent 1px);
  background-size: 24px 24px;
}

.venue-map-pin {
  position: relative;
  z-index: 1;
  width: 60px;
  height: 60px;
  color: var(--accent);
  filter: drop-shadow(0 0 18px rgba(0, 229, 160, 0.5));
}

.venue-map-label {
  position: absolute;
  bottom: var(--space-4);
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(11, 15, 20, 0.8);
  padding: var(--space-1) var(--space-3);
  border-radius: 100px;
  white-space: nowrap;
}

.venue-address {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: var(--space-3);
}

.venue-directions {
  color: var(--text-muted);
}

.direction-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.direction-list li {
  display: flex;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  color: var(--text-muted);
  font-size: 0.9rem;
}

.direction-list svg {
  width: 18px;
  height: 18px;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 3px;
}

/* Sponsors */
.sponsors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space-4);
}

.sponsor-tile {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-5);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  transition: all 0.3s ease;
  filter: brightness(1.2);
}

.sponsor-tile:hover, .sponsor-tile:focus-visible {
  filter: brightness(1.35);
  border-color: var(--accent);
  box-shadow: 0 0 20px rgba(0, 229, 160, 0.2);
  transform: translateY(-3px);
}

.sponsor-tile svg {
  width: 100%;
  max-width: 165px;
  height: auto;
}

.sponsor-logo {
  height: 60px;
  width: auto;
  color: var(--accent);
  fill: currentColor;
}

/* RSVP form */
.rsvp-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
  max-width: 640px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.rsvp-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--violet));
}

.form-group {
  margin-bottom: var(--space-5);
}

.form-group label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: var(--space-2);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 229, 160, 0.15);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}

.form-error {
  color: #ff6b6b;
  font-size: 0.8rem;
  margin-top: var(--space-1);
  display: none;
}

.form-group.has-error input,
.form-group.has-error select,
.form-group.has-error textarea {
  border-color: #ff6b6b;
}

.form-group.has-error .form-error {
  display: block;
}

.form-success {
  display: none;
  background: var(--accent-dim);
  border: 1px solid rgba(0, 229, 160, 0.4);
  border-radius: var(--radius-sm);
  padding: var(--space-4);
  color: var(--accent);
  font-weight: 500;
  margin-bottom: var(--space-4);
  text-align: center;
}

.form-success.visible {
  display: block;
  animation: fade-in 0.4s ease;
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Footer */
.site-footer {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  padding: var(--space-7) 0;
  margin-top: var(--space-8);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  justify-content: space-between;
  align-items: center;
}

.footer-info {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.footer-social {
  display: flex;
  gap: var(--space-4);
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-social a {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 0.25s ease;
}

.footer-social a:hover, .footer-social a:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-dim);
}

.footer-social svg {
  width: 18px;
  height: 18px;
}

/* Reveal on scroll — only when JS is active */
html.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

html.js .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  html.js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .btn {
    transition: none;
  }
  .hero-badge .dot {
    animation: none;
  }
}

/* Responsive */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-list {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(11, 15, 20, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    padding: var(--space-4) var(--space-5);
    gap: var(--space-3);
    border-bottom: 1px solid var(--border);
  }

  .nav-list.open {
    display: flex;
  }

  .header-inner {
    position: relative;
  }

  .hero {
    min-height: auto;
    padding: var(--space-7) 0;
  }

  .venue-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .rsvp-card {
    padding: var(--space-5);
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .hero-meta {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }
  .section {
    padding: var(--space-7) 0;
  }
}