/* Hermes AI — v2 visual system, derived from the approved reference board. */
@font-face { font-family: Inter; src: url('/assets/redesign/fonts/Inter-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: Inter; src: url('/assets/redesign/fonts/Inter-500.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: Inter; src: url('/assets/redesign/fonts/Inter-600.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: Inter; src: url('/assets/redesign/fonts/Inter-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: Inter; src: url('/assets/redesign/fonts/Inter-800.woff2') format('woff2'); font-weight: 800; font-display: swap; }

:root {
  color-scheme: dark;
  --cyan: #00dceb;
  --blue: #3b82f6;
  --violet: #8b5cf6;
  --gradient: linear-gradient(110deg, #00dceb 0%, #3b82f6 52%, #8b5cf6 100%);
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --max: 1240px;
  --radius: 16px;
  --radius-small: 11px;
  --ease: 220ms cubic-bezier(.2, .75, .25, 1);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root,
[data-theme="dark"] {
  color-scheme: dark;
  --bg: #061020;
  --surface: #0b1727;
  --surface-raised: #111f32;
  --surface-hover: #192a40;
  --text: #f8fafc;
  --muted: #a7b7cc;
  --border: #263a53;
  --border-strong: #3a5473;
  --header: rgba(6, 16, 32, .86);
  --shadow: 0 22px 70px rgba(0, 0, 0, .28);
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #f7fafe;
  --surface: #ffffff;
  --surface-raised: #eef4fb;
  --surface-hover: #e5edf7;
  --text: #0f172a;
  --muted: #52657c;
  --border: #d6e1ee;
  --border-strong: #afc1d5;
  --header: rgba(247, 250, 254, .88);
  --shadow: 0 22px 70px rgba(22, 42, 74, .12);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); color: var(--text); scroll-behavior: smooth; overflow-x: hidden; }
body { margin: 0; min-width: 320px; background: var(--bg); color: var(--text); line-height: 1.65; overflow-x: hidden; }
body, button, a { font-family: inherit; }
img { max-width: 100%; height: auto; }
a { color: var(--cyan); }
a:hover { color: var(--blue); }
button { color: inherit; }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 4px; }
::selection { color: #03101b; background: var(--cyan); }

.container { width: min(100% - 3rem, var(--max)); margin-inline: auto; }
.section { padding: clamp(4rem, 8vw, 7.5rem) 0; }
.section--muted { background: var(--surface); }
.eyebrow { margin: 0 0 1.15rem; color: var(--cyan); font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { color: var(--text); letter-spacing: -.04em; }
h1 { max-width: 11ch; margin-bottom: 1.5rem; font-size: clamp(2.8rem, 6vw, 5.25rem); line-height: 1.01; font-weight: 800; }
h2 { max-width: 15ch; margin-bottom: 1.15rem; font-size: clamp(2rem, 4vw, 3.35rem); line-height: 1.08; font-weight: 800; }
h3 { margin-bottom: .55rem; font-size: 1.2rem; line-height: 1.2; font-weight: 700; }
.lead { max-width: 62ch; color: var(--muted); font-size: clamp(1rem, 1.4vw, 1.15rem); line-height: 1.65; }
.accent { color: var(--cyan); }
.muted { color: var(--muted); }

/* Navigation */
.site-header { position: sticky; top: 0; z-index: 30; border-bottom: 1px solid color-mix(in srgb, var(--border) 72%, transparent); background: var(--header); backdrop-filter: blur(18px); }
.nav-container { display: flex; align-items: center; justify-content: space-between; min-height: 74px; gap: 1.25rem; }
.brand { display: inline-flex; align-items: center; flex: 0 0 auto; }
.brand img { width: clamp(145px, 13vw, 185px); }
.brand .logo-light, [data-theme="light"] .brand .logo-dark { display: none; }
[data-theme="light"] .brand .logo-light { display: block; }
.primary-nav { display: flex; align-items: center; gap: clamp(.8rem, 1.7vw, 1.6rem); margin-left: auto; }
.primary-nav a { position: relative; padding: .8rem 0; color: var(--muted); font-size: .8rem; font-weight: 500; white-space: nowrap; }
.primary-nav a::after { position: absolute; right: 0; bottom: .4rem; left: 0; height: 2px; content: ""; background: var(--gradient); transform: scaleX(0); transform-origin: center; transition: transform var(--ease); }
.primary-nav a:hover, .primary-nav a:focus-visible { color: var(--text); }
.primary-nav a:hover::after, .primary-nav a:focus-visible::after { transform: scaleX(1); }
.nav-actions { display: flex; align-items: center; gap: .55rem; }
.icon-button, .lang-switch, .theme-toggle { display: inline-flex; align-items: center; justify-content: center; min-height: 38px; border: 1px solid var(--border); border-radius: 10px; background: transparent; color: var(--muted); font-size: .8rem; font-weight: 600; }
.icon-button { width: 38px; padding: 0; }
.lang-switch, .theme-toggle { padding: .45rem .7rem; }
.icon-button:hover, .lang-switch:hover, .theme-toggle:hover { border-color: var(--border-strong); background: var(--surface-hover); color: var(--text); }
.community-link { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: .5rem .85rem; border-radius: 10px; background: var(--gradient); color: #04121e !important; font-size: .78rem; font-weight: 700; }
.community-link:hover { color: #04121e !important; filter: brightness(1.08); }
.mobile-menu { display: none; width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 10px; background: transparent; }
.mobile-extras { display: none; }
.theme-toggle #themeIcon { display: none; }
.hamburger-lines, .hamburger-lines::before, .hamburger-lines::after { display: block; width: 17px; height: 2px; border-radius: 2px; background: currentColor; content: ""; }
.hamburger-lines { position: relative; }
.hamburger-lines::before, .hamburger-lines::after { position: absolute; left: 0; }
.hamburger-lines::before { top: -6px; }
.hamburger-lines::after { top: 6px; }

/* Icon masks keep the supplied stroke icon system themeable. */
.icon { display: inline-block; width: 24px; height: 24px; flex: 0 0 24px; background: var(--cyan); -webkit-mask: center / contain no-repeat; mask: center / contain no-repeat; }
.icon--search { width: 18px; height: 18px; flex-basis: 18px; -webkit-mask-image: url('/assets/redesign/icons/search.svg'); mask-image: url('/assets/redesign/icons/search.svg'); }
.icon--memory { -webkit-mask-image: url('/assets/redesign/icons/memory.svg'); mask-image: url('/assets/redesign/icons/memory.svg'); }
.icon--tools { -webkit-mask-image: url('/assets/redesign/icons/tools.svg'); mask-image: url('/assets/redesign/icons/tools.svg'); }
.icon--mcp { -webkit-mask-image: url('/assets/redesign/icons/mcp.svg'); mask-image: url('/assets/redesign/icons/mcp.svg'); }
.icon--automation { -webkit-mask-image: url('/assets/redesign/icons/automation.svg'); mask-image: url('/assets/redesign/icons/automation.svg'); }
.icon--community { -webkit-mask-image: url('/assets/redesign/icons/community.svg'); mask-image: url('/assets/redesign/icons/community.svg'); }
.icon--opensource { -webkit-mask-image: url('/assets/redesign/icons/agent.svg'); mask-image: url('/assets/redesign/icons/agent.svg'); }
.icon--install { -webkit-mask-image: url('/assets/redesign/icons/install.svg'); mask-image: url('/assets/redesign/icons/install.svg'); }
.icon--hosting { -webkit-mask-image: url('/assets/redesign/icons/hosting.svg'); mask-image: url('/assets/redesign/icons/hosting.svg'); }
.icon--skills { -webkit-mask-image: url('/assets/redesign/icons/skills.svg'); mask-image: url('/assets/redesign/icons/skills.svg'); }
.icon--security { -webkit-mask-image: url('/assets/redesign/icons/security.svg'); mask-image: url('/assets/redesign/icons/security.svg'); }

/* Hero */
.hero { position: relative; isolation: isolate; min-height: min(800px, calc(100vh - 74px)); display: grid; align-items: center; padding: clamp(4.5rem, 8vw, 7.5rem) 0 clamp(3.5rem, 7vw, 6rem); overflow: hidden; }
.hero::before { position: absolute; z-index: -2; inset: 0; content: ""; background: var(--bg) url('/assets/redesign/images/hero/hero-background-dark.webp') center right / cover no-repeat; opacity: .92; }
[data-theme="light"] .hero::before { background-image: url('/assets/redesign/images/hero/hero-background-light.webp'); opacity: .72; }
.hero::after { position: absolute; z-index: -1; inset: 0; content: ""; background: linear-gradient(90deg, var(--bg) 0%, color-mix(in srgb, var(--bg) 90%, transparent) 38%, transparent 78%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(420px, 1.1fr); align-items: center; gap: clamp(1rem, 4vw, 4rem); }
.hero-copy { position: relative; z-index: 1; }
.hero-kicker { display: flex; flex-wrap: wrap; gap: .75rem; margin-bottom: 1.5rem; }
.hero-kicker span { padding: .32rem .7rem; border: 1px solid color-mix(in srgb, var(--cyan) 70%, var(--border)); border-radius: 999px; color: var(--cyan); font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.hero-kicker span + span { border-color: var(--border); color: var(--muted); }
.hero-copy .lead { max-width: 57ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; gap: .55rem; padding: .7rem 1.1rem; border: 1px solid transparent; border-radius: 11px; font-size: .9rem; font-weight: 700; transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease), background var(--ease); }
.button--primary { background: var(--gradient); color: #04121e; box-shadow: 0 12px 28px rgba(0, 220, 235, .18); }
.button--primary:hover { color: #04121e; transform: translateY(-2px); box-shadow: 0 16px 34px rgba(0, 220, 235, .26); }
.button--secondary { border-color: var(--border-strong); background: color-mix(in srgb, var(--surface) 55%, transparent); color: var(--text); }
.button--secondary:hover { border-color: var(--cyan); background: var(--surface-hover); color: var(--text); transform: translateY(-2px); }
.hero-art { position: relative; min-height: 460px; }
.hero-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: center; filter: drop-shadow(0 26px 42px rgba(0, 0, 0, .22)); }
.theme-light { display: none; }
[data-theme="light"] .theme-dark { display: none; }
[data-theme="light"] .theme-light { display: block; }
.hero-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; margin-top: clamp(3rem, 6vw, 5rem); }
.stat { display: grid; grid-template-columns: 42px 1fr; align-items: center; gap: .7rem; min-width: 0; }
.stat .icon { width: 26px; height: 26px; flex-basis: 26px; }
.stat-icon { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 50%; background: color-mix(in srgb, var(--surface) 78%, transparent); }
.stat strong { display: block; color: var(--text); font-size: 1.15rem; line-height: 1.1; }
.stat small { display: block; margin-top: .22rem; color: var(--muted); font-size: .72rem; }

/* Editorial sections */
.section-heading { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, .85fr); align-items: end; gap: 3rem; margin-bottom: 3rem; }
.section-heading .lead { justify-self: end; max-width: 48ch; }
.split-feature { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(0, 1.2fr); align-items: center; gap: clamp(2rem, 7vw, 7rem); }
.split-feature__visual { padding: clamp(1.25rem, 3vw, 2.5rem); border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.split-feature__visual img { width: 100%; max-height: 360px; object-fit: contain; }
.feature-list { display: grid; gap: 1.6rem; }
.feature-row { display: grid; grid-template-columns: 48px 1fr; gap: 1rem; padding-bottom: 1.6rem; border-bottom: 1px solid var(--border); }
.feature-row:last-child { padding-bottom: 0; border-bottom: 0; }
.feature-row .icon-wrap { display: grid; place-items: center; width: 48px; height: 48px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface-raised); }
.feature-row p { max-width: 55ch; margin-bottom: 0; color: var(--muted); font-size: .95rem; }
.feature-row h3 { margin-top: .15rem; }
.bento { display: grid; grid-template-columns: 1.2fr .8fr; gap: 1rem; }
.bento-panel { min-height: 260px; padding: clamp(1.5rem, 3vw, 2.6rem); border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.bento-panel--wide { display: grid; grid-template-columns: .9fr 1.1fr; align-items: center; gap: 1rem; background: var(--surface-raised); }
.bento-panel--wide img { width: 100%; max-height: 240px; object-fit: contain; }
.bento-panel--stack { display: grid; align-content: space-between; background: var(--bg); }
.bento-panel--stack .icon { width: 34px; height: 34px; flex-basis: 34px; }
.bento-panel p { max-width: 48ch; color: var(--muted); }
.bento-link { display: inline-flex; align-items: center; gap: .35rem; font-weight: 700; }
.terminal { position: relative; overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius); background: #07111f; color: #dce9f4; box-shadow: var(--shadow); }
.terminal::before { position: absolute; top: 0; right: 0; width: 42%; height: 100%; content: ""; background: url('/assets/redesign/images/sections/installation-terminal.webp') center / cover no-repeat; opacity: .45; mask-image: linear-gradient(90deg, transparent, #000); }
.terminal-content { position: relative; max-width: 620px; padding: clamp(1.5rem, 4vw, 3rem); }
.terminal h2 { color: #fff; }
.terminal p { color: #a7b7cc; }
.code { margin-top: 1.5rem; padding: 1rem 1.2rem; border: 1px solid #263a53; border-radius: 11px; background: #030b16; color: #bdeff4; overflow-x: auto; font: .85rem/1.8 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.code .comment { color: #71859e; }
.code .prompt { color: var(--cyan); }
.community { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: clamp(2rem, 6vw, 6rem); }
.community img { width: 100%; max-height: 380px; object-fit: contain; }
.callout { margin-top: 2rem; padding: 1rem 1.2rem; border-left: 2px solid var(--cyan); background: color-mix(in srgb, var(--surface-raised) 72%, transparent); color: var(--muted); }

/* Footer */
.site-footer { position: relative; margin-top: 3rem; padding: 5rem 0 1.5rem; border-top: 1px solid var(--border); background: var(--surface); overflow: hidden; }
.site-footer::before { position: absolute; top: 0; right: 0; left: 0; height: 135px; content: ""; background: url('/assets/redesign/images/footer/footer-wave-dark.svg') top center / cover no-repeat; opacity: .16; pointer-events: none; }
[data-theme="light"] .site-footer::before { background-image: url('/assets/redesign/images/footer/footer-wave-light.svg'); opacity: .5; }
.footer-grid { position: relative; display: grid; grid-template-columns: 1.35fr repeat(3, 1fr); gap: 2rem; }
.footer-brand p { max-width: 31ch; margin-top: 1rem; color: var(--muted); font-size: .86rem; }
.footer-col h3 { margin-bottom: .85rem; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }
.footer-col a { display: block; margin: .45rem 0; color: var(--muted); font-size: .84rem; }
.footer-col a:hover { color: var(--text); }
.footer-bottom { position: relative; display: flex; justify-content: space-between; gap: 1rem; margin-top: 3rem; padding-top: 1.2rem; border-top: 1px solid var(--border); color: var(--muted); font-size: .78rem; }
.partner-link { color: var(--muted); }

@media (max-width: 1080px) {
  .primary-nav { gap: .7rem; }
  .primary-nav a { font-size: .76rem; }
  .community-link { display: none; }
  .hero-grid { grid-template-columns: 1fr .95fr; }
}
@media (max-width: 820px) {
  .container { width: min(100% - 2rem, var(--max)); }
  .primary-nav { position: absolute; top: calc(100% + 1px); right: 1rem; left: 1rem; display: none; align-items: stretch; flex-direction: column; gap: 0; padding: .65rem 1rem; border: 1px solid var(--border); border-radius: 13px; background: var(--surface); box-shadow: var(--shadow); }
  .primary-nav.is-open { display: flex; }
  .primary-nav.is-open .mobile-extras { display: flex; gap: .55rem; padding: .7rem 0 .1rem; }
  .primary-nav.is-open .mobile-extras button { display: inline-flex; }
  .primary-nav a { padding: .75rem .2rem; border-bottom: 1px solid var(--border); font-size: .9rem; }
  .primary-nav a:last-child { border-bottom: 0; }
  .nav-actions .lang-switch, .nav-actions .theme-toggle { display: none; }
  .mobile-menu { display: inline-grid; place-items: center; }
  .hero { min-height: auto; padding-top: 4rem; }
  .hero-grid, .split-feature, .community, .section-heading { grid-template-columns: 1fr; gap: 2rem; }
  .hero-copy { max-width: 680px; }
  .hero-art { min-height: 360px; order: -1; }
  .section-heading .lead { justify-self: start; }
  .bento { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .nav-container { min-height: 66px; }
  .nav-actions { gap: .35rem; }
  .icon-button { display: none; }
  h1 { font-size: clamp(2.55rem, 13vw, 4rem); }
  .hero-kicker { gap: .45rem; }
  .hero-actions .button { width: 100%; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 1.15rem .7rem; }
  .stat { grid-template-columns: 34px 1fr; gap: .5rem; }
  .stat-icon { width: 34px; height: 34px; }
  .stat .icon { width: 21px; height: 21px; flex-basis: 21px; }
  .stat strong { font-size: 1rem; }
  .bento-panel--wide { grid-template-columns: 1fr; }
  .terminal::before { width: 100%; opacity: .18; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-bottom { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Secondary pages, guides and the blog use the same editorial system. */
:root { --text-secondary: var(--muted); --text-muted: var(--muted); --hero-gradient: var(--gradient); --card-bg: var(--surface); }
.page-shell { min-height: 55vh; padding: clamp(3.5rem, 7vw, 6.5rem) 0; background: radial-gradient(circle at 85% 0%, color-mix(in srgb, var(--violet) 12%, transparent), transparent 34rem), var(--bg); }
.page-content > .container { width: 100%; }
.page-content .hero { min-height: 0; margin: calc(clamp(3.5rem, 7vw, 6.5rem) * -1) calc((100vw - min(100vw - 3rem, var(--max))) / -2) 0; padding: clamp(4rem, 8vw, 7rem) max(1.5rem, calc((100vw - var(--max)) / 2)); }
.page-content .hero .container { width: min(100%, var(--max)); margin-inline: auto; }
.article, .page-content > .container > article { max-width: 850px; margin-inline: auto; }
.article h1, .page-content > .container > h1 { max-width: 18ch; margin-bottom: 1rem; }
.article h2, .article h3, .page-content > .container h2, .page-content > .container h3 { max-width: 30ch; margin-top: 2.5rem; }
.article p, .article li, .page-content > .container p, .page-content > .container li { color: var(--muted); }
.article > p:first-of-type, .article .lead, .page-content > .container > .lead { color: var(--text); font-size: 1.1rem; }
.article img { border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.article blockquote, .tip, .note { margin: 1.5rem 0; padding: 1rem 1.25rem; border-left: 3px solid var(--cyan); background: var(--surface-raised); border-radius: 0 var(--radius-small) var(--radius-small) 0; }
.article blockquote p, .tip p, .note p { margin-bottom: 0; }
.cards-grid, .blog-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin: 2rem 0; }
.card, .blog-card { padding: 1.35rem; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); box-shadow: 0 12px 34px color-mix(in srgb, var(--bg) 55%, transparent); transition: transform var(--ease), border-color var(--ease), background var(--ease); }
.card:hover, .blog-card:hover { transform: translateY(-3px); border-color: var(--border-strong); background: var(--surface-hover); }
.card h3, .blog-card h2, .blog-card h3 { margin-top: .45rem; }
.card-icon { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; margin-bottom: .6rem; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-raised); font-size: 1.25rem; }
.tag { display: inline-block; margin: .25rem .25rem 0 0; padding: .22rem .5rem; border: 1px solid var(--border); border-radius: 999px; color: var(--cyan); font-size: .72rem; }
.code-block, pre { margin: 1.5rem 0; padding: 1.2rem 1.35rem; overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-small); background: #07111f; color: #dce9f4; font: .88rem/1.75 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; }
.code-block .comment, .code-block .c { color: #7f94ad; }
.code-block .prompt, .code-block .p, .code-block .cmd { color: var(--cyan); }
.table-wrapper { overflow-x: auto; margin: 2rem 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.table-wrapper table { width: 100%; min-width: 620px; border-collapse: collapse; }
.table-wrapper th, .table-wrapper td { padding: .85rem 1rem; border-bottom: 1px solid var(--border); text-align: left; }
.table-wrapper th { color: var(--text); background: var(--surface-raised); font-size: .82rem; }
.table-wrapper td { color: var(--muted); }
.table-wrapper tr:last-child td { border-bottom: 0; }
.btn, .hero-buttons a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; gap: .4rem; padding: .65rem 1rem; border: 1px solid transparent; border-radius: 10px; background: var(--gradient); color: #04121e; font-weight: 700; text-decoration: none; }
.btn:hover, .hero-buttons a:hover { color: #04121e; filter: brightness(1.08); transform: translateY(-1px); }
.btn-outline { border-color: var(--border-strong); background: transparent; color: var(--text) !important; }
.back-link { display: inline-flex; margin-top: 2rem; color: var(--cyan); font-weight: 700; }
.pagination { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2rem; }
.pagination a, .pagination span { padding: .55rem .8rem; border: 1px solid var(--border); border-radius: 9px; color: var(--muted); }
.pagination .active, .pagination a:hover { border-color: var(--cyan); color: var(--text); }
.blog-card a { color: inherit; text-decoration: none; }
.blog-card .date, .blog-meta { color: var(--muted); font-size: .78rem; }
.section-header { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.section-tag, .hero-badge { display: inline-flex; width: fit-content; margin-bottom: .75rem; padding: .3rem .7rem; border: 1px solid color-mix(in srgb, var(--cyan) 70%, var(--border)); border-radius: 999px; color: var(--cyan); font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; margin-top: 2rem; }
.stats .stat { display: block; padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius-small); background: color-mix(in srgb, var(--surface) 72%, transparent); }
.stat-num { color: var(--text); font-size: 1.35rem; font-weight: 800; }
.stat-label { color: var(--muted); font-size: .78rem; }
.hero-buttons { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.steps { display: grid; gap: 1rem; counter-reset: steps; list-style: none; }
.steps > * { position: relative; padding: 1rem 1rem 1rem 3.4rem; border: 1px solid var(--border); border-radius: var(--radius-small); background: var(--surface); counter-increment: steps; }
.steps > *::before { position: absolute; top: 1rem; left: 1rem; display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--gradient); color: #04121e; content: counter(steps); font-weight: 800; }
@media (max-width: 820px) { .cards-grid, .blog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .section-header { display: block; } .stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .page-shell { padding: 3rem 0; } .page-content .hero { margin-inline: -1rem; padding-inline: 1rem; } .cards-grid, .blog-grid, .stats { grid-template-columns: 1fr; } .code-block, pre { font-size: .78rem; } }

/* Board-aligned revision: the supplied profile artwork is the hero focal point. */
.hero:not(.route-hero) {
  min-height: 0;
  padding: clamp(2rem, 4vw, 3.6rem) 0 1.4rem;
}
.hero:not(.route-hero)::before {
  background: radial-gradient(circle at 82% 36%, color-mix(in srgb, var(--blue) 12%, transparent), transparent 34rem), var(--bg);
  opacity: 1;
}
.hero:not(.route-hero)::after {
  background: linear-gradient(90deg, var(--bg) 0%, color-mix(in srgb, var(--bg) 88%, transparent) 45%, transparent 78%);
  opacity: .9;
}
.hero-grid { grid-template-columns: minmax(0, .95fr) minmax(440px, 1.05fr); gap: clamp(1rem, 2.5vw, 2.75rem); }
.hero-copy h1 { max-width: 13ch; margin-bottom: 1.15rem; font-size: clamp(2.8rem, 4.8vw, 4.65rem); }
.hero-copy h1 { max-width: none; font-size: clamp(2.8rem, 4vw, 4.05rem); }
.hero-accent-tail { color: var(--cyan); }
[data-theme="light"] .hero-accent-tail { color: var(--text); }
.hero-copy .lead { max-width: 48ch; font-size: clamp(.95rem, 1.1vw, 1.08rem); }
.hero-actions { margin-top: 1.45rem; }
.hero-art { min-height: 0; aspect-ratio: 1672 / 941; }
.hero-art, .route-hero-art { overflow: hidden; }
.hero-art img {
  position: static;
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center;
  border-radius: 28px;
  filter: drop-shadow(0 26px 42px rgba(0, 0, 0, .24));
}
.route-hero-art img { top: -15%; bottom: auto; height: 130%; }
.route-hero-art--hero { min-height: 0; min-width: 0; }
.route-hero-art picture { display: block; width: 100%; }
.route-hero-art--hero img {
  position: static;
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center;
  border-radius: 28px;
  filter: drop-shadow(0 22px 34px rgba(0, 0, 0, .22));
  mask-image: none;
  -webkit-mask-image: none;
}
[data-theme="light"] .hero-art .theme-light,
[data-theme="light"] .route-hero-art .theme-light {
  filter: contrast(1.3) saturate(1.3) brightness(.94) drop-shadow(0 24px 38px rgba(22, 42, 74, .15));
  mix-blend-mode: multiply;
}
[data-theme="light"] .hero-art .theme-light { top: -20%; height: 140%; }
.hero-stats { margin-top: 1.1rem; }
.theme-image { display: block; min-width: 0; }
.theme-image img { display: block; width: 100%; }
.bento-panel--wide .theme-image { min-width: 0; }

/* Theme variants must never render as a vertical image stack. */
html[data-theme="dark"] img.theme-light { display: none; }
html[data-theme="light"] img.theme-dark { display: none; }
html[data-theme="light"] img.theme-light { display: block; }

/* Route heroes make the secondary pages follow the same board rhythm. */
.page-content > .route-hero,
.page-content .route-hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(380px, 1.1fr);
  align-items: center;
  gap: clamp(1.5rem, 4vw, 4.5rem);
  min-height: 360px;
  margin: calc(clamp(3.5rem, 7vw, 6.5rem) * -1) calc((100vw - min(100vw - 3rem, var(--max))) / -2) 3rem;
  padding: clamp(3.5rem, 6vw, 5.5rem) max(1.5rem, calc((100vw - var(--max)) / 2));
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.route-hero::before {
  position: absolute;
  z-index: -2;
  inset: 0;
  content: "";
  background: radial-gradient(circle at 78% 42%, color-mix(in srgb, var(--violet) 14%, transparent), transparent 34rem), var(--bg);
}
.route-hero::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background: linear-gradient(90deg, var(--bg) 0%, color-mix(in srgb, var(--bg) 90%, transparent) 43%, transparent 80%);
}
.route-hero__copy { position: relative; z-index: 1; max-width: 620px; }
.route-hero__copy h1 { max-width: 15ch; margin-bottom: 1rem; font-size: clamp(2.4rem, 4.8vw, 4.5rem); }
.route-hero__copy .lead { max-width: 53ch; }
.route-hero-art { position: relative; z-index: 0; min-height: 300px; }
.route-hero-art img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 26px;
  filter: drop-shadow(0 22px 34px rgba(0, 0, 0, .22));
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 90%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 12%, #000 90%, transparent 100%);
}
.route-hero-art img.hero-artwork {
  position: static !important;
  display: block !important;
  width: 100% !important;
  height: auto !important;
  object-fit: contain !important;
  object-position: center !important;
  border-radius: 28px !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}
.route-hero + .hero {
  min-height: 0;
  margin-top: -3rem;
  padding-top: 0;
  background: transparent !important;
}
.route-hero + .hero::before,
.route-hero + .hero::after { display: none; }
.route-hero + .hero .hero-grid { display: block; }
.route-hero + .hero .hero-art { display: none; }
.route-hero + .hero .hero-stats { margin-top: 1rem; }
.blog-grid .blog-card-icon { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface-raised); color: var(--cyan); font-size: 1.15rem; }

@media (max-width: 1080px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(360px, .95fr); }
}
@media (max-width: 820px) {
  .hero:not(.route-hero) { padding-top: 3rem; }
  .hero-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .hero-copy { order: 1; }
  .hero-art { order: 2; min-height: 0; aspect-ratio: 1672 / 941; }
  .hero-stats { order: 3; }
  .page-content > .route-hero,
  .page-content .route-hero {
    grid-template-columns: 1fr;
    gap: 1.2rem;
    min-height: 0;
    margin-inline: -1rem;
    padding: 3rem 1rem 2rem;
  }
  .route-hero__copy { order: 1; }
  .route-hero-art { order: 2; min-height: 250px; }
  .route-hero + .hero { margin-top: -1.5rem; }
}
@media (max-width: 560px) {
  .hero-copy h1, .route-hero__copy h1 { font-size: clamp(2.45rem, 12vw, 3.7rem); }
  .hero-art { min-height: 0; aspect-ratio: 1672 / 941; }
  .route-hero-art { min-height: 215px; }
  .route-hero-art--hero { min-height: 0; }
  .hero-art img, .route-hero-art img { border-radius: 20px; }
  .route-hero-art img { top: -16%; height: 132%; }
  .route-hero-art--hero img.hero-artwork { top: auto; height: auto !important; }
}

/* ===== Hero jako plakát (15. 10. 2026) =====
   Obrázek je pozadí celé sekce, text leží nad ním jako vrstva, dole se obrázek
   rozplyne do další sekce. Výška sekce vychází z obsahu — žádné pevné 560 px. */
.hero--poster,
.page-content .route-hero--poster {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  grid-template-columns: none;
  min-height: 0;
  margin: 0;
  padding: clamp(2rem, 3.1vw, 2.75rem) max(1.5rem, calc((100vw - var(--max)) / 2));
  overflow: hidden;
  border-bottom: 0;
  border-radius: 0;
  background: var(--bg);
  color: #F5FAFF;
}
.page-content .route-hero--poster {
  margin: calc(clamp(3.5rem, 7vw, 6.5rem) * -1) calc((100vw - min(100vw - 3rem, var(--max))) / -2) 0;
}
/* obrázek mimo tok dokumentu — v sekci tak nezůstává prázdný sloupec */
.hero--poster > picture,
.page-content .route-hero--poster > picture {
  position: absolute;
  inset: 0;
  z-index: -2;
  display: block;
  width: 100%;
  height: 100%;
}
.hero--poster__bg,
.route-hero--poster__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 68% 25%;
  border-radius: 0;
  /* plynulé rozplynutí do další sekce */
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 58%, rgba(0, 0, 0, .4) 82%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 58%, rgba(0, 0, 0, .4) 82%, transparent 100%);
}
.hero--poster::before,
.page-content .route-hero--poster::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  background: linear-gradient(90deg, #07111F 0%, rgba(7, 17, 31, .92) 32%, rgba(7, 17, 31, .62) 58%, rgba(7, 17, 31, .16) 82%, rgba(7, 17, 31, 0) 100%);
}
.hero--poster::after,
.page-content .route-hero--poster::after {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -1;
  height: 34%;
  content: "";
  background: linear-gradient(180deg, rgba(7, 17, 31, 0), var(--bg));
}
/* text nad obrázkem */
.hero--poster .hero-copy,
.page-content .route-hero--poster .route-hero__copy { position: relative; z-index: 1; max-width: 620px; }
.hero--poster h1,
.page-content .route-hero--poster h1 {
  max-width: 20ch;
  margin-bottom: .8rem;
  font-size: clamp(1.9rem, 3vw, 2.75rem);
  line-height: 1.14;
  color: #FFFFFF;
}
.hero--poster .hero-copy h1 { max-width: 30ch; font-size: clamp(2rem, 3.1vw, 2.85rem); }
.page-content .route-hero--poster .lead { margin-bottom: 0; max-width: 47ch; color: #C8D8E8; font-size: clamp(.94rem, 1.05vw, 1.05rem); }
.hero--poster .lead { color: #C8D8E8; }
.hero--poster .eyebrow,
.page-content .route-hero--poster .eyebrow { margin-bottom: .5rem; color: var(--cyan); }
.hero--poster .hero-kicker span,
.page-content .route-hero--poster .hero-kicker span { border-color: rgba(255, 255, 255, .24); color: #DCE9F5; }
.hero--poster .stat { padding: .55rem .7rem; }
.hero--poster .stat strong { color: #FFFFFF; }
.hero--poster .stat small { color: #C8D8E8; }
.hero--poster .stat-icon { width: 34px; height: 34px; border-color: rgba(255, 255, 255, .22); background: rgba(7, 17, 31, .42); }
.hero--poster .hero-stats { margin-top: clamp(.9rem, 1.6vw, 1.4rem); }
.hero--poster .hero-actions { margin-top: 1.2rem; }
.hero--poster .hero-accent-tail,
.page-content .route-hero--poster .hero-accent-tail { color: var(--cyan); }
.hero--poster .button--secondary,
.page-content .route-hero--poster .button--secondary { border-color: rgba(255, 255, 255, .34); background: rgba(7, 17, 31, .45); color: #F5FAFF; }
.hero--poster .button--secondary:hover,
.page-content .route-hero--poster .button--secondary:hover { border-color: var(--cyan); background: rgba(7, 17, 31, .65); color: #FFFFFF; }
/* úvodní stránka: mírně vyšší kvůli statistikám, ale stále podle obsahu */
.hero--poster { min-height: clamp(360px, 33vw, 440px); }
.hero--poster .hero-grid { display: block; max-width: 660px; }
.hero--poster .hero--poster__bg,
.hero--poster > picture .hero--poster__bg { object-position: 62% 5%; }
html[data-theme] .hero--poster::before {
  background: linear-gradient(90deg, #07111F 0%, rgba(7, 17, 31, .92) 32%, rgba(7, 17, 31, .62) 58%, rgba(7, 17, 31, .16) 82%, rgba(7, 17, 31, 0) 100%);
}
html[data-theme] .hero--poster::after { background: linear-gradient(180deg, rgba(7, 17, 31, 0), var(--bg)); }

@media (max-width: 820px) {
  .hero--poster,
  .page-content .route-hero--poster {
    min-height: clamp(300px, 72vw, 400px);
    justify-content: flex-end;
    margin-inline: -1rem;
    padding: 3rem 1rem 1.35rem;
  }
  .hero--poster__bg,
  .route-hero--poster__bg {
    object-position: center 12%;
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 58%, rgba(0, 0, 0, .45) 82%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 58%, rgba(0, 0, 0, .45) 82%, transparent 100%);
  }
  .hero--poster::before,
  .page-content .route-hero--poster::before {
    background: linear-gradient(180deg, rgba(7, 17, 31, .18) 0%, rgba(7, 17, 31, .5) 30%, rgba(7, 17, 31, .92) 62%, #07111F 90%);
  }
  .hero--poster::after,
  .page-content .route-hero--poster::after { height: 12%; }
  .hero--poster .hero--poster__bg { object-position: center 10%; }
  html[data-theme] .hero--poster::before {
    background: linear-gradient(180deg, rgba(7, 17, 31, .18) 0%, rgba(7, 17, 31, .5) 30%, rgba(7, 17, 31, .92) 62%, #07111F 90%);
  }
  .hero--poster h1,
  .page-content .route-hero--poster h1 { max-width: none; margin-bottom: .6rem; font-size: clamp(1.8rem, 7.6vw, 2.4rem); }
  .hero--poster .hero-copy h1 { font-size: clamp(1.9rem, 8vw, 2.5rem); }
  .page-content .route-hero--poster .lead,
  .hero--poster .lead { margin-bottom: 0; font-size: .94rem; line-height: 1.5; }
  .hero--poster .hero-actions { margin-top: 1rem; gap: .6rem; }
  .hero--poster .hero-actions .button { width: auto; min-height: 40px; padding: .55rem .9rem; font-size: .88rem; }
  .hero--poster .hero-kicker { margin-bottom: .8rem; }
  .hero--poster .hero-stats { grid-template-columns: repeat(4, 1fr); gap: .4rem; margin-top: .9rem; }
  .hero--poster .stat { padding: .45rem .3rem; }
  .hero--poster .stat strong { font-size: .95rem; }
  .hero--poster .stat small { font-size: .66rem; }
  .hero--poster .stat-icon { width: 28px; height: 28px; }
}
@media (max-width: 480px) {
  .hero--poster .hero-stats { grid-template-columns: repeat(2, 1fr); }
}
