/* Los tokens de color (--bg-dark, --primary, --text-*, etc.) viven en
   theme.css, compartido con widget.css. Este archivo debe cargarse después
   de theme.css en cada página. */

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

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
}

/* Ambient Glowing Orbs */
.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
}

.orb-1 {
  width: 500px;
  height: 500px;
  background: var(--primary-glow);
  top: -100px;
  left: 10%;
}

.orb-2 {
  width: 450px;
  height: 450px;
  background: rgba(91, 91, 246, 0.14);
  top: 400px;
  right: 5%;
}

/* Layout Wrapper */
.app-wrapper {
  position: relative;
  z-index: 1;
  max-width: 1150px;
  width: 100%;
  margin: 0 auto;
  padding: 0 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Header & Navigation */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border-card);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-main);
}

.brand-icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--primary), var(--primary-tint));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 15px var(--primary-glow);
}

.brand-icon svg {
  width: 24px;
  height: 24px;
  color: white;
}

.brand-title {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.brand-badge {
  font-size: 0.7rem;
  font-weight: 600;
  background: rgba(91, 91, 246, 0.15);
  color: var(--primary-tint);
  border: 1px solid rgba(91, 91, 246, 0.3);
  padding: 2px 8px;
  border-radius: 20px;
  letter-spacing: 0.05em;
}

/* Unified & Eye-Catching Navigation Buttons */
.nav-wrapper {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

nav {
  display: flex;
  gap: 0.85rem;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

nav .nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.4rem;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  background: var(--surface-1);
  border: 1px solid var(--border-card);
  backdrop-filter: blur(10px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  letter-spacing: 0.01em;
}

nav .nav-btn:hover {
  color: var(--text-main);
  background: var(--surface-2);
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--surface-1);
  border: 1px solid var(--border-card);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.theme-toggle:hover {
  color: var(--text-main);
  background: var(--surface-2);
  border-color: var(--border-hover);
}

.theme-toggle svg { display: block; }

nav .nav-btn.active {
  color: var(--primary-tint);
  background: rgba(91, 91, 246, 0.16);
  border-color: rgba(91, 91, 246, 0.6);
  box-shadow: 0 0 20px var(--primary-glow);
}

nav .nav-btn:focus-visible,
.theme-toggle:focus-visible,
.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.form-control:focus-visible,
.email-direct-box:focus-visible {
  outline: 2px solid var(--primary-tint);
  outline-offset: 2px;
}

/* Status Tag */
.status-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(91, 91, 246, 0.1);
  border: 1px solid rgba(91, 91, 246, 0.3);
  color: var(--primary-tint);
  padding: 6px 18px;
  border-radius: 30px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 2rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  background-color: var(--primary);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--primary);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

@media (prefers-reduced-motion: reduce) {
  .status-dot { animation: none; }
  nav .nav-btn, .btn-primary, .btn-secondary, .highlight-card,
  .product-card, .email-direct-box, .form-control {
    transition: none;
  }
}

/* Page Section Common */
.page-content {
  padding: 4rem 0;
  flex: 1;
}

/* Hero Section */
.hero {
  padding: 4rem 0 3rem;
  text-align: center;
  max-width: 850px;
  margin: 0 auto;
}

.hero-signal {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: var(--primary);
  opacity: 0.85;
}

.hero-signal .hs-node {
  animation: hs-pulse 2.4s ease-in-out infinite;
}
.hero-signal .hs-node:nth-of-type(1) { animation-delay: 0s; }
.hero-signal .hs-node:nth-of-type(2) { animation-delay: 0.15s; }
.hero-signal .hs-node:nth-of-type(3) { animation-delay: 0.3s; }
.hero-signal .hs-node:nth-of-type(4) { animation-delay: 0.3s; }
.hero-signal .hs-node:nth-of-type(5) { animation-delay: 0.45s; }
.hero-signal .hs-node:nth-of-type(6) { animation-delay: 0.45s; }
.hero-signal .hs-node:nth-of-type(7) { animation-delay: 0.6s; }

@keyframes hs-pulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-signal .hs-node { animation: none; opacity: 0.85; }
}

.hero h1 {
  font-size: 3.25rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, var(--text-main) 40%, var(--text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

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

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: white;
  text-decoration: none;
  padding: 0.9rem 2rem;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  box-shadow: 0 10px 25px -5px var(--primary-glow);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 30px -5px rgba(91, 91, 246, 0.5);
}

.btn-secondary {
  background: var(--surface-1);
  border: 1px solid var(--border-card);
  color: var(--text-main);
  text-decoration: none;
  padding: 0.9rem 2rem;
  border-radius: 12px;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--surface-2);
  border-color: var(--border-hover);
}

/* Feature Highlights Grid */
.feature-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 3rem 0;
}

.highlight-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 20px;
  padding: 2rem;
  backdrop-filter: blur(15px);
  transition: all 0.3s ease;
}

.highlight-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
}

.highlight-icon {
  width: 48px;
  height: 48px;
  background: rgba(91, 91, 246, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  color: var(--primary);
}

.highlight-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.highlight-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Products Section */
.products-section {
  padding: 2rem 0 4rem;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.5rem;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 20px;
  padding: 2rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 10px 30px -10px var(--primary-glow);
}

.product-badge {
  align-self: flex-start;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  background: var(--surface-1);
  color: var(--text-muted);
  border: 1px solid var(--border-card);
  margin-bottom: 1.25rem;
}

.product-card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.product-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  flex: 1;
  margin-bottom: 1.5rem;
}

.product-list {
  list-style: none;
  margin-bottom: 1.5rem;
}

.product-list li {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-list li::before {
  content: "✓";
  color: var(--primary-tint);
  font-weight: bold;
}

/* Contact Card / Form */
.contact-card-box {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 24px;
  padding: 3rem 2rem;
  max-width: 680px;
  margin: 0 auto;
  backdrop-filter: blur(20px);
}

.form-group {
  margin-bottom: 1.5rem;
  text-align: left;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.form-control {
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--border-card);
  border-radius: 12px;
  padding: 0.875rem 1.25rem;
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: all 0.3s ease;
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(91, 91, 246, 0.2);
}

.form-control[readonly] {
  opacity: 0.7;
  cursor: not-allowed;
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.email-direct-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--input-bg);
  border: 1px solid var(--border-card);
  padding: 1rem 1.75rem;
  border-radius: 14px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--primary-tint);
  text-decoration: none;
  transition: all 0.3s ease;
  margin-bottom: 2.5rem;
}

.email-direct-box:hover {
  border-color: var(--primary);
  box-shadow: 0 0 20px var(--primary-glow);
  transform: translateY(-2px);
}

/* Legal Container (Impressum Page) */
.legal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 24px;
  padding: 3rem;
  max-width: 800px;
  margin: 0 auto;
  backdrop-filter: blur(20px);
}

.legal-card h1 {
  font-size: 2.25rem;
  margin-bottom: 1rem;
}

.legal-card h3 {
  font-size: 1.3rem;
  margin: 1.75rem 0 0.5rem;
  color: var(--primary-tint);
}

.legal-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}

/* Footer */
footer {
  border-top: 1px solid var(--border-card);
  padding: 2.5rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.9rem;
  color: var(--text-dim);
  margin-top: auto;
}

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

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.25rem;
  }

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

  footer {
    flex-direction: column;
    text-align: center;
  }
}
