
:root {
  --color-bg: #f4f8fb;
  --color-bg-alt: #ffffff;
  --color-primary: #1368d6;
  --color-primary-soft: #e1edff;
  --color-accent: #0bb38c;
  --color-text: #1f2933;
  --color-muted: #6b7280;
  --color-border: #e5e7eb;
  --shadow-soft: 0 8px 18px rgba(15, 23, 42, 0.08);
}
body.dark {
  --color-bg: #020617;
  --color-bg-alt: #020617;
  --color-text: #e5e7eb;
  --color-muted: #9ca3af;
  --color-border: #1f2937;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html, body { margin: 0; padding: 0; }
body {
  font-family: "Inter", "Roboto", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
}
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1rem;
}
.site-header {
  background: var(--color-bg-alt);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 0;
  gap: 1rem;
}
.logo a {
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-primary);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.logo-mark {
  background: linear-gradient(135deg, #1368d6, #0bb38c);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  font-size: 0.95rem;
}
.site-search {
  flex: 1;
  display: flex;
  max-width: 420px;
  background: var(--color-bg);
  border-radius: 999px;
  border: 1px solid var(--color-border);
  overflow: hidden;
}
.site-search input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.45rem 0.8rem;
  font-size: 0.9rem;
  color: var(--color-text);
}
.site-search input:focus { outline: none; }
.site-search button {
  border: none;
  padding: 0.45rem 0.9rem;
  font-size: 0.9rem;
  background: var(--color-primary);
  color: #fff;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
}
.site-search button:hover {
  background: #0e4ea4;
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}
.theme-toggle {
  border: none;
  background: var(--color-bg);
  border-radius: 999px;
  width: 36px;
  height: 36px;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
}
.main-nav {
  border-top: 1px solid rgba(148, 163, 184, 0.3);
  border-bottom: 1px solid rgba(148, 163, 184, 0.3);
  background: var(--color-bg-alt);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-menu {
  display: flex;
  list-style: none;
  padding: 0.4rem 0;
  margin: 0;
  gap: 1rem;
  font-size: 0.9rem;
}
.nav-menu a {
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  transition: background 0.1s ease, color 0.1s ease, transform 0.1s ease;
}
.nav-menu a:hover {
  background: var(--color-primary-soft);
  color: var(--color-primary);
  transform: translateY(-1px);
}
.nav-toggle {
  display: none;
  border: none;
  background: transparent;
  font-size: 1.35rem;
}
.site-main { padding: 1.5rem 0 2.5rem; }
.content-with-sidebar {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 1.4fr);
  gap: 1.75rem;
  align-items: flex-start;
}
.main-content {
  background: var(--color-bg-alt);
  border-radius: 16px;
  padding: 1.5rem 1.6rem 2rem;
  box-shadow: var(--shadow-soft);
}
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.sidebar-card,
.blog-card {
  background: var(--color-bg-alt);
  border-radius: 14px;
  border: 1px solid var(--color-border);
  padding: 1rem 1.1rem;
  box-shadow: var(--shadow-soft);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.sidebar-card:hover,
.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 35px rgba(15, 23, 42, 0.18);
}
h1, h2, h3, h4 {
  font-family: "Inter", system-ui, sans-serif;
  margin-top: 0;
  color: var(--color-text);
}
h1 { font-size: 1.8rem; margin-bottom: 0.3rem; }
h2 { font-size: 1.35rem; margin-top: 1.4rem; }
h3 { font-size: 1.1rem; margin-top: 1.1rem; }
h4 { font-size: 1rem; color: var(--color-muted); }
.breadcrumbs {
  font-size: 0.82rem;
  color: var(--color-muted);
  margin-bottom: 0.6rem;
}
.breadcrumbs a { color: var(--color-muted); }
.toc {
  background: var(--color-primary-soft);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  margin: 1rem 0 1.4rem;
  border: 1px solid rgba(59, 130, 246, 0.3);
}
.toc h2 {
  font-size: 0.95rem;
  margin: 0 0 0.45rem;
}
.toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.toc li {
  font-size: 0.87rem;
  margin-bottom: 0.2rem;
}
ul, ol { padding-left: 1.4rem; }
.faq-item { margin-bottom: 0.7rem; }
.faq-q { font-weight: 600; }
.faq-a { font-size: 0.93rem; color: var(--color-muted); }
.newsletter-form input[type="email"],
.contact-form input,
.contact-form textarea {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--color-border);
  padding: 0.6rem 0.7rem;
  font-size: 0.95rem;
  margin-bottom: 0.6rem;
  background: var(--color-bg);
  color: var(--color-text);
}
.newsletter-form button,
.contact-form button {
  background: var(--color-accent);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.95rem;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.newsletter-form button:hover,
.contact-form button:hover {
  background: #079270;
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}
.sidebar-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.sidebar-list li { margin-bottom: 0.4rem; }
.sidebar-list a { font-size: 0.9rem; }
.blog-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(0, 1.1fr);
  gap: 1.5rem;
}
.blog-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.blog-card h2 { font-size: 1.1rem; }
.blog-card .meta {
  font-size: 0.78rem;
  color: var(--color-muted);
}
.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}
.share-row a {
  font-size: 0.8rem;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--color-border);
}
.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 1.3rem 0;
  background: var(--color-bg-alt);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}
.footer-links a {
  margin-right: 0.8rem;
  font-size: 0.88rem;
}
.footer-meta {
  font-size: 0.8rem;
  color: var(--color-muted);
}
.footer-small { margin: 0.15rem 0 0; }
.footer-social a {
  margin-left: 0.55rem;
  font-size: 0.86rem;
}
.cookie-banner {
  position: fixed;
  bottom: 0.8rem;
  left: 50%;
  transform: translateX(-50%);
  width: min(100% - 2rem, 680px);
  background: var(--color-bg-alt);
  border-radius: 999px;
  padding: 0.6rem 0.95rem;
  box-shadow: var(--shadow-soft);
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  z-index: 60;
}
.cookie-banner p {
  margin: 0;
  flex: 1;
}
.cookie-banner button {
  border-radius: 999px;
  border: none;
  padding: 0.35rem 0.9rem;
  background: var(--color-primary);
  color: #fff;
  cursor: pointer;
}
.cookie-banner.hidden { display: none; }
@media (max-width: 860px) {
  .content-with-sidebar { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .site-search { display: none; }
  .nav-menu {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    background: var(--color-bg-alt);
    padding: 0.6rem 1rem 0.9rem;
    border-bottom: 1px solid var(--color-border);
    display: none;
  }
  .nav-menu.open { display: flex; }
  .nav-toggle { display: block; }
}
@media (max-width: 480px) {
  .main-content {
    padding: 1rem 1.05rem 1.4rem;
  }
  .cookie-banner {
    flex-direction: column;
    align-items: stretch;
  }
}
