/* element pages, elements hub, 404 (static, no JS) */
:root {
  --ep-bg: #06070f;
  --ep-bg-2: #0c0e1d;
  --ep-panel: rgba(255, 255, 255, .045);
  --ep-line: rgba(255, 255, 255, .09);
  --ep-text: #eef1fb;
  --ep-muted: #99a1bd;
  --ep-brand: #7c5cff;
  --ep-brand-2: #00d4ff;
}
body.light-theme {
  --ep-bg: #f4f6fc;
  --ep-bg-2: #e9edf8;
  --ep-panel: rgba(255, 255, 255, .85);
  --ep-line: rgba(20, 26, 56, .12);
  --ep-text: #141a38;
  --ep-muted: #59608a;
  --ep-brand: #5b3df0;
  --ep-brand-2: #0083c8;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Vazirmatn", system-ui, sans-serif;
  background: var(--ep-bg);
  color: var(--ep-text);
  line-height: 1.9;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: var(--ep-brand-2); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.5; margin: 0 0 .6rem; }
h1 { font-size: clamp(1.5rem, 4vw, 2.1rem); }
h2 { font-size: 1.2rem; }
h3 { font-size: 1.02rem; margin-top: 1.1rem; }
p { margin: 0 0 .8rem; }

.ep-wrap { width: min(1080px, 100% - 2rem); margin-inline: auto; }
main.ep-wrap { flex: 1; padding-block: 1.2rem 2.5rem; }

/* header */
.ep-header { border-bottom: 1px solid var(--ep-line); background: var(--ep-bg-2); }
.ep-header-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-block: .7rem; }
.ep-logo { display: inline-flex; align-items: center; gap: .55rem; color: var(--ep-text); font-weight: 700; white-space: nowrap; flex-shrink: 0; }
.ep-logo:hover { text-decoration: none; }
.ep-nav { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; font-size: .9rem; }
.ep-nav a { color: var(--ep-muted); }
.ep-nav a:hover { color: var(--ep-brand-2); text-decoration: none; }

/* breadcrumbs */
.ep-crumbs { font-size: .82rem; color: var(--ep-muted); margin-bottom: 1rem; }
.ep-crumbs a { color: var(--ep-muted); }

/* hero */
.ep-hero { display: flex; gap: 1.4rem; align-items: center; margin-bottom: 1.4rem; }
.ep-tile {
  --c: hsl(var(--hue, 220) 80% 58%);
  flex: 0 0 auto;
  width: 132px; height: 132px;
  border-radius: 18px;
  display: grid; place-items: center; align-content: center; text-align: center;
  border: 2px solid var(--c);
  background: color-mix(in srgb, var(--c) 16%, transparent);
  direction: ltr;
}
.ep-tile small { font-size: .82rem; color: var(--ep-muted); }
.ep-tile strong { font-size: 2.6rem; line-height: 1.1; color: var(--c); }
.ep-tile span { font-size: .85rem; direction: rtl; }
.ep-hero-text { min-width: 0; }
.ep-lead { color: var(--ep-muted); font-size: 1.02rem; }

.ep-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .8rem; }
.ep-btn {
  display: inline-block; padding: .5rem 1.05rem; border-radius: 10px; font-size: .9rem;
  border: 1px solid var(--ep-line); background: var(--ep-panel); color: var(--ep-text);
}
.ep-btn:hover { text-decoration: none; border-color: var(--ep-brand-2); }
.ep-btn-main { background: var(--ep-brand); border-color: var(--ep-brand); color: #fff; }

/* cards */
.ep-card { background: var(--ep-panel); border: 1px solid var(--ep-line); border-radius: 14px; padding: 1.1rem 1.2rem; margin-bottom: 1rem; }
.ep-note { background: var(--ep-panel); border: 1px dashed var(--ep-line); border-radius: 10px; padding: .6rem .9rem; color: var(--ep-muted); font-size: .9rem; }

.ep-dl { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .5rem .9rem; margin: 0; }
.ep-dl div { display: flex; justify-content: space-between; gap: .8rem; padding: .35rem 0; border-bottom: 1px solid var(--ep-line); }
.ep-dl dt { color: var(--ep-muted); }
.ep-dl dd { margin: 0; font-weight: 600; text-align: left; }

.ep-shells { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 0; }
.ep-shells li { display: inline-flex; align-items: center; gap: .45rem; border: 1px solid var(--ep-line); border-radius: 999px; padding: .15rem .8rem; }
.ep-shell-name { color: var(--ep-muted); font-weight: 700; }
.ep-shell-n { font-weight: 700; color: var(--ep-brand-2); }

.ep-list { margin: 0; padding-inline-start: 1.3rem; }
.ep-faq p { color: var(--ep-muted); margin-bottom: .3rem; }
.ep-chips { display: flex; flex-wrap: wrap; gap: .45rem; margin: 0; }
.ep-chips a { border: 1px solid var(--ep-line); border-radius: 999px; padding: .1rem .75rem; font-size: .88rem; color: var(--ep-text); }
.ep-chips a:hover { border-color: var(--ep-brand-2); text-decoration: none; }
.ep-cat-info { color: var(--ep-muted); font-size: .92rem; }
.ep-card h2 small { color: var(--ep-muted); font-weight: 400; font-size: .85rem; }

.ep-pager { display: flex; justify-content: space-between; gap: 1rem; margin-block: 1.4rem 0; }
.ep-pager a { display: block; border: 1px solid var(--ep-line); border-radius: 12px; padding: .6rem 1rem; background: var(--ep-panel); color: var(--ep-text); }
.ep-pager small { display: block; color: var(--ep-muted); font-size: .75rem; }
.ep-pager a:hover { text-decoration: none; border-color: var(--ep-brand-2); }
.ep-next { text-align: left; }

.ep-table-wrap { overflow-x: auto; }
.ep-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.ep-table th, .ep-table td { padding: .4rem .6rem; border-bottom: 1px solid var(--ep-line); text-align: right; white-space: nowrap; }
.ep-table th { color: var(--ep-muted); font-weight: 600; }

.ep-404 { text-align: center; margin-top: 2rem; }
.ep-404 .ep-actions { justify-content: center; }

/* footer */
.ep-footer { border-top: 1px solid var(--ep-line); background: var(--ep-bg-2); padding-block: 1.1rem; font-size: .85rem; color: var(--ep-muted); }
.ep-footer-links { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; margin-bottom: .4rem; }
.ep-footer-links a { color: var(--ep-muted); }
.ep-footer p { margin: 0; }

@media (max-width: 640px) {
  .ep-hero { flex-direction: column; align-items: flex-start; }
  .ep-tile { width: 108px; height: 108px; }
  .ep-tile strong { font-size: 2.1rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .ep-btn, .ep-chips a, .ep-pager a { transition: border-color .15s ease; }
}

/* electron configuration */
.ep-cfg { margin: 0 0 .8rem; display: grid; gap: .5rem; }
.ep-cfg > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1rem; padding: .5rem .8rem; border: 1px solid var(--ep-line); border-radius: 10px; background: var(--ep-panel); }
.ep-cfg dt { color: var(--ep-muted); font-size: .85rem; min-width: 6.5rem; }
.ep-cfg dd { margin: 0; font-weight: 600; font-size: 1.02rem; letter-spacing: .02em; word-spacing: .15em; direction: ltr; }
.ep-cfg-last { border-color: var(--ep-brand-2) !important; }
.ep-cfg-last dd { color: var(--ep-brand-2); font-size: 1.15rem; }
.ep-cfg-line { color: var(--ep-muted); letter-spacing: .03em; }
.ep-cfgcell { direction: ltr; text-align: left !important; }
.ep-lead bdi, .ep-list bdi, .ep-cat-info bdi { font-weight: 600; }
