/* ===========================================================
   Mandakaru Wear — Landing Page
   Conceito: folheto de cordel / xilogravura nordestina
   =========================================================== */

:root {
  --sand:      #EDE3CE;
  --sand-dark: #E4D6B8;
  --ink:       #241B15;
  --terra:     #C1512E;
  --terra-dk:  #9E3F23;
  --green:     #5C7A4E;
  --blue:      #25465A;
  --sun:       #E5A430;
  --cream-card:#FBF6EA;

  --display: "Fraunces", ui-serif, Georgia, serif;
  --body: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

  --radius: 2px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: var(--body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 28px;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* Subtle paper grain overlay */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  opacity: 0.05;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Eyebrow / labels (cordel "folha" numbering) ---------- */
.eyebrow {
  display: inline-block;
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terra-dk);
  border-bottom: 2px solid var(--terra);
  padding-bottom: 6px;
  margin-bottom: 22px;
}
.eyebrow-light {
  color: var(--sun);
  border-bottom-color: var(--sun);
}

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 10;
  padding: 22px 0;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.logo {
  height: 46px;
  width: auto;
  display: block;
}
.header-tag {
  margin: 0;
  padding: 0;
  border: none;
  font-size: 12px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 40px 0 90px;
  overflow: hidden;
}

.hero-sun {
  position: absolute;
  top: -120px;
  right: -140px;
  width: 480px;
  height: 480px;
  z-index: 0;
  opacity: 0.9;
}
.sun-svg { width: 100%; height: 100%; }
.sun-rays {
  transform-origin: 200px 200px;
  animation: spin 90s linear infinite;
}
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .sun-rays { animation: none; }
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 56px;
}
.hero-copy { flex: 1 1 460px; }
.hero-image { flex: 1 1 420px; }

.hero-title {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(42px, 6vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.01em;
  margin: 0 0 22px;
  color: var(--ink);
}
.hero-title em {
  font-style: italic;
  font-weight: 600;
  color: var(--terra);
}

.hero-sub {
  font-size: 18px;
  line-height: 1.6;
  max-width: 46ch;
  color: #4a3f34;
  margin: 0 0 32px;
}

.waitlist-form {
  display: flex;
  gap: 0;
  max-width: 460px;
  border: 2.5px solid var(--ink);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--cream-card);
}
.waitlist-form input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 16px 18px;
  font-family: var(--body);
  font-size: 15.5px;
  color: var(--ink);
  outline: none;
  min-width: 0;
}
.waitlist-form input::placeholder { color: #8a7d6c; }
.waitlist-form button {
  border: none;
  background: var(--terra);
  color: var(--cream-card);
  font-family: var(--body);
  font-weight: 700;
  font-size: 15px;
  padding: 16px 24px;
  cursor: pointer;
  transition: background 0.15s ease;
  white-space: nowrap;
}
.waitlist-form button:hover { background: var(--terra-dk); }
.waitlist-form button:focus-visible,
.waitlist-form input:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: -3px;
}

.form-note {
  font-family: var(--mono);
  font-size: 12.5px;
  color: #6b6053;
  margin: 12px 0 0;
  max-width: 46ch;
}
.form-note-dark { color: #d9c9ae; }

.hero-image {
  position: relative;
}
.hero-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  border: 3px solid var(--ink);
}
.tag-badge {
  position: absolute;
  bottom: -16px;
  left: -16px;
  background: var(--blue);
  color: var(--sand);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 9px 14px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
}

/* ---------- About ---------- */
.about { padding: 30px 0 90px; }
.about-grid {
  display: flex;
  flex-wrap: wrap;
  border: 3px solid var(--ink);
  border-radius: var(--radius);
  overflow: hidden;
}
.about-grid .about-block { flex: 1 1 420px; }
.about-block { padding: 56px 48px; }
.block-terra {
  background: var(--terra);
  color: var(--cream-card);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.block-terra h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(28px, 3.2vw, 38px);
  line-height: 1.12;
  margin: 0 0 18px;
}
.block-terra p {
  font-size: 16.5px;
  line-height: 1.65;
  color: #fbeadf;
  margin: 0;
  max-width: 42ch;
}
.block-photo { padding: 0; }
.block-photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  min-height: 340px;
}

/* ---------- Estampas ---------- */
.estampas { padding: 20px 0 100px; }
.section-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(30px, 3.6vw, 42px);
  margin: 0 0 48px;
  max-width: 20ch;
}
.estampas-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
}
.estampa-card { flex: 1 1 280px; }
.estampa-card {
  background: var(--cream-card);
  border: 2.5px solid var(--ink);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease;
}
.estampa-card:hover { transform: translateY(-4px); }
.estampa-img {
  aspect-ratio: 4/5;
  overflow: hidden;
  border-bottom: 2.5px solid var(--ink);
}
.estampa-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.estampa-card h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 21px;
  margin: 20px 22px 8px;
}
.estampa-card p {
  font-size: 14.5px;
  color: #5a5044;
  line-height: 1.55;
  margin: 0 22px 22px;
}

/* ---------- CTA ---------- */
.cta {
  background: var(--blue);
  color: var(--sand);
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(115deg, rgba(229,164,48,0.06) 0 2px, transparent 2px 44px);
  pointer-events: none;
}
.cta-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 640px;
}
.cta h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(32px, 4.2vw, 48px);
  line-height: 1.12;
  margin: 0 0 18px;
  color: #fbf6ea;
}
.cta > .wrap > p, .cta-inner > p {
  font-size: 17px;
  color: #cfe0e7;
  max-width: 44ch;
  margin: 0 auto 34px;
}
.waitlist-form-dark {
  margin: 0 auto;
  border-color: var(--sun);
  background: #1b3341;
}
.waitlist-form-dark input {
  color: var(--sand);
}
.waitlist-form-dark input::placeholder { color: #7f96a1; }
.waitlist-form-dark button {
  background: var(--sun);
  color: var(--ink);
}
.waitlist-form-dark button:hover { background: #cf9226; }

/* ---------- Footer ---------- */
.site-footer {
  padding: 40px 0;
  border-top: 2px solid rgba(36,27,21,0.12);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.logo-small { height: 32px; opacity: 0.85; }
.footer-links a {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--terra);
}

/* ---------- Success / error message state ---------- */
.waitlist-form.is-success input,
.waitlist-form.is-success button { opacity: 0.55; pointer-events: none; }
.form-note.is-success { color: var(--green); font-weight: 600; }
.form-note.is-error { color: var(--terra-dk); font-weight: 600; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-image { order: -1; }
  .about-grid { grid-template-columns: 1fr; }
  .block-photo img { min-height: 260px; }
  .estampas-grid { grid-template-columns: 1fr; }
  .hero-sun { width: 320px; height: 320px; top: -80px; right: -100px; }
}

@media (max-width: 520px) {
  .waitlist-form { flex-direction: column; }
  .waitlist-form button { width: 100%; }
  .about-block { padding: 40px 28px; }
}
