/* --------------- Refurbishment Services Page --------------- */

body.page-refurbishment {
  color: var(--brand);
  background: #f6f8fb;
}

.refurb-main {
  background: #f6f8fb;
  color: var(--brand);
}

.refurb-icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.refurb-hero {
  position: relative;
  padding: clamp(2rem, 6vw, 3.5rem) 0;
  color: #fff;
  background: #101a2d;
  overflow: hidden;
  isolation: isolate;
}

.refurb-hero .hero-bg {
  object-position: center 35%;
}

.refurb-hero .hero__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(105deg, rgba(10, 18, 32, 0.66), rgba(10, 18, 32, 0.2)),
    linear-gradient(180deg, rgba(9, 20, 46, 0.08), rgba(9, 20, 46, 0.16));
}

.refurb-hero__content {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.65rem;
}

.refurb-hero .eyebrow {
  color: rgba(255, 255, 255, 0.9);
}

.refurb-hero .eyebrow::before {
  background: currentColor;
}

.refurb-hero__title {
  margin: 0;
  color: #fff;
  font-size: clamp(1.8rem, 2vw + 1rem, 2.6rem);
  line-height: 1.2;
}

.refurb-overview,
.refurb-services,
.refurb-faq,
.refurbishment-form {
  padding: clamp(2.25rem, 6vw, 4rem) 0;
}

.refurb-overview {
  background: #fff;
}

.refurb-overview__grid {
  display: grid;
  gap: clamp(1.25rem, 4vw, 2rem);
  align-items: start;
}

.refurb-overview__copy {
  display: grid;
  gap: 0.75rem;
  max-width: 780px;
}

.refurb-overview__copy p {
  margin: 0;
  color: var(--muted);
}

.refurb-contact {
  display: grid;
  gap: 0.85rem;
  padding: 1.1rem;
  border: 1px solid #dde7f2;
  border-radius: 0.5rem;
  background: linear-gradient(135deg, #f8fbff, #eef8f2);
  box-shadow: var(--shadow-sm);
}

.refurb-contact h2 {
  margin: 0;
  color: #10203a;
  font-size: 1.2rem;
}

.refurb-contact p {
  margin: 0;
  color: var(--muted);
}

.refurb-contact__links {
  display: grid;
  gap: 0.75rem;
}

.refurb-contact__links a {
  position: relative;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 0.7rem;
  row-gap: 0.12rem;
  align-items: center;
  min-height: 56px;
  padding: 0.55rem 0.85rem;
  border-radius: 0.5rem;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 52%), #192945;
  color: #fff;
  text-decoration: none;
  border: 1px solid rgba(25, 41, 69, 0.18);
  box-shadow: 0 12px 26px rgba(25, 41, 69, 0.16);
  overflow: hidden;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease,
    background-color 0.2s ease;
}

.refurb-contact__links a::before,
.refurb-contact__links a::after {
  content: "";
  display: block;
}

.refurb-contact__links a::before {
  grid-column: 1;
  grid-row: 1 / span 2;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background-color: rgba(255, 255, 255, 0.92);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 22px 22px;
}

.refurb-contact__links a[href^="tel"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23192945' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2A19.8 19.8 0 0 1 12 19a19.51 19.51 0 0 1-7-7 19.8 19.8 0 0 1-2.92-7A2 2 0 0 1 4.11 2h3A2 2 0 0 1 9 3.72L9.7 6a2 2 0 0 1-.45 2.11L7.91 9.46a16 16 0 0 0 6.63 6.63l1.35-1.34A2 2 0 0 1 18 14.91l2.28.7A2 2 0 0 1 22 16.92Z'/%3E%3C/svg%3E");
}

.refurb-contact__links a[href^="mailto"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23192945' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3 7 9 6 9-6'/%3E%3C/svg%3E");
}

.refurb-contact__links a[href="#refurbishment-form"]::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23192945' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z'/%3E%3Cpath d='M14 2v4a2 2 0 0 0 2 2h4'/%3E%3Cpath d='M8 13h8'/%3E%3Cpath d='M8 17h5'/%3E%3C/svg%3E");
}

.refurb-contact__links a::after {
  grid-column: 3;
  grid-row: 1 / span 2;
  width: 18px;
  height: 18px;
  background: currentColor;
  opacity: 0.72;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h14m-6-6 6 6-6 6' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h14m-6-6 6 6-6 6' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center/contain no-repeat;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}

.refurb-contact__links a:hover,
.refurb-contact__links a:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(25, 41, 69, 0.32);
  box-shadow:
    0 18px 34px rgba(25, 41, 69, 0.22),
    0 0 0 3px rgba(44, 62, 80, 0.26);
  outline: none;
}

.refurb-contact__links a:hover::after,
.refurb-contact__links a:focus-visible::after {
  transform: translateX(4px);
  opacity: 1;
}

.refurb-contact__links span {
  grid-column: 2;
  grid-row: 1;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.refurb-contact__links strong {
  grid-column: 2;
  grid-row: 2;
  color: #fff;
  font-size: 0.98rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.refurb-contact__links small {
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.78em;
  font-weight: 700;
  white-space: nowrap;
}

@media (min-width: 860px) {
  .refurb-overview__grid {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
  }
}

.refurb-services {
  background: linear-gradient(180deg, #f6f8fb 0%, #eef4f9 100%);
}

.refurb-services__head {
  max-width: 820px;
}

.service-group {
  display: grid;
  gap: 1rem;
  margin-top: clamp(1.4rem, 4vw, 2rem);
}

.service-group + .service-group {
  margin-top: clamp(2rem, 6vw, 3rem);
}

.service-group__header {
  display: grid;
  gap: 0.25rem;
}

.service-group__header h3 {
  margin: 0;
  color: #10203a;
  font-size: clamp(1.25rem, 1.3vw + 1rem, 1.75rem);
}

.service-group__header p {
  margin: 0;
  color: var(--muted);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 0.9rem;
}

.service-card {
  min-height: 218px;
  border-radius: 0.5rem;
  cursor: pointer;
  perspective: 1100px;
  outline: none;
}

.service-card:focus-visible {
  box-shadow: var(--ring);
}

.service-card__inner {
  position: relative;
  min-height: 218px;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.58s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.service-card.is-flipped .service-card__inner {
  transform: rotateY(180deg);
}

@media (hover: hover) and (pointer: fine) {
  .service-card:hover .service-card__inner {
    transform: rotateY(180deg);
  }
}

.service-card__face {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: center;
  gap: 0.8rem;
  padding: 1.05rem;
  border-radius: 0.5rem;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border: 1px solid #dce6f1;
  box-shadow: var(--shadow-sm);
}

.service-card__face--front {
  justify-items: center;
  text-align: center;
  background: #fff;
}

.service-card__face--back {
  align-content: center;
  justify-items: center;
  text-align: center;
  transform: rotateY(180deg);
  background:
    linear-gradient(145deg, rgba(159, 231, 193, 0.14), transparent 48%), #192945;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.14);
}

.service-icon {
  display: inline-flex;
  width: 92px;
  height: 92px;
  align-items: center;
  justify-content: center;
  color: #192945;
}

.service-icon svg {
  width: 76px;
  height: 76px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.45;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-icon--solid svg {
  width: 66px;
  height: 66px;
  fill: currentColor;
  stroke: none;
}

.service-card h4 {
  margin: 0;
  color: #10203a;
  font-size: 1.05rem;
  line-height: 1.25;
}

.service-card__face--back h4 {
  color: #fff;
}

.service-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.95rem;
}

.refurb-faq {
  background: #fff;
}

.refurb-faq__grid {
  display: grid;
  gap: clamp(1.2rem, 4vw, 2rem);
  align-items: start;
}

.refurb-faq__intro {
  display: grid;
  gap: 0.45rem;
}

.refurb-faq__items {
  display: grid;
  gap: 0.75rem;
}

.refurb-faq details {
  border: 1px solid #dce6f1;
  border-radius: 0.5rem;
  background: #f8fbff;
  box-shadow: var(--shadow-sm);
}

.refurb-faq summary {
  cursor: pointer;
  padding: 0.95rem 1rem;
  color: #10203a;
  font-weight: 800;
}

.refurb-faq summary:focus-visible {
  outline: 3px solid rgba(79, 126, 247, 0.3);
  outline-offset: 3px;
}

.refurb-faq details[open] summary {
  border-bottom: 1px solid #dce6f1;
}

.refurb-faq details p {
  margin: 0;
  padding: 0.95rem 1rem 1rem;
  color: var(--muted);
}

@media (min-width: 900px) {
  .refurb-faq__grid {
    grid-template-columns: minmax(260px, 0.42fr) minmax(0, 0.58fr);
  }
}

.refurbishment-form {
  background: #f6f8fb;
}

.page-refurbishment .brochure-form__card {
  border-radius: 0.5rem;
}

.page-refurbishment .refurb-form-row {
  display: grid;
  grid-column: 1 / -1;
  gap: 1rem;
}

.page-refurbishment .refurb-form-row .form-field {
  min-width: 0;
}

.page-refurbishment .submit-row .btn {
  width: 100%;
  white-space: normal;
}

.page-refurbishment .turnstile {
  max-width: 100%;
}

@media (min-width: 720px) {
  .page-refurbishment .refurb-form-row--intro {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .page-refurbishment .refurb-form-row--person,
  .page-refurbishment .refurb-form-row--contact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .page-refurbishment .refurb-form-row--serial {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .service-icon {
    width: 80px;
    height: 80px;
  }

  .service-icon svg {
    width: 66px;
    height: 66px;
  }

  .service-icon--solid svg {
    width: 58px;
    height: 58px;
  }

  .service-card,
  .service-card__inner {
    min-height: 208px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .service-card,
  .service-card__inner,
  .service-card__face {
    transition: none;
  }

  .service-card__inner,
  .service-card.is-flipped .service-card__inner {
    transform: none;
  }

  .service-card__face {
    position: relative;
    inset: auto;
    backface-visibility: visible;
  }

  .service-card__face--back {
    display: none;
    margin-top: 0.65rem;
    transform: none;
  }

  .service-card.is-flipped .service-card__face--back {
    display: grid;
  }

  @media (hover: hover) and (pointer: fine) {
    .service-card:hover .service-card__face--back {
      display: grid;
    }
  }
}
