/* ============================================================
   Mandorly — mandorly.id marketing site
   Design tokens derived from the actual product's brand system
   (app/globals.css), not invented fresh for this site: terracotta
   is the real logo color, cream/concrete is the real app background.
   A marketing site for a product should look like it belongs to
   that product, not like a different agency designed it.
   ============================================================ */

:root {
  /* ---- Brand (exact) vs UI-safe tint, same split the app itself
     uses: brand color for large graphic/decorative use, the darker
     tint anywhere text needs to sit on it and clear contrast. ---- */
  --brand: #d06438;
  --terracotta: #ae4e29;
  --terracotta-deep: #6e3419;
  --sage: #536d46;
  --sage-deep: #3c4f33;
  --amber: #986a1b;
  --charcoal: #252421;
  --charcoal-70: rgba(37, 36, 33, 0.7);
  --charcoal-50: rgba(37, 36, 33, 0.5);
  --charcoal-30: rgba(37, 36, 33, 0.3);
  --charcoal-12: rgba(37, 36, 33, 0.12);
  --cream: #f5f3ef;
  --cream-deep: #ece7de;
  --paper: #ffffff;
  --line: #e4ddd0;

  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", ui-monospace, monospace;

  --container: 1120px;
  --radius: 20px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--charcoal);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0;
  color: var(--charcoal);
}

p { margin: 0; }

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terracotta-deep);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: var(--terracotta);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 14px 26px;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--terracotta);
  color: var(--paper);
  box-shadow: 0 1px 0 rgba(0,0,0,0.05), 0 10px 24px -12px rgba(174,78,41,0.55);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -12px rgba(174,78,41,0.6); }
.btn-ghost {
  background: transparent;
  color: var(--charcoal);
  border-color: var(--charcoal-12);
}
.btn-ghost:hover { border-color: var(--terracotta); color: var(--terracotta-deep); }
.btn-block { width: 100%; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 243, 239, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  color: var(--charcoal);
}
.brand-mark {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: var(--terracotta);
  position: relative;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}
.brand-mark span { display: block; width: 4px; border-radius: 2px; background: var(--cream); }
.brand-mark span:first-child { height: 16px; }
.brand-mark span:last-child { height: 10px; align-self: flex-end; margin-bottom: 3px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--charcoal-70);
}
.nav-links a:hover { color: var(--terracotta-deep); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; }

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-cta .btn-ghost { display: none; }
}

@media (max-width: 480px) {
  .nav-inner { gap: 10px; }
  .brand { font-size: 16px; }
  .brand-mark { width: 26px; height: 26px; }
  .nav-cta .btn-primary {
    padding: 10px 16px;
    font-size: 13px;
  }
}

.cta-short { display: none; }
@media (max-width: 380px) {
  .nav-cta .cta-full { display: none; }
  .nav-cta .cta-short { display: inline; }
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--line);
  padding: 64px 0 32px;
  margin-top: 120px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
}
.footer-brand p {
  color: var(--charcoal-70);
  font-size: 14.5px;
  margin-top: 14px;
  max-width: 280px;
}
.footer-col h4 {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--charcoal-50);
  margin-bottom: 16px;
}
.footer-col a, .footer-col p {
  display: block;
  font-size: 14.5px;
  color: var(--charcoal-70);
  margin-bottom: 10px;
}
.footer-col a:hover { color: var(--terracotta-deep); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--charcoal-50);
  flex-wrap: wrap;
  gap: 12px;
}

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

/* ---------- Ruler / measurement motif ----------
   The signature device for this site: a thin dashed ruler with tick
   marks, used as a section divider. Ties directly to the product's
   own subject matter — blueprints, measurements, tracked progress —
   rather than a decorative generic line. */
.ruler {
  height: 22px;
  background-image: repeating-linear-gradient(
    to right,
    var(--charcoal-30) 0, var(--charcoal-30) 1px,
    transparent 1px, transparent 24px
  );
  background-position: bottom;
  background-size: 100% 10px;
  background-repeat: repeat-x;
  position: relative;
  margin: 0 auto;
  max-width: var(--container);
}
.ruler::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--charcoal-30);
}

/* ---------- Section rhythm ---------- */
section { padding: 96px 0; }
section.tight { padding: 64px 0; }

.section-head {
  max-width: 640px;
  margin-bottom: 56px;
}
.section-head h2 { font-size: clamp(28px, 4vw, 40px); margin-top: 16px; }
.section-head p { color: var(--charcoal-70); font-size: 17px; margin-top: 16px; }

/* ---------- Cards ---------- */
.card {
  background: var(--paper);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  padding: 28px;
}

.tag {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 100px;
  background: var(--sage-deep);
  color: #fff;
}
.tag-amber { background: var(--amber); }
.tag-terracotta { background: var(--terracotta); }

@media (max-width: 640px) {
  section { padding: 64px 0; }
  .wrap { padding: 0 20px; }
}
