/* UNA v2.4 — Wireframe brain, rays from neurons, i18n all pages */

:root {
  --bg-dark: #0a0e17;
  --bg-card: rgba(12, 20, 35, 0.85);
  /* Кнопки: фон в 2 раза прозрачнее карточки (card/refund), та же рамка и анимация */
  --bg-btn: rgba(12, 20, 35, 0.42);
  --accent: #00e5ff;
  --accent-dim: #00a8cc;
  --neural: #7c4dff;
  --text: #e8ecf4;
  --text-muted: #8b9bb5;
  --border: rgba(0, 229, 255, 0.2);
  --glow: 0 0 20px rgba(0, 229, 255, 0.3);
  --font-sans: 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-mono: 'Consolas', 'Monaco', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* LLC legal line in footer (data-i18n / EIN) */
.legal-footer-intl {
  display: block;
  margin: 0 0 0.75rem;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-dark);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

#bg,
#brainCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  display: block;
  pointer-events: none;
}

.wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 10px 20px;
  background: rgba(10, 14, 23, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  overflow: visible;
  min-height: 48px;
}

.site-header .wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 16px;
  min-height: 0;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.logo:hover {
  color: #fff;
  text-shadow: var(--glow);
}

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  flex: 1;
  justify-content: flex-end;
  min-width: 0;
}

.nav a {
  color: var(--text-muted);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.9rem;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s;
}

.nav a:hover {
  color: var(--accent);
  background: rgba(0, 229, 255, 0.08);
}

.lang-switcher-wrap {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding-left: 12px;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}
.lang-select {
  padding: 6px 8px;
  min-width: 52px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  appearance: auto;
}
.lang-select:hover { color: var(--accent); border-color: rgba(0, 229, 255, 0.4); }
.lang-select:focus { outline: none; border-color: var(--accent); color: var(--accent); }

@media (max-width: 900px) {
  .site-header .wrapper { flex-wrap: wrap; }
  .nav { flex-wrap: wrap; justify-content: flex-end; }
}

/* Единый стиль кнопок: как card-link, фон в 2 раза прозрачнее карточки, та же рамка и анимация */
.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  border: 1px solid var(--border);
  cursor: pointer;
  font-size: 1rem;
  background: var(--bg-btn);
  color: var(--text);
}

.btn:hover {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

.btn:focus,
.btn:active {
  outline: 2px solid rgba(0, 200, 255, 0.55);
  outline-offset: 2px;
  border-radius: 12px;
  border-color: var(--accent);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.25);
}

.btn-primary {
  background: var(--bg-btn);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-primary:hover {
  border-color: var(--accent);
  opacity: 0.95;
  box-shadow: var(--glow);
}

.btn-outline {
  background: var(--bg-btn);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.875rem;
}

/* Кнопка «Войти через Google»: контейнер для виджета Google и fallback-ссылки */
#google-signin-wrap,
#google-signin-wrap-reg {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-bottom: 8px;
  gap: 8px;
}

#google-signin-wrap #google-button-container,
#google-signin-wrap-reg #google-button-container-reg {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-width: 240px;
  min-height: 44px;
  visibility: visible;
  overflow: visible;
}

#google-signin-wrap #google-button-container > div,
#google-signin-wrap-reg #google-button-container-reg > div {
  margin: 0 auto;
}

#google-signin-wrap #login-google-link,
#google-signin-wrap-reg #register-google-link {
  display: inline-block;
  text-align: center;
  box-sizing: border-box;
  margin-top: 8px;
}

/* Hero */
.hero {
  padding: 140px 24px 80px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #fff, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero .tagline {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 32px;
}

.hero .buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Sections */
.section {
  padding: 64px 24px;
}

.section h2 {
  font-size: 2rem;
  margin-bottom: 24px;
  color: var(--text);
}

.section p {
  color: var(--text-muted);
  max-width: 720px;
  margin-bottom: 16px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.card:hover {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

.card h3 {
  color: var(--accent);
  margin-bottom: 12px;
  font-size: 1.2rem;
}

.card p {
  margin-bottom: 0;
  font-size: 0.95rem;
}

a.card-link {
  color: inherit;
  text-decoration: none !important;
  display: block;
  outline: none;
}

a.card-link:hover {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

a.card-link:focus,
a.card-link:active {
  text-decoration: none !important;
  outline: 2px solid rgba(0, 200, 255, 0.55);
  outline-offset: 2px;
  border-radius: 12px;
  border-color: var(--accent);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.25);
}

/* Footer */
.site-footer {
  padding: 48px 24px 24px;
  border-top: 1px solid var(--border);
  margin-top: 48px;
}

.site-footer .wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent);
}

.copyright {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Page layout (inner pages) */
.page-header {
  padding: 120px 24px 40px;
  text-align: center;
}

.page-header h1 {
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.page-content {
  padding: 24px 24px 64px;
  max-width: 800px;
  margin: 0 auto;
}

.page-content h2 {
  font-size: 1.4rem;
  margin: 32px 0 12px;
  color: var(--accent);
}

.page-content p, .page-content li {
  color: var(--text-muted);
  margin-bottom: 12px;
}

.page-content ul {
  padding-left: 24px;
  margin-bottom: 16px;
}

/* Modal (payments, dialogs) */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s, visibility 0.25s;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  max-width: 480px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal h3 {
  margin-bottom: 16px;
  color: var(--accent);
}

.modal .actions {
  margin-top: 24px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Pricing table */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s;
}

.pricing-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
}

.pricing-card.featured {
  border-color: var(--accent);
  box-shadow: var(--glow);
}

.pricing-card .name {
  font-size: 1.2rem;
  color: var(--accent);
  margin-bottom: 8px;
}

.pricing-card .price {
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.pricing-card .price span {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-muted);
}

.pricing-card ul {
  list-style: none;
  padding: 0;
  margin: 20px 0;
  text-align: left;
}

.pricing-card li {
  padding: 6px 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.pricing-card li:last-child {
  border-bottom: none;
}

/* Downloads */
.download-list {
  list-style: none;
  padding: 0;
}

.download-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 12px;
}

.download-list a {
  color: var(--accent);
  text-decoration: none;
}

.download-list a:hover {
  text-decoration: underline;
}

/* Form elements */
input, select, textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(10, 14, 23, 0.8);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
  margin-bottom: 12px;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 229, 255, 0.15);
}

label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .hero { padding-top: 120px; }
  .section { padding: 48px 24px; }
  .lang-select { min-width: 48px; font-size: 0.8rem; padding: 8px 6px; }
  .nav a { padding: 8px 6px; font-size: 0.85rem; }
}
@media (max-width: 480px) {
  .site-header { padding: 8px 12px; }
  .wrapper { padding: 0 16px; }
  .hero { padding-top: 100px; padding-left: 16px; padding-right: 16px; }
  .section { padding: 32px 16px; }
}
