/*
Theme Name: Atelier Storefront
Theme URI: https://example.test/atelier-storefront
Author: Atelier Commerce
Description: Configurable boutique cross-border storefront preview.
Version: 0.1.0
Requires at least: 7.0
Requires PHP: 8.3
Text Domain: atelier-storefront
*/

:root {
  --atelier-paper: #f7f3ec;
  --atelier-ink: #171411;
  --atelier-line: #d7cfc3;
  --atelier-forest: #214f3b;
  --atelier-seal: #a52a24;
  --atelier-blue: #164f9f;
}

body.atelier-storefront {
  margin: 0;
  background: var(--atelier-paper);
  color: var(--atelier-ink);
  font-family: Inter, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

.storefront-template {
  min-height: 100vh;
}

.storefront-hero {
  position: relative;
  min-height: 78vh;
  display: grid;
  align-items: end;
  overflow: hidden;
  background: var(--atelier-ink);
}

.storefront-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.82;
}

.storefront-hero div {
  position: relative;
  max-width: 920px;
  padding: 0 6vw 8vh;
  color: #fff;
  text-shadow: 0 2px 18px rgb(0 0 0 / 44%);
}

.storefront-hero p {
  margin: 0 0 10px;
  font-size: 14px;
}

.storefront-hero h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(46px, 8vw, 112px);
  line-height: 0.92;
}

.storefront-hero span {
  display: block;
  max-width: 560px;
  margin-top: 18px;
  font-size: 18px;
  line-height: 1.6;
}

.storefront-chrome {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 6vw;
}

.storefront-chrome strong {
  font-size: 15px;
  letter-spacing: 0;
}

.storefront-chrome nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.storefront-chrome a,
.storefront-product a,
.storefront-catalog-link a,
.storefront-product-missing a {
  color: inherit;
}

.storefront-products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  grid-column: 1 / -1;
  width: 100%;
  margin-top: 28px;
}

.storefront-product {
  display: flex;
  min-width: 0;
  flex-direction: column;
  background: #fffdfa;
  border: 1px solid var(--atelier-line);
}

.storefront-product__image {
  display: grid;
  min-height: 240px;
  place-items: center;
  overflow: hidden;
  background: #e7e1d8;
  color: var(--atelier-forest);
  text-decoration: none;
}

.storefront-product__image img {
  width: 100%;
  height: 100%;
  min-height: 240px;
  object-fit: cover;
}

.storefront-product__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 18px;
}

.storefront-product__eyebrow,
.storefront-catalog-page > p {
  margin: 0 0 8px;
  color: var(--atelier-seal);
  font-size: 12px;
}

.storefront-product h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
}

.storefront-product h3 a {
  text-decoration: none;
}

.storefront-product__meta {
  display: grid;
  gap: 5px;
  margin-top: 18px;
  font-size: 13px;
}

.storefront-product__meta strong {
  color: var(--atelier-forest);
  font-size: 16px;
}

.storefront-product__description {
  margin: 14px 0 0;
  color: #4e463f;
  font-size: 14px;
  line-height: 1.6;
}

.storefront-product__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: auto 0 0;
  padding-top: 18px;
}

.storefront-product__actions a {
  border-bottom: 1px solid currentcolor;
  font-size: 14px;
  text-decoration: none;
}

.storefront-product__actions [data-rfq-locked] {
  cursor: not-allowed;
  opacity: 0.5;
  pointer-events: none;
}

.storefront-catalog-link {
  grid-column: 1 / -1;
  margin: 2px 0 0;
}

.storefront-rfq {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(220px, 0.8fr) minmax(320px, 1.2fr);
  gap: 28px;
  width: 100%;
  margin-top: 34px;
  padding: 28px;
  background: #fffdfa;
  border: 1px solid var(--atelier-line);
  box-shadow: 0 18px 54px rgb(23 20 17 / 8%);
}

.storefront-rfq__copy h3 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 46px);
}

.storefront-rfq__copy p:last-child,
.storefront-rfq__status {
  color: #4e463f;
  line-height: 1.7;
}

.storefront-rfq__form,
.storefront-rfq__fields {
  display: grid;
  gap: 14px;
}

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

.storefront-rfq [data-rfq-lines] {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.storefront-rfq label {
  display: grid;
  gap: 7px;
  color: #514941;
  font-size: 13px;
}

.storefront-rfq input,
.storefront-rfq select,
.storefront-rfq textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 13px;
  background: #f7f3ec;
  border: 1px solid var(--atelier-line);
  border-radius: 0;
  color: var(--atelier-ink);
  font: inherit;
}

.storefront-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--atelier-line);
  font-size: 14px;
}

.storefront-pagination div {
  display: flex;
  gap: 18px;
}

.storefront-pagination a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.storefront-rfq__consent {
  display: flex !important;
  align-items: center;
  gap: 9px !important;
  width: fit-content;
}

.storefront-rfq__consent input {
  width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--atelier-ink);
}

.storefront-rfq button {
  justify-self: start;
  padding: 12px 20px;
  background: var(--atelier-ink);
  border: 1px solid var(--atelier-ink);
  color: #fffdfa;
  cursor: pointer;
  font: inherit;
}

.storefront-rfq__status {
  margin: 0;
  font-size: 13px;
}

.storefront-catalog-page,
.storefront-product-missing {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 6vw;
}

.storefront-catalog-page h1,
.storefront-product-missing h1 {
  margin: 0;
  font-size: 44px;
}

.storefront-product-detail {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 0.8fr);
  max-width: 1180px;
  min-height: 64vh;
  margin: 0 auto;
  background: #fffdfa;
}

.storefront-product-detail > img {
  width: 100%;
  min-height: 460px;
  height: 100%;
  object-fit: cover;
  background: #e7e1d8;
}

.storefront-product-detail__body {
  padding: 8vw 6vw;
}

.storefront-product-detail h1 {
  margin: 0;
  font-size: 42px;
  line-height: 1.05;
}

.storefront-product-detail__description {
  color: #4e463f;
  line-height: 1.7;
}

.slot-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--atelier-line);
}

.slot-grid,
.slot-band,
.slot-editorial,
.trade-row {
  padding: 42px 6vw;
}

.slot-grid h2,
.slot-band h2,
.slot-editorial h2,
.trade-row h2 {
  margin: 0 0 10px;
  font-size: 26px;
}

.slot-grid p,
.slot-band p,
.slot-editorial p,
.trade-row p {
  max-width: 620px;
  margin: 0;
  color: #4e463f;
  line-height: 1.7;
}

.slot-band {
  border-top: 1px solid var(--atelier-line);
}

.storefront-template--issue {
  background: #14120f;
  color: #f7f3ec;
}

.storefront-template--issue .slot-editorial {
  display: grid;
  grid-template-columns: 120px minmax(220px, 0.8fr) minmax(260px, 1fr);
  gap: 28px;
  border-top: 1px solid #39332d;
}

.storefront-template--issue .slot-editorial p {
  color: #d6cec1;
}

.storefront-template--issue .storefront-product,
.storefront-template--issue .storefront-product-detail {
  background: #211d19;
  border-color: #4b4239;
}

.storefront-template--issue .storefront-product__description,
.storefront-template--issue .storefront-product-detail__description {
  color: #d6cec1;
}

.storefront-template--trade {
  background: #f8f6f0;
}

.trade-board {
  max-width: 1160px;
  margin: 0 auto;
  padding: 28px 24px 56px;
}

.trade-row {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  border-bottom: 1px solid var(--atelier-line);
}

.storefront-template--trade .storefront-products {
  grid-column: 1 / -1;
}

@media (max-width: 760px) {
  .storefront-hero {
    min-height: 72vh;
  }

  .storefront-hero div {
    padding: 0 22px 54px;
  }

  .storefront-hero h1 {
    font-size: 48px;
  }

  .slot-grid,
  .storefront-template--issue .slot-editorial,
  .trade-row {
    grid-template-columns: 1fr;
  }

  .slot-grid,
  .slot-band,
  .slot-editorial,
  .trade-row {
    padding: 28px 22px;
  }

  .storefront-chrome {
    align-items: flex-start;
    flex-direction: column;
    padding: 18px 22px;
  }

  .storefront-products,
  .storefront-product-detail,
  .storefront-rfq,
  .storefront-rfq__fields,
  .storefront-rfq [data-rfq-lines] {
    grid-template-columns: 1fr;
  }

  .storefront-product-detail > img {
    min-height: 300px;
  }

  .storefront-catalog-page,
  .storefront-product-missing {
    padding: 42px 22px;
  }
}
