/* =====================================================
   JAKALELANA — Consolidated & Improved Stylesheet
   (Merged CSS1 + CSS2, cleaned, responsive, accessible)
   ===================================================== */
/* =========================
   Theme / Design Tokens
   ========================= */
:root {
  --bg: #ffffff;
  --panel: #f8fafb;
  --muted: #6b7280;
  --text: #0f172a;
  --accent: #0ea5a4;
  --accent-600: #0b9a98;
  --accent-700: #087f7d;
  --accent-light: rgba(14, 165, 164, 0.08);
  --card-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
  --card-shadow-hover: 0 12px 32px rgba(15, 23, 42, 0.12);
  --glass: rgba(255, 255, 255, 0.8);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --max-width: 1100px;
  --container-padding: 1.25rem;
  --transition: 220ms cubic-bezier(.2, .9, .2, 1);
  --reader-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  --border-light: #eef2f4;
  --toast-zindex: 1300;
  --shadow-soft: 0 4px 12px rgba(15, 23, 42, 0.08);
  --break-sm: 600px;
  --break-md: 720px;
  --break-lg: 1024px;
  --break-xl: 1200px;
}

/* =========================
   Reset / Base
   ========================= */
* {
  box-sizing: border-box
}

html,
body {
  height: 100%;
  margin: 0;
  font-family: var(--reader-font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth
}

img {
  max-width: 100%;
  display: block;
  object-fit: cover;
  border-radius: inherit
}

a {
  color: inherit;
  text-decoration: none
}

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: transparent
}

h1,
h2,
h3,
h4,
p,
ul,
ol {
  margin: 0
}

/* =========================
   Utilities & Small UI bits
   ========================= */
.muted {
  color: var(--muted) !important
}

.hidden {
  display: none !important
}

.small {
  font-size: .85rem;
  color: var(--muted)
}

.blog-badge {
  display: inline-block;
  padding: .25rem .6rem;
  background: var(--bg);
  color: var(--accent-600);
  font-size: .75rem;
  font-weight: 500;
  border-radius: 999px
}

/* loading spinner */
.blog-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 0;
  gap: 1rem
}

.loading-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--panel);
  border-top: 3px solid var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite
}

.blog-loading.small {
  padding: 1rem 0;
  gap: .5rem
}

.blog-loading.small .loading-spinner {
  width: 1.5rem;
  height: 1.5rem
}

@keyframes spin {
  0% {
    transform: rotate(0deg)
  }

  100% {
    transform: rotate(360deg)
  }
}

/* =========================
   Layout Containers
   ========================= */
.blog-body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfd 100%)
}

.art-body {
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 100vh
}

.blog-container,
.art-container {
  width: min(100%, var(--max-width));
  padding: 0 var(--container-padding);
  margin: 0 auto
}

/* =========================
   Header / Navigation
   ========================= */
/* gunakan var tinggi header agar sticky wrapper tahu posisi */
:root {
  --header-height: 56px;
  /* otomatis dipakai search-wrapper */
}

.blog-header {
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(8px);
  background: var(--glass);
  border-bottom: 1px solid var(--border-light);
  padding: .65rem 0;
  touch-action: pan-y;
  height: var(--header-height);
  display: flex;
  align-items: center;
}

.blog-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

/* brand */
.blog-brand {
  display: flex;
  flex-direction: column;
  gap: .15rem;
}

.blog-brand-text {
  font-size: 1.18rem;
  font-weight: 700;
  color: var(--text);
}

.blog-brand-tagline {
  font-size: .76rem;
  color: var(--muted);
  letter-spacing: .02em;
  line-height: 1.25;
}

/* =========================
   Search Wrapper (di bawah header)
   ========================= */
.blog-search-wrapper {
  width: 100%;
  padding: .8rem 0 1rem;
  background: var(--glass);
  border-bottom: 1px solid var(--border-light);
  backdrop-filter: blur(8px);
  position: sticky;
  top: var(--header-height);
  z-index: 90;
}

/* =========================
   Search
   ========================= */
.blog-search {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .48rem 1rem;
  background: var(--panel);
  border-radius: 999px;
  border: 1px solid var(--border-light);
  transition: box-shadow var(--transition), border-color var(--transition);
}

.blog-search:focus-within {
  box-shadow: 0 0 0 3px var(--accent-light);
  border-color: var(--accent-600);
}

.blog-search span {
  font-size: 1rem;
  opacity: .75;
}

/* input */
.blog-search input {
  background: transparent;
  border: none;
  padding: .25rem .3rem;
  width: 240px;
  min-width: 150px;
  outline: none;
  font-size: .95rem;
}

.blog-search input::placeholder {
  color: var(--muted);
  opacity: .8;
}

@media (min-width: 768px) {
  .blog-search input {
    width: 280px;
  }
}

/* =========================
   Hero
   ========================= */
.blog-hero {
  margin: 2.25rem 0 2.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  position: relative;
}

.blog-hero-head {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  position: relative;
  padding-left: 1.75rem;
}

.blog-hero-decor {
  position: absolute;
  left: 0;
  top: 2px;
  font-size: 1.4rem;
  opacity: .65;
}

.blog-hero-title {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -.02em;
  color: var(--text);
}

@media (min-width:720px) {
  .blog-hero-title {
    font-size: 2.25rem;
  }
}

.blog-hero-text {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
  max-width: 680px;
}

/* =========================
   Category Filter
   ========================= */
.blog-category-filter {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-light);
}

.blog-filter-btn {
  padding: .45rem .9rem;
  border-radius: 999px;
  font-size: .85rem;
  font-weight: 500;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--border-light);
  transition: all var(--transition);
}

.blog-filter-btn:hover,
.blog-filter-btn.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(14, 165, 164, 0.15);
}

/* =========================
   Grid / Cards
   ========================= */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem
}

@media(min-width:var(--break-md)) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.75rem
  }
}

@media(min-width:var(--break-lg)) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem
  }
}

.blog-card {
  display: flex;
  flex-direction: column;
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: all var(--transition);
  height: 100%
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--card-shadow-hover)
}

.blog-card a {
  display: flex;
  flex-direction: column;
  height: 100%
}

.blog-thumb {
  height: 180px;
  background-size: cover;
  background-position: center;
  position: relative
}

@media(max-width:600px) {
  .blog-thumb {
    height: 150px
  }
}

.blog-thumb::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(to top, rgba(0, 0, 0, .15), transparent)
}

.blog-card-badge {
  position: absolute;
  top: .75rem;
  right: .75rem;
  z-index: 10
}

.blog-meta {
  display: flex;
  gap: .75rem;
  align-items: center;
  padding: 1rem 1.25rem 0;
  color: var(--muted);
  font-size: .8rem
}

.blog-meta .blog-date {
  display: flex;
  align-items: center;
  gap: .25rem
}

.blog-card-title {
  margin: .75rem 1.25rem 0;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text);
  transition: color var(--transition)
}

.blog-card:hover .blog-card-title {
  color: var(--accent)
}

.blog-card-text {
  margin: .5rem 1.25rem 1.25rem;
  font-size: .9rem;
  color: var(--muted);
  line-height: 1.6;
  flex-grow: 1
}

.blog-grid .muted:not(.blog-meta *) {
  grid-column: 1/-1;
  text-align: center;
  padding: 2rem 0;
  font-size: 1rem
}

/* =========================
   Visitor / Testimonials
   ========================= */
.blog-visitor {
  margin-top: 1.5rem;
  padding: 1.5rem 1.25rem;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--card-shadow);
  margin-bottom: 2rem
}

.blog-visitor-header {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light)
}

.blog-visitor-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600
}

.blog-visitor-subtitle {
  margin: 0;
  font-size: .9rem;
  color: var(--muted)
}

.blog-visitor-list {
  display: flex;
  flex-direction: column;
  gap: 1rem
}

.blog-visitor-card {
  background: var(--panel);
  border: 1px solid var(--border-light);
  padding: 1rem;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  gap: .75rem;
  transition: all var(--transition);
  cursor: pointer
}

.blog-visitor-card:hover {
  transform: translateY(-3px);
  background: white;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05)
}

.blog-visitor-head {
  display: flex;
  align-items: center;
  gap: .75rem;
  font-weight: 600
}

.blog-visitor-avatar {
  width: 32px;
  height: 32px;
  background: var(--accent-light);
  color: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  font-weight: 700
}

.blog-visitor-head .small {
  font-weight: 400;
  font-size: .8rem;
  color: var(--muted);
  margin-left: auto
}

.blog-visitor-card p {
  margin: 0;
  font-size: .95rem;
  line-height: 1.6;
  color: var(--text)
}

/* =========================
   Buttons / CTA
   ========================= */
.center-cta {
  display: flex;
  justify-content: center;
  margin: 1rem 0 3rem;
  padding: 0 var(--container-padding)
}

.blog-btn-link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1.25rem;
  border-radius: 999px;
  transition: all var(--transition);
  text-decoration: none;
  color: #fff;
  background: var(--accent);
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(14, 165, 164, 0.15)
}

.blog-btn-link:hover {
  transform: translateY(-2px);
  background: var(--accent-600);
  box-shadow: 0 6px 16px rgba(14, 165, 164, 0.2)
}

.blog-btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .65rem 1rem;
  border-radius: var(--radius-sm);
  font-weight: 500;
  transition: all var(--transition)
}

.blog-btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 12px rgba(14, 165, 164, 0.18)
}

.blog-btn-primary:hover {
  background: var(--accent-700);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(14, 165, 164, 0.25)
}

.blog-btn-ghost {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text)
}

.blog-btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light)
}

.blog-btn:focus {
  outline: 3px solid var(--accent-light);
  outline-offset: 2px
}

/* =========================
   Forms
========================= */
.form-group {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-bottom: 1.25rem;
}

.form-label {
  font-size: .9rem;
  font-weight: 500;
}

.form-input {
  width: 100%;
  padding: .75rem .9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  background: white;
  outline: none;
  font-size: .95rem;
  transition: all var(--transition);
}

.form-input:focus {
  border-color: var(--accent-600);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.form-input::placeholder {
  color: var(--muted);
  opacity: .7;
}

.form-action-group {
  margin-top: 1.5rem;
  display: flex;
  gap: .75rem;
  justify-content: flex-end;
}

/* =========================
   Modals
========================= */
.blog-modal {
  position: fixed;
  inset: 0;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  z-index: 1200;
  background: rgba(6, 10, 14, 0.5);
  backdrop-filter: blur(4px);
  animation: modalFadeIn var(--transition) ease-in-out;
}

.blog-modal.show {
  display: flex;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.blog-modal-content {
  width: 100%;
  max-width: 720px;
  padding: 1.75rem 1.5rem;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(2, 6, 23, 0.25);
  position: relative;
  transform: translateY(20px);
  opacity: 0;
  transition: all var(--transition) ease-in-out;
}

.blog-modal.show .blog-modal-content {
  transform: translateY(0);
  opacity: 1;
  transition-delay: 50ms;
}

.blog-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  padding: .5rem;
  font-size: 1.25rem;
  color: var(--muted);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.blog-close:hover {
  background: var(--panel);
  color: var(--text);
}

.blog-modal-title {
  margin: 0 0 .5rem;
  font-size: 1.35rem;
  font-weight: 600;
}

.blog-modal-subtitle {
  margin: 0 0 1.5rem;
  font-size: .95rem;
  line-height: 1.5;
  color: var(--muted);
}

/* Wrapper modal */
.visitor-modal-content {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-light);
  font-size: .95rem;
  /* konsisten */
  line-height: 1.55;
  /* cukup padat */
  color: var(--text);
}

/* Info header */
.visitor-info {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  /* sedikit lebih padat */
  margin-bottom: .85rem;
  /* beri jeda jelas sebelum cerita */
}

/* Baris item */
.vi-item {
  color: var(--text);
}

/* Cerita */
.visitor-story {
  margin-top: .25rem;
  /* tidak terlalu jauh dari info */
}

.visitor-story-label {
  font-weight: 600;
  margin-bottom: .2rem;
}

.visitor-story-text {
  white-space: pre-wrap;
  /* hanya diterapkan ke teks cerita */
  color: var(--text);
}

/* =========================
   Article Page
   ========================= */
.art-article {
  margin: 1.5rem 0 2rem;
  padding: 1.75rem 1.5rem;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--card-shadow)
}

@media(max-width:600px) {
  .art-article {
    padding: 1.25rem 1rem
  }
}

.art-title {
  margin: 0 0 1rem;
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.01em
}

@media(min-width:720px) {
  .art-title {
    font-size: 2rem
  }
}

@media(max-width:600px) {
  .art-title {
    font-size: 1.35rem
  }
}

.art-meta {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
  font-size: .9rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--muted)
}

.art-thumb {
  margin: 1.5rem 0;
  overflow: hidden;
  border-radius: var(--radius);
  height: auto;
  max-height: 500px
}

.art-content {
  line-height: 1.8;
  font-size: 1.05rem;
  color: var(--text)
}

.art-content p {
  margin: 0 0 1.5rem
}

.art-content h2 {
  font-size: 1.35rem;
  font-weight: 600;
  margin: 2rem 0 1rem;
  color: var(--text);
  padding-left: .75rem;
  border-left: 3px solid var(--accent)
}

.art-content h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.75rem 0 .75rem;
  color: var(--text)
}

.art-content ol,
.art-content ul {
  margin: 0 0 1.5rem 1.5rem;
  padding-left: 1rem
}

.art-content li {
  margin-bottom: .5rem
}

.art-content a {
  color: var(--accent);
  text-decoration: underline;
  transition: color var(--transition)
}

.art-content a:hover {
  color: var(--accent-700)
}

.art-content img {
  margin: 1.5rem auto;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
  max-height: 600px;
  display: block
}

/* =========================
   Related Articles
   ========================= */
.art-related {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-light)
}

.art-related-title {
  margin: 0 0 1.25rem;
  font-size: 1.2rem;
  font-weight: 600
}

.art-related-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1rem
}

@media(min-width:var(--break-md)) {
  .art-related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem
  }
}

@media(min-width:var(--break-lg)) {
  .art-related-grid {
    grid-template-columns: repeat(3, 1fr)
  }
}

.art-related-card {
  display: flex;
  gap: 1rem;
  background: var(--panel);
  border-radius: var(--radius);
  padding: 1rem;
  transition: all var(--transition);
  height: 100%
}

.art-related-card:hover {
  background: white;
  box-shadow: var(--card-shadow);
  transform: translateY(-2px)
}

@media(max-width:600px) {
  .art-related-card {
    flex-direction: column
  }
}

.art-related-thumb {
  width: 100px;
  height: 80px;
  border-radius: var(--radius-sm);
  background-size: cover;
  background-position: center;
  flex-shrink: 0
}

@media(max-width:600px) {
  .art-related-thumb {
    width: 100%;
    height: 120px
  }
}

.art-related-info {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  flex-grow: 1
}

.art-related-title {
  margin: 0;
  font-size: .95rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
  transition: color var(--transition)
}

.art-related-card:hover .art-related-title {
  color: var(--accent)
}

.art-related-date {
  font-size: .8rem;
  color: var(--muted)
}

/* =========================
   Toast / Notifications
   ========================= */
.blog-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translate(-50%, 20px);
  padding: .75rem 1.25rem;
  border-radius: var(--radius-sm);
  color: white;
  font-weight: 500;
  opacity: 0;
  transition: all .3s ease;
  z-index: var(--toast-zindex);
  pointer-events: none;
  max-width: 90%;
  text-align: center;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.15)
}

.blog-toast.show {
  transform: translate(-50%, 0);
  opacity: 1
}

.blog-toast--success {
  background: #10b981
}

.blog-toast--error {
  background: #ef4444
}

.blog-toast--warning {
  background: #f59e0b
}

.blog-toast--info {
  background: #3b82f6
}

/* =========================
   Responsive Tweaks
   ========================= */
@media(max-width:600px) {
  :root {
    --container-padding: 1rem
  }

  .blog-hero-title {
    font-size: 1.45rem;
    padding-left: 1rem
  }

  .blog-hero-decor {
    font-size: 1.25rem;
    top: -5px
  }

  .blog-search input {
    width: 140px
  }

  .blog-card-title {
    font-size: 1rem
  }

  .blog-visitor {
    padding: 1.25rem 1rem
  }

  .blog-modal-content {
    padding: 1.5rem 1.25rem;
    border-radius: var(--radius)
  }
}

/* wide screens */
@media(min-width:var(--break-xl)) {

  .blog-container,
  .art-container {
    max-width: 1150px
  }

  .blog-grid {
    grid-template-columns: repeat(3, 1fr)
  }
}

/* =========================
   Print Styles
   ========================= */
@media print {

  .blog-header,
  .center-cta,
  .blog-search,
  .blog-modal,
  .blog-category-filter,
  .blog-visitor,
  .art-related,
  .blog-toast {
    display: none !important
  }

  body {
    background: #fff;
    color: #000;
    font-size: 11pt
  }

  .blog-container,
  .art-container {
    width: 100%;
    padding: 0
  }

  .blog-card,
  .art-article {
    box-shadow: none;
    border: none;
    padding: 0;
    margin: 0 0 1.5rem
  }

  .art-title {
    font-size: 18pt;
    margin-bottom: .5rem;
    color: #000
  }

  .art-meta {
    border-bottom: 1px solid #ddd;
    padding-bottom: .5rem;
    margin-bottom: 1rem;
    color: #555
  }

  .art-thumb img {
    max-height: 300px;
    object-fit: contain;
    margin: 1rem auto
  }

  .art-content {
    line-height: 1.5;
    color: #000
  }

  .art-content a {
    color: #000;
    text-decoration: underline
  }
}

/* =========================
   End of stylesheet
   ========================= */
/* =========================
   Pagination — Improved
   ========================= */
.blog-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
  margin: 2.5rem 0 3rem;
}

.blog-pagination button {
  padding: .55rem 1rem;
  border-radius: 8px;
  font-weight: 600;
  transition: all .25s ease;
  background: var(--accent, #0ea5a4);
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(14, 165, 164, 0.15);
}

.blog-pagination button.active {
  background: var(--accent-700, #0b8b8a);
  transform: translateY(-2px);
}

.blog-pagination button:hover:not(:disabled) {
  background: var(--accent-700, #0b8b8a);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(14, 165, 164, 0.22);
}

.blog-pagination button:disabled {
  opacity: .45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

@media (max-width: 480px) {
  .blog-pagination button {
    padding: .45rem .8rem;
    font-size: .9rem;
  }
}