/* ==========================================================================
   Base — reset, pola tekstur, primitif geometris, utilitas
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: var(--t-base);
  line-height: 1.55;
  color: var(--ink);
  background-color: var(--cream);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: var(--ink); text-decoration: none; }
table { border-collapse: collapse; width: 100%; }
strong, b { font-weight: 700; }
code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--slate-100);
  padding: 2px 6px;
  border-radius: var(--r-sm);
}

::selection { background: var(--amber); color: var(--ink); }

/* ---------- Focus: tebal + hard shadow ---------- */
:focus { outline: none; }
:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -120px;
  z-index: 200;
  background: var(--primary);
  color: #fff;
  padding: 14px 24px;
  border: var(--bw) solid var(--ink);
  border-radius: var(--r-full);
  box-shadow: var(--pop);
  transition: top var(--d) var(--ease-bounce);
}
.skip-link:focus { top: 16px; }

.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;
}
[hidden] { display: none !important; }

/* ==========================================================================
   Pola & tekstur (signature Memphis)
   ========================================================================== */

.pattern-dots {
  background-image: radial-gradient(var(--ink) 1.6px, transparent 1.6px);
  background-size: 18px 18px;
}
.pattern-dots-sm {
  background-image: radial-gradient(currentColor 1.2px, transparent 1.2px);
  background-size: 11px 11px;
}
.pattern-dots-soft {
  background-image: radial-gradient(var(--slate-300) 1.6px, transparent 1.6px);
  background-size: 16px 16px;
}
.pattern-grid {
  background-image:
    linear-gradient(var(--slate-200) 1.4px, transparent 1.4px),
    linear-gradient(90deg, var(--slate-200) 1.4px, transparent 1.4px);
  background-size: 28px 28px;
}
.pattern-stripe {
  background-image: repeating-linear-gradient(
    -45deg,
    var(--ink) 0 3px,
    transparent 3px 11px
  );
}
.pattern-stripe-soft {
  background-image: repeating-linear-gradient(
    -45deg,
    var(--slate-300) 0 2px,
    transparent 2px 10px
  );
}
.pattern-amber-stripe {
  background-image: repeating-linear-gradient(
    45deg,
    var(--amber) 0 10px,
    var(--pink) 10px 20px,
    var(--primary) 20px 30px,
    var(--mint) 30px 40px
  );
}

/* ==========================================================================
   Bentuk dekoratif (confetti)
   ========================================================================== */

.deco { position: absolute; pointer-events: none; z-index: 0; }
.deco--circle { border-radius: 50%; }
.deco--triangle {
  width: 0; height: 0;
  border-left: 26px solid transparent;
  border-right: 26px solid transparent;
  border-bottom: 44px solid currentColor;
}
.deco--square { border-radius: 6px; }
.deco--pill { border-radius: var(--r-full); }
.deco--ring {
  border-radius: 50%;
  border: 8px solid currentColor;
  background: transparent;
}
.deco--squiggle {
  height: 18px;
  background-repeat: repeat-x;
  background-size: 30px 18px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 18'%3E%3Cpath d='M0 9 Q7.5 0 15 9 T30 9' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E");
}

.c-primary { color: var(--primary); }
.c-pink { color: var(--pink); }
.c-amber { color: var(--amber); }
.c-mint { color: var(--mint); }
.c-slate { color: var(--slate-300); }
.c-ink { color: var(--ink); }

/* ==========================================================================
   Pop-in & wiggle
   ========================================================================== */

@keyframes pop-in {
  0% { opacity: 0; transform: scale(0.6) translateY(14px); }
  70% { opacity: 1; transform: scale(1.06) translateY(-3px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

.pop {
  opacity: 0;
  animation: pop-in 560ms var(--ease-bounce) forwards;
}
.pop-1 { animation-delay: 60ms; }
.pop-2 { animation-delay: 140ms; }
.pop-3 { animation-delay: 220ms; }
.pop-4 { animation-delay: 300ms; }
.pop-5 { animation-delay: 380ms; }
.pop-6 { animation-delay: 460ms; }

@keyframes wiggle {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(4deg); }
  55% { transform: rotate(-3deg); }
  78% { transform: rotate(2deg); }
}
.wiggle { transition: transform var(--d) var(--ease-bounce); }
.wiggle:hover { animation: wiggle 620ms var(--ease-bounce); }

@keyframes float-slow {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-14px) rotate(6deg); }
}
.float { animation: float-slow 6s ease-in-out infinite; }
.float--delay { animation-delay: -2.2s; }
.float--delay2 { animation-delay: -4s; }

/* ==========================================================================
   Utilitas layout
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
  padding-inline: 24px;
}
.section { position: relative; padding-block: 88px; }
.section--tight { padding-block: 64px; }

.stack { display: flex; flex-direction: column; }
.stack-2 { gap: 8px; }
.stack-3 { gap: 12px; }
.stack-4 { gap: 16px; }
.stack-5 { gap: 24px; }
.stack-6 { gap: 32px; }

.row { display: flex; align-items: center; }
.row-2 { gap: 8px; }
.row-3 { gap: 12px; }
.row-4 { gap: 16px; }
.row-6 { gap: 24px; }
.row-wrap { flex-wrap: wrap; }
.row-between { justify-content: space-between; }
.row-end { justify-content: flex-end; }
.row-center { justify-content: center; }
.grow { flex: 1 1 auto; min-width: 0; }

.grid { display: grid; gap: 28px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-auto { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.text-center { text-align: center; }
.divider { height: 2px; background: var(--ink); border: 0; opacity: 0.12; margin: 0; }

@media (max-width: 900px) {
  .section { padding-block: 60px; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  :root { --t-5xl: 2.9rem; --t-4xl: 2.5rem; --t-3xl: 2rem; --t-2xl: 1.7rem; }
}

@media (max-width: 620px) {
  .container { padding-inline: 18px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); }
  .grid { gap: 20px; }
  .section { padding-block: 48px; }
  :root { --t-5xl: 2.3rem; --t-4xl: 2.05rem; --t-3xl: 1.75rem; --t-2xl: 1.45rem; }
  /* Pop shadow dikecilkan di layar kecil */
  :root {
    --pop: 3px 3px 0 0 var(--ink);
    --pop-md: 4px 4px 0 0 var(--ink);
    --pop-lg: 5px 5px 0 0 var(--ink);
    --pop-soft: 4px 4px 0 0 var(--slate-200);
    --pop-pink: 5px 5px 0 0 var(--pink);
    --pop-amber: 5px 5px 0 0 var(--amber);
    --pop-mint: 5px 5px 0 0 var(--mint);
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .pop { opacity: 1; }
  .float, .wiggle:hover { animation: none; }
}