/* ============================================================
   RGB — PT Ragam Gagas Berkarya
   Minimalism 2.0 — light, airy, RGB tri-accent system
   ============================================================ */

:root {
  /* Surfaces — soft light */
  --bg:        #ffffff;
  --bg-2:      #f6f6f3;   /* alt section wash */
  --surface:   #ffffff;
  --surface-2: #fafaf8;
  --border:    rgba(17,18,22,0.08);
  --border-2:  rgba(17,18,22,0.14);

  /* Text — near-black, refined grays */
  --text:      #0e0f13;
  --text-mid:  #494c55;
  --text-dim:  #8a8d96;

  /* Accent (dominant; overridable via tweaks) */
  --accent:    #3b6fff;
  --accent-2:  #2a59e0;
  --accent-ink:#ffffff;
  --accent-glow: rgba(59,111,255,0.18);

  /* RGB brand triad — muted/refined for light bg */
  --rgb-r: #e5484d;
  --rgb-g: #2fa867;
  --rgb-b: #3b6fff;

  /* Soft depth */
  --shadow-sm: 0 1px 2px rgba(15,17,25,0.04), 0 1px 3px rgba(15,17,25,0.06);
  --shadow-md: 0 2px 6px rgba(15,17,25,0.05), 0 14px 30px -18px rgba(15,17,25,0.22);
  --shadow-lg: 0 8px 24px rgba(15,17,25,0.06), 0 40px 80px -36px rgba(15,17,25,0.28);

  /* Type */
  --font-display: "Sora", system-ui, sans-serif;
  --font-body: "Plus Jakarta Sans", system-ui, sans-serif;

  /* Radii — generous, soft */
  --r-sm: 12px;
  --r-md: 18px;
  --r-lg: 26px;
  --r-xl: 34px;

  /* Layout */
  --maxw: 1180px;
  --pad: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 92px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--accent); color: #fff; }

/* ---------- Layout helpers ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding-inline: var(--pad);
}

.section {
  position: relative;
  padding-block: clamp(84px, 12vw, 160px);
}
.section.wash { background: var(--bg-2); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before {
  content: "";
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
}

.section-title {
  font-size: clamp(32px, 5vw, 56px);
  margin-top: 20px;
  color: var(--text);
}

.lead {
  color: var(--text-mid);
  font-size: clamp(17px, 1.6vw, 20px);
  max-width: 58ch;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 14px 24px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  transition: transform .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--text);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--accent);
  box-shadow: 0 10px 26px -10px var(--accent-glow);
  transform: translateY(-2px);
}

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-2);
}
.btn-ghost:hover { border-color: var(--text); background: var(--surface-2); }

.btn-arrow svg { transition: transform .2s ease; }
.btn:hover .btn-arrow svg { transform: translateX(3px); }

/* ---------- Pills / chips ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-2);
  background: var(--surface);
  font-size: 13.5px;
  color: var(--text-mid);
  font-weight: 500;
}

/* ---------- RGB logo mark ---------- */
.rgb-mark {
  display: inline-grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
  width: 30px;
  height: 30px;
  flex: none;
}
.rgb-mark span {
  border-radius: 3px;
  background: #cfd1d6;
  transition: background .3s ease, transform .3s ease;
}
.rgb-mark.lit span:nth-child(3n+1) { background: var(--rgb-r); }
.rgb-mark.lit span:nth-child(3n+2) { background: var(--rgb-g); }
.rgb-mark.lit span:nth-child(3n+3) { background: var(--rgb-b); }
.brand:hover .rgb-mark.lit span:nth-child(3n+1) { transform: translateX(-1.6px); }
.brand:hover .rgb-mark.lit span:nth-child(3n+3) { transform: translateX(1.6px); }

/* utility */
.grad-text {
  background: linear-gradient(100deg, var(--rgb-r), var(--rgb-g) 38%, var(--rgb-b) 72%, var(--rgb-r));
  background-size: 230% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
@media (prefers-reduced-motion: no-preference) {
  .grad-text { animation: hueShift 13s linear infinite; }
}
@keyframes hueShift { to { background-position: 230% 0; } }

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

/* RGB signature stripe */
.rgb-rule {
  height: 3px;
  width: 100%;
  border: 0;
  background: linear-gradient(90deg, var(--rgb-r), var(--rgb-g) 50%, var(--rgb-b));
}
.rgb-bar-top {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 3px;
  z-index: 101;
  background: linear-gradient(90deg, var(--rgb-r), var(--rgb-g) 50%, var(--rgb-b));
}

/* eyebrow color variants — section colour-coding */
.eyebrow.c-r { color: var(--rgb-r); }
.eyebrow.c-r::before { background: var(--rgb-r); }
.eyebrow.c-g { color: var(--rgb-g); }
.eyebrow.c-g::before { background: var(--rgb-g); }
.eyebrow.c-b { color: var(--rgb-b); }
.eyebrow.c-b::before { background: var(--rgb-b); }

/* editorial section index */
.eyebrow.num::before { display: none; }
.eb-no {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.eb-no::after {
  content: "";
  display: inline-block;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.45;
  margin: 0 10px 3px 9px;
  vertical-align: middle;
}

/* media placeholder */
.placeholder {
  position: relative;
  border-radius: var(--r-md);
  border: 1px solid var(--border-2);
  background:
    repeating-linear-gradient(135deg, rgba(17,18,22,0.03) 0 12px, transparent 12px 24px),
    var(--surface-2);
  overflow: hidden;
  display: grid;
  place-items: center;
}
.placeholder .ph-label {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--text-dim);
  background: rgba(255,255,255,0.7);
  padding: 5px 11px;
  border-radius: 6px;
  border: 1px solid var(--border);
}
