/* AgileAlert — Shared Blog & Article Stylesheet */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700&display=swap');

:root {
  --bg:     #000000;
  --dark1:  #0a0a0f;
  --dark2:  #0e0e12;
  --panel:  #111117;
  --border: rgba(255,255,255,.09);
  --text:   #f5f5f7;
  --text2:  #d1d1d6;
  --muted:  #a1a1a6;
  --green:  #00d4aa;
  --blue:   #3b9eff;
  --yellow: #f59e0b;
  --red:    #ff5c5c;
}

@keyframes pulse {
  0%,100% { opacity:1; box-shadow:0 0 0 0 rgba(0,212,170,.5) }
  60%      { opacity:.7; box-shadow:0 0 0 8px rgba(0,212,170,0) }
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0 }
html { scroll-behavior: smooth }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', system-ui, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit }
img { max-width: 100%; display: block }

/* =====================
   NAV
   ===================== */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 68px;
  background: rgba(0,0,0,.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,.07);
}

/* Logo */
.nav-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}
.nav-logo::after { content: none }
.nav-logo img, .nav-logo svg { height: 32px; width: auto; display: block; max-width: 180px }

.nav-logo span { color: var(--green) }

/* Centre nav links */
.nav-links {
  display: flex;
  gap: 36px;
}
.nav-links a {
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,.55);
  letter-spacing: .02em;
  transition: color .2s;
}
.nav-links a:hover { color: var(--text) }

/* Right side */
.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* CTA pill button */
.nav-cta {
  background: var(--green);
  color: #000 !important;
  padding: 9px 20px;
  border-radius: 9999px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  transition: opacity .2s, transform .15s;
  white-space: nowrap;
}
.nav-cta:hover { opacity: .88; transform: translateY(-1px) }

/* =====================
   ARTICLE LAYOUT
   ===================== */
.article-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 96px;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.article-tag {
  display: inline-block;
  background: rgba(0,212,170,.1);
  border: 1px solid rgba(0,212,170,.2);
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 9999px;
  letter-spacing: .8px;
  text-transform: uppercase;
}
.article-date, .article-read {
  font-size: 13px;
  color: var(--muted);
  font-family: 'DM Sans', sans-serif;
}

h1.article-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -.02em;
  margin-bottom: 20px;
  color: var(--text);
}

.article-intro {
  font-size: 19px;
  color: var(--text2);
  line-height: 1.75;
  margin-bottom: 36px;
  border-left: 3px solid var(--green);
  padding-left: 20px;
  font-family: 'DM Sans', sans-serif;
}

/* Article body text */
.article-body h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 400;
  margin: 48px 0 16px;
  color: var(--text);
  letter-spacing: -.01em;
  line-height: 1.2;
}
.article-body h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 32px 0 12px;
  color: var(--text);
}
.article-body p {
  font-size: 17px;
  color: var(--text2);
  line-height: 1.82;
  margin-bottom: 20px;
}
.article-body strong { color: var(--text); font-weight: 700 }
.article-body a { color: var(--green) }
.article-body a:hover { text-decoration: underline }
.article-body ul, .article-body ol {
  margin: 0 0 20px 22px;
  color: var(--text2);
}
.article-body li {
  margin-bottom: 9px;
  font-size: 17px;
  line-height: 1.7;
}

/* Tables */
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0 32px;
  font-size: 14px;
  border-radius: 10px;
  overflow: hidden;
}
.article-body th {
  text-align: left;
  padding: 11px 16px;
  background: rgba(255,255,255,.04);
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .5px;
  font-family: 'DM Sans', sans-serif;
}
.article-body td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,.05);
  color: var(--text2);
  font-size: 15px;
}
.article-body tr:last-child td { border-bottom: none }
.article-body tr:hover td { background: rgba(255,255,255,.02) }
.saving { color: var(--green); font-weight: 700 }

/* =====================
   CTA BOX
   ===================== */
.cta-box {
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,212,170,.07) 0%, transparent 70%),
              var(--dark2);
  border: 1px solid rgba(0,212,170,.2);
  border-radius: 16px;
  padding: 32px;
  margin: 40px 0;
  text-align: center;
}
.cta-box h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.7rem;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 10px;
  line-height: 1.2;
}
.cta-box p {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 20px;
  line-height: 1.6;
}
.cta-btn {
  display: inline-block;
  background: var(--green);
  color: #000;
  padding: 13px 28px;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: .1em;
  text-transform: uppercase;
  transition: opacity .2s, transform .15s;
}
.cta-btn:hover { opacity: .88; transform: translateY(-1px) }

/* =====================
   FAQ
   ===================== */
.faq-item {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px 24px;
  margin-bottom: 12px;
  transition: border-color .2s;
}
.faq-item:hover { border-color: rgba(0,212,170,.2) }
.faq-q {
  font-weight: 700;
  margin-bottom: 10px;
  font-size: 16px;
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
}
.faq-a {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.75;
}

/* =====================
   RELATED ARTICLES GRID
   ===================== */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.related-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
  transition: border-color .2s, transform .2s;
  display: block;
}
.related-card:hover {
  border-color: var(--green);
  transform: translateY(-2px);
}
.related-card .tag {
  font-size: 11px;
  color: var(--green);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  margin-bottom: 7px;
  display: block;
}
.related-card .title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

/* =====================
   BLOG INDEX PAGE
   ===================== */

/* Filter tabs */
.filter-wrap {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}
.filter-btn {
  background: var(--panel);
  border: 1px solid var(--border);
  color: var(--muted);
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s;
  letter-spacing: .02em;
}
.filter-btn:hover { border-color: rgba(0,212,170,.3); color: var(--text) }
.filter-btn.active {
  background: var(--green);
  border-color: var(--green);
  color: #000;
}

/* Blog card grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.blog-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 26px;
  text-decoration: none;
  color: var(--text);
  transition: border-color .2s, transform .2s, box-shadow .2s;
}
.blog-card:hover {
  border-color: rgba(0,212,170,.3);
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(0,0,0,.5);
}

.blog-card .tag {
  display: inline-block;
  background: rgba(0,212,170,.08);
  border: 1px solid rgba(0,212,170,.15);
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 9999px;
  width: fit-content;
}
.blog-card h2 {
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
}
.blog-card p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.55;
  flex: 1;
}
.blog-card .meta {
  font-size: 12px;
  color: rgba(255,255,255,.25);
  margin-top: 4px;
  font-family: 'DM Sans', sans-serif;
}

#no-results {
  display: none;
  padding: 60px 20px;
  text-align: center;
  color: var(--muted);
  font-size: 16px;
}

/* =====================
   FOOTER
   ===================== */
footer {
  border-top: 1px solid var(--border);
  margin-top: auto;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 44px 48px 32px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  border-bottom: 1px solid var(--border);
}
.footer-logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--green);
  letter-spacing: .02em;
  margin-bottom: 10px;
}
.footer-logo span { color: var(--green) }
.footer-tagline {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.65;
  max-width: 240px;
}
.footer-col h4 {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: rgba(255,255,255,.35);
  margin-bottom: 16px;
}
.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 11px;
  transition: color .2s;
}
.footer-col a:hover { color: var(--text) }

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 48px 36px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-bottom p {
  font-size: 13px;
  color: rgba(255,255,255,.3);
}
.footer-legal {
  font-size: 12px;
  color: rgba(161,161,166,.5);
  line-height: 1.75;
  max-width: 640px;
}

/* =====================
   RESPONSIVE
   ===================== */
@media (max-width: 1024px) {
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 32px }
}

@media (max-width: 768px) {
  nav { padding: 0 20px; height: 60px }
  .nav-links { display: none }
  .nav-logo::after { display: none }

  h1.article-title { font-size: 2rem }
  .article-intro { font-size: 17px }
  .article-wrap { padding: 32px 16px 64px }
  .article-body p { font-size: 16px }
  .article-body h2 { font-size: 1.5rem }

  .blog-grid { grid-template-columns: 1fr }
  .filter-wrap { gap: 6px }
  .filter-btn { font-size: 12px; padding: 7px 14px }

  .footer-inner { grid-template-columns: 1fr; padding: 32px 20px 24px; gap: 28px }
  .footer-bottom { padding: 16px 20px 28px; flex-direction: column; gap: 8px }
}

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