/* site_templates — light catalog look that fits Zettabyte design */

html { scroll-behavior: smooth; }

.st-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 980px) { .st-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .st-grid { grid-template-columns: 1fr; } }

.st-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s, border-color .2s, box-shadow .2s;
  text-decoration: none;
}
.st-card:hover {
  transform: translateY(-3px);
  border-color: #cbd5e1;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .08);
}
.st-card__media {
  position: relative;
  display: block;
  aspect-ratio: 1440 / 900;
  overflow: hidden;
  background: #eef2f6;
}
.st-card__media img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  transition: transform .4s;
}
.st-card:hover .st-card__media img { transform: scale(1.03); }
.st-card__badge {
  position: absolute; top: 12px; left: 12px;
  background: rgba(15, 23, 42, .85);
  color: #fff; padding: 5px 10px; border-radius: 999px;
  font-size: 12px; letter-spacing: .02em;
}
.st-card__body {
  padding: 16px 18px 18px;
  display: flex; flex-direction: column; gap: 10px; flex: 1;
}
.st-card__title {
  margin: 0; font-size: 16px; line-height: 1.3; font-weight: 600;
  color: var(--text-primary);
}
.st-card__title a { color: inherit; }
.st-card__title a:hover { color: var(--text-blue); }
.st-card__desc {
  margin: 0; color: var(--text-secondary); font-size: 14px; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.st-card__tags { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; }
.st-card__tags a {
  padding: 3px 10px; border-radius: 999px;
  background: var(--bg-pill); color: var(--text-secondary);
}
.st-card__tags a:hover { background: #e2e8f0; color: var(--text-primary); }
.st-card__actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.st-card__actions .btn { padding: 8px 12px; font-size: 13px; border-radius: 10px; }

/* category chips */
.st-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.st-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 999px; font-size: 13px;
  color: var(--text-primary);
}
.st-chip:hover { border-color: #94a3b8; }
.st-chip b { color: var(--text-muted); font-weight: 600; font-size: 11px; }
.st-chip.is-active { background: var(--bg-dark); color: #fff; border-color: var(--bg-dark); }
.st-chip.is-active b { color: rgba(255,255,255,.6); }

/* SEO tag links row */
.st-tag-links { display: flex; flex-wrap: wrap; gap: 8px; }
.st-tag-links a {
  padding: 6px 12px; border: 1px solid var(--border); background: var(--bg-card);
  border-radius: 999px; font-size: 13px; color: var(--text-primary);
}
.st-tag-links a:hover { border-color: var(--text-blue); color: var(--text-blue); }

/* pagination */
.st-pagination { display: flex; gap: 6px; justify-content: center; margin-top: 36px; flex-wrap: wrap; }
.st-page {
  display: inline-grid; place-items: center;
  min-width: 38px; height: 38px; padding: 0 12px;
  border-radius: 8px; border: 1px solid var(--border);
  background: var(--bg-card); color: var(--text-primary); font-size: 14px;
}
.st-page:hover { border-color: #94a3b8; }
.st-page.is-active { background: var(--bg-dark); border-color: var(--bg-dark); color: #fff; }

/* detail page */
.st-detail { padding: 8px 0 32px; }
.st-detail h1 { font-size: 28px; line-height: 1.2; margin: 0 0 12px; }
@media (min-width: 768px) { .st-detail h1 { font-size: 36px; } }
.st-detail__subtitle { margin: 0 0 14px; color: var(--text-secondary); font-size: 16px; max-width: 760px; }
.st-detail__meta { display: flex; flex-wrap: wrap; gap: 16px; color: var(--text-secondary); font-size: 14px; margin-bottom: 24px; }
.st-detail__meta a { color: var(--text-blue); }

.st-browser {
  border-radius: 14px; overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-muted);
  box-shadow: 0 12px 32px rgba(15, 23, 42, .08);
}
.st-browser__chrome {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  background: #f1f5f9;
  border-bottom: 1px solid var(--border);
}
.st-browser__dot { width: 11px; height: 11px; border-radius: 50%; flex: none; display: inline-block; }
.st-browser__dot--r { background: #ff5f57; }
.st-browser__dot--y { background: #febc2e; }
.st-browser__dot--g { background: #28c840; }
.st-browser__url {
  margin-left: 14px; flex: 1; background: #fff;
  border: 1px solid var(--border); border-radius: 7px;
  padding: 5px 11px; font-size: 12.5px; color: var(--text-secondary);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.st-browser__viewport { aspect-ratio: 1440 / 900; background: #fff; overflow: hidden; }
.st-browser__viewport img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }

.st-detail__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 24px; }

/* tech chips */
.st-tech { display: flex; gap: 8px; flex-wrap: wrap; }
.st-tech span {
  display: inline-flex; padding: 6px 12px; font-size: 13px; font-weight: 600;
  border-radius: 999px; border: 1px solid var(--border); background: var(--bg-card);
}
.st-tech .t-php { color: #6d4cd1; border-color: #d8ccf6; }
.st-tech .t-html { color: #c44a17; border-color: #f6cfb8; }
.st-tech .t-js { color: #b07e09; border-color: #f1de9d; }
.st-tech .t-css { color: #1d4ed8; border-color: #bfdbfe; }

/* features */
.st-features { margin-top: 40px; }
.st-feat {
  display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: center;
  padding: 20px 0; border-bottom: 1px solid var(--border);
}
.st-feat:last-child { border-bottom: none; }
.st-feat.is-right .st-feat__text { order: 2; }
.st-feat__text h3 { margin: 0 0 8px; font-size: 20px; }
.st-feat__text p { margin: 0; color: var(--text-secondary); }
.st-feat__media {
  border-radius: 14px; overflow: hidden;
  border: 1px solid var(--border); background: var(--bg-muted);
  aspect-ratio: 4 / 3;
}
.st-feat__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 780px) {
  .st-feat { grid-template-columns: 1fr; }
  .st-feat.is-right .st-feat__text { order: 0; }
}

/* install instructions — numbered step list */
.st-install {
  margin-top: 48px;
  padding: 28px 28px 24px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--bg-card);
  scroll-margin-top: 160px;
}
@media (max-width: 780px) { .st-install { padding: 22px 18px; scroll-margin-top: 140px; } }
.st-install__head { margin-bottom: 22px; }
.st-install__pill {
  display: inline-block; padding: 4px 12px;
  font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  color: #1d4ed8; background: #eff6ff; border-radius: 999px;
}
.st-install__title { margin: 12px 0 8px; font-size: 24px; font-weight: 700; letter-spacing: -.01em; }
@media (min-width: 780px) { .st-install__title { font-size: 28px; } }
.st-install__lede { margin: 0; color: var(--text-secondary); max-width: 760px; font-size: 15px; }

.st-steps { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.st-step {
  position: relative;
  display: grid; grid-template-columns: 44px 1fr; gap: 16px;
  padding: 18px 0;
  border-top: 1px solid var(--border);
}
.st-step:first-child { border-top: none; }
.st-step__num {
  display: grid; place-items: center;
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--bg-dark); color: #fff;
  font-weight: 800; font-size: 15px; letter-spacing: -.01em;
  margin-top: 2px;
}
.st-step__body h3 { margin: 0 0 6px; font-size: 17px; font-weight: 700; }
.st-step__body p { margin: 0 0 8px; color: var(--text-primary); }
.st-step__body p:last-child { margin-bottom: 0; }
.st-step__body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px; background: var(--bg-pill);
  padding: 1px 6px; border-radius: 5px;
  color: #1e293b;
}
.st-step__body a { color: var(--text-blue); text-decoration: underline; text-underline-offset: 2px; }
.st-step__body a:hover { text-decoration-thickness: 2px; }

.st-list { margin: 6px 0 8px 0; padding-left: 22px; }
.st-list li { margin: 3px 0; color: var(--text-primary); }

.st-code {
  margin: 8px 0;
  background: #0f172a; color: #e2e8f0;
  padding: 12px 14px; border-radius: 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px; line-height: 1.5;
  overflow-x: auto;
  white-space: pre;
}
.st-code b { color: #fde047; font-weight: 700; }

.st-install__hint {
  margin-top: 18px; padding: 14px 16px;
  background: var(--bg-pill); border-radius: 10px;
  font-size: 14px; color: var(--text-primary);
  border-left: 3px solid #0ea5e9;
}
.st-install__hint b { color: #0c4a6e; }

/* promo block — calm slate, distinct without screaming */
.st-promo {
  position: relative;
  margin-top: 48px;
  border-radius: 20px;
  overflow: hidden;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  isolation: isolate;
  color: var(--text-primary);
  box-shadow: 0 1px 3px rgba(15, 23, 42, .04);
}
.st-promo__bg {
  position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none;
}
.st-grid-bg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(15, 23, 42, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, .045) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 30%, #000 30%, transparent 85%);
}
.st-orb {
  position: absolute; border-radius: 50%;
  filter: blur(70px); opacity: .35;
}
.st-orb--1 { width: 360px; height: 360px; background: radial-gradient(circle, #cbd5e1, transparent 70%); top: -120px; left: -80px; }
.st-orb--2 { width: 320px; height: 320px; background: radial-gradient(circle, #bae6fd, transparent 70%); bottom: -120px; right: -60px; }
.st-orb--3 { display: none; }

.st-promo__inner { position: relative; z-index: 1; padding: 36px 36px; }
@media (max-width: 780px) { .st-promo__inner { padding: 28px 22px; } }

.st-promo__pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 12px; border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary); font-size: 12px; font-weight: 600;
  letter-spacing: .01em;
}
.st-promo__pill-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #0ea5e9;
  box-shadow: 0 0 0 3px rgba(14, 165, 233, .15);
}

.st-promo__title {
  margin: 16px 0 10px;
  font-size: 26px; line-height: 1.2; letter-spacing: -.01em; font-weight: 700;
  color: var(--text-primary);
}
@media (min-width: 780px) { .st-promo__title { font-size: 30px; } }
.st-promo__hl { color: #0f172a; font-weight: 800; }
.st-promo__lede {
  margin: 0 0 22px;
  color: var(--text-secondary);
  font-size: 15px; max-width: 720px;
}

.st-promo__cards {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px;
  margin: 0 0 24px;
}
@media (max-width: 980px) { .st-promo__cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .st-promo__cards { grid-template-columns: 1fr; } }

.st-srv {
  position: relative;
  padding: 16px 16px 14px;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 6px;
  transition: transform .15s, border-color .15s;
}
.st-srv:hover { transform: translateY(-2px); border-color: #cbd5e1; }
.st-srv__icon {
  width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center;
  background: var(--bg-pill);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.st-srv h3 { margin: 4px 0 0; font-size: 14px; font-weight: 700; color: var(--text-primary); }
.st-srv p { margin: 0; color: var(--text-secondary); font-size: 13px; line-height: 1.45; }

.st-promo__cta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

.st-btn-mega {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 20px; border-radius: 10px;
  font-weight: 600; font-size: 14px; letter-spacing: .01em;
  color: #fff;
  background: var(--bg-dark);
  border: 1px solid var(--bg-dark);
  transition: background .15s, transform .12s;
}
.st-btn-mega:hover { background: #1e293b; color: #fff; transform: translateY(-1px); }
.st-btn-mega:active { transform: translateY(0); }
.st-btn-mega svg { transition: transform .2s; }
.st-btn-mega:hover svg { transform: translateX(3px); }

/* hero subhead intro paragraph fits within hero */
.hero--st { display: flex; flex-direction: column; gap: 12px; }
.hero--st p { max-width: none; }
.hero--st .st-chips { margin-top: 6px; }

.st-section-title { margin: 32px 0 14px; font-size: 22px; font-weight: 600; }
