/* Variables & Tokens - Позитивная, светлая и энергичная палитра */
:root {
  --bg-color: #f7fafc;
  --bg-card: rgba(255, 255, 255, 0.85);
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --accent: #38bdf8;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --border: rgba(99, 102, 241, 0.15);
  --success: #10b981;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-logo: 'Outfit', sans-serif;
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: var(--font-sans);
}

body {
  overflow-x: hidden;
  /* Мягкие, теплые и свежие весенние градиенты */
  background: radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 10% 60%, rgba(56, 189, 248, 0.08) 0%, transparent 45%),
              #f1f5f9;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  border: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, #6366f1 100%);
  color: #fff;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.btn-secondary {
  background-color: #fff;
  color: #4f46e5;
  border: 1px solid rgba(79, 70, 229, 0.2);
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.btn-secondary:hover {
  background-color: rgba(79, 70, 229, 0.05);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(79, 70, 229, 0.2);
  color: #4f46e5;
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(79, 70, 229, 0.3);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 14px;
  border-radius: 8px;
}

.btn-block {
  width: 100%;
}

/* Typography & Helpers */
.gradient-text {
  background: linear-gradient(90deg, #4f46e5, #0ea5e9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-center {
  text-align: center;
}

/* Glassmorphism Card (Light theme) */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(79, 70, 229, 0.1);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(79, 70, 229, 0.08);
}

/* Header */
header {
  border-bottom: 1px solid rgba(79, 70, 229, 0.1);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-logo);
  font-weight: 800;
  font-size: 24px;
}

nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s;
}

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

/* Hero Section */
.hero {
  padding: 80px 0 100px 0;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 60px;
}

.badge {
  display: inline-flex;
  padding: 6px 14px;
  background: rgba(79, 70, 229, 0.08);
  border: 1px solid rgba(79, 70, 229, 0.2);
  color: var(--primary);
  border-radius: 99px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero-content h1 {
  font-size: 54px;
  line-height: 1.15;
  font-weight: 800;
  margin-bottom: 20px;
  letter-spacing: -1px;
  color: #0f172a;
}

.hero-subtitle {
  font-size: 18px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  margin-bottom: 48px;
}

.hero-stats {
  display: flex;
  gap: 40px;
  border-top: 1px solid rgba(79, 70, 229, 0.1);
  padding-top: 32px;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-num {
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
}

.stat-label {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Hero Visual & Micro-animations */
.hero-visual {
  display: flex;
  justify-content: center;
}

.main-preview {
  width: 100%;
  max-width: 420px;
  height: 280px;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(79, 70, 229, 0.1);
}

.card-header {
  height: 48px;
  border-bottom: 1px solid rgba(79, 70, 229, 0.1);
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 6px;
  background: #f8fafc;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.card-title {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 10px;
  font-weight: 500;
}

.card-body {
  padding: 24px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.line {
  height: 12px;
  background: #f1f5f9;
  border-radius: 6px;
  width: 90%;
  animation: pulse 2s infinite ease-in-out;
}

.line.delay-1 { width: 75%; animation-delay: 0.4s; }
.line.delay-2 { width: 85%; animation-delay: 0.8s; }

.check-result {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.check-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: #f1f5f9;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  width: fit-content;
  color: #475569;
}

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

@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* Features */
.features {
  padding: 100px 0;
  border-top: 1px solid rgba(79, 70, 229, 0.1);
}

.section-title {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 48px;
  color: #0f172a;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-card {
  background: #fff;
  border: 1px solid rgba(79, 70, 229, 0.1);
  border-radius: 16px;
  padding: 32px;
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(79, 70, 229, 0.3);
  box-shadow: 0 10px 20px rgba(79, 70, 229, 0.05);
}

.feature-icon {
  font-size: 32px;
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 20px;
  margin-bottom: 12px;
  color: #0f172a;
}

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

/* Demo Section */
.demo-section {
  padding: 100px 0;
  border-top: 1px solid rgba(79, 70, 229, 0.1);
}

.section-subtitle {
  color: var(--text-muted);
  margin-top: 12px;
  margin-bottom: 48px;
}

.demo-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 400px;
  background: #fff;
}

.demo-inputs {
  padding: 32px;
  border-right: 1px solid rgba(79, 70, 229, 0.1);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.demo-outputs {
  padding: 32px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
}

.input-group, .output-group {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.output-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.uniqueness-tag {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
  font-size: 13px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
}

.uniqueness-tag.hidden {
  display: none;
}

label {
  font-size: 14px;
  font-weight: 600;
  color: #475569;
  margin-bottom: 8px;
}

textarea {
  width: 100%;
  flex-grow: 1;
  min-height: 180px;
  background: #fff;
  border: 1px solid rgba(79, 70, 229, 0.15);
  border-radius: 12px;
  color: var(--text-main);
  padding: 16px;
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  resize: none;
  outline: none;
  transition: border-color 0.2s;
}

textarea:focus {
  border-color: var(--primary);
}

.char-counter {
  text-align: right;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

.modes-select {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.mode-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: #fff;
  border: 1px solid rgba(79, 70, 229, 0.15);
  border-radius: 10px;
  color: var(--text-muted);
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 600;
  transition: all 0.2s;
}

.mode-btn:hover {
  background: rgba(79, 70, 229, 0.05);
}

.mode-btn.active {
  background: rgba(79, 70, 229, 0.08);
  border-color: var(--primary);
  color: var(--primary);
}

.result-placeholder {
  color: var(--text-muted);
  font-style: italic;
  font-size: 15px;
  line-height: 1.5;
  padding: 16px;
  background: #fff;
  border: 1px dashed rgba(79, 70, 229, 0.2);
  border-radius: 12px;
  flex-grow: 1;
  overflow-y: auto;
  white-space: pre-wrap;
  min-height: 180px;
  margin-bottom: 16px;
}

.result-text-active {
  color: var(--text-main);
  font-style: normal;
  border-style: solid;
  border-color: rgba(79, 70, 229, 0.15);
}

.hidden {
  display: none !important;
}

/* Tariffs */
.tariffs {
  padding: 100px 0;
  border-top: 1px solid rgba(79, 70, 229, 0.1);
}

.tariffs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.tariff-card {
  background: #fff;
  border: 1px solid rgba(79, 70, 229, 0.1);
  border-radius: 20px;
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

.tariff-card.popular {
  border-color: var(--primary);
  background: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.08) 0%, transparent 70%),
              #fff;
  box-shadow: 0 10px 30px rgba(79, 70, 229, 0.08);
}

.popular-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  padding: 4px 16px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.tariff-header h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 16px;
  color: #0f172a;
}

.tariff-header .price {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 8px;
  color: var(--primary);
}

.price-desc {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.tariff-features {
  list-style: none;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex-grow: 1;
}

.tariff-features li {
  font-size: 15px;
  color: #475569;
}

/* Footer */
footer {
  border-top: 1px solid rgba(79, 70, 229, 0.1);
  padding: 40px 0;
  background: #fff;
}

.footer-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

/* Responsive */
@media (max-width: 968px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .hero-visual {
    order: -1;
  }
  .features-grid, .tariffs-grid {
    grid-template-columns: 1fr;
  }
  .demo-box {
    grid-template-columns: 1fr;
  }
  .demo-inputs {
    border-right: none;
    border-bottom: 1px solid rgba(79, 70, 229, 0.1);
  }
}
