/* ============================================================
   GLASS BLOG — Glassmorphism Theme
   Palette: White / Half-White / Black / Dark Black / Blue
   Font: Montserrat
   Pure HTML/CSS/JS — Hostinger copy-paste friendly
   ============================================================ */

/* ---------- Color tokens ---------- */
:root {
  --white:       #ffffff;
  --half-white:  #e9edf5;   /* soft off-white */
  --black:       #000000;
  --dark-black:  #0a0d14;   /* deep near-black background */
  --blue:        #2f6bff;   /* accent blue */
  --blue-soft:   rgba(47, 107, 255, 0.35);

  /* Glass surfaces */
  --glass-bg:      rgba(255, 255, 255, 0.08);
  --glass-bg-2:    rgba(255, 255, 255, 0.05);
  --glass-border:  rgba(255, 255, 255, 0.18);
  --glass-shadow:  0 8px 32px rgba(0, 0, 0, 0.45);
  --blur:          18px;

  --text:        var(--half-white);
  --text-dim:    rgba(233, 237, 245, 0.62);
  --radius:      20px;
  --maxw:        1140px;
}

/* ---------- Reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: "Montserrat", "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: var(--dark-black);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* ---------- Animated background blobs ---------- */
body::before,
body::after {
  content: "";
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  z-index: -2;
  opacity: 0.55;
  animation: float 18s ease-in-out infinite alternate;
}
body::before {
  width: 480px; height: 480px;
  background: var(--blue);
  top: -120px; left: -100px;
}
body::after {
  width: 420px; height: 420px;
  background: #1b3a8a;
  bottom: -140px; right: -90px;
  animation-delay: -6s;
}
@keyframes float {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(60px, 40px) scale(1.15); }
}

/* Subtle grid overlay */
body { background-image:
  radial-gradient(circle at 20% 20%, rgba(47,107,255,0.10), transparent 40%),
  radial-gradient(circle at 80% 80%, rgba(47,107,255,0.08), transparent 40%);
}

/* ---------- Layout helper ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Glass utility ---------- */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: var(--radius);
}

/* ============================================================
   NAVBAR
   ============================================================ */
.nav {
  position: sticky;
  top: 16px;
  z-index: 50;
  margin: 16px auto 0;
  max-width: var(--maxw);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
}
.nav__brand {
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: 0.5px;
  color: var(--white);
  text-decoration: none;
  display: flex; align-items: center; gap: 10px;
}
.nav__dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 14px var(--blue);
}
.nav__links { display: flex; gap: 8px; list-style: none; }
.nav__links a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 8px 16px;
  border-radius: 999px;
  transition: background 0.25s, color 0.25s;
}
.nav__links a:hover,
.nav__links a.active {
  background: var(--blue);
  color: var(--white);
}
.nav__toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 5px;
}
.nav__toggle span {
  width: 24px; height: 2px; background: var(--white); border-radius: 2px;
  transition: 0.3s;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  text-align: center;
  padding: 90px 24px 60px;
  max-width: 860px;
  margin: 0 auto;
}
.hero__badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: 18px;
}
.hero h1 span { color: var(--blue); }
.hero p {
  font-size: 1.1rem;
  color: var(--text-dim);
  max-width: 620px;
  margin: 0 auto 32px;
}
.hero__cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
  font-family: inherit;
  font-weight: 600;
  font-size: 0.98rem;
  padding: 13px 28px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.btn--primary {
  background: var(--blue);
  color: var(--white);
  box-shadow: 0 8px 24px var(--blue-soft);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px var(--blue-soft); }
.btn--ghost {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--white);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}
.btn--ghost:hover { transform: translateY(-2px); background: var(--glass-bg-2); }

/* ============================================================
   SECTION TITLES
   ============================================================ */
.section { padding: 40px 0 20px; }
.section__head {
  display: flex; align-items: end; justify-content: space-between;
  margin-bottom: 28px; flex-wrap: wrap; gap: 12px;
}
.section__head h2 {
  font-size: 1.8rem; font-weight: 800; color: var(--white);
}
.section__head p { color: var(--text-dim); font-size: 0.95rem; }

/* ============================================================
   BLOG GRID + CARDS
   ============================================================ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.card {
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}
.card:hover {
  transform: translateY(-6px);
  border-color: var(--blue-soft);
  box-shadow: 0 16px 40px rgba(0,0,0,0.55);
}
.card__img {
  height: 190px;
  background-size: cover;
  background-position: center;
  position: relative;
}
.card__img::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(10,13,20,0.7), transparent 60%);
}
.card__tag {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  background: var(--blue);
  color: var(--white);
  font-size: 0.72rem; font-weight: 600;
  padding: 5px 12px; border-radius: 999px;
  letter-spacing: 0.5px;
}
.card__body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.card__meta { font-size: 0.78rem; color: var(--text-dim); margin-bottom: 10px; }
.card__body h3 {
  font-size: 1.2rem; font-weight: 700; color: var(--white);
  margin-bottom: 10px; line-height: 1.3;
}
.card__body p { font-size: 0.92rem; color: var(--text-dim); margin-bottom: 18px; flex: 1; }
.card__link {
  color: var(--blue); font-weight: 600; font-size: 0.9rem;
  text-decoration: none; display: inline-flex; align-items: center; gap: 6px;
  transition: gap 0.2s;
}
.card__link:hover { gap: 12px; }

/* ============================================================
   NEWSLETTER / CTA STRIP
   ============================================================ */
.subscribe {
  margin: 60px 0;
  padding: 48px 32px;
  text-align: center;
}
.subscribe h2 { font-size: 1.9rem; color: var(--white); font-weight: 800; margin-bottom: 12px; }
.subscribe p { color: var(--text-dim); margin-bottom: 26px; }
.subscribe form {
  display: flex; gap: 12px; max-width: 460px; margin: 0 auto; flex-wrap: wrap;
}
.subscribe input {
  flex: 1; min-width: 200px;
  padding: 13px 20px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: rgba(255,255,255,0.06);
  color: var(--white);
  font-family: inherit; font-size: 0.95rem;
  outline: none;
}
.subscribe input::placeholder { color: var(--text-dim); }
.subscribe input:focus { border-color: var(--blue); }

/* ============================================================
   SINGLE POST (post.html)
   ============================================================ */
.article { max-width: 800px; margin: 40px auto; padding: 0 24px; }
.article__hero {
  height: 340px; border-radius: var(--radius);
  background-size: cover; background-position: center;
  margin-bottom: 30px; position: relative;
}
.article__meta { color: var(--text-dim); font-size: 0.88rem; margin-bottom: 14px; }
.article h1 {
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  color: var(--white); font-weight: 800; line-height: 1.15; margin-bottom: 24px;
}
.article__content { padding: 36px; }
.article__content h2 { color: var(--white); font-size: 1.5rem; margin: 28px 0 14px; font-weight: 700; }
.article__content p { color: var(--text); margin-bottom: 18px; }
.article__content blockquote {
  border-left: 3px solid var(--blue);
  padding: 8px 20px; margin: 24px 0;
  color: var(--text-dim); font-style: italic;
  background: rgba(47,107,255,0.06); border-radius: 0 12px 12px 0;
}
.article__content a { color: var(--blue); }

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.about { max-width: 820px; margin: 40px auto; padding: 0 24px; }
.about__card { padding: 40px; }
.about__card h1 { color: var(--white); font-size: 2.2rem; font-weight: 800; margin-bottom: 20px; }
.about__card p { color: var(--text); margin-bottom: 16px; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  margin-top: 60px;
  padding: 40px 24px 30px;
  text-align: center;
  border-top: 1px solid var(--glass-border);
}
.footer__brand { color: var(--white); font-weight: 800; font-size: 1.2rem; margin-bottom: 12px; }
.footer__social { display: flex; gap: 14px; justify-content: center; margin-bottom: 18px; }
.footer__social a {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  color: var(--white); text-decoration: none; font-weight: 700;
  transition: background 0.25s;
}
.footer__social a:hover { background: var(--blue); }
.footer p { color: var(--text-dim); font-size: 0.85rem; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 760px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute; top: 70px; right: 24px; left: 24px;
    flex-direction: column;
    padding: 16px;
    background: rgba(10,13,20,0.92);
    backdrop-filter: blur(var(--blur));
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    display: none;
  }
  .nav__links.open { display: flex; }
}

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s, transform 0.6s; }
.reveal.visible { opacity: 1; transform: translateY(0); }
