/*
Theme Name: Agen Laris
Theme URI: https://agenlaris.com
Author: Agen Laris
Description: Tema blog Agen Laris. Mengikuti palet, tipografi, dan tata letak landing page supaya blog terasa satu produk, bukan WordPress yang ditempel.
Version: 2.1.0
Requires at least: 6.5
Requires PHP: 8.0
License: GPL-2.0-or-later
Text Domain: agenlaris
*/

/* Tokens taken from the "Blog AgenLaris" design file, which shares its palette
   with apps/site/tailwind.config.ts. Duplicated rather than shared because
   WordPress cannot read the Tailwind config; change one, change the other. */
:root {
  --bg: #fbfaf7;
  --ink: #0f1a14;
  --lead: #31423a;
  --body: #41544a;
  --muted: #5f6a63;
  --faint: #8b948d;
  --dim: #a3aba5;
  --dot: #cfc9bc;
  --line: #eae6dd;
  --edge: #d9d4c8;
  --green: #12b764;
  --green-dark: #0e9b55;
  --green-deep: #0b7a46;
  --mint: #ecfaf2;
  --mint-2: #f1fcf6;
  --card: #fff;
  /* The design draws the blog at 1180px, but the landing page shipped at
     1240px and the header is the one thing a reader sees on both. Matching the
     live site wins over matching the mockup's number. */
  --shell: 1240px;
  --measure: 720px;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--green-dark);
  text-decoration: none;
}
a:hover {
  color: var(--green);
}

.shell {
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 640px) {
  .shell {
    padding: 0 28px;
  }
}

/* Keyboard users land here first; visually hidden until focused. */
.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 200;
  background: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--green);
}

/* ── header ───────────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(251, 250, 247, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.site-header .shell {
  display: flex;
  align-items: center;
  gap: 36px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.03em;
}
.brand:hover {
  color: var(--ink);
}
.brand svg {
  color: var(--green);
  flex-shrink: 0;
}
.site-nav {
  display: flex;
  gap: 28px;
  font-size: 14px;
  margin-right: auto;
}
.site-nav a {
  color: var(--muted);
}
.site-nav a:hover {
  color: var(--ink);
}
/* The design marks the section you are in. On the blog that is always Blog. */
.site-nav a[aria-current] {
  color: var(--ink);
  font-weight: 600;
}
.cta-pill {
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  padding: 11px 20px;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(18, 183, 100, 0.24);
  transition:
    background 0.15s,
    transform 0.15s;
}
.cta-pill:hover {
  background: var(--green-dark);
  color: #fff;
  transform: translateY(-1px);
}
@media (max-width: 860px) {
  .site-nav {
    display: none;
  }
  .brand {
    margin-right: auto;
  }
}

/* ── blog index hero ──────────────────────────────────────────────────── */
.index-hero {
  padding: 56px 0 0;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid rgba(18, 183, 100, 0.28);
  background: var(--mint);
  color: var(--green-deep);
  font-size: 13px;
  font-weight: 600;
  padding: 7px 15px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.eyebrow i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  animation: alPulse 2s infinite;
}
@keyframes alPulse {
  0%,
  100% {
    opacity: 0.5;
    transform: scale(1);
  }
  50% {
    opacity: 0.95;
    transform: scale(1.08);
  }
}
/* Someone who set "reduce motion" asked not to see a dot breathing at them. */
@media (prefers-reduced-motion: reduce) {
  .eyebrow i {
    animation: none;
  }
}

.hero-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.hero-row h1 {
  font-weight: 800;
  font-size: clamp(34px, 4.6vw, 60px);
  letter-spacing: -0.045em;
  line-height: 1.02;
  margin: 0 0 14px;
  max-width: 660px;
  text-wrap: balance;
}
.hero-row .lede {
  font-size: 18px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
  max-width: 520px;
}

/* ── category chips ───────────────────────────────────────────────────── */
.chips {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  margin-top: 34px;
  padding-bottom: 34px;
  border-bottom: 1px solid var(--line);
}
.chip {
  font-size: 14px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--muted);
  transition:
    border-color 0.15s,
    color 0.15s;
}
.chip:hover {
  border-color: rgba(18, 183, 100, 0.45);
  color: var(--green-deep);
}
.chip[aria-current] {
  border-color: var(--green);
  background: var(--mint);
  color: var(--green-deep);
}

/* ── featured post ────────────────────────────────────────────────────── */
.featured-wrap {
  padding: 44px 0 0;
}
.featured {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 26px;
  color: inherit;
  transition:
    border-color 0.18s,
    box-shadow 0.18s;
}
.featured:hover {
  color: inherit;
  border-color: rgba(18, 183, 100, 0.45);
  box-shadow: 0 22px 50px rgba(15, 26, 20, 0.09);
}
.featured-body {
  padding: 44px 44px 40px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.badges {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.badge-pick {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #fff;
  background: var(--green);
  padding: 5px 11px;
  border-radius: 999px;
}
.badge-cat {
  font-size: 13px;
  font-weight: 600;
  color: var(--green-deep);
  background: var(--mint);
  padding: 5px 11px;
  border-radius: 999px;
}
.featured h2 {
  font-weight: 800;
  font-size: clamp(26px, 2.8vw, 38px);
  letter-spacing: -0.035em;
  line-height: 1.1;
  margin: 0 0 16px;
  text-wrap: balance;
}
.featured p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--muted);
  margin: 0 0 28px;
  max-width: 480px;
}
.featured-meta {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
  color: var(--faint);
  flex-wrap: wrap;
}
.read-more {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--green-dark);
  font-weight: 700;
}
.featured-media {
  min-width: 0;
  aspect-ratio: 4 / 3;
  border-left: 1px solid var(--line);
  overflow: hidden;
  border-radius: 0 25px 25px 0;
}
/* Once the grid wraps to one column the image sits below the text, so the
   rounding and the divider have to move with it. */
@media (max-width: 767px) {
  .featured-body {
    padding: 28px 24px 26px;
  }
  .featured-media {
    border-left: 0;
    border-top: 1px solid var(--line);
    border-radius: 0 0 25px 25px;
  }
}

/* ── post grid ────────────────────────────────────────────────────────── */
.grid-wrap {
  padding: 52px 0 96px;
}
.grid-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 26px;
}
.grid-head h2 {
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.03em;
  margin: 0;
}
.grid-head span {
  font-size: 14px;
  color: var(--faint);
  white-space: nowrap;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
/* The design was drawn at 1280px only. Below that the three columns have to
   step down or the cards become unreadable slivers. */
@media (max-width: 1000px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .card-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: inherit;
  transition:
    border-color 0.18s,
    box-shadow 0.18s,
    transform 0.18s;
}
.card:hover {
  color: inherit;
  border-color: rgba(18, 183, 100, 0.45);
  box-shadow: 0 18px 40px rgba(15, 26, 20, 0.08);
  transform: translateY(-4px);
}
@media (prefers-reduced-motion: reduce) {
  .card:hover {
    transform: none;
  }
}
.card-media {
  aspect-ratio: 16 / 10;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.card-body {
  padding: 24px 24px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.card-body .badge-cat {
  align-self: flex-start;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 10px;
  margin-bottom: 14px;
}
.card-body h3 {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.3;
  margin: 0 0 10px;
  text-wrap: pretty;
}
.card-body p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 20px;
}
.card-meta {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--faint);
}

/* The separator between date and reading time, as a dot rather than a glyph
   so it never gets read out by a screen reader. */
.sep {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--dot);
  flex-shrink: 0;
}

/* ── featured-image fallback ──────────────────────────────────────────── */
/* Most posts will not have a featured image on day one. An empty box would
   collapse the card layout, so the slot always renders something on-brand. */
.thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.thumb-blank {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(120% 120% at 20% 0%, rgba(18, 183, 100, 0.16), transparent 62%),
    var(--mint-2);
}
.thumb-blank svg {
  color: rgba(18, 183, 100, 0.4);
}

/* ── search ───────────────────────────────────────────────────────────── */
.searchform {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 16px;
  min-width: 270px;
}
.searchform:focus-within {
  border-color: rgba(18, 183, 100, 0.45);
}
.searchform svg {
  color: var(--faint);
  flex-shrink: 0;
}
.searchform input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: none;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
}
.searchform input::placeholder {
  color: var(--faint);
}
.searchform button {
  border: 0;
  background: none;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  color: var(--green-dark);
  cursor: pointer;
  padding: 0;
}

/* ── archive header ───────────────────────────────────────────────────── */
.archive-head {
  padding: 44px 0 0;
  background: radial-gradient(900px 420px at 20% -20%, rgba(18, 183, 100, 0.14), transparent 62%);
}
.crumbs {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
  color: var(--faint);
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.crumbs a {
  color: var(--faint);
}
.crumbs a:hover {
  color: var(--ink);
}
.crumbs [aria-current] {
  color: var(--ink);
  font-weight: 600;
}
.archive-head h1 {
  font-weight: 800;
  font-size: clamp(30px, 4.2vw, 54px);
  letter-spacing: -0.045em;
  line-height: 1.03;
  margin: 0 0 14px;
}
.archive-head .lede {
  font-size: 18px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 30px;
  max-width: 540px;
}
.archive-head .chips {
  margin-top: 0;
  padding-bottom: 32px;
}
.archive-grid {
  padding: 36px 0 96px;
}

/* ── banner CTA ───────────────────────────────────────────────────────── */
.banner {
  margin-top: 40px;
  background: var(--mint-2);
  border: 1px solid rgba(18, 183, 100, 0.26);
  border-radius: 24px;
  padding: 36px 38px;
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
}
.banner div {
  flex: 1;
  min-width: 280px;
}
.banner h2 {
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.03em;
  margin: 0 0 8px;
  text-wrap: balance;
}
.banner p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--body);
  margin: 0;
}
.btn-primary {
  display: inline-block;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 15px 28px;
  border-radius: 13px;
  white-space: nowrap;
  box-shadow: 0 10px 26px rgba(18, 183, 100, 0.26);
  transition: background 0.15s;
}
.btn-primary:hover {
  background: var(--green-dark);
  color: #fff;
}

/* ── single post ──────────────────────────────────────────────────────── */
.post-head {
  padding: 44px 0 0;
  background: radial-gradient(900px 420px at 25% -24%, rgba(18, 183, 100, 0.13), transparent 62%);
}
.post-head h1 {
  font-weight: 800;
  font-size: clamp(30px, 4.4vw, 56px);
  letter-spacing: -0.045em;
  line-height: 1.04;
  margin: 0 0 20px;
  max-width: 820px;
  text-wrap: balance;
}
.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
  color: var(--faint);
  padding-bottom: 32px;
  flex-wrap: wrap;
}
.post-meta .cat {
  font-weight: 600;
  color: var(--green-deep);
}
/* Once the meta row wraps, the dot before the category is left dangling at the
   end of the previous line. Drop it and give the category its own row. */
@media (max-width: 560px) {
  .post-meta .sep-cat {
    display: none;
  }
  .post-meta .cat {
    flex-basis: 100%;
  }
}
.post-hero {
  aspect-ratio: 21 / 9;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--line);
}

/* padding-block only: .post-layout shares its element with .shell, and the
   shorthand would reset the shell's side gutter (see .entry-content note). */
.post-layout {
  padding-top: 52px;
  padding-bottom: 96px;
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}
/* Below this the sidebar would squeeze the 720px measure, so the table of
   contents goes inline above the article instead of beside it. */
@media (max-width: 1040px) {
  .post-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
}

.toc {
  position: sticky;
  top: 96px;
}
/* This un-sticks the sidebar and MUST come after the rule above, not inside
   the earlier media query. Same specificity means source order decides: with
   the override written first, `position: sticky` won at every width, and on a
   one-column layout the pinned list sat on top of the article text. */
@media (max-width: 1040px) {
  .toc {
    position: static;
  }
}
.toc-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--faint);
  margin-bottom: 14px;
}
.toc-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-left: 2px solid var(--line);
}
.toc-list a {
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
  padding: 8px 0 8px 14px;
}
.toc-list a.is-active {
  color: var(--ink);
  font-weight: 600;
  border-left: 2px solid var(--green);
  margin-left: -2px;
}
/* Guarded, because on a touch screen :hover sticks after a tap and leaves a
   second entry marked green alongside the one you are actually reading. */
@media (hover: hover) {
  .toc-list a:hover {
    color: var(--ink);
    font-weight: 600;
    border-left: 2px solid var(--green);
    margin-left: -2px;
  }
}

.entry-content {
  max-width: var(--measure);
}
.entry-content > *:first-child {
  margin-top: 0;
}
.entry-content p {
  font-size: 17px;
  line-height: 1.8;
  color: var(--body);
  margin: 0 0 20px;
}
/* The design opens every article with a larger, darker standfirst. */
.entry-content > p:first-of-type {
  font-size: 19px;
  line-height: 1.75;
  color: var(--lead);
  font-weight: 500;
  margin-bottom: 28px;
}
.entry-content h2 {
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.03em;
  margin: 44px 0 14px;
  /* Clears the sticky header when a table-of-contents link jumps here. */
  scroll-margin-top: 96px;
}
.entry-content h3 {
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -0.025em;
  margin: 32px 0 12px;
  scroll-margin-top: 96px;
}
.entry-content ul,
.entry-content ol {
  font-size: 17px;
  line-height: 1.8;
  color: var(--body);
  margin: 0 0 20px;
  padding-left: 22px;
}
.entry-content li + li {
  margin-top: 8px;
}
.entry-content blockquote {
  margin: 32px 0;
  padding: 24px 28px;
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 3px solid var(--green);
  border-radius: 0 16px 16px 0;
}
.entry-content blockquote p {
  font-size: 18px;
  line-height: 1.7;
  font-weight: 600;
  color: var(--ink);
  margin: 0;
}
.entry-content img,
.entry-content .wp-block-image img {
  border-radius: 16px;
}
.entry-content figure {
  margin: 32px 0;
}
.entry-content figcaption {
  font-size: 13.5px;
  color: var(--faint);
  margin-top: 10px;
}
.entry-content code {
  background: var(--mint);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 0.9em;
}
.entry-content pre {
  background: var(--ink);
  color: #e7efe9;
  padding: 18px;
  border-radius: 14px;
  overflow-x: auto;
}
.entry-content pre code {
  background: none;
  padding: 0;
  color: inherit;
}
.entry-content table {
  width: 100%;
  border-collapse: collapse;
  display: block;
  overflow-x: auto;
}
.entry-content th,
.entry-content td {
  border-bottom: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  font-size: 16px;
}

/* ── in-article product CTA ───────────────────────────────────────────── */
/* The blog exists to sell the product. The design puts one CTA partway down a
   long read and one at the end. */
.post-cta {
  margin: 40px 0;
  background: var(--mint-2);
  border: 1px solid rgba(18, 183, 100, 0.28);
  border-radius: 22px;
  padding: 34px 36px;
  max-width: var(--measure);
}
.post-cta .tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fff;
  background: var(--green);
  padding: 5px 11px;
  border-radius: 999px;
}
.post-cta h3 {
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.03em;
  margin: 16px 0 10px;
  text-wrap: balance;
}
.post-cta p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--body);
  margin: 0 0 22px;
  max-width: 480px;
}
.post-cta .row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.post-cta .row span {
  font-size: 14px;
  color: var(--muted);
}

/* ── share ────────────────────────────────────────────────────────────── */
.share {
  margin-top: 44px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  max-width: var(--measure);
}
.share > span {
  font-size: 14px;
  color: var(--faint);
}
.share .row {
  display: flex;
  gap: 8px;
}
.share a,
.share button {
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--muted);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 9px 16px;
  border-radius: 10px;
  cursor: pointer;
  transition:
    border-color 0.15s,
    color 0.15s;
}
.share a:hover,
.share button:hover {
  border-color: var(--green);
  color: var(--green-dark);
}

/* ── related ──────────────────────────────────────────────────────────── */
.related {
  padding: 0 0 96px;
}
.related-inner {
  padding-top: 44px;
  border-top: 1px solid var(--line);
}
.related h2 {
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.03em;
  margin: 0 0 26px;
}

/* ── pagination, empty, 404 ───────────────────────────────────────────── */
.pagination {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 40px;
}
.pagination .page-numbers {
  padding: 9px 15px;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 10px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
}
.pagination a.page-numbers:hover {
  border-color: var(--green);
  color: var(--green-dark);
}
.pagination .page-numbers.current {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.empty {
  padding: 48px 0 96px;
  color: var(--muted);
  max-width: var(--measure);
  font-size: 17px;
  line-height: 1.7;
}
.empty .searchform {
  margin-top: 22px;
  max-width: 420px;
}

/* Same reason as .post-layout: this class lands on the .shell element. */
.page-entry {
  padding-top: 56px;
  padding-bottom: 96px;
}
.page-entry h1 {
  font-weight: 800;
  font-size: clamp(30px, 4.2vw, 48px);
  letter-spacing: -0.04em;
  line-height: 1.06;
  margin: 0 0 24px;
  max-width: 22ch;
  text-wrap: balance;
}

/* ── footer ───────────────────────────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 36px 0 56px;
}
.site-footer .row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.site-footer .tagline {
  font-size: 14px;
  color: var(--faint);
}
.site-footer nav {
  margin-left: auto;
  display: flex;
  gap: 24px;
  font-size: 14px;
}
.site-footer nav a {
  color: var(--muted);
}
.site-footer nav a:hover {
  color: var(--ink);
}
.disclaimer {
  margin-top: 22px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--dim);
}
