/*
Theme Name: Equalis Theme
Description: Tema a medida para Equalis Consultoria Canaria
Author: Antigravity
Version: 5.2.0
*/

:root {
  --violet: #845ec2;
  --violet-deep: #10174f;
  --green: #10174f;
  --gradient-start: rgba(16, 23, 79, 0.85);
  --gradient-end: rgba(16, 23, 79, 0.95);
  --ink: #000000;
  --muted: #5A5D60;
  --line: #e6e1ea;
  --soft: #f8f9fa;
  --white: #ffffff;
  --shadow: 0 4px 6px -1px rgba(33, 26, 39, 0.05), 0 18px 48px rgba(33, 26, 39, 0.08);
  --header: 74px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

[id] {
  scroll-margin-top: calc(var(--header) + 22px);
}

body {
  margin: 0;
  color: var(--text-color, var(--ink));
  font-family: var(--font-body, Inter, Montserrat, "Segoe UI", Arial, sans-serif);
  background: var(--bg-color, var(--white));
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading, var(--font-body, Inter, Montserrat, "Segoe UI", Arial, sans-serif));
}

body.nav-open {
  overflow: hidden;
}

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

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  min-height: var(--header);
  padding: 12px clamp(18px, 4vw, 56px);
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(230, 225, 234, 0.9);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  min-width: 214px;
}

.brand-mark {
  display: grid;
  width: 48px;
  height: 42px;
  place-items: center;
  background:
    linear-gradient(135deg, var(--violet) 0%, var(--violet-deep) 100%);
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(0, 122, 130, 0.18);
}

.brand-symbol {
  display: block;
  width: 28px;
  height: 21px;
  background:
    linear-gradient(var(--white), var(--white)) 0 0 / 3px 100% no-repeat,
    linear-gradient(var(--white), var(--white)) 0 0 / 17px 3px no-repeat,
    linear-gradient(var(--white), var(--white)) 0 9px / 17px 3px no-repeat,
    linear-gradient(var(--white), var(--white)) 0 18px / 17px 3px no-repeat,
    linear-gradient(#a8e3d3, #a8e3d3) 20px 5px / 8px 3px no-repeat,
    linear-gradient(#a8e3d3, #a8e3d3) 20px 13px / 8px 3px no-repeat;
}

.brand-copy {
  min-width: 0;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  color: var(--violet-deep);
  font-size: 1.12rem;
  line-height: 1.1;
}

.brand small {
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.15;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 2vw, 28px);
  font-size: 0.94rem;
  font-weight: 650;
}

.site-nav a {
  padding: 10px 0;
  color: #3e3744;
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--violet);
}

.header-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 16px;
  font-weight: 760;
  line-height: 1.15;
  text-decoration: none;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.header-cta,
.button-primary {
  color: var(--white);
  background: var(--violet);
}

.header-cta:hover,
.button-primary:hover {
  background: var(--violet-deep);
  transform: translateY(-1px);
}

.button-secondary {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.64);
  background: rgba(255, 255, 255, 0.12);
}

.button-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--violet-deep);
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: calc(78vh - var(--header));
  overflow: hidden;
  color: var(--white);
}

.hero-video,
.hero-image,
.hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-video,
.hero-image {
  object-fit: cover;
}

.hero-poster {
  opacity: 0;
}

.hero-overlay {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(820px, calc(100% - 36px));
  margin-left: clamp(18px, 8vw, 112px);
  padding: clamp(42px, 8vw, 90px) 0;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 820;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow,
.landing-hero .eyebrow,
.page-hero .eyebrow,
.online-hero .eyebrow {
  color: #ffffff !important;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(2.35rem, 5vw, 4.25rem);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  max-width: 760px;
  margin: 0;
  color: var(--violet-deep);
  font-size: clamp(2rem, 4vw, 3.25rem);
  line-height: 1.05;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 10px;
  color: var(--violet-deep);
  font-size: 1.18rem;
  line-height: 1.22;
  letter-spacing: 0;
}

.hero-subtitle {
  max-width: 680px;
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1.08rem, 2vw, 1.28rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.band {
  padding: clamp(58px, 8vw, 108px) clamp(18px, 4vw, 56px);
}

.band.alt {
  background: var(--soft);
}

.band.deep {
  color: var(--white);
  background: var(--violet-deep);
}

.wrap {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.section-heading {
  margin-bottom: clamp(28px, 5vw, 50px);
}

.section-heading.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.55fr);
  gap: 28px;
  align-items: end;
}

.section-heading p,
.diagnostic-layout > div > p,
.trust-copy > p {
  margin-top: 18px;
  color: var(--muted);
  font-size: 1.06rem;
}

.deep .section-heading h2,
.deep .section-heading p {
  color: var(--white);
}

.deep .eyebrow {
  color: #a8e3d3;
}

.needs-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.need-item,
.service-list article,
.faq-grid article,
.diagnostic-form,
.contact-note {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: 0 1px 0 rgba(33, 26, 39, 0.04);
}

.need-item {
  min-height: 260px;
  padding: 24px;
}

.icon-dot {
  display: inline-grid;
  width: 42px;
  height: 42px;
  margin-bottom: 28px;
  place-items: center;
  color: var(--white);
  font-size: 0.82rem;
  font-weight: 800;
  background: var(--violet);
  border-radius: 16px;
}

.icon-dot.green {
  background: var(--green);
}

.need-item p,
.service-list p,
.sector-card p,
.process-steps span,
.check-list {
  margin: 0;
  color: var(--muted);
}

.sector-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.sector-card {
  display: grid;
  grid-template-columns: 42% 1fr;
  min-height: 330px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.sector-card img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
}

.sector-card div {
  display: flex;
  flex-direction: column;
  padding: 26px;
}

.sector-card span {
  margin-bottom: 12px;
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

.sector-card a {
  margin-top: auto;
  padding-top: 18px;
  color: var(--violet);
  font-weight: 800;
  text-decoration: none;
}

.service-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.service-list article {
  min-height: 220px;
  padding: 26px;
}

.service-list a {
  display: inline-flex;
  margin-top: 18px;
  color: var(--violet);
  font-weight: 800;
  text-decoration: none;
}

.service-list article:nth-child(1),
.service-list article:nth-child(2) {
  grid-column: span 1;
}

.service-list article:nth-child(5) {
  grid-column: span 2;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: process;
}

.process-steps li {
  position: relative;
  min-height: 210px;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
}

.process-steps li::before {
  counter-increment: process;
  content: counter(process);
  display: grid;
  width: 42px;
  height: 42px;
  margin-bottom: 24px;
  place-items: center;
  color: var(--violet-deep);
  font-weight: 850;
  background: #a8e3d3;
  border-radius: 16px;
}

.process-steps strong,
.process-steps span {
  display: block;
}

.process-steps strong {
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.process-steps span {
  color: rgba(255, 255, 255, 0.78);
}

.trust-layout,
.diagnostic-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(320px, 1fr);
  gap: clamp(28px, 6vw, 74px);
  align-items: center;
}

.trust-image {
  margin: 0;
  overflow: hidden;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.trust-image img {
  width: 100%;
  height: min(520px, 56vw);
  object-fit: cover;
}

.entity-definition {
  padding: 20px;
  color: var(--violet-deep);
  border-left: 4px solid var(--green);
  background: rgba(47, 125, 109, 0.08);
}

.entity-definition strong {
  color: var(--violet-deep);
}

.faq {
  background: var(--white);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.faq-grid article {
  min-height: 240px;
  padding: 24px;
}

.faq-grid p {
  margin: 0;
  color: var(--muted);
}

.check-list {
  display: grid;
  gap: 12px;
  margin-top: 24px;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 30px;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.48em;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--green);
}

.diagnostic-layout {
  align-items: start;
}

.contact-note {
  display: grid;
  gap: 6px;
  width: min(430px, 100%);
  margin-top: 28px;
  padding: 20px;
}

.contact-note strong {
  color: var(--violet-deep);
}

.contact-note a {
  color: var(--green);
  font-weight: 780;
  text-decoration: none;
}

.diagnostic-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: clamp(20px, 4vw, 34px);
}

.diagnostic-form label {
  display: grid;
  gap: 7px;
  color: var(--violet-deep);
  font-size: 0.9rem;
  font-weight: 760;
}

.diagnostic-form label span,
.privacy-note {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 500;
}

.diagnostic-form input,
.diagnostic-form select,
.diagnostic-form textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 13px;
  color: var(--ink);
  font: inherit;
  border: 1px solid #d8d1de;
  border-radius: 16px;
  background: var(--white);
}

.diagnostic-form textarea {
  resize: vertical;
}

.diagnostic-form input:focus,
.diagnostic-form select:focus,
.diagnostic-form textarea:focus {
  outline: 3px solid rgba(0, 156, 166, 0.16);
  border-color: var(--violet);
}

.full {
  grid-column: 1 / -1;
}

.privacy-note {
  margin: -4px 0 0;
}

.form-success {
  grid-column: 1 / -1;
  padding: 28px;
  color: var(--violet-deep);
  border: 1px solid rgba(47, 125, 109, 0.25);
  border-radius: 16px;
  background: rgba(47, 125, 109, 0.09);
}

.form-success strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.22rem;
}

.page-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: calc(72vh - var(--header));
  overflow: hidden;
  color: var(--white);
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
}

.page-hero > img,
.page-hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.page-hero > img {
  object-fit: cover;
  mix-blend-mode: overlay;
  opacity: 0.15;
  z-index: 0;
}

.page-hero-overlay {
  display: none;
}

.page-hero-content {
  position: relative;
  z-index: 1;
  width: min(980px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(64px, 9vw, 118px) 0;
}

.page-hero h1 {
  max-width: 860px;
  margin: 0;
  font-size: clamp(2.4rem, 5.6vw, 4.8rem);
  line-height: 1;
}

.page-hero p:not(.eyebrow) {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1.05rem, 2vw, 1.24rem);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.9rem;
}

.breadcrumb a {
  color: var(--white);
  text-decoration: none;
}

.breadcrumb span::before {
  content: "/";
  margin-right: 8px;
}

.page-grid,
.page-two-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.48fr);
  gap: clamp(24px, 5vw, 58px);
  align-items: start;
}

.page-main h2,
.page-two-cols h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.8rem);
}

.page-main p {
  color: var(--muted);
  font-size: 1.08rem;
}

.page-card {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.page-card a,
.related-links a {
  color: var(--green);
  font-weight: 800;
  text-decoration: none;
}

.rich-list {
  display: grid;
  gap: 14px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.rich-list li {
  position: relative;
  padding: 18px 18px 18px 44px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
}

.rich-list li::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 1.42em;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
}

.related-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.related-links a {
  display: flex;
  align-items: center;
  min-height: 110px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--soft);
}

.sector-depth .section-heading {
  margin-bottom: 30px;
}

.scenario-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.scenario-grid article {
  min-height: 180px;
  padding: 22px;
  color: var(--violet-deep);
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
}

.scenario-grid p {
  margin: 0;
  font-weight: 700;
}

.faq-grid.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.faq-grid.compact article {
  min-height: 190px;
}

@media (max-width: 1050px) {
  .site-header {
    grid-template-columns: auto auto;
  }

  .menu-toggle {
    display: block;
    justify-self: end;
  }

  .site-nav,
  .header-cta {
    display: none;
  }

  .site-header.is-open .site-nav {
    position: fixed;
    inset: var(--header) 0 auto 0;
    display: grid;
    gap: 0;
    padding: 16px 22px 22px;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }

  .site-header.is-open .site-nav a {
    padding: 16px 4px;
    border-bottom: 1px solid var(--line);
  }

  .section-heading.split,
  .trust-layout,
  .diagnostic-layout,
  .page-grid,
  .page-two-cols {
    grid-template-columns: 1fr;
  }

  .needs-grid,
  .process-steps,
  .scenario-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sector-grid,
  .service-list,
  .related-links,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .service-list article:nth-child(5) {
    grid-column: span 1;
  }
}

@media (max-width: 720px) {
  :root {
    --header: 68px;
  }

  .site-header {
    padding: 10px 16px;
  }

  .brand {
    min-width: 0;
  }

  .hero {
    min-height: calc(82vh - var(--header));
  }

  .hero-content {
    width: calc(100% - 32px);
    margin: 0 auto;
  }

  h1 {
    font-size: clamp(2.05rem, 11vw, 3.1rem);
  }

  .button,
  .hero-actions {
    width: 100%;
  }

  .needs-grid,
  .process-steps,
  .scenario-grid,
  .diagnostic-form {
    grid-template-columns: 1fr;
  }

  .sector-card {
    grid-template-columns: 1fr;
  }

  .sector-card img {
    height: 230px;
    min-height: 230px;
  }

  .trust-image img {
    height: 320px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-video {
    display: none;
  }

  .hero-poster {
    opacity: 1;
  }
}


/* --- MODERNIZATION TWEAKS --- */
.need-item,
.sector-card,
.service-list article,
.faq-grid article,
.page-card,
.process-steps li {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.need-item:hover,
.sector-card:hover,
.service-list article:hover,
.faq-grid article:hover,
.page-card:hover,
.process-steps li:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  border-color: rgba(0, 156, 166, 0.2);
}

/* More breathing room */
.need-item, .service-list article, .faq-grid article, .page-card {
  padding: 32px;
}
.sector-card div {
  padding: 32px;
}


/* --- ACCORDION FAQ --- */
.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}
.faq-item {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  overflow: hidden;
  transition: all 0.3s ease;
}
.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 32px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--violet-deep);
  font-family: inherit;
}
.faq-icon {
  flex-shrink: 0;
  margin-left: 16px;
  transition: transform 0.3s ease;
  color: var(--green);
}
.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s ease;
}
.faq-answer-inner {
  overflow: hidden;
  padding: 0 32px;
}
.faq-item.is-open .faq-answer {
  grid-template-rows: 1fr;
}
.faq-item.is-open .faq-answer-inner {
  padding: 0 32px 32px;
}
.faq-item.is-open {
  box-shadow: var(--shadow);
  border-color: rgba(0, 156, 166, 0.2);
  transform: translateY(-2px);
}
.faq-item.is-open .faq-icon {
  transform: rotate(45deg);
}
.nav-dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--white);
  min-width: 260px;
  box-shadow: 0 10px 30px rgba(0, 122, 130, 0.15);
  border-radius: 12px;
  padding: 10px 0;
  z-index: 100;
  border: 1px solid rgba(230,225,234,0.8);
}

.dropdown-menu a {
  color: var(--ink) !important;
  padding: 12px 20px !important;
  text-decoration: none;
  display: block;
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}

.dropdown-menu a:hover {
  background-color: rgba(0, 156, 166, 0.05) !important;
  color: var(--violet) !important;
}

.nav-dropdown:hover .dropdown-menu {
  display: block;
  animation: fadeIn 0.2s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translate(-50%, 10px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* CTA Banner Alignment Rules */
.cta-banner {
  text-align: center !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
}

.cta-banner h2,
.cta-banner h3 {
  text-align: center !important;
  color: #ffffff !important;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 800px !important;
  width: 100% !important;
  display: block !important;
}

.cta-banner p {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 650px !important;
}

.cta-banner .eyebrow {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.cta-banner .button,
.cta-banner .button-secondary {
  margin-left: auto !important;
  margin-right: auto !important;
  display: inline-block !important;
}