:root {
  --ink: #17202a;
  --muted: #5f6c78;
  --line: #dfe6eb;
  --page: #f7faf9;
  --panel: #ffffff;
  --green: #1f7a5a;
  --green-dark: #14533d;
  --gold: #f4b942;
  --blue: #4a8fbb;
  --pink: #df7c91;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
}

.site-header {
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  padding: 16px clamp(18px, 4vw, 48px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  color: var(--green-dark);
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  justify-content: flex-end;
}

nav span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  padding: 0;
}

main {
  margin: 0 auto;
  max-width: 1180px;
  padding: 0 clamp(18px, 4vw, 48px) 48px;
}

.hero {
  align-items: center;
  display: grid;
  gap: 32px;
  grid-template-columns: minmax(0, 1fr) 220px;
  min-height: 380px;
  padding: 50px 0 34px;
}

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

h1 {
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.02;
  margin: 0;
  max-width: 780px;
}

.lead {
  color: var(--muted);
  font-size: 18px;
  margin: 22px 0 0;
  max-width: 640px;
}

.hero-visual {
  align-items: center;
  aspect-ratio: 1;
  background:
    radial-gradient(circle at 62% 28%, #ffffff 0 10%, transparent 11%),
    linear-gradient(135deg, var(--green), var(--gold));
  border: 1px solid rgba(20, 83, 61, 0.18);
  border-radius: 8px;
  box-shadow: 0 20px 45px rgba(23, 32, 42, 0.13);
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 180px;
}

.hero-visual span {
  font-size: 86px;
  font-weight: 900;
  line-height: 0.9;
}

.hero-visual small {
  font-size: 24px;
  font-weight: 800;
}

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

.product-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  grid-template-rows: 220px minmax(0, 1fr);
  overflow: hidden;
}

.product-art {
  background-color: #fff;
  background-image: url("assets/products-sprite.png");
  background-repeat: no-repeat;
  background-size: 300% 200%;
  border-bottom: 1px solid var(--line);
  min-height: 220px;
  position: relative;
}

.product-copy {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 20px;
}

.product-copy h2 {
  font-size: 21px;
  margin: 0;
}

.product-copy p {
  color: var(--muted);
  margin: 0;
  min-height: 72px;
}

.product-copy strong,
.price {
  color: var(--green-dark);
  display: block;
  font-size: 24px;
  font-weight: 900;
}

.product-link,
.subscribe-form button {
  align-items: center;
  background: var(--green);
  border: 0;
  border-radius: 6px;
  color: white;
  cursor: pointer;
  display: inline-flex;
  font-size: 14px;
  font-weight: 800;
  justify-content: center;
  margin-top: auto;
  min-height: 42px;
  padding: 0 16px;
  text-decoration: none;
  width: fit-content;
}

.product-link:hover,
.product-link:focus,
.subscribe-form button:hover,
.subscribe-form button:focus {
  background: var(--green-dark);
}

.egg-art {
  background-position: 0 0;
}

.tissue-art {
  background-position: 50% 0;
}

.rice-art {
  background-position: 100% 0;
}

.milk-art {
  background-position: 0 100%;
}

.dish-art {
  background-position: 50% 100%;
}

.laundry-art {
  background-position: 100% 100%;
}

.product-detail {
  align-items: stretch;
  display: grid;
  gap: 32px;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  padding-top: 48px;
}

.detail-art {
  background-color: #fff;
  background-image: url("assets/products-sprite.png");
  background-repeat: no-repeat;
  background-size: 300% 200%;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 430px;
}

.detail-copy {
  align-self: center;
}

.inline-detail {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-top: 28px;
  padding: 22px;
}

.inline-detail[hidden] {
  display: none;
}

.same-page-details {
  margin-top: 28px;
}

.same-page-detail {
  display: none;
  padding-top: 22px;
  scroll-margin-top: 86px;
}

.same-page-detail:target {
  display: grid;
}

.detail-copy h1 {
  font-size: clamp(34px, 5vw, 58px);
}

.details {
  color: var(--muted);
  font-size: 17px;
  margin: 18px 0 22px;
}

.subscribe-form {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-top: 18px;
  max-width: 560px;
  padding-top: 18px;
}

.subscribe-form label {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  grid-column: 1 / -1;
}

.subscribe-form input {
  background: #fff;
  border: 1px solid #bdc9d1;
  border-radius: 6px;
  color: var(--ink);
  font: inherit;
  min-height: 46px;
  min-width: 0;
  padding: 0 14px;
}

.form-message {
  color: var(--green-dark);
  font-size: 14px;
  font-weight: 700;
  grid-column: 1 / -1;
  min-height: 20px;
}

.compact-form {
  grid-template-columns: 1fr;
  margin-top: 8px;
  padding-top: 14px;
}

.compact-form button {
  width: 100%;
}

.text-button {
  background: transparent;
  border: 0;
  color: var(--green-dark);
  cursor: pointer;
  display: inline-block;
  font: inherit;
  font-weight: 800;
  margin-top: 18px;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
  padding: 22px clamp(18px, 4vw, 48px);
  text-align: center;
}

@media (max-width: 900px) {
  .hero,
  .product-detail {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    max-width: 240px;
  }

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

}

@media (max-width: 640px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    justify-content: flex-start;
  }

  .hero {
    min-height: auto;
    padding-top: 34px;
  }

  .product-grid,
  .subscribe-form {
    grid-template-columns: 1fr;
  }

  .product-card {
    grid-template-rows: 190px minmax(0, 1fr);
  }

  .product-art {
    min-height: 190px;
  }

  .subscribe-form button {
    width: 100%;
  }
}
