:root {
  --bg0: #03090a;
  --bg1: #071014;
  --text: #d7e9e3;
  --muted: #9ab2ab;
  --phosphor: #8ef7c4;
  --phosphor2: #77cfff;
  --panel0: #091315;
  --panel1: #0e1d20;
  --line: rgba(139, 238, 201, 0.24);
  --glow: rgba(117, 245, 188, 0.22);
  --danger: #ff8f78;
  --font_head: "Rubik", sans-serif;
  --font_body: "Assistant", sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: clip;
  color: var(--text);
  font-family: var(--font_body);
  background-color: var(--bg0);
  background-image:
    radial-gradient(110% 75% at 50% -12%, rgba(120, 189, 185, 0.18), transparent 58%),
    linear-gradient(162deg, var(--bg1) 0%, var(--bg0) 62%, #020607 100%),
    repeating-linear-gradient(
      0deg,
      rgba(168, 242, 213, 0.03) 0,
      rgba(168, 242, 213, 0.03) 1px,
      transparent 1px,
      transparent 3px
    ),
    repeating-linear-gradient(
      90deg,
      rgba(117, 177, 175, 0.018) 0,
      rgba(117, 177, 175, 0.018) 1px,
      transparent 1px,
      transparent 5px
    );
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}

body::before {
  z-index: -3;
  background: radial-gradient(circle at 50% 43%, transparent 38%, rgba(0, 0, 0, 0.64) 100%);
  opacity: 0.82;
}

body::after {
  z-index: -2;
  inset: -10%;
  background: radial-gradient(circle at 50% 35%, rgba(142, 247, 196, 0.24), transparent 62%);
  filter: blur(34px);
  opacity: 0.34;
  animation: pulse_glow 8s ease-in-out infinite alternate;
}

.site-shell {
  position: relative;
  min-height: 100vh;
}

.site-shell::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.18;
  background-image:
    repeating-linear-gradient(90deg, transparent 0 63px, rgba(142, 247, 196, 0.1) 63px 64px),
    repeating-linear-gradient(0deg, transparent 0 63px, rgba(142, 247, 196, 0.08) 63px 64px);
  animation: grid_drift 20s linear infinite;
}

.container {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

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

a {
  color: inherit;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.2;
  font-family: var(--font_head);
}

p {
  margin: 0;
}

.sr-only {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.micro-label {
  margin: 10px 0px 5px 0px;
  color: rgba(181, 220, 206, 0.66);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
}
.micro-label a {
  text-decoration: none;
  color: var(--phosphor);
}

.site-header {
  position: relative;
  margin: 1rem 0 1.4rem;
  padding: 0.6rem 0 0.55rem;
  border: 1px solid rgba(142, 247, 196, 0.24);
  background: linear-gradient(146deg, rgba(9, 18, 20, 0.92), rgba(8, 14, 16, 0.9));
  box-shadow:
    0 0 0 1px rgba(6, 13, 14, 0.92),
    0 0 0 1px rgba(146, 248, 207, 0.2) inset,
    0 18px 42px rgba(0, 0, 0, 0.36),
    0 0 32px rgba(110, 240, 184, 0.08);
}

.site-header::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(114, 176, 165, 0.22);
  pointer-events: none;
}

.site-header::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 3px;
  background: repeating-linear-gradient(
    90deg,
    rgba(154, 255, 215, 0.28) 0 5px,
    rgba(154, 255, 215, 0.04) 5px 11px
  );
}

.header-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 0.65rem;
  padding: 0.3rem 0 0.7rem;
}

.site-logo {
  display: inline-block;
  max-inline-size: 14ch;
  line-height: 1.04;
  word-break: break-word;
  text-decoration: none;
  font-size: clamp(1.35rem, 5.8vw, 2.2rem);
  background: linear-gradient(180deg, #e8fdf5 10%, #b7f5dc 48%, #8fd7ff 120%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 20px rgba(141, 247, 196, 0.26);
}

.circuit-icon {
  width: clamp(88px, 22vw, 132px);
  height: auto;
  stroke: rgba(149, 243, 209, 0.72);
  fill: none;
  stroke-width: 1.3;
  opacity: 0.86;
}

.circuit-icon circle {
  fill: rgba(119, 207, 255, 0.88);
  stroke: none;
}

.menu-toggle {
  appearance: none;
  border: 1px solid rgba(145, 243, 207, 0.44);
  background: linear-gradient(140deg, rgba(8, 18, 20, 0.96), rgba(8, 16, 18, 0.9));
  color: var(--text);
  width: 2.75rem;
  height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 0 1px rgba(86, 149, 136, 0.22) inset;
}

.menu-toggle svg {
  width: 1.25rem;
  height: 1.25rem;
}

.main-nav {
  display: none;
}

.main-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
}

.main-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.15rem;
  padding: 0.4rem 0.82rem;
  border: 1px solid rgba(130, 201, 186, 0.3);
  background: rgba(10, 22, 24, 0.56);
  color: #c9e6de;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.main-nav a[aria-current="page"] {
  border-color: rgba(142, 247, 196, 0.72);
  color: #e5fff4;
  box-shadow: 0 0 0 1px rgba(144, 242, 205, 0.35) inset, 0 0 22px rgba(115, 237, 190, 0.18);
}

.menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 35;
  opacity: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 35%, rgba(36, 72, 66, 0.2), rgba(0, 0, 0, 0.78)),
    repeating-linear-gradient(0deg, rgba(142, 247, 196, 0.08) 0 1px, transparent 1px 4px);
  transition: opacity 0.23s ease;
}

.menu-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-panel {
  position: fixed;
  inset-block: 0;
  right: 0;
  width: min(88vw, 22rem);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.35rem 1rem 1.1rem;
  transform: translateX(110%);
  border-inline-start: 1px solid rgba(137, 231, 196, 0.38);
  background: linear-gradient(160deg, rgba(8, 18, 20, 0.98), rgba(6, 12, 14, 0.98));
  box-shadow:
    0 0 0 1px rgba(155, 247, 214, 0.16) inset,
    -20px 0 44px rgba(0, 0, 0, 0.58);
  transition: transform 0.24s ease;
}

.mobile-panel.is-open {
  transform: translateX(0);
}

.mobile-nav {
  display: grid;
  gap: 0.55rem;
}

.mobile-nav a {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.8rem;
  padding: 0.55rem 0.72rem;
  border: 1px solid rgba(128, 206, 190, 0.34);
  background: rgba(10, 22, 25, 0.72);
  color: #d4ece5;
  text-decoration: none;
  font-size: 1.07rem;
  font-weight: 700;
}

.mobile-nav a::before {
  content: "";
  inline-size: 0.52rem;
  block-size: 0.52rem;
  border: 1px solid rgba(122, 217, 255, 0.9);
  background: rgba(122, 217, 255, 0.34);
  box-shadow: 0 0 10px rgba(122, 217, 255, 0.36);
}

body.menu-open {
  overflow: hidden;
}

main {
  padding-bottom: 2.4rem;
}

.page-hero {
  margin-bottom: 1.2rem;
}

.page-title {
  margin-bottom: 0.78rem;
  font-size: clamp(2rem, 8vw, 3.5rem);
  background: linear-gradient(180deg, #e9fcf7 6%, #baf8df 42%, #8ec0ff 118%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 24px rgba(146, 248, 206, 0.22);
}

.lead {
  max-inline-size: 66ch;
  line-height: 1.78;
  color: var(--muted);
  font-size: 1.05rem;
}

.wave-divider {
  margin-block: 0.8rem 1.4rem;
}

.wave-divider svg {
  display: block;
  width: 100%;
  height: 30px;
  stroke: rgba(146, 247, 208, 0.84);
  stroke-width: 1.8;
  fill: none;
}

.section-head {
  margin-bottom: 0.75rem;
  display: grid;
  gap: 0.28rem;
}

.section-head h2 {
  color: #dff9f0;
  font-size: clamp(1.45rem, 4vw, 1.9rem);
}

.post-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.post-card {
  position: relative;
  isolation: isolate;
  padding: 0.45rem;
  border: 1px solid rgba(138, 234, 199, 0.24);
  background: linear-gradient(160deg, var(--panel1), var(--panel0));
  box-shadow:
    0 0 0 1px rgba(8, 15, 16, 0.94),
    0 0 0 1px rgba(124, 209, 188, 0.22) inset,
    0 0 26px rgba(114, 233, 186, 0.13);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.post-card::before,
.post-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.post-card::before {
  inset: 2px;
  border: 1px solid rgba(158, 247, 212, 0.32);
}

.post-card::after {
  inset: 6px;
  border: 1px solid rgba(111, 174, 158, 0.18);
}

.card-shell {
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, rgba(12, 28, 30, 0.95), rgba(8, 18, 20, 0.96));
}

.card-shell::before,
.card-shell::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.card-shell::before {
  inset: -45% 38% -45% -92%;
  opacity: 0.22;
  transform: translateX(-38%) rotate(15deg);
  background: linear-gradient(116deg, transparent 42%, rgba(217, 255, 246, 0.2) 51%, transparent 59%);
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.card-shell::after {
  inset: 0;
  opacity: 0.08;
  background: repeating-linear-gradient(
    0deg,
    rgba(168, 241, 209, 0.08) 0,
    rgba(168, 241, 209, 0.08) 1px,
    transparent 1px,
    transparent 4px
  );
  transition: opacity 0.3s ease, background-position 0.3s ease;
}

.card-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  min-height: 2rem;
  padding: 0.4rem 0.62rem;
  border-bottom: 1px solid rgba(146, 233, 202, 0.2);
}

.card-lights {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
}

.card-lights span {
  inline-size: 0.54rem;
  block-size: 0.54rem;
  border-radius: 50%;
  border: 1px solid rgba(8, 16, 17, 0.56);
  box-shadow: 0 0 8px rgba(133, 225, 191, 0.2);
}

.card-lights span:nth-child(1) {
  background: rgba(142, 247, 196, 0.75);
}

.card-lights span:nth-child(2) {
  background: rgba(119, 207, 255, 0.74);
}

.card-lights span:nth-child(3) {
  background: rgba(255, 143, 120, 0.65);
}

.card-code {
  color: rgba(170, 217, 199, 0.72);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.21em;
}

.card-image {
  display: block;
  border-bottom: 1px solid rgba(136, 205, 186, 0.18);
}

.card-image img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  filter: saturate(0.9) contrast(1.06);
}

.card-body {
  padding: 0.72rem;
  display: grid;
  gap: 0.5rem;
}

.card-title {
  font-size: clamp(1.08rem, 3.2vw, 1.3rem);
  letter-spacing: 0.01em;
}

.card-title a {
  text-decoration: none;
  color: #dcf8ef;
}

.card-date {
  color: rgba(127, 216, 255, 0.88);
  font-size: 0.87rem;
  letter-spacing: 0.03em;
}

.card-excerpt {
  color: var(--muted);
  line-height: 1.65;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.article-view {
  position: relative;
  padding: 0.66rem;
  border: 1px solid rgba(136, 224, 191, 0.25);
  background: linear-gradient(166deg, rgba(10, 21, 24, 0.95), rgba(7, 15, 17, 0.96));
  box-shadow:
    0 0 0 1px rgba(7, 13, 14, 0.94),
    0 0 0 1px rgba(136, 221, 191, 0.2) inset,
    0 0 28px rgba(109, 235, 186, 0.11);
}

.article-view::before {
  content: "";
  position: absolute;
  inset: 5px;
  border: 1px solid rgba(111, 184, 163, 0.2);
  pointer-events: none;
}

.article-meta {
  margin-top: 0.58rem;
  color: rgba(126, 212, 252, 0.86);
  font-size: 0.93rem;
}

.article-media {
  margin: 1rem 0;
  padding: 0.36rem;
  border: 1px solid rgba(138, 224, 196, 0.24);
  background: rgba(9, 20, 22, 0.84);
}

.article-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.article-content {
  display: grid;
  gap: 1rem;
}

.article-content p {
  line-height: 1.82;
  color: #cde2db;
}

.article-content h2 {
  margin-top: 0.4rem;
  font-size: clamp(1.25rem, 3.8vw, 1.65rem);
  color: #d7faec;
}

.article-content ul {
  margin: 0;
  padding-inline: 1rem 1.2rem;
  color: #cde2db;
  line-height: 1.75;
}

.more-posts {
  margin-top: 2rem;
}

.more-posts h2 {
  margin-top: 0.15rem;
}

.home-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
  min-height: 2.5rem;
  padding: 0.45rem 1rem;
  border: 1px solid rgba(137, 229, 195, 0.42);
  text-decoration: none;
  font-weight: 700;
  color: #ddf9ee;
  box-shadow: 0 0 18px rgba(111, 230, 185, 0.17);
}

.site-footer {
  margin-top: 2rem;
  padding: 1.2rem 0 1.6rem;
  border-top: 1px solid rgba(130, 216, 186, 0.28);
  background: linear-gradient(180deg, rgba(9, 16, 18, 0.93), rgba(8, 13, 15, 0.95));
  box-shadow: 0 -10px 26px rgba(116, 239, 191, 0.08);
}

.footer-wave {
  margin-bottom: 0.9rem;
}

.footer-wave svg {
  width: 100%;
  height: 28px;
  stroke: rgba(142, 247, 196, 0.74);
  stroke-width: 1.6;
  fill: none;
}

.footer-top {
  display: grid;
  gap: 0.8rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  font-size: clamp(1.1rem, 3.7vw, 1.34rem);
  color: #d8f8ec;
}

.sigil-mark {
  width: 1.45rem;
  height: 1.45rem;
  stroke: rgba(142, 247, 196, 0.8);
  stroke-width: 1.5;
  fill: none;
}

.footer-nav {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0;
  padding: 0;
}

.footer-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid rgba(127, 198, 182, 0.28);
  text-decoration: none;
  color: #c6ddd6;
}

.copyright {
  margin-top: 0.7rem;
  color: rgba(165, 193, 184, 0.78);
  font-size: 0.82rem;
}

.error-shell {
  margin-top: 0.75rem;
  padding: 0.7rem;
  border: 1px solid rgba(255, 143, 120, 0.36);
  background: linear-gradient(165deg, rgba(20, 13, 14, 0.93), rgba(11, 10, 12, 0.96));
  box-shadow:
    0 0 0 1px rgba(28, 15, 15, 0.9),
    0 0 0 1px rgba(255, 143, 120, 0.16) inset,
    0 0 28px rgba(255, 143, 120, 0.14);
}

.warning-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.34rem 0.62rem;
  border: 1px solid rgba(255, 143, 120, 0.46);
  color: rgba(255, 173, 156, 0.94);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

.warning-chip::before {
  content: "";
  inline-size: 0.5rem;
  block-size: 0.5rem;
  border-radius: 50%;
  background: rgba(255, 143, 120, 0.9);
  box-shadow: 0 0 12px rgba(255, 143, 120, 0.66);
}

.error-page .page-title {
  background: linear-gradient(180deg, #ffe5df 8%, #ffc2b5 48%, #ff9f8b 118%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 22px rgba(255, 143, 120, 0.28);
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--phosphor);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px rgba(142, 247, 196, 0.26);
}

@media (hover: hover) {
  .post-card:hover {
    transform: translateY(-5px);
    box-shadow:
      0 0 0 1px rgba(7, 14, 15, 0.95),
      0 0 0 1px rgba(136, 228, 194, 0.26) inset,
      0 0 34px rgba(114, 242, 194, 0.24);
  }

  .post-card:hover .card-shell::before {
    opacity: 0.45;
    transform: translateX(52%) rotate(15deg);
  }

  .post-card:hover .card-shell::after {
    opacity: 0.15;
    background-position: 0 2px;
  }

  .post-card:hover .card-title a {
    color: #f0fff8;
    text-shadow: 1px 0 rgba(142, 247, 196, 0.23), -1px 0 rgba(119, 207, 255, 0.16);
  }

  .main-nav a:hover,
  .footer-nav a:hover,
  .home-link:hover,
  .mobile-nav a:hover {
    border-color: rgba(142, 247, 196, 0.72);
    box-shadow: 0 0 20px rgba(111, 234, 188, 0.18);
    color: #e8fff7;
  }
}

@media (min-width: 700px) {
  .post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 980px) {
  .site-header {
    margin-top: 1.2rem;
  }

  .header-row {
    grid-template-columns: 1fr auto;
  }

  .menu-toggle {
    display: none;
  }

  .main-nav {
    display: block;
  }

  .mobile-panel,
  .menu-overlay {
    display: none;
  }

  .footer-top {
    grid-template-columns: auto 1fr;
    align-items: center;
  }

  .footer-nav {
    justify-self: end;
  }
}

@media (min-width: 1220px) {
  .post-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .more-posts .post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }

  body::after {
    filter: none;
  }

  .post-card:hover {
    transform: none;
  }
}

@keyframes pulse_glow {
  from {
    opacity: 0.28;
    transform: scale(1);
  }

  to {
    opacity: 0.4;
    transform: scale(1.03);
  }
}

@keyframes grid_drift {
  from {
    background-position: 0 0, 0 0;
  }

  to {
    background-position: 38px 0, 0 38px;
  }
}
