/* AI Hungary — Premium AI Consultant Website */
:root {
  --bg: #0a0a0b;
  --bg-elevated: #111113;
  --bg-card: rgba(255, 255, 255, 0.02);
  --fg: #fafafa;
  --fg-muted: #a1a1aa;
  --accent: #6366f1;
  --accent-light: #818cf8;
  --accent-glow: rgba(99, 102, 241, 0.25);
  --border: rgba(255, 255, 255, 0.06);
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Space Grotesk', sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Preloader */
#loader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

#loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.loader-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: 0.05em;
}

.loader-logo span {
  color: var(--accent);
}

.loader-bar-track {
  width: 160px;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
  border-radius: 2px;
}

.loader-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  width: 0%;
  transition: width 0.2s ease;
}

.loader-text {
  font-size: 0.75rem;
  color: var(--fg-muted);
}

/* Background layers */
.hero-gradient {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 100vh;
  background: 
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(99, 102, 241, 0.15), transparent),
    radial-gradient(ellipse 60% 40% at 80% 50%, rgba(99, 102, 241, 0.06), transparent),
    radial-gradient(ellipse 40% 30% at 20% 80%, rgba(99, 102, 241, 0.04), transparent);
  z-index: -2;
  pointer-events: none;
}

#neural-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

.grain-overlay {
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  opacity: 0.03;
  z-index: 0;
  pointer-events: none;
}

/* Navigation */
#main-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1.25rem 0;
  transition: background var(--transition), backdrop-filter var(--transition), padding var(--transition);
}

#main-nav.scrolled {
  background: rgba(10, 10, 11, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.05em;
  color: var(--fg);
  text-decoration: none;
}

.nav-logo span {
  color: var(--accent);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.nav-link {
  color: var(--fg-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color var(--transition);
}

.nav-link:hover {
  color: var(--fg);
}

.nav-cta {
  padding: 0.6rem 1.25rem;
  background: var(--accent);
  color: white;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}

.nav-cta:hover {
  background: var(--accent-light);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--fg);
  transition: var(--transition);
}

/* Hero */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem 0 4rem;
  position: relative;
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-content {
  max-width: 560px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.9rem;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent-light);
  margin-bottom: 1.5rem;
}

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

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

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}

.hero-title .line {
  display: block;
}

.hero-title .accent {
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-lead {
  font-size: 1.125rem;
  color: var(--fg-muted);
  line-height: 1.7;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.75rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 10px;
  text-decoration: none;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
  font-family: inherit;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-primary:hover {
  background: var(--accent-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-ghost {
  background: transparent;
  color: var(--fg-muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  color: var(--fg);
  border-color: rgba(255, 255, 255, 0.15);
}

/* Hero visual mockup */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-mockup {
  width: 100%;
  max-width: 480px;
}

.mockup-browser {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.mockup-dots {
  display: flex;
  gap: 8px;
  padding: 1rem 1.25rem;
  background: rgba(0, 0, 0, 0.2);
  border-bottom: 1px solid var(--border);
}

.mockup-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
}

.mockup-content {
  padding: 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  position: relative;
}

.mockup-node {
  padding: 0.75rem 1.25rem;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--accent-light);
}

.mockup-line {
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0.5;
  position: relative;
  overflow: hidden;
}

.mockup-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 12px;
  height: 100%;
  background: var(--accent-light);
  animation: flow 2s ease-in-out infinite;
}

@keyframes flow {
  0% { transform: translateX(-100%); opacity: 0; }
  50% { opacity: 1; }
  100% { transform: translateX(200%); opacity: 0; }
}

.mockup-pulse {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--fg-muted);
  font-size: 0.75rem;
}

.scroll-mouse {
  width: 24px;
  height: 36px;
  border: 2px solid var(--border);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}

.scroll-wheel {
  width: 4px;
  height: 8px;
  background: var(--fg-muted);
  border-radius: 2px;
  animation: scroll 2s ease-in-out infinite;
}

@keyframes scroll {
  0%, 100% { opacity: 1; transform: translateY(0); }
  50% { opacity: 0.3; transform: translateY(6px); }
}

/* Trust bar */
.trust-bar {
  padding: 3rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.trust-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.trust-label {
  text-align: center;
  font-size: 0.8rem;
  color: var(--fg-muted);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.trust-logos {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
}

.trust-logo {
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg-muted);
  opacity: 0.7;
}

/* Sections */
.section {
  padding: 6rem 0;
}

.section-dark {
  background: var(--bg-elevated);
}

.section-cta {
  padding: 6rem 0;
}

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

.section-header {
  margin-bottom: 3rem;
  max-width: 560px;
}

.section-header-center {
  text-align: center;
  max-width: none;
}

.section-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.section-lead {
  font-size: 1.125rem;
  color: var(--fg-muted);
  line-height: 1.6;
}

/* Service cards */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.service-card {
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}

.service-card:hover {
  border-color: rgba(99, 102, 241, 0.2);
  background: rgba(99, 102, 241, 0.03);
  transform: translateY(-4px);
}

.card-icon {
  width: 48px;
  height: 48px;
  margin-bottom: 1.25rem;
  color: var(--accent);
}

.card-icon svg {
  width: 100%;
  height: 100%;
}

.service-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.service-card p {
  color: var(--fg-muted);
  font-size: 0.95rem;
  margin-bottom: 1rem;
  line-height: 1.6;
}

.card-tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.card-tags li {
  font-size: 0.75rem;
  color: var(--fg-muted);
  padding: 0.25rem 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
}

/* Products */
.products-showcase {
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.product-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.product-card-reverse {
  direction: rtl;
}

.product-card-reverse > * {
  direction: ltr;
}

.product-visual {
  position: relative;
}

.product-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
}

.product-frame img {
  width: 100%;
  height: auto;
  display: block;
}

.product-info {
  padding: 1rem 0;
}

.product-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.product-info h3 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.product-info p {
  color: var(--fg-muted);
  margin-bottom: 1.25rem;
  line-height: 1.6;
}

.product-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent-light);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: gap var(--transition);
}

.product-link:hover {
  gap: 0.75rem;
}

/* Process */
.process-steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 0;
  align-items: start;
  max-width: 900px;
}

.process-step {
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}

.process-step:hover {
  border-color: rgba(99, 102, 241, 0.2);
}

.step-number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.process-step h4 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.process-step p {
  color: var(--fg-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.process-connector {
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--border), transparent);
  margin-top: 3rem;
}

/* CTA / Contact */
.cta-box {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
  max-width: 900px;
  margin: 0 auto;
}

.cta-content h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.cta-content p {
  color: var(--fg-muted);
  line-height: 1.6;
}

.cta-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  position: relative;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 1rem 1.25rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--fg);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-group label {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--fg-muted);
  font-size: 1rem;
  pointer-events: none;
  transition: all var(--transition);
}

.form-group textarea + label {
  top: 1.5rem;
  transform: none;
}

.form-group input:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:focus + label,
.form-group textarea:not(:placeholder-shown) + label {
  top: -0.5rem;
  left: 0.75rem;
  font-size: 0.75rem;
  color: var(--accent);
  background: var(--bg-elevated);
  padding: 0 0.25rem;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: transparent;
}

.btn-submit {
  width: 100%;
  justify-content: center;
  background: var(--accent);
  color: white;
  padding: 1rem;
  margin-top: 0.5rem;
}

.btn-submit:hover {
  background: var(--accent-light);
  transform: none;
}

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

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}

.footer-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.05em;
}

.footer-logo span {
  color: var(--accent);
}

.footer-brand p {
  font-size: 0.9rem;
  color: var(--fg-muted);
  margin-top: 0.25rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: var(--fg-muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--fg);
}

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

/* Responsive */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    max-width: none;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    order: -1;
  }

  .hero-mockup {
    max-width: 400px;
    margin: 0 auto;
  }

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

  .product-card,
  .product-card-reverse {
    grid-template-columns: 1fr;
    direction: ltr;
  }

  .product-card-reverse .product-visual {
    order: 1;
  }

  .process-steps {
    grid-template-columns: 1fr;
  }

  .process-connector {
    width: 2px;
    height: 24px;
    margin: 0 auto;
    background: linear-gradient(180deg, var(--border), transparent);
  }

  .cta-box {
    grid-template-columns: 1fr;
    padding: 2.5rem;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100vh;
    background: var(--bg-elevated);
    border-left: 1px solid var(--border);
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
    padding: 4rem 2rem;
    transform: translateX(100%);
    transition: transform var(--transition);
    z-index: 999;
  }

  .nav-menu.open {
    transform: translateX(0);
  }

  .nav-toggle {
    display: flex;
    z-index: 1001;
  }

  .nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .nav-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .hero-title {
    font-size: 2rem;
  }

  .trust-logos {
    gap: 1.5rem;
  }

  .section {
    padding: 4rem 0;
  }

  .container {
    padding: 0 1.5rem;
  }
}
