/* Cores e aparência geral. As regras @media adaptam o catálogo aos diferentes ecrãs. */
:root {
  color-scheme:light;
  --ink:#173d33;
  --paper:#f7f3ea;
  --muted:#58675f;
  --line:#d8d9cc;
  --accent:#a3783e;
}

* {
  box-sizing:border-box;
}

html {
  scroll-behavior:smooth;
  scroll-padding-top:24px;
}

body {
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font:16px/1.6 Arial,sans-serif;
}

a {
  color:inherit;
}

button,a {
  -webkit-tap-highlight-color:transparent;
}

button {
  font:inherit;
}

button:focus-visible,a:focus-visible {
  outline:3px solid #aa7433;
  outline-offset:4px;
}

.skip {
  position:absolute;
  top:-100px;
}

.skip:focus {
  top:10px;
  background:white;
  padding:12px;
  z-index:9;
}

.masthead,main,footer {
  max-width:1240px;
  margin:auto;
  padding-left:40px;
  padding-right:40px;
}

.masthead {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:20px;
  padding-top:20px;
  padding-bottom:18px;
  border-bottom:1px solid var(--line);
}

.brand {
  display:flex;
  gap:14px;
  align-items:center;
  text-decoration:none;
}

.brand img {
  object-fit:contain;
}

.brand strong {
  display:block;
  font-size:22px;
  letter-spacing:2px;
}

.brand small {
  display:block;
  font-size:12px;
  letter-spacing:1.7px;
}

.instagram {
  font-size:14px;
  text-underline-offset:5px;
}

.intro {
  display:flex;
  justify-content:space-between;
  gap:32px;
  padding:30px 0 22px;
}

.eyebrow {
  font-size:12px;
  letter-spacing:1.7px;
  font-weight:700;
  color:var(--accent);
  margin:0 0 12px;
}

h1,h2,h3 {
  font-family:Georgia,serif;
  font-weight:400;
  line-height:1.12;
  margin:0;
}

h1 {
  font-size:clamp(32px,4vw,48px);
  letter-spacing:-1.5px;
}

h1 em {
  font-weight:400;
}

.lead {
  color:var(--muted);
  margin:18px 0 0;
  max-width:550px;
}

.intro-note {
  min-width:195px;
  padding:8px 0 0 28px;
  border-left:1px solid var(--line);
  align-self:center;
}

.intro-note .number {
  font-size:12px;
  color:var(--accent);
  letter-spacing:3px;
}

.intro-note p {
  font:22px/1.45 Georgia,serif;
  margin:12px 0;
}

.categories {
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:8px;
  padding:15px 0 25px;
}

.category {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  padding:9px 8px;
  border-radius:9px;
  background:#fffdf9;
  text-decoration:none;
  border:1px solid var(--line);
  text-align:center;
  font-size:14px;
  transition:background .15s;
}

.category img {
  width:42px;
  height:42px;
  object-fit:contain;
  border-radius:6px;
}

.category:hover {
  background:#e8eadf;
}

.category[aria-current=true] {
  background:var(--ink);
  border-color:var(--ink);
  color:white;
}

.section-heading {
  display:flex;
  justify-content:space-between;
  align-items:end;
  gap:16px;
  padding:19px 0;
}

.section-heading h2 {
  font-size:34px;
}

.section-heading .eyebrow {
  margin-bottom:7px;
}

.count {
  font-size:14px;
  color:var(--muted);
  margin:0;
}

.price-note {
  display:flex;
  gap:20px;
  align-items:center;
  background:#e9ece1;
  padding:16px 20px;
  margin-bottom:25px;
  border-left:3px solid var(--accent);
  border-radius:0 9px 9px 0;
}

[hidden] {
  display:none!important;
}

.price-note strong {
  font-size:16px;
  max-width:250px;
  flex-shrink:0;
}

.price-note span {
  color:var(--muted);
  font-size:14px;
}

.grid {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:24px 20px;
}

.card {
  min-width:0;
  display:flex;
  flex-direction:column;
  background:#fffdf9;
  border:1px solid #e8e2d7;
  border-radius:12px;
  overflow:hidden;
  box-shadow:0 4px 16px #49321c06;
}

.card-copy {
  padding:17px;
  display:flex;
  flex-direction:column;
  flex:1;
}

.photo-button {
  position:relative;
  display:block;
  width:100%;
  padding:0;
  background:#f0ede6;
  border:0;
  cursor:pointer;
  aspect-ratio:1/1;
  overflow:hidden;
}

.photo-button img {
  display:block;
  width:100%;
  height:100%;
  object-fit:contain;
  transition:transform .2s;
}

.photo-button:hover img {
  filter:brightness(1.025);
}

.code {
  position:absolute;
  top:10px;
  left:10px;
  background:#fffdf9ed;
  color:var(--ink);
  border-radius:4px;
  font-size:12px;
  letter-spacing:.5px;
  padding:3px 8px;
}

.card h3 {
  font-size:21px;
  margin-top:0;
}

.card .description {
  font-size:14px;
  color:var(--muted);
  margin:9px 0 14px;
}

.card-bottom {
  display:flex;
  flex-direction:column;
  margin-top:auto;
  gap:8px;
  align-items:stretch;
}

.card-bottom span {
  font-size:12px;
  color:var(--muted);
}

.detail-button {
  border:1px solid #d8e0d9;
  border-radius:6px;
  padding:10px 8px;
  background:#edf2ec;
  cursor:pointer;
  color:var(--ink);
  font-size:14px;
}

.detail-button:hover {
  background:var(--ink);
  color:#fff;
}

.reference {
  font-size:12px;
  color:var(--muted);
  margin:30px 0 0;
  max-width:760px;
}

.order-note {
  margin:55px 0 45px;
  background:var(--ink);
  padding:38px;
  color:var(--paper);
  border-radius:14px;
}

.order-note .eyebrow {
  color:#dfbd84;
}

.order-note h2 {
  font-size:32px;
}

.order-note p:not(.eyebrow) {
  max-width:630px;
  color:#e3e8db;
}

.contact-button {
  display:inline-block;
  background:var(--ink);
  color:white;
  padding:13px 20px;
  text-decoration:none;
  font-size:14px;
  font-weight:bold;
  border:1px solid var(--ink);
  text-align:center;
  border-radius:6px;
}

.order-note .contact-button {
  background:var(--paper);
  color:var(--ink);
  margin-top:8px;
}

footer {
  display:flex;
  justify-content:space-between;
  gap:20px;
  flex-wrap:wrap;
  border-top:1px solid var(--line);
  padding-top:22px;
  padding-bottom:30px;
  font-size:12px;
  color:var(--muted);
}

footer strong {
  color:var(--ink);
  letter-spacing:1px;
}

dialog {
  padding:0;
  border:0;
  max-width:940px;
  width:calc(100% - 40px);
  max-height:90dvh;
  background:var(--paper);
  color:var(--ink);
  overflow:auto;
}

dialog::backdrop {
  background:#10251ec4;
  backdrop-filter:blur(4px);
}

.close {
  position:absolute;
  right:12px;
  top:10px;
  width:44px;
  height:44px;
  border:1px solid var(--line);
  border-radius:50%;
  background:var(--paper);
  color:var(--ink);
  font-size:28px;
  cursor:pointer;
  z-index:2;
}

.detail-layout {
  display:grid;
  grid-template-columns:1fr 1fr;
}

.detail-photo {
  background:#eae9df;
  display:flex;
  align-items:center;
  padding:25px;
}

.detail-photo img {
  width:100%;
  height:auto;
  max-height:70vh;
  object-fit:contain;
}

.detail-copy {
  padding:60px 32px 32px;
}

.detail-copy h2 {
  font-size:34px;
}

.detail-copy>p {
  color:var(--muted);
}

.detail-copy .quote {
  color:var(--ink);
  font-weight:bold;
  margin-top:25px;
}

.detail-instruction {
  font-size:14px;
}

.fine {
  font-size:12px;
}

.loading {
  grid-column:1/-1;
  padding:30px 0;
}

.error {
  grid-column:1/-1;
  padding:25px;
  background:white;
}

.error a {
  display:inline-block;
  margin-top:10px;
}

@media(min-width:1100px) {
  .card {
    display:flex;
    flex-direction:column;
  }

  .card-bottom {
    margin-top:auto;
  }

}

@media(max-width:900px) {
  .grid {
    grid-template-columns:repeat(3,minmax(0,1fr));
  }

  .intro-note {
    display:none;
  }

  .categories {
    grid-template-columns:repeat(3,1fr);
  }

  .masthead,main,footer {
    padding-left:25px;
    padding-right:25px;
  }

  .price-note {
    align-items:start;
  }

}

@media(max-width:600px) {
  .masthead,main,footer {
    padding-left:18px;
    padding-right:18px;
  }

  .masthead {
    padding-top:14px;
    padding-bottom:14px;
  }

  .brand img {
    width:48px;
    height:48px;
  }

  .brand {
    gap:8px;
  }

  .brand strong {
    font-size:17px;
    letter-spacing:1px;
  }

  .brand small {
    font-size:10px;
    letter-spacing:1px;
  }

  .instagram {
    font-size:12px;
    max-width:115px;
    overflow-wrap:anywhere;
  }

  .intro {
    padding:27px 0 15px;
  }

  .intro .eyebrow {
    font-size:11px;
    letter-spacing:1px;
  }

  h1 {
    font-size:35px;
    letter-spacing:-.8px;
  }

  .lead {
    font-size:15px;
    margin-top:13px;
  }

  .categories {
    display:flex;
    overflow-x:auto;
    scrollbar-width:thin;
    gap:6px;
    padding-top:15px;
    padding-bottom:10px;
  }

  .category {
    flex:0 0 auto;
    padding:7px 10px;
  }

  .category img {
    width:34px;
    height:34px;
  }

  .section-heading h2 {
    font-size:29px;
  }

  .price-note {
    display:block;
    padding:12px 15px;
    margin-bottom:20px;
  }

  .price-note strong {
    display:block;
    max-width:none;
    font-size:15px;
  }

  .price-note span {
    display:block;
    margin-top:5px;
    font-size:13px;
  }

  .grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:27px 14px;
  }

  .photo-button {
    padding:0;
  }

  .code {
    font-size:10px;
    top:7px;
    left:7px;
  }

  .card h3 {
    font-size:19px;
    line-height:1.2;
    margin-top:0;
  }

  .card-copy {
    padding:12px;
  }

  .card .description {
    font-size:14px;
    line-height:1.5;
  }

  .card-bottom {
    display:flex;
  }

  .card-bottom span {
    display:block;
  }

  .detail-button {
    min-height:42px;
  }

  .order-note {
    padding:25px;
    margin-top:36px;
  }

  .order-note h2 {
    font-size:28px;
  }

  .detail-layout {
    grid-template-columns:1fr;
  }

  .detail-photo {
    padding:30px;
  }

  .detail-photo img {
    max-height:35dvh;
  }

  .detail-copy {
    padding:23px;
  }

  .detail-copy h2 {
    font-size:28px;
  }

  .detail-copy .contact-button {
    width:100%;
  }

  dialog {
    width:calc(100% - 24px);
  }

  footer {
    gap:10px;
  }

  footer span {
    width:100%;
  }

}

@media(prefers-reduced-motion:reduce) {
  * {
    scroll-behavior:auto!important;
    transition:none!important;
  }

}

/* Imagens quadradas: preservar sempre o produto completo. */
.detail-photo { background:#f7f3ea; padding:12px; }
.detail-photo img { border-radius:8px; }
body:has(dialog[open]) { overflow:hidden; }
@media(max-width:600px) { .detail-photo { padding:12px; } }
