:root {
  color-scheme: light;
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;

  /* Core palette (Ruta A - Premium Enterprise) */
  --bg: #f7f8fb;
  --surface: #ffffff;
  --text: #0f172a;
  --muted: #4b5563;
  --line: #e2e8f0;

  /* Brand */
  --primary: #0b1f3a;          /* navy base */
  --primary-strong: #102a4a;   /* navy deeper */
  --accent: #1f4e79;           /* enterprise blue */
  --accent-light: #e6eff8;     /* soft blue tint */

  /* Effects */
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 10px 25px rgba(15, 23, 42, 0.08);

  /* Radius */
  --radius-lg: 20px;
  --radius-md: 16px;
  --radius-sm: 12px;

  /* Focus */
  --focus: rgba(31, 78, 121, 0.35);
}

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

html {
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;

  /* Premium readability */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

a:focus,
button:focus,
summary:focus {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 8px;
}

img {
  max-width: 100%;
  display: block;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 16px;
  background: var(--primary);
  color: #fff;
  padding: 8px 16px;
  border-radius: 999px;
  z-index: 999;
}

.skip-link:focus {
  left: 16px;
}

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

.section {
  padding: 80px 0;
}

.section.alt {
  background: var(--surface);
}

.section-heading {
  max-width: 720px;
  margin-bottom: 32px;
}

.section-heading h2 {
  font-size: clamp(1.8rem, 2vw, 2.3rem);
  margin-bottom: 12px;
  letter-spacing: -0.2px;
}

.section-heading p {
  color: var(--muted);
}

.site-header {
  position: sticky;
  top: 0;

  /* Premium glassy */
  background: rgba(247, 248, 251, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);

  border-bottom: 1px solid var(--line);
  z-index: 10;
}

/* Fallback if blur not supported */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header {
    background: rgba(247, 248, 251, 0.98);
  }
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.logo {
  font-weight: 800;
  letter-spacing: 0.3px;
  color: var(--primary);
}

.main-nav {
  position: relative;
}

.nav-menu {
  list-style: none;
  display: flex;
  gap: 20px;
}

.nav-menu a {
  color: var(--muted);
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-menu a:hover {
  background: rgba(31, 78, 121, 0.08);
  color: var(--primary);
}

.nav-menu a.active {
  color: var(--primary);
  font-weight: 700;
  background: rgba(31, 78, 121, 0.10);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-toggle:hover {
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}

.nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--primary);
  margin: 4px 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.hero {
  padding: 110px 0 90px;

  /* Enterprise gradient */
  background: linear-gradient(
    120deg,
    rgba(15, 23, 42, 0.05),
    rgba(31, 78, 121, 0.08)
  );
}

.hero-grid {
  display: grid;
  gap: 40px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: center;
}

.hero-content h1 {
  font-size: clamp(2.4rem, 3vw, 3.2rem);
  margin: 16px 0;
  letter-spacing: -0.4px;
}

.hero-subtitle {
  color: var(--muted);
  font-size: 1.05rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 28px 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.2px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
}

.button.primary {
  background: var(--primary);
  color: #fff;
  box-shadow: var(--shadow);
}

.button.primary:hover {
  background: var(--primary-strong);
}

.button.secondary {
  border-color: var(--primary);
  color: var(--primary);
  background: transparent;
}

.button.secondary:hover {
  background: rgba(11, 31, 58, 0.06);
}

.button:hover {
  transform: translateY(-1px);
}

.hero-badges {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  margin-top: 12px;
}

.badge-title {
  display: block;
  font-weight: 700;
}

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

.hero-panel {
  display: grid;
  gap: 20px;
}

.panel-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--line);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.05);
}

.panel-card.highlight {
  background: var(--primary);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 18px 45px rgba(11, 31, 58, 0.25);
}

.panel-card ul {
  margin-top: 12px;
  padding-left: 18px;
}

.panel-title {
  font-weight: 700;
  margin-bottom: 8px;
}

.grid-4,
.grid-3 {
  display: grid;
  gap: 20px;
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 24px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 35px rgba(15, 23, 42, 0.10);
  border-color: rgba(31, 78, 121, 0.25);
}

.card h3 {
  margin-bottom: 12px;
  letter-spacing: -0.2px;
}

.card p {
  color: var(--muted);
}

.note {
  margin-top: 20px;
  font-weight: 700;
  color: var(--accent);
}

.steps {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.step {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 24px;
  border: 1px solid var(--line);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.05);
}

.step-number {
  display: inline-block;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 12px;
}

.kpi-list {
  list-style: none;
  display: grid;
  gap: 12px;
  padding-left: 0;
}

.kpi-list li {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  border: 1px solid var(--line);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.04);
}

.faq-list details {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  border: 1px solid var(--line);
  margin-bottom: 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.04);
}

.faq-list summary {
  font-weight: 700;
  cursor: pointer;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.contact {
  background: var(--primary);
  color: #fff;
}

.contact-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  align-items: center;
}

.contact-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact .button.secondary {
  border-color: #fff;
  color: #fff;
}

.contact .button.secondary:hover {
  background: rgba(255, 255, 255, 0.10);
}

.contact-note {
  opacity: 0.85;
}

.site-footer {
  padding: 32px 0;
  background: #0f172a;
  color: #e2e8f0;
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.footer-links {
  display: flex;
  gap: 16px;
}

.footer-links a {
  color: inherit;
  opacity: 0.85;
  transition: opacity 0.2s ease;
}

.footer-links a:hover {
  opacity: 1;
}

/* Mobile nav */
@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-menu {
    position: absolute;
    right: 0;
    top: 52px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 12px;
    flex-direction: column;
    padding: 16px;
    gap: 12px;
    min-width: 200px;
    box-shadow: var(--shadow);
    display: none;
  }

  .nav-menu.open {
    display: flex;
  }
}

@media (max-width: 600px) {
  .hero {
    padding-top: 90px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Accessibility: reduce motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
