/* ==========================================================================
   Install, S. Coop. — Landing corporativa
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design tokens
   -------------------------------------------------------------------------- */
:root {
  /* Color */
  --bg:            #f4f3ee;
  --bg-strong:     #ecebe2;
  --white:         #ffffff;
  --ink:           #26302a;
  --ink-soft:      #4a564e;
  --ink-muted:     #6a7269;
  --heading:       #1e2a24;
  --primary:       #3c5545;
  --primary-deep:  #1e2a24;
  --accent:        #2f8552;
  --accent-light:  #8ee0a1;
  --line:          #ddd9cd;
  --line-soft:     #eceadf;
  --line-strong:   #d6d2c4;
  --hero:          #16211b;
  --hero-text:     #f4f3ee;
  --hero-muted:    #c2cec4;

  /* Tipografía */
  --font-sans:  'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-serif: 'Spectral', Georgia, 'Times New Roman', serif;

  /* Layout */
  --container: 1200px;
  --radius: 2px;
  --header-h: 68px;

  /* Sombra y transición */
  --shadow-soft: 0 12px 32px rgba(22, 33, 27, 0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

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

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  color: var(--heading);
  margin: 0;
}

p {
  margin: 0;
}

ul, ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

::selection {
  background: var(--primary);
  color: var(--bg);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

/* --------------------------------------------------------------------------
   3. Accesibilidad y utilidades
   -------------------------------------------------------------------------- */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 12px 20px;
  background: var(--primary-deep);
  color: var(--bg);
  font-weight: 700;
  font-size: 14px;
  border-radius: var(--radius);
  transition: top 0.2s var(--ease);
}

.skip-link:focus {
  top: 12px;
  color: var(--bg);
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.eyebrow--light {
  color: var(--accent-light);
  margin-bottom: 34px;
}

.eyebrow__rule {
  width: 32px;
  height: 2px;
  background: var(--accent-light);
  display: inline-block;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   4. Botones
   -------------------------------------------------------------------------- */
.btn {
  display: inline-block;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 800;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
  transition: background 0.2s var(--ease), color 0.2s var(--ease),
              border-color 0.2s var(--ease), transform 0.15s var(--ease);
}

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

/* Botón de navegación (Contacto) */
.btn--solid {
  background: var(--primary);
  color: var(--bg);
  padding: 11px 20px;
}

.btn--solid:hover {
  background: var(--primary-deep);
  color: var(--bg);
}

/* CTA del hero */
.btn--accent {
  background: var(--accent-light);
  color: #12201a;
  padding: 16px 32px;
}

.btn--accent:hover {
  background: #a5e8b5;
  color: #12201a;
}

/* CTA fantasma sobre fondo oscuro */
.btn--ghost-light {
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--hero-text);
  padding: 15px 30px;
  font-weight: 700;
  background: transparent;
}

.btn--ghost-light:hover {
  border-color: rgba(255, 255, 255, 0.7);
  color: var(--hero-text);
}

/* --------------------------------------------------------------------------
   5. Header
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.site-header__logo img {
  height: 38px;
  width: auto;
  display: block;
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.site-nav__list a:not(.btn) {
  color: var(--ink-soft);
}

.site-nav__list a:not(.btn):hover {
  color: var(--primary-deep);
}

/* Hamburguesa (móvil) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
}

.nav-toggle__bar {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--ink);
  transition: transform 0.25s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* --------------------------------------------------------------------------
   6. Secciones genéricas
   -------------------------------------------------------------------------- */
.section {
  padding: 92px 0;
}

.section--white {
  background: var(--white);
  border-bottom: 1px solid var(--line-soft);
}

.section--dark {
  background: var(--primary-deep);
}

.section--narrow {
  max-width: 1000px;
  margin: 0 auto;
  padding: 104px 0;
}

.section-title {
  font-weight: 500;
  font-size: 52px;
  line-height: 1.06;
  color: var(--heading);
}

.section-title--dark {
  color: var(--bg);
  font-weight: 400;
  font-size: 56px;
  line-height: 1.08;
  margin-bottom: 64px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 52px;
}

.section-heading__note {
  font-size: 16px;
  color: var(--ink-soft);
  max-width: 34ch;
}

/* --------------------------------------------------------------------------
   7. Hero
   -------------------------------------------------------------------------- */
.hero {
  background: var(--hero);
  color: var(--hero-text);
}

.hero__inner {
  padding-top: 120px;
  padding-bottom: 116px;
}

.hero__title {
  font-weight: 600;
  font-size: 88px;
  line-height: 1.0;
  letter-spacing: -0.02em;
  color: #ffffff;
  max-width: 16ch;
  margin-bottom: 32px;
}

.hero__lead {
  font-size: 21px;
  line-height: 1.6;
  color: var(--hero-muted);
  max-width: 60ch;
  margin-bottom: 44px;
}

.hero__actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   8. Nosotros
   -------------------------------------------------------------------------- */
.nosotros__grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 72px;
  align-items: start;
  padding-top: 80px;
  padding-bottom: 80px;
}

.nosotros__grid .section-title {
  font-size: 46px;
  line-height: 1.1;
}

.nosotros__body {
  font-size: 17px;
  line-height: 1.72;
  color: var(--ink-soft);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* --------------------------------------------------------------------------
   9. Servicios
   -------------------------------------------------------------------------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
}

.service-card {
  background: var(--bg);
  padding: 34px 28px 40px;
  display: flex;
  flex-direction: column;
  min-height: 230px;
}

.service-card__num {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: auto;
}

.service-card h3 {
  font-weight: 600;
  font-size: 22px;
  margin: 24px 0 10px;
}

.service-card p {
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink-soft);
}

/* --------------------------------------------------------------------------
   10. Valores
   -------------------------------------------------------------------------- */
.values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.value {
  padding: 40px 40px 8px 0;
  border-right: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--bg);
}

.value:nth-child(2) {
  padding: 40px 40px 8px;
}

.value:nth-child(3) {
  padding: 40px 0 8px 40px;
  border-right: none;
}

.value__num {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--accent-light);
  display: block;
  margin-bottom: 22px;
}

.value h3 {
  font-weight: 500;
  font-size: 24px;
  margin-bottom: 12px;
  color: var(--bg);
}

.value p {
  font-size: 15px;
  line-height: 1.65;
  color: #b9c2bb;
}

/* --------------------------------------------------------------------------
   11. Ámbito
   -------------------------------------------------------------------------- */
.ambito__lead {
  font-size: 19px;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-bottom: 36px;
  max-width: 60ch;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tags li {
  border: 1px solid #c9c5b7;
  border-radius: var(--radius);
  padding: 11px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--primary);
  background: var(--white);
}

/* --------------------------------------------------------------------------
   12. Clientes
   -------------------------------------------------------------------------- */
.section--clients {
  background: var(--bg-strong);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
  padding: 80px 0;
}

.clients__title {
  font-size: 44px;
  line-height: 1.12;
  margin: 0 auto 48px;
  max-width: 30ch;
}

.client-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line-strong);
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  overflow: hidden;
}

.client-list li {
  background: #f6f5f0;
  padding: 38px 20px;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 24px;
  letter-spacing: 0.02em;
  color: var(--primary);
  display: grid;
  place-items: center;
}

.clients__note {
  font-size: 15px;
  color: var(--ink-muted);
  margin: 28px auto 0;
  max-width: 52ch;
}

/* --------------------------------------------------------------------------
   13. Contacto
   -------------------------------------------------------------------------- */
.section--contact {
  padding: 96px 0 88px;
}

.contacto__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: start;
}

.contacto__lead {
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-top: 22px;
  max-width: 42ch;
}

.contact-card {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  margin: 0;
}

.contact-card__item {
  background: var(--white);
  padding: 26px 28px;
}

.contact-card dt {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8a9089;
  margin-bottom: 8px;
}

.contact-card dd {
  font-size: 16.5px;
  line-height: 1.55;
  color: var(--ink);
  margin: 0;
}

.contact-card a {
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   14. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--primary-deep);
  color: #b9c2bb;
}

.site-footer__main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
  padding-top: 56px;
  padding-bottom: 56px;
}

.site-footer__brand {
  max-width: 34ch;
}

.site-footer__name {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 26px;
  color: var(--bg);
  letter-spacing: 0.02em;
}

.site-footer__name span {
  color: var(--accent-light);
}

.site-footer__tagline {
  font-size: 15px;
  line-height: 1.6;
  margin-top: 16px;
  color: #9aa79d;
  font-style: italic;
}

.site-footer__label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin-bottom: 14px;
}

.site-footer__contact {
  font-size: 14.5px;
  line-height: 1.7;
  color: #c4ccc5;
}

.site-footer__contact a {
  color: #c4ccc5;
}

.site-footer__contact a:hover {
  color: var(--accent-light);
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.site-footer__bottom-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 20px;
  padding-bottom: 20px;
  font-size: 13px;
  color: #7f8a82;
}

/* --------------------------------------------------------------------------
   15. Tipografías auto-alojadas
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../assets/fonts/manrope-variable.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../assets/fonts/spectral-300.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../assets/fonts/spectral-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('../assets/fonts/spectral-italic-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../assets/fonts/spectral-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../assets/fonts/spectral-600.woff2') format('woff2');
}

@font-face {
  font-family: 'Spectral';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../assets/fonts/spectral-700.woff2') format('woff2');
}

/* --------------------------------------------------------------------------
   16. Responsive
   -------------------------------------------------------------------------- */

/* ---- tablet ---- */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .value:nth-child(2) {
    border-right: none;
  }

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

  .value,
  .value:nth-child(2),
  .value:nth-child(3) {
    padding: 32px 0 8px;
  }

  .nosotros__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* ---- móvil ---- */
@media (max-width: 900px) {
  .container {
    padding-left: 24px;
    padding-right: 24px;
  }

  .section {
    padding: 72px 0;
  }

  .section--narrow {
    padding: 80px 0;
  }

  .section--clients {
    padding: 64px 0;
  }

  .section--contact {
    padding: 72px 0 64px;
  }

  .section-title,
  .section-title--dark {
    font-size: 38px;
  }

  /* Navegación móvil: panel desplegable */
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    transition: max-height 0.35s var(--ease), visibility 0.35s var(--ease);
  }

  .site-nav.is-open {
    max-height: 480px;
    visibility: visible;
  }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 0 24px;
  }

  .site-nav__list li + li {
    border-top: 1px solid var(--line-soft);
  }

  .site-nav__list a:not(.btn) {
    display: block;
    padding: 16px 0;
    font-size: 15px;
  }

  .site-nav__list .btn--nav {
    margin-top: 20px;
    text-align: center;
  }

  .hero__inner {
    padding-top: 84px;
    padding-bottom: 84px;
  }

  .hero__title {
    font-size: 52px;
  }

  .hero__lead {
    font-size: 18px;
  }

  .nosotros__grid {
    padding-top: 64px;
    padding-bottom: 64px;
  }

  .nosotros__grid .section-title {
    font-size: 38px;
  }

  .client-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .contacto__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .clients__title {
    font-size: 36px;
  }
}

/* ---- teléfono ---- */
@media (max-width: 560px) {
  .services-grid {
    grid-template-columns: 1fr;
  }

  .hero__title {
    font-size: 42px;
  }

  .hero__actions .btn {
    width: 100%;
  }

  .client-list {
    grid-template-columns: 1fr;
  }

  .client-list li {
    padding: 28px 20px;
  }

  .site-footer__bottom-inner {
    flex-direction: column;
    gap: 4px;
  }
}

/* --------------------------------------------------------------------------
   17. Movimiento reducido
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
