.project {
  padding-block: 3.2rem 2rem;
}

/* ============ topo: galeria + painel ============ */

.project__top {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: start;
}

/* ---- galeria ---- */

.gallery__main {
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
}

.gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery__thumbs {
  margin-top: 1.2rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 1.2rem;
}

.gallery__thumb {
  padding: 0;
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 4 / 3;
  transition: border-color 0.2s var(--ease), opacity 0.2s var(--ease);
  opacity: 0.7;
}

.gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery__thumb:hover {
  opacity: 1;
}

.gallery__thumb.is-active {
  border-color: var(--ink);
  opacity: 1;
}

/* ---- painel de compra ---- */

.buy-panel {
  position: sticky;
  top: calc(var(--header-h) + 2rem);
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 3.2rem;
}

.buy-panel h1 {
  font-size: 2.8rem;
  margin-block: 1.2rem 0.8rem;
}

.buy-panel__code {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--clay);
}

/* ---- ficha técnica ---- */

.spec-table {
  width: 100%;
  margin-top: 2.4rem;
  border-top: 1px solid var(--line);
  border-collapse: collapse;
}

.spec-table tr {
  border-bottom: 1px solid var(--line-soft);
}

.spec-table th,
.spec-table td {
  padding-block: 1.1rem;
  font-size: 1.4rem;
  text-align: left;
}

.spec-table th {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--stone);
}

.spec-table td {
  text-align: right;
  color: var(--ink);
  font-weight: 500;
}

/* ---- etiquetas de características ---- */

.feature-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.feature-tags li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.25rem;
  color: var(--graphite);
  background-color: var(--bone);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.6rem 1rem;
}

.feature-tags i {
  color: var(--clay);
  font-size: 1.2rem;
}

/* ---- opções de compra ---- */

.buy-option {
  border: none;
  margin-top: 3.2rem;
  padding-top: 2.4rem;
  border-top: 1px solid var(--line);
}

.buy-option__hint {
  font-size: 1.25rem;
  color: var(--stone);
  line-height: 1.6;
  margin-bottom: 1.4rem;
}

.buy-radio {
  display: flex;
  align-items: flex-start;
  gap: 1.2rem;
  padding: 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  margin-bottom: 0.8rem;
  transition: border-color 0.2s var(--ease);
}

.buy-radio:hover {
  border-color: var(--stone);
}

.buy-radio input {
  margin-top: 0.3rem;
  accent-color: var(--clay);
  width: 1.6rem;
  height: 1.6rem;
  cursor: pointer;
  flex-shrink: 0;
}

.buy-radio:has(input:checked) {
  border-color: var(--ink);
  background-color: var(--bone);
}

.buy-radio span {
  display: flex;
  flex-direction: column;
}

.buy-radio strong {
  font-size: 1.45rem;
  color: var(--ink);
  font-weight: 500;
}

.buy-radio small {
  font-size: 1.2rem;
  color: var(--stone);
}

.buy-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 1.2rem;
  padding: 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  margin-bottom: 0.8rem;
  transition: border-color 0.2s var(--ease);
}

.buy-item:hover {
  border-color: var(--stone);
}

.buy-item:has(input:checked) {
  border-color: var(--ink);
}

.buy-item.is-required {
  background-color: var(--bone);
  cursor: default;
}

.buy-item input {
  margin-top: 0.3rem;
  accent-color: var(--clay);
  width: 1.6rem;
  height: 1.6rem;
  cursor: pointer;
}

.buy-item__text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.buy-item__text strong {
  font-size: 1.45rem;
  color: var(--ink);
  font-weight: 500;
}

.buy-item__text small {
  font-size: 1.2rem;
  color: var(--stone);
  line-height: 1.5;
}

.buy-item__price {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

/* ---- total e garantias ---- */

.buy-panel__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.6rem;
  padding-block: 2.4rem;
  margin-top: 1.6rem;
  border-top: 1px solid var(--line);
}

.buy-panel__total strong {
  font-family: var(--font-display);
  font-size: 3.2rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1;
}

.buy-panel__adapt {
  margin-top: 2.4rem;
  padding-top: 2.4rem;
  border-top: 1px solid var(--line);
  font-size: 1.35rem;
  color: var(--stone);
  line-height: 1.7;
}

.buy-panel__adapt a {
  color: var(--clay);
}

/* ============ seções inferiores ============ */

.project__section {
  padding-block: 6.4rem;
  border-top: 1px solid var(--line);
  margin-top: 6.4rem;
}

.project__section .eyebrow {
  display: block;
  margin-bottom: 1.6rem;
}

.project__section .section-title {
  margin-bottom: 4rem;
}

.project__about {
  max-width: 76ch;
  font-size: 1.65rem;
  line-height: 1.8;
  color: var(--graphite);
}

/* ============ responsivo ============ */

@media (max-width: 1100px) {
  .project__top {
    grid-template-columns: 1fr;
  }

  .buy-panel {
    position: static;
  }
}

@media (max-width: 767px) {
  .project {
    padding-block: 2rem;
  }

  .project__top {
    gap: 2.4rem;
  }

  .buy-panel {
    padding: 2.4rem 2rem;
  }

  .buy-panel h1 {
    font-size: 2.2rem;
  }

  .buy-panel__total strong {
    font-size: 2.6rem;
  }

  .project__section {
    padding-block: 4rem;
    margin-top: 4rem;
  }

  .project__section .section-title {
    margin-bottom: 2.4rem;
  }
}
