/* Cerrajería Iván · correcciones v5 */
:root {
  --header-height: 74px;
}

html {
  scroll-padding-top: calc(var(--header-height) + 24px);
}

section[id],
article[id] {
  scroll-margin-top: calc(var(--header-height) + 24px);
}

.header-layout {
  min-height: var(--header-height);
}

.brand {
  min-width: 0;
}

.brand__logo {
  width: 168px;
  max-height: 48px;
  object-fit: contain;
  object-position: left center;
}

.hero-grid {
  min-height: 540px;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
}

.hero-copy {
  min-width: 0;
  padding: 62px 48px 62px 0;
}

.hero-copy h1 {
  max-width: 540px;
  font-size: clamp(46px, 4.2vw, 66px);
  line-height: 1.01;
  letter-spacing: -.05em;
  text-wrap: pretty;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}

.hero-copy p {
  max-width: 520px;
}

.hero-media {
  min-height: 540px;
}

.hero-media::after {
  display: none !important;
  content: none !important;
}

.feature-grid {
  align-items: stretch;
}

.feature-card {
  height: 100%;
  display: grid;
  grid-template-rows: minmax(290px, auto) 230px;
}

.feature-card__content {
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  align-content: start;
  padding: 38px 38px 34px;
}

.feature-card__content .red-line {
  margin-bottom: 22px;
}

.feature-card h2 {
  min-height: 2.1em;
  margin-bottom: 18px;
}

.feature-card p {
  margin: 0;
  align-self: start;
}

.feature-card a {
  align-self: end;
  margin-top: 28px;
  padding-top: 0;
}

.photo-cylinder,
.photo-portal,
.photo-car {
  min-height: 230px;
  height: 230px;
}

.process {
  padding: 94px 0 0;
  color: var(--ink);
  background: #f1eee8;
}

.process::before {
  inset: 18px auto auto 62%;
  width: 300px;
  height: 300px;
  border-color: rgba(183,27,28,.12);
}

.process-heading {
  position: relative;
  z-index: 2;
  margin-bottom: 46px;
}

.process-heading .red-line {
  margin-bottom: 18px;
}

.process-heading h2 {
  max-width: 620px;
  color: var(--ink);
}

.process-heading p {
  max-width: 620px;
  margin-top: 16px;
  font-size: 1.02rem;
}

.process-grid {
  min-height: 0;
  background: transparent;
}

.process-step {
  min-height: 260px;
  padding: 38px 30px 42px;
  color: var(--ink);
  background: rgba(255,255,255,.72);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  transition: transform 260ms ease, background-color 260ms ease, box-shadow 260ms ease;
}

.process-step:last-child {
  border-right: 1px solid var(--line);
}

.process-step:hover {
  z-index: 2;
  transform: translateY(-10px);
  background: var(--white);
  box-shadow: 0 28px 70px rgba(17,17,17,.10);
}

.process-step > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  color: var(--red);
  font-size: 1.25rem;
  border: 1px solid rgba(183,27,28,.28);
  border-radius: 50%;
  transition: transform 260ms ease, color 260ms ease, background-color 260ms ease;
}

.process-step:hover > span {
  color: var(--white);
  background: var(--red);
  transform: rotate(-6deg) scale(1.05);
}

.process-step h2 {
  color: var(--ink);
  font-size: clamp(22px, 1.8vw, 28px);
}

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

.faq-items details {
  overflow: hidden;
}

.faq-answer {
  height: 0;
  overflow: hidden;
  opacity: 0;
}

.faq-answer p {
  margin: 0;
  padding: 0 0 28px;
}

.faq-items details[open] .faq-answer {
  opacity: 1;
}

.contact-brand {
  display: block;
}

.contact-brand__logo {
  width: min(280px, 100%);
  height: auto;
  margin-bottom: 24px;
}

.contact-brand h2,
.contact-brand > img + div {
  display: none;
}

@media (max-width: 1180px) {
  .brand__logo {
    width: 150px;
  }

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

  .hero-copy {
    padding-right: 0;
  }

  .hero-copy h1 {
    max-width: 720px;
  }

  .feature-card {
    grid-template-columns: 1fr .9fr;
    grid-template-rows: 1fr;
  }

  .photo-cylinder,
  .photo-portal,
  .photo-car {
    height: 100%;
    min-height: 100%;
  }
}

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

  .brand__logo {
    width: 138px;
    max-height: 42px;
  }

  .hero-copy h1 {
    font-size: clamp(44px, 8vw, 62px);
  }

  .process {
    padding-top: 76px;
  }

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

  .process-step:nth-child(3) {
    border-left: 0;
  }
}

@media (max-width: 640px) {
  .brand__logo {
    width: 126px;
  }

  .hero-copy {
    padding: 48px 22px;
  }

  .hero-copy h1 {
    max-width: none;
    font-size: clamp(40px, 12vw, 54px);
  }

  .feature-card {
    grid-template-columns: 1fr;
    grid-template-rows: auto 220px;
  }

  .feature-card h2 {
    min-height: 0;
  }

  .photo-cylinder,
  .photo-portal,
  .photo-car {
    min-height: 220px;
    height: 220px;
  }

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

  .process-step,
  .process-step:nth-child(3),
  .process-step:last-child {
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }
}
