:root {
  --ink: #111827;
  --muted: #64748b;
  --primary: #4a5568;
  --accent: #4FA0C9;
  --accent-2: #5a8fe0;
  --surface: rgba(255,255,255,.78);
  --line: rgba(74,85,104,.14);
  --shadow: 0 24px 70px rgba(36, 44, 64, .12);
  --radius: 28px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #f8fafc;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.resources-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 15% 10%, rgba(122,102,204,.26), transparent 30%),
    radial-gradient(circle at 80% 20%, rgba(90,143,224,.24), transparent 34%),
    radial-gradient(circle at 50% 85%, rgba(167,139,250,.18), transparent 38%),
    #f8fafc;
}

.resources-shell {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.piya-header-wrap {
  position: sticky;
  top: 18px;
  z-index: 20;
  padding: 0 20px;
}

.piya-header {
  max-width: 1160px;
  margin: 0 auto;
  border: 1px solid rgba(255,255,255,.8);
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(18px);
  border-radius: 999px;
  box-shadow: 0 12px 35px rgba(17,24,39,.08);
}

.header-row {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}

.piya-brand img { width: 48px; }

.piya-menu {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
}

.piya-menu a[aria-current="page"] { color: var(--accent); }

.piya-login-cta {
  padding: 12px 18px;
  border-radius: 999px;
  color : #fff;
  background: linear-gradient(
    90deg,
    #43A6D9 0%,
    #A49FE2 50%,
    #43A6D9 100%
  );
  background-size: 200% 200%;
  box-shadow:
    0 4px 14px rgba(67,166,217,.18),
    0 0 18px rgba(164,159,226,.18);
  transition:
    transform .25s ease,
    box-shadow .25s ease,
    background-position .35s ease;
}

.piya-burger {
  display: none;
  border: 0;
  background: transparent;
  width: 42px;
  height: 42px;
}

.piya-burger span,
.piya-burger span::before,
.piya-burger span::after {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  content: "";
  margin: auto;
  position: relative;
}

.piya-burger span::before { position: absolute; top: -7px; }
.piya-burger span::after { position: absolute; top: 7px; }

.resources-hero { padding: 120px 0 52px; }

.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr .75fr;
  gap: 34px;
  align-items: center;
}

.hero-kicker,
.section-kicker {
  color: var(--accent);
  font-family: "Pacifico", cursive;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  font-size: 20px;
}

h1 {
  margin: 12px 0 22px;
  font-family: Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 600;
  font-size: clamp(42px, 7vw, 76px);
  line-height: .98;
  letter-spacing: -0.055em;
  max-width: 850px;
  color: var(--ink);
}

.hero-text {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
  max-width: 720px;
}

.hero-actions,
.cta-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 800;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 18px 38px rgba(90,143,224,.25);
}

.btn-secondary {
  background: rgba(255,255,255,.8);
  border: 1px solid var(--line);
  color: var(--primary);
}

.hero-card {
  padding: 28px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(255,255,255,.75);
  box-shadow: var(--shadow);
}

.hero-card-label {
  display: block;
  font-family: "Pacifico", cursive;
  font-weight: 400;
  font-size: 21px;
  margin-bottom: 12px;
  color: var(--accent);
}

.hero-card p {
  color: var(--muted);
  line-height: 1.7;
  margin: 0;
}

.resources-tools { padding: 22px 0 50px; }

.search-panel {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(255,255,255,.75);
  box-shadow: var(--shadow);
}

.search-panel label {
  display: block;
  font-family: "Pacifico", cursive;
  font-weight: 400;
  font-size: 21px;
  margin-bottom: 12px;
  color: var(--accent);
}

.search-box {
  display: flex;
  gap: 12px;
}

.search-box input {
  flex: 1;
  min-height: 54px;
  border-radius: 18px;
  border: 1px solid var(--line);
  padding: 0 18px;
  font: inherit;
  outline: none;
  background: #fff;
}

.search-box input:focus {
  border-color: rgba(122,102,204,.65);
  box-shadow: 0 0 0 4px rgba(122,102,204,.12);
}

.search-box button,
.pill,
.page-btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  color: var(--primary);
}

.category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.pill { min-height: 44px; }
.pill.is-active { background: var(--ink); color: #fff; border-color: var(--ink); }

.featured-section,
.latest-section,
.resources-cta {
  padding: 36px 0;
}

.section-head { margin-bottom: 22px; }

.section-head h2 {
  font-size: clamp(28px, 4vw, 44px);
  margin: 6px 0 0;
  letter-spacing: -.04em;
}

.split-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.results-count {
  color: var(--muted);
  font-weight: 700;
}

.featured-grid,
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.article-card {
  border-radius: var(--radius);
  background: rgba(255,255,255,.82);
  border: 1px solid rgba(255,255,255,.8);
  box-shadow: 0 18px 50px rgba(17,24,39,.08);
  transition: transform .2s ease, box-shadow .2s ease;
  overflow: hidden;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.article-link {
  display: block;
  padding: 24px;
  min-height: 100%;
}

.article-category {
  display: inline-flex;
  font-size: 12px;
  font-weight: 800;
  color: var(--accent);
  background: rgba(122,102,204,.1);
  border-radius: 999px;
  padding: 7px 10px;
  margin-bottom: 18px;
}

.article-card h3 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0 0 12px;
  letter-spacing: -.025em;
}

.article-card p {
  color: var(--muted);
  line-height: 1.65;
  margin: 0 0 20px;
}

.article-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 700;
}

.featured-card {
  background: linear-gradient(145deg, rgba(255,255,255,.92), rgba(238,242,255,.84));
}

.empty-state {
  text-align: center;
  padding: 44px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
}

.pagination {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 28px;
}

.page-btn {
  width: 42px;
  height: 42px;
  padding: 0;
}

.page-btn.is-active {
  background: var(--ink);
  color: #fff;
}

.cta-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 34px;
  border-radius: calc(var(--radius) + 8px);
  background: linear-gradient(135deg, rgba(17,24,39,.96), rgba(74,85,104,.92));
  color: #fff;
  box-shadow: var(--shadow);
}

.cta-box p {
  color: rgba(255,255,255,.75);
  line-height: 1.7;
}

.cta-box .section-kicker { color: #c4b5fd; }

.cta-box .btn-secondary {
  color: #fff;
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.2);
}

.resources-footer {
  padding: 34px 0 46px;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.footer-inner nav {
  display: flex;
  gap: 18px;
  font-weight: 700;
}

@media (max-width: 900px) {
  .piya-burger { display: block; }

  .piya-menu {
    position: absolute;
    top: 82px;
    left: 20px;
    right: 20px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 20px;
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--shadow);
  }

  .piya-menu.open { display: flex; }

  .hero-grid,
  .featured-grid,
  .articles-grid {
    grid-template-columns: 1fr;
  }

  .resources-hero { padding-top: 90px; }

  .search-box,
  .split-head,
  .cta-box,
  .footer-inner {
    flex-direction: column;
    align-items: stretch;
  }
}