:root {
  --bg: #090b0b;
  --bg-elevated: #0d1010;
  --panel: #111515;
  --panel-strong: #161a19;
  --panel-hover: #1c211f;
  --border: #2b3431;
  --border-soft: #202825;
  --text: #f2f5f3;
  --text-secondary: #a3aca8;
  --text-muted: #707c77;
  --accent: #22c55e;
  --accent-strong: #16a34a;
  --accent-soft: rgba(34, 197, 94, .13);
  --info: #34d399;
  --positive: #35e77a;
  --negative: #ff3b52;
  --shadow: 0 20px 70px rgba(0, 0, 0, .42);
}

[data-theme="light"] {
  --bg: #f2f4f3;
  --bg-elevated: #fff;
  --panel: #fcfdfc;
  --panel-strong: #f4f6f5;
  --panel-hover: #ecefed;
  --border: #cfd5d1;
  --border-soft: #e0e4e1;
  --text: #111512;
  --text-secondary: #505954;
  --text-muted: #7a827d;
  --accent: #111412;
  --accent-strong: #000;
  --accent-soft: rgba(0, 0, 0, .075);
  --info: #111412;
  --positive: #087a3f;
  --negative: #d72f43;
  --shadow: 0 20px 55px rgba(20, 24, 21, .11);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg); color-scheme: dark; scroll-behavior: smooth; }
html[data-theme="light"] { color-scheme: light; }
body {
  min-height: 100%;
  margin: 0;
  background:
    radial-gradient(circle at 82% -18%, rgba(22, 163, 74, .075), transparent 35rem),
    radial-gradient(circle at 105% 42%, rgba(255, 255, 255, .018), transparent 32rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, Manrope, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
  font-feature-settings: "tnum" 1, "ss01" 1;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.nav-open { overflow: hidden; }
[data-theme="light"] body { background: radial-gradient(circle at 80% -15%, rgba(0, 0, 0, .055), transparent 34rem), var(--bg); }
body.admin-bar .marketing-nav { top: 32px; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
button, input, textarea, select { font: inherit; color: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
::selection { background: rgba(34, 197, 94, .3); }
svg { display: block; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link:focus { position: fixed; z-index: 9999; top: 12px; left: 12px; width: auto; height: auto; padding: 10px 14px; clip: auto; border-radius: 8px; background: var(--text); color: var(--bg); }

.brand { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 10px; font-size: 16px; font-weight: 650; letter-spacing: -.025em; }
.brand-mark { display: grid; width: 32px; height: 32px; place-items: center; overflow: hidden; border: 1px solid rgba(34, 197, 94, .3); border-radius: 10px; background: #080a09; box-shadow: inset 0 1px rgba(255,255,255,.08), 0 0 18px rgba(34,197,94,.12); }
.brand-logo-image { width: 100%; height: 100%; object-fit: cover; display:block; }
.brand-name span { background: linear-gradient(90deg, #4ade80, var(--info)); background-clip: text; color: transparent; }
[data-theme="light"] .brand-name span { background: none; color: #0d0f0e; }

.btn { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 8px; padding: 0 16px; border: 1px solid var(--border); border-radius: 10px; background: var(--panel); color: var(--text); font-size: 14px; font-weight: 600; cursor: pointer; transition: border-color 160ms ease, background 160ms ease, transform 160ms ease; }
.btn:hover { border-color: #46534e; background: var(--panel-hover); transform: translateY(-1px); }
.btn-primary { border-color: var(--accent-strong); background: var(--accent); color: #fff; box-shadow: 0 8px 24px rgba(34,197,94,.14); }
.btn-primary:hover { border-color: #31d970; background: #24d466; }
.btn-ghost { background: transparent; }
.icon-button { width: 38px; min-height: 38px; padding: 0; border: 0; background: transparent; color: var(--text-secondary); }
.icon-button svg { width: 17px; height: 17px; }
[data-theme="light"] .btn-primary { border-color: #080a09; background: #0b0e0c; color: #fff; box-shadow: 0 8px 24px rgba(0,0,0,.16); }
[data-theme="light"] .btn-primary:hover { border-color: #000; background: #000; }

.marketing-nav { position: fixed; z-index: 50; top: 0; right: 0; left: 0; border-bottom: 1px solid rgba(255,255,255,.07); background: rgba(9,11,11,.9); backdrop-filter: blur(18px); }
.marketing-nav-inner { display: flex; width: min(1180px, calc(100% - 40px)); height: 68px; margin: 0 auto; align-items: center; justify-content: space-between; gap: 24px; }
.marketing-links { margin-left: auto; }
.marketing-links .menu { display: flex; align-items: center; gap: 30px; margin: 0; padding: 0; list-style: none; color: var(--text-secondary); font-size: 14px; }
.marketing-links a { transition: color 150ms ease; }
.marketing-links a:hover, .marketing-links .current-menu-item > a { color: var(--text); }
.marketing-actions { display: flex; align-items: center; gap: 10px; }
.marketing-menu-toggle { display: none; width: 40px; height: 40px; align-items: center; justify-content: center; padding: 0; border: 1px solid var(--border); border-radius: 11px; background: var(--panel); color: var(--text); cursor: pointer; }
.marketing-menu-toggle svg { width: 20px; height: 20px; }
.marketing-menu-toggle .close-icon { display: none; }
.marketing-menu-toggle[aria-expanded="true"] .menu-icon { display: none; }
.marketing-menu-toggle[aria-expanded="true"] .close-icon { display: block; }
.marketing-mobile-menu, .marketing-mobile-backdrop { display: none; }
[data-theme="light"] .marketing-nav { border-color: rgba(0,0,0,.1); background: rgba(250,251,250,.9); }

.language-switcher { display: inline-flex; min-height: 38px; align-items: center; gap: 3px; padding: 3px 4px 3px 8px; border: 1px solid var(--border); border-radius: 10px; background: var(--panel); color:var(--text-muted); transition:opacity 160ms ease; }
.language-switcher > svg { width: 14px; height: 14px; flex: 0 0 auto; }
.language-switcher .language-option { display:inline-flex; min-width:30px; height:29px; align-items:center; justify-content:center; padding:0 8px; border:0; border-radius:7px; background:transparent; color:var(--text-muted); font-size:10px; font-weight:800; letter-spacing:.04em; cursor:pointer; transition:background 140ms ease,color 140ms ease,box-shadow 140ms ease; }
.language-switcher .language-option > a { display:flex !important; width:100%; height:100%; align-items:center; justify-content:center; padding:0 !important; margin:0 !important; border:0 !important; background:transparent !important; color:inherit !important; font:inherit !important; letter-spacing:inherit !important; text-decoration:none !important; box-shadow:none !important; }
.language-switcher .language-option:hover { color:var(--text); }
.language-switcher .language-option.active, .language-switcher .language-option[aria-current="true"] { background:var(--accent-soft); color:var(--accent); box-shadow:inset 0 0 0 1px rgba(34,197,94,.18); }
html.pnlflow-language-switching .language-switcher { opacity:.72; pointer-events:none; }
.language-switcher.mobile { display:flex; width:100%; justify-content:space-between; padding:4px; border-radius:14px; }
.language-switcher.mobile > svg { display:none; }
.language-switcher.mobile .language-option { flex:1 1 0; min-width:0; height:36px; font-size:12px; }
.theme-icon-moon { display: none; }
[data-theme="light"] .theme-icon-sun { display: none; }
[data-theme="light"] .theme-icon-moon { display: block; }

.marketing-page { min-height: 100vh; }
.blog-page, .article-page { padding-bottom: 100px; overflow: hidden; }
.blog-hero { position: relative; width: min(1060px, calc(100% - 40px)); margin: 0 auto; padding: 158px 0 64px; border-bottom: 1px solid var(--border-soft); }
.blog-hero::after { content: ""; position: absolute; z-index: -1; top: 70px; right: -120px; width: 440px; height: 300px; border-radius: 50%; background: radial-gradient(circle, rgba(34,197,94,.16), transparent 68%); filter: blur(12px); }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px; padding: 7px 11px; border: 1px solid rgba(34,197,94,.28); border-radius: 999px; background: rgba(34,197,94,.06); color: #80e9a8; font-size: 12px; font-weight: 700; }
.eyebrow svg { width: 13px; height: 13px; }
.blog-hero h1 { max-width: 800px; margin: 4px 0 18px; font-size: clamp(45px, 6vw, 76px); font-weight: 500; line-height: 1; letter-spacing: -.058em; }
.blog-hero > p, .archive-description { max-width: 650px; margin: 0; color: var(--text-secondary); font-size: 17px; line-height: 1.65; }
.blog-hero-compact { padding-bottom: 46px; }
.blog-hero-compact h1 { font-size: clamp(40px, 5vw, 62px); }

.blog-grid { display: grid; width: min(1060px, calc(100% - 40px)); grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; margin: 34px auto 0; }
.blog-card { display: grid; min-height: 370px; grid-template-rows: 135px 1fr; overflow: hidden; border: 1px solid var(--border-soft); border-radius: 18px; background: var(--panel); transition: transform 160ms ease, border-color 160ms ease; }
.blog-card:hover { transform: translateY(-3px); border-color: rgba(34,197,94,.38); }
.blog-card.featured { grid-column: 1 / -1; grid-template-columns: .8fr 1.2fr; grid-template-rows: 1fr; min-height: 315px; }
.blog-card-visual { position: relative; display: grid; place-items: center; overflow: hidden; border-bottom: 1px solid var(--border-soft); background: radial-gradient(circle at 70% 20%, rgba(34,197,94,.2), transparent 42%), linear-gradient(145deg,var(--panel-strong),var(--bg-elevated)); }
.featured .blog-card-visual { border-right: 1px solid var(--border-soft); border-bottom: 0; }
.blog-card-visual-image { background: #090b0b; }
.blog-card-visual-image img { width: 100%; height: 100%; min-width: 100%; min-height: 100%; object-fit: cover; display: block; transition: transform 260ms ease, opacity 180ms ease; }
.blog-card:hover .blog-card-visual-image img { transform: scale(1.025); }
.blog-card-visual-image::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, transparent 58%, rgba(0,0,0,.18)); }
.blog-card-copy { display: flex; min-width: 0; flex-direction: column; padding: 25px; }
.blog-category { color: var(--accent); font-size: 10px; font-weight: 750; letter-spacing: .09em; text-transform: uppercase; }
.blog-card h2 { margin: 12px 0 10px; font-size: 23px; font-weight: 600; line-height: 1.16; letter-spacing: -.035em; }
.blog-card h2 a { transition: color 150ms ease; }
.blog-card h2 a:hover { color: var(--accent); }
.blog-card-excerpt, .blog-card-excerpt p { margin: 0; color: var(--text-secondary); font-size: 13px; line-height: 1.6; }
.blog-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: auto; padding-top: 22px; }
.blog-card-footer > span, .blog-card-footer > a { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; }
.blog-card-footer > span { color: var(--text-muted); }
.blog-card-footer > a { color: var(--accent); font-weight: 700; }
.blog-card-footer svg { width: 13px; height: 13px; }

.pagination { width: min(1060px, calc(100% - 40px)); margin: 32px auto 0; }
.pagination .nav-links { display: flex; justify-content: center; gap: 7px; }
.pagination .page-numbers { display: grid; min-width: 40px; height: 40px; place-items: center; padding: 0 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--panel); color: var(--text-secondary); font-size: 12px; }
.pagination .page-numbers.current, .pagination a:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.empty-state { width: min(1060px, calc(100% - 40px)); margin: 34px auto 0; padding: 70px 24px; border: 1px dashed var(--border); border-radius: 18px; background: var(--panel); text-align: center; }
.empty-state > span { color: var(--accent); font-size: 52px; font-weight: 800; opacity: .5; }
.empty-state h2 { margin: 12px 0 8px; }
.empty-state p { margin: 0; color: var(--text-secondary); }

.article-shell { width: min(820px, calc(100% - 40px)); margin: 0 auto; padding: 135px 0 40px; }
.article-back { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 48px; color: var(--text-secondary); font-size: 12px; }
.article-back:hover { color: var(--accent); }
.article-shell h1 { max-width: 780px; margin: 14px 0 20px; font-size: clamp(40px, 6vw, 68px); font-weight: 550; line-height: 1.04; letter-spacing: -.055em; text-wrap: balance; }
.article-lead { max-width: 690px; margin: 0; color: var(--text-secondary); font-size: 18px; line-height: 1.65; }
.article-meta { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 25px; color: var(--text-muted); font-size: 11px; }
.article-meta span { display: flex; align-items: center; gap: 7px; }
.article-meta svg { width: 13px; height: 13px; }
.article-cover { position: relative; display: grid; height: 330px; place-items: center; margin: 50px 0; overflow: hidden; border: 1px solid var(--border-soft); border-radius: 22px; background: radial-gradient(circle at 70% 35%, rgba(34,197,94,.22), transparent 32%), radial-gradient(circle at 25% 65%, rgba(255,83,101,.12), transparent 28%), var(--panel); }
.article-cover span { color: var(--accent); font-size: 90px; font-weight: 850; letter-spacing: -.08em; opacity: .62; }
.article-cover i { position: absolute; width: 360px; height: 80px; border-top: 8px solid var(--accent); border-radius: 50%; transform: rotate(-8deg); }
.article-cover-image { height: auto; max-height: 520px; }
.article-cover-image img { width: 100%; height: 100%; max-height: 520px; object-fit: cover; }
.article-content { color: var(--text-secondary); font-size: 17px; line-height: 1.82; }
.article-content > *:first-child { margin-top: 0; }
.article-content h2, .article-content h3, .article-content h4 { color: var(--text); line-height: 1.17; letter-spacing: -.04em; text-wrap: balance; }
.article-content h2 { margin: 58px 0 20px; font-size: clamp(29px,4vw,41px); }
.article-content h3 { margin: 42px 0 15px; font-size: 26px; }
.article-content p, .article-content ul, .article-content ol { margin: 0 0 24px; }
.article-content li + li { margin-top: 8px; }
.article-content a { color: var(--accent); text-decoration: underline; text-underline-offset: 4px; }
.article-content blockquote { margin: 34px 0; padding: 22px 25px; border-left: 3px solid var(--accent); border-radius: 0 14px 14px 0; background: var(--accent-soft); color: var(--text); }
.article-content blockquote p:last-child { margin-bottom: 0; }
.article-content pre { overflow: auto; padding: 20px; border: 1px solid var(--border); border-radius: 14px; background: var(--bg-elevated); }
.article-content img { margin: 34px auto; border-radius: 16px; }
.article-content table { width: 100%; margin: 32px 0; border-collapse: collapse; font-size: 14px; }
.article-content th, .article-content td { padding: 12px 14px; border: 1px solid var(--border); text-align: left; }
.article-content th { background: var(--panel-strong); color: var(--text); }
.article-cta { margin-top: 64px; padding: 30px; border: 1px solid rgba(34,197,94,.25); border-radius: 20px; background: radial-gradient(circle at 100% 0, rgba(34,197,94,.12), transparent 46%), var(--panel); }
.article-cta h2 { margin: 12px 0 10px; font-size: 27px; letter-spacing: -.035em; }
.article-cta p { margin: 0 0 21px; color: var(--text-secondary); }
.post-navigation .nav-links { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 28px; }
.post-navigation a { display: grid; gap: 6px; height: 100%; padding: 17px 19px; border: 1px solid var(--border); border-radius: 14px; background: var(--panel); font-size: 13px; }
.post-navigation a:hover { border-color: rgba(34,197,94,.35); }
.post-navigation a span { color: var(--text-muted); font-size: 10px; }
.nav-next { text-align: right; }
.page-article { min-height: 70vh; }

.search-form { display: flex; max-width: 620px; gap: 8px; margin-top: 28px; }
.search-field { flex: 1; min-width: 0; min-height: 44px; padding: 0 13px; border: 1px solid var(--border); border-radius: 10px; background: var(--panel); outline: none; }
.search-field:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.search-submit { min-height: 44px; padding: 0 16px; border: 1px solid var(--accent-strong); border-radius: 10px; background: var(--accent); color: #fff; font-weight: 650; cursor: pointer; }
.not-found { display: grid; width: min(760px, calc(100% - 40px)); min-height: 78vh; margin: 0 auto; padding-top: 125px; place-content: center; text-align: center; }
.error-code { color: var(--accent); font-size: 100px; font-weight: 800; line-height: 1; opacity: .5; }
.not-found h1 { margin: 12px 0; font-size: clamp(38px,6vw,65px); }
.not-found p { color: var(--text-secondary); }
.not-found > div { display: flex; justify-content: center; gap: 9px; margin-top: 15px; }

.marketing-footer { display: flex; width: min(1100px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 40px; align-items: center; justify-content: space-between; gap: 24px; border-top: 1px solid var(--border-soft); color: var(--text-muted); font-size: 12px; }

@media (max-width: 980px) {
  .marketing-links .menu { gap: 18px; }
}

@media (max-width: 820px) {
  body.admin-bar .marketing-nav { top: 46px; }
  .marketing-links { display: none; }
  .marketing-menu-toggle { display: inline-flex; flex: 0 0 40px; }
  .marketing-mobile-backdrop.is-open { display: block; position: fixed; z-index: 48; inset: 68px 0 0; width: 100%; padding: 0; border: 0; background: rgba(0,0,0,.58); backdrop-filter: blur(3px); }
  .marketing-mobile-menu.is-open { display: grid; position: fixed; z-index: 60; top: 78px; right: 14px; left: 14px; gap: 13px; max-height: calc(100dvh - 92px); padding: 16px; overflow-y: auto; border: 1px solid var(--border); border-radius: 18px; background: color-mix(in srgb, var(--panel-strong) 96%, transparent); box-shadow: 0 28px 80px rgba(0,0,0,.45); backdrop-filter: blur(22px); animation: menu-in 180ms ease both; }
  body.admin-bar .marketing-mobile-menu.is-open { top: 124px; max-height: calc(100dvh - 138px); }
  .marketing-mobile-menu-label { padding: 1px 4px 4px; color: var(--text-muted); font-size: 10px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
  .marketing-mobile-menu-links { display: grid; gap: 6px; }
  .marketing-mobile-menu-links > a { display: grid; min-height: 50px; grid-template-columns: 34px 1fr auto; align-items: center; gap: 11px; padding: 7px 12px 7px 8px; border: 1px solid transparent; border-radius: 12px; color: var(--text-secondary); font-size: 14px; font-weight: 650; }
  .marketing-mobile-menu-links > a:hover { border-color: rgba(34,197,94,.24); background: var(--accent-soft); color: var(--text); }
  .marketing-mobile-menu-links > a > span { display: grid; width: 34px; height: 34px; place-items: center; border: 1px solid rgba(34,197,94,.2); border-radius: 10px; background: rgba(34,197,94,.08); color: var(--accent); }
  .marketing-mobile-menu-links b { color: var(--text-muted); }
  .marketing-mobile-menu-footer { display: grid; grid-template-columns: 1fr; gap: 8px; padding-top: 13px; border-top: 1px solid var(--border-soft); }
  .blog-grid { grid-template-columns: 1fr; }
  .blog-card.featured { grid-column: auto; grid-template-columns: 1fr; grid-template-rows: 135px 1fr; min-height: 370px; }
  .featured .blog-card-visual { border-right: 0; border-bottom: 1px solid var(--border-soft); }
  @keyframes menu-in { from { opacity: 0; transform: translateY(-10px) scale(.985); } to { opacity: 1; transform: none; } }
}

@media (max-width: 600px) {
  .marketing-nav-inner, .blog-hero, .blog-grid, .pagination, .marketing-footer { width: min(100% - 28px, 1060px); }
  .marketing-nav-inner { gap: 8px; }
  .marketing-nav .brand { gap: 7px; font-size: 14px; }
  .marketing-nav .brand-mark { width: 30px; height: 30px; border-radius: 9px; }
  .marketing-actions { gap: 5px; }
  .language-switcher.compact { gap: 1px; padding-right: 3px; padding-left: 3px; }
  .language-switcher.compact > svg { display: none; }
  .language-switcher.compact .language-option { min-width: 26px; padding: 0 6px; }
  .language-switcher.mobile { padding: 4px; }
  .blog-hero { padding-top: 126px; padding-bottom: 46px; }
  .blog-hero::after { right: -240px; }
  .eyebrow { margin-bottom: 22px; font-size: 10px; }
  .blog-hero h1 { font-size: 43px; }
  .blog-hero > p, .archive-description { font-size: 15px; }
  .blog-card { min-height: 345px; border-radius: 16px; }
  .blog-card-copy { padding: 21px; }
  .blog-card h2 { font-size: 21px; }
  .article-shell { width: calc(100% - 28px); padding-top: 116px; }
  .article-back { margin-bottom: 35px; }
  .article-shell h1 { font-size: 40px; }
  .article-lead { font-size: 16px; }
  .article-cover { height: 230px; margin: 36px 0; border-radius: 16px; }
  .article-cover span { font-size: 64px; }
  .article-cover i { width: 230px; height: 58px; }
  .article-content { font-size: 16px; line-height: 1.75; }
  .article-content table { display: block; overflow-x: auto; }
  .article-cta { margin-top: 48px; padding: 23px; }
  .post-navigation .nav-links { grid-template-columns: 1fr; }
  .nav-next { text-align: left; }
  .marketing-footer { align-items: flex-start; flex-direction: column; padding-bottom: 28px; }
  .not-found > div { flex-direction: column; }
}

@media (max-width: 360px) {
  .marketing-nav .brand { font-size: 13px; }
  .language-switcher.compact .language-option { min-width: 23px; padding-inline: 4px; }
  .icon-button { width: 34px; }
  .marketing-menu-toggle { width: 36px; flex-basis: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
