:root {
  --bg-primary: #0a0a0a;
  --bg-elevated: #000000;
  --text-primary: #ffffff;
  --text-muted: #9595a7;
  --text-inversed: #0a0a0a;
  --text-muted-inversed: #242424;
  --accent-cyan: #00d9ff;
  --accent-green-dark: #008d1f;
  --accent-green: #00ff9f;
  --border: #444444;
  --glow-cyan: rgba(0, 217, 255, 0.3);
  --glow-green: rgba(0, 255, 159, 0.3);
}

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

::selection {
  background-color: var(--accent-green);
  color: var(--text-inversed)
}

body {
  font-family: 'IBM Plex Mono', 'Consolas', 'Monaco', monospace;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 15px;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 217, 255, 0.03) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
  z-index: 0;
}

/* Container */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

/* Header */
header {
  padding: 60px 0 40px;
  border-bottom: 2px solid var(--border);
  position: relative;
}

header::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 50px;
  height: 2px;
  background: var(--accent-cyan);
  animation: scanline 60s linear infinite;
}

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

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 24px;
}

/* Error Toast Styles */
.error-toast {
  position: fixed;
  top: 20px;
  left: 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--accent-cyan);
  padding: 16px 24px;
  font-size: 14px;
  color: var(--text-primary);
  box-shadow: 0 0 10px var(--accent-cyan);
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 1000;
  max-width: 300px;
  display: none;
}

.error-toast.visible {
  opacity: 1;
  transform: translateY(0);
  display: block;
}

.error-toast p {
  margin: 0;
  color: var(--text-muted);
}

h1 {
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.5px;
  color: var(--text-primary);
  margin-bottom: 8px;
  text-shadow: 0 0 20px var(--glow-cyan);
}

.prompt {
  color: var(--accent-green);
  font-size: 32px;
  margin-right: 8px;
}

.tagline {
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 8px;
}

.nav-container {
  position: fixed;
  left: 0;
  top: 40%;
  transform: translateY(-50%);
  z-index: 1000;
  width: 150px;
  padding: 20px 0;
}

nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 5px;
  border-radius: 0 12px 12px 0;
  backdrop-filter: blur(2px);
  border: 1px solid var(--border);
  border-left: none;
}

nav a {
  color: var(--accent-cyan);
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
  padding: 10px 20px;
  border-radius: 0 8px 8px 0;
  display: block;
}

nav a::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 0;
  background: var(--accent-green);
  transition: all 0.3s ease;
  border-radius: 0 3px 3px 0;
}

nav a:hover {
  color: var(--accent-green);
  text-shadow: 0 0 8px var(--glow-green);
  transform: translateX(5px);
  background: rgba(0, 255, 136, 0.1);
}

nav a:hover::before {
  height: 100%;
}

nav a.active {
  color: var(--accent-green);
  background: rgba(0, 255, 136, 0.15);
  box-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
}

nav a.active::before {
  height: 100%;
}

/* Смещение контента для навигации */
.main-content {
  margin-left: 240px;
  padding: 20px;
}

/* Main Content */
main {
  padding: 80px 0;
}

section {
  margin-bottom: 80px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease-out;
}

section.visible {
  opacity: 1;
  transform: translateY(0);
}

h2 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  display: inline-block;
  position: relative;
}

.section-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 26px;
}

p {
  color: var(--text-muted);
  margin-bottom: 8px;
}

/* Accordion Common Styles */
.accordion-item {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: 
    border-color 0.3s ease, 
    box-shadow 0.3s ease, 
    background-color 0.3s ease, 
    color 0.3s ease;
}

.accordion-item:hover {
  border-color: var(--accent-green);
  box-shadow: 0 0 10px var(--glow-green);
  background-color: var(--accent-green-dark);
  color: var(--text-inversed);
}

.accordion-header {
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.accordion-header svg {
  flex-shrink: 0;
  transition: transform 0.6s ease;
}

.accordion-header .icon-open {
  display: none;
}

.accordion-item.active .accordion-header .icon-closed {
  display: none;
}

.accordion-item.active .accordion-header .icon-open {
  display: block;
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-6px);
  transition:
    max-height 0.5s ease,
    opacity 0.8s ease,
    transform 0.4s ease;
}

.accordion-item.active {
  background-color: var(--accent-green-dark);
  color: var(--text-inversed);
  box-shadow: 0 0 20px var(--glow-green);
  border-color: var(--accent-green);
}

.accordion-item.active .accordion-content {
  font-size: 18px;
  font-weight: bold;
  opacity: 1;
  transform: translateY(0);
  background-color: var(--accent-green-dark);
}

.accordion-content p {
  padding: 12px 24px 16px;
  font-size: 13px;
  color: var(--text-inversed);
  margin: 0;
}

/* Services / Bots List */
.services-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 32px;
  max-width: 100%;
}

/* Links Section */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.link-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 20px;
  text-decoration: none;
  color: var(--text-primary);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.link-card:hover {
  border-color: var(--accent-green-dark);
  background-color: var(--accent-green-dark);
  color: var(--text-inversed);
  padding-right: 48px;
  box-shadow: 0 0 20px var(--glow-cyan);
}

.link-icon {
  font-size: 24px;
  line-height: 1;
}

.link-content h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
}

.link-content p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
  transition: color 0.3s ease
}

.link-card:hover .link-content p {
  color: var(--text-inversed);
}

/* Demo Bots badge */
.demo-badge {
  position: absolute;
  top: 8px;
  right: 12px;
  font-size: 10px;
  color: var(--accent-cyan);
  paint-order: stroke fill;
  -webkit-text-stroke: #000000 3px;
  letter-spacing: 1px;
  text-transform: uppercase;
  opacity: 0.8;
}

/* Pricing Section */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 32px;
}

.pricing-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: all 0.5s ease;
  position: relative;
}

.pricing-card:hover {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 20px var(--glow-cyan);
}

.pricing-card.featured {
  border-color: var(--accent-green);
  box-shadow: 0 0 16px var(--glow-green);
}

.pricing-card.featured::before {
  content: '// recommended';
  position: absolute;
  top: -1px;
  right: 16px;
  background: var(--accent-green);
  color: var(--text-inversed);
  font-size: 11px;
  font-weight: 600;
  padding: 2px 10px;
  font-family: 'IBM Plex Mono', monospace;
}

.pricing-tier {
  font-size: 11px;
  color: var(--accent-cyan);
  letter-spacing: 3px;
  text-transform: uppercase;
}

.pricing-price span {
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
}

.pricing-divider {
  height: 1px;
  background: var(--border);
}

.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.pricing-features li {
  font-size: 13px;
  color: var(--text-muted);
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.5;
}

.pricing-features li::before {
  content: '>';
  color: var(--accent-green);
  flex-shrink: 0;
  font-weight: 600;
}

.pricing-btn {
  display: block;
  text-align: center;
  padding: 10px 16px;
  border: 1px solid var(--border);
  color: var(--text-primary);
  text-decoration: none;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  background: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 4px;
}

.pricing-btn:hover {
  background: var(--accent-green-dark);
  border-color: var(--accent-green);
  color: var(--text-inversed);
  box-shadow: 0 0 10px var(--glow-green);
}

.pricing-card.featured .pricing-btn {
  background: var(--accent-green-dark);
  border-color: var(--accent-green);
  color: var(--text-inversed);
}

.pricing-card.featured .pricing-btn:hover {
  box-shadow: 0 0 20px var(--glow-green);
}

.pricing-note {
  font-size: 14px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 16px;
}

.pricing-note span {
  color: var(--text-muted);
}

/* Contact Form Styles */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 24px;
  margin-bottom: 24px;
  max-width: 100%;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-group label {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.form-group input,
.form-group textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 12px 16px;
  font-family: inherit;
  font-size: 13px;
  color: var(--text-primary);
  transition: all 0.3s ease;
  resize: none;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent-green);
  box-shadow: 0 0 10px var(--glow-green);
  outline: none;
}

.form-group input {
  height: 40px;
}

.form-group textarea {
  height: 120px;
}

.submit-button {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 12px 24px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  align-self: center;
}

.submit-button:hover {
  background: var(--accent-green-dark);
  border-color: var(--accent-green);
  color: var(--text-inversed);
  box-shadow: 0 0 10px var(--glow-green);
}

.submit-wrapper {
  position: relative;
  display: flex;
  align-self: center;
}

.loader {
  display: none;
  border: 4px solid var(--border);
  border-top: 4px solid var(--accent-green-dark);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
  margin-left: 16px;
  margin-top: 8px;
  box-shadow: 0 0 10px var(--glow-green);
}

/* Success Message Styles */
#successMessage {
  display: none;
  color: var(--accent-green);
  font-size: 14px;
  font-weight: 600;
  margin-top: 24px;
  padding: 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--accent-green);
  box-shadow: 0 0 10px var(--glow-green);
  align-items: center;
  gap: 12px;
}

#successMessage svg {
  width: 24px;
  height: 24px;
  stroke: var(--accent-green);
}

/* Language Selector */
.language-selector {
  position: absolute;
  top: 100px;
  right: 0px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.lang-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 24px;
  font-weight: 600;
  padding: 4px 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  min-width: 32px;
}

.lang-btn:hover {
  border-color: var(--accent-green);
  color: var(--accent-green);
}

.lang-btn.active {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  color: var(--text-inversed);
  box-shadow: 0 0 10px var(--glow-cyan);
}

.lang-btn.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-cyan);
}

/* Comparison Terminal Styles */
.comparison-terminal {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 32px;
}

.terminal-block {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: all 0.4s ease;
}

.terminal-header {
  background: rgba(0, 0, 0, 0.3);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
}

.terminal-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.terminal-content {
  padding: 16px;
}

.pros-cons-section {
  margin-bottom: 20px;
}

.pros-cons-title {
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 4px 8px;
  margin-bottom: 8px;
  display: inline-block;
}

.pros-cons-title.good {
  background: rgba(0, 255, 159, 0.1);
  color: var(--accent-green);
}

.pros-cons-title.bad {
  background: rgba(255, 77, 77, 0.1);
  color: #ff4d4d;
}

.terminal-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.terminal-list li {
  font-size: 13px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.4;
  color: var(--text-muted);
}

.terminal-list li::before {
  font-size: 12px;
  margin-top: 1px;
  font-weight: bold;
}

.pros-cons-section .good + .terminal-list li::before {
  content: '+';
  font-size: 14px;
  color: var(--accent-green);
}

.pros-cons-section .bad + .terminal-list li::before {
  content: '-';
  font-size: 14px;
  color: #ff4d4d;
}

/* Who Needs Custom Bots Section */
.who-needs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 32px;
}

.who-needs-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 24px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.who-needs-card:hover {
  border-color: var(--accent-green);
  box-shadow: 0 0 15px var(--glow-green);
  transform: scale(1.05)
}

.who-needs-icon {
  margin-bottom: 16px;
  color: var(--text-primary);
  transition: all 0.3s ease;
}

.who-needs-card:hover .who-needs-icon{
  color: var(--accent-cyan);
}


.who-needs-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.who-needs-card p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Footer */
footer {
  padding: 40px 0;
  border-top: 2px solid var(--border);
  margin-top: 80px;
  text-align: center;
}

footer p {
  color: var(--text-muted);
  font-size: 13px;
  margin: 0;
}

.cursor-blink {
  display: inline-block;
  width: 8px;
  height: 18px;
  background: var(--accent-cyan);
  margin-left: 4px;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Адаптивность */
@media (max-width: 1248px) {
  .nav-container {
    position: relative;
    transform: none;
    width: 100%;
    padding: 0;
  }

  nav ul {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    box-shadow: none;
    backdrop-filter: none;
    border: none;
  }

  nav a {
    padding: 5px 5px;
    font-size: 16px;
    text-align: center;
  }

  nav li {
  flex: 1 1 120px; /* минимум 120px — при нехватке места переносится */
  }
}

/* Responsive */
@media (max-width: 768px) {
  h1 { font-size: 26px; }
  h2 { font-size: 20px; }

  .comparison-terminal {
    grid-template-columns: 1fr;
  }

  .header-content {
    flex-direction: column;
  }

  .language-selector {
    position: static;
    margin-top: 30px;
    margin-left: 0;
  }

  nav ul {
    gap: 24px;
  }

  nav a {
    font-size: 16px;
  }

  main {
    padding: 60px 0;
  }

  section {
    margin-bottom: 60px;
  }

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