/* VRL Demo Site - Global Styles */

:root {
  --bg-dark: #0a0e1a;
  --bg-darker: #050709;
  --bg-card: #1a1f2e;
  --bg-hover: #252d3f;
  --accent: #4f8ef7;
  --accent-purple: #7c3aed;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --text-primary: #ffffff;
  --text-secondary: #b0b8d4;
  --border: #2a3245;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  letter-spacing: 0.3px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.5em;
}

h1 {
  font-size: 3.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1em;
  color: var(--text-secondary);
  font-size: 1rem;
}

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

a:hover {
  color: var(--accent-purple);
}

/* Layout */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background: var(--bg-darker);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  background-color: rgba(5, 7, 9, 0.8);
}

nav {
  padding: 1.5rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-purple) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
  align-items: center;
}

nav a {
  color: var(--text-secondary);
  font-size: 0.95rem;
  transition: color 0.2s;
}

nav a:hover,
nav a.active {
  color: var(--accent);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 0.375rem;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  text-align: center;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-purple);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(79, 142, 247, 0.3);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn-secondary:hover {
  background: var(--accent);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
  padding: 0.65rem 1.4rem;
}

.btn-outline:hover {
  background: var(--accent);
  color: #fff;
}

.btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 2rem;
  transition: all 0.3s;
}

.card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(79, 142, 247, 0.1);
  transform: translateY(-4px);
}

.card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.card-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-purple) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.card h3 {
  margin: 0;
}

.card p {
  margin-bottom: 0;
}

/* Sections */
section {
  padding: 4rem 0;
  border-bottom: 1px solid var(--border);
}

section:last-child {
  border-bottom: none;
}

section h2 {
  margin-bottom: 3rem;
}

/* Hero */
.hero {
  padding: 6rem 0;
  text-align: center;
}

.hero h1 {
  margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--accent);
  margin-bottom: 2rem;
  font-weight: 500;
}

.hero-description {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 3rem;
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 4rem;
}

/* Grid */
.grid {
  display: grid;
  gap: 2rem;
  margin-bottom: 3rem;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
}

thead {
  border-bottom: 2px solid var(--border);
}

th {
  text-align: left;
  padding: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

td {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

tbody tr:hover {
  background: var(--bg-card);
}

/* Badge */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-certified {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.badge-reviewed {
  background: rgba(245, 158, 11, 0.2);
  color: var(--warning);
}

.badge-experimental {
  background: rgba(107, 114, 128, 0.2);
  color: #9ca3af;
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text-primary);
}

input,
textarea,
select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.375rem;
  background: var(--bg-card);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 1rem;
  transition: border-color 0.2s;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(79, 142, 247, 0.1);
}

textarea {
  resize: vertical;
  min-height: 200px;
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.9rem;
}

/* Code */
code {
  background: var(--bg-card);
  padding: 0.2em 0.4em;
  border-radius: 0.25rem;
  color: var(--accent);
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.9em;
}

pre {
  background: var(--bg-darker);
  border: 1px solid var(--border);
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  margin: 1rem 0;
}

pre code {
  background: none;
  padding: 0;
  color: inherit;
}

/* Footer */
footer {
  background: var(--bg-darker);
  border-top: 1px solid var(--border);
  padding: 3rem 0 1rem;
  margin-top: 4rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  font-size: 0.95rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.footer-section ul {
  list-style: none;
}

.footer-section a {
  display: block;
  padding: 0.5rem 0;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-section a:hover {
  color: var(--accent);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Verifier Styles */
.verifier-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.input-area,
.output-area {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 1.5rem;
}

.output-area {
  display: none;
}

.output-area.active {
  display: block;
}

.result-step {
  padding: 0.75rem 0;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  border-bottom: 1px solid var(--border);
}

.result-step:last-child {
  border-bottom: none;
}

.result-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  margin-top: 0.25rem;
}

.result-step.pass .result-icon {
  color: var(--success);
}

.result-step.fail .result-icon {
  color: var(--error);
}

.result-step.loading .result-icon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.result-content h4 {
  margin-bottom: 0.25rem;
  font-size: 1rem;
}

.result-content p {
  margin-bottom: 0;
  font-size: 0.9rem;
}

.result-step.pass .result-content p {
  color: var(--text-secondary);
}

.result-step.fail .result-content p {
  color: var(--error);
}

/* Table Styles */
.circuit-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  overflow: hidden;
}

.circuit-table thead {
  background: var(--bg-darker);
}

.circuit-table th {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
}

.circuit-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
}

.circuit-table tbody tr:hover {
  background: var(--bg-hover);
}

.circuit-table .expandable-trigger {
  cursor: pointer;
  color: var(--accent);
  font-weight: 500;
  transition: color 0.2s;
}

.circuit-table .expandable-trigger:hover {
  color: var(--accent-purple);
}

/* Expandable Details */
.expandable-details {
  display: none;
  background: var(--bg-darker);
  padding: 2rem;
  border-top: 1px solid var(--border);
}

.expandable-details.active {
  display: block;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.detail-item h4 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}

.detail-item p {
  margin-bottom: 0;
}

.detail-schemas {
  margin-top: 1.5rem;
}

.schema-section {
  margin-bottom: 1.5rem;
}

.schema-section h5 {
  margin-bottom: 0.5rem;
  color: var(--accent);
}

/* Filters */
.filter-controls {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.filter-group select {
  width: 100%;
}

.search-input {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 0.375rem;
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 1rem;
}

.search-input::placeholder {
  color: var(--text-secondary);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem;
  color: var(--text-secondary);
}

.empty-state p {
  margin-bottom: 0;
}

/* Responsive */
@media (max-width: 768px) {
  h1 {
    font-size: 2.5rem;
  }

  h2 {
    font-size: 2rem;
  }

  nav ul {
    gap: 1rem;
    font-size: 0.9rem;
  }

  .hero {
    padding: 3rem 0;
  }

  .verifier-wrapper {
    grid-template-columns: 1fr;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    width: 100%;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  table {
    font-size: 0.9rem;
  }

  th,
  td {
    padding: 0.75rem;
  }

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

  section {
    padding: 2.5rem 0;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  nav {
    flex-direction: column;
    gap: 1rem;
  }

  nav ul {
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
  }

  nav a {
    display: block;
  }

  .btn {
    width: 100%;
  }

  .hero-buttons {
    gap: 0.5rem;
  }

  section {
    padding: 2rem 0;
  }
}
