.site-shell {
    min-height: 100vh;
    background:
        radial-gradient(900px 420px at 10% -5%, var(--hero-glow-1), transparent 60%),
        radial-gradient(700px 360px at 90% 0%, var(--hero-glow-2), transparent 55%),
        var(--bg);
    transition: background 0.25s ease;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    background: var(--header-bg);
    border-bottom: 1px solid var(--line);
}
.site-header > .wrap.header-inner {
    width: min(1140px, calc(100% - 1rem));
}
.theme-switch {
    display: inline-flex;
    border: 1px solid var(--line);
    border-radius: 999px;
    overflow: hidden;
}
.theme-btn {
    min-width: 44px;
    min-height: 44px;
    padding: 0 0.5rem;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.theme-btn.is-active {
    background: var(--accent-dim);
    color: var(--accent);
}
.theme-btn:hover { color: var(--text); }
.header-inner {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem 1.25rem;
    min-height: 72px;
    overflow: visible;
}
.header-brand {
    justify-self: start;
    margin-left: -0.35rem;
}
.header-end {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-shrink: 0;
    margin-right: -0.25rem;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    color: var(--text);
    font-family: var(--font-display);
    font-weight: 700;
    flex-shrink: 0;
}
.brand-logo-wrap {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    line-height: 1;
}
.brand-logo-digital {
    position: relative;
}
.brand-logo-brain {
    position: relative;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
}
.brand-logo-pulse {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px solid rgba(0, 217, 192, 0.45);
    pointer-events: none;
    animation: brandBrainPulse 2.8s ease-out infinite;
}
.brand-logo-pulse-2 {
    animation-delay: 1.4s;
    border-color: rgba(0, 191, 255, 0.35);
}
.brand-logo-pulse-3 {
    animation-delay: 2.1s;
    border-color: rgba(99, 102, 241, 0.3);
}
.brand-logo-glyph {
    position: relative;
    z-index: 1;
    width: 40px;
    height: 40px;
    color: #f0f4f8;
    overflow: visible;
    filter:
        drop-shadow(0 0 6px rgba(0, 229, 255, 0.55))
        drop-shadow(0 0 14px rgba(0, 114, 255, 0.35));
    animation: brandLogoGlowHue 4.5s ease-in-out infinite;
    transition: filter 0.25s ease;
}
.brand-logo-glyph-inner {
    transform-box: fill-box;
    transform-origin: center;
    animation: brandLogoAlive 3.2s ease-in-out infinite;
}
.brand-logo-hex {
    transform-box: fill-box;
    transform-origin: center;
    animation: brandLogoHexWarp 4.8s ease-in-out infinite;
}
.brand-logo-spark {
    transform-box: fill-box;
    transform-origin: center;
    animation: brandLogoSparkSpin 8s linear infinite;
}
.brand-logo-core {
    transform-box: fill-box;
    transform-origin: center;
    animation: brandLogoCorePulse 2.4s ease-in-out infinite;
}
.brand-logo-neural-lines {
    stroke: #00D9C0;
    animation: brandLogoLineFade 2.8s ease-in-out infinite;
}
.brand-logo-node {
    fill: #00D9C0;
    stroke: #00E5FF;
    stroke-width: 0.35;
    transform-box: fill-box;
    transform-origin: center;
    animation: brandLogoNodePulse 2.4s ease-in-out infinite;
}
.brand-logo-node:nth-of-type(1) { animation-delay: 0s; }
.brand-logo-node:nth-of-type(2) { animation-delay: 0.35s; }
.brand-logo-node:nth-of-type(3) { animation-delay: 0.7s; }
.brand-logo-node:nth-of-type(4) { animation-delay: 1.05s; }
.brand-logo-node:nth-of-type(5) { animation-delay: 1.4s; }
.brand-logo-node:nth-of-type(6) { animation-delay: 1.75s; }
.brand-logo-hub {
    animation: brandLogoHubGlow 2.4s ease-in-out infinite;
}
.brand-logo-spark-mini {
    animation: brandLogoMiniSpark 3s ease-in-out infinite;
}
.brand-logo-brain-glow {
    animation: brandBrainGlow 2.8s ease-in-out infinite;
}
html[data-theme="light"] .brand-logo-glyph,
html[data-theme="brand"] .brand-logo-glyph {
    color: #0f172a;
}
.brand-logo-text {
    position: relative;
    display: inline-flex;
    align-items: baseline;
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    white-space: nowrap;
    line-height: 1;
    text-transform: uppercase;
}
.brand-logo-ai {
    background: linear-gradient(120deg, #00E5FF 0%, #00BFFF 35%, #0072FF 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: brandLogoShimmer 4s ease-in-out infinite;
    text-shadow: 0 0 24px rgba(0, 191, 255, 0.25);
}
.brand-logo-pay {
    color: #f0f4f8;
    text-shadow:
        0 0 12px rgba(0, 217, 192, 0.35),
        0 0 1px rgba(255, 255, 255, 0.5);
}
html[data-theme="light"] .brand-logo-pay,
html[data-theme="brand"] .brand-logo-pay {
    color: #0f172a;
    text-shadow: 0 0 10px rgba(0, 114, 255, 0.15);
}
.brand-logo-scan {
    position: absolute;
    inset: -2px -4px;
    overflow: hidden;
    pointer-events: none;
    border-radius: 4px;
    mix-blend-mode: screen;
    opacity: 0.55;
}
.brand-logo-scan::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    height: 40%;
    top: -50%;
    background: linear-gradient(180deg, transparent, rgba(0, 229, 255, 0.45), transparent);
    animation: brandLogoScan 3.2s ease-in-out infinite;
}
.brand:hover .brand-logo-glyph {
    animation-duration: 2.2s;
    filter:
        drop-shadow(0 0 10px rgba(0, 229, 255, 0.85))
        drop-shadow(0 0 22px rgba(0, 217, 192, 0.55))
        drop-shadow(0 0 32px rgba(99, 102, 241, 0.35));
}
.brand:hover .brand-logo-glyph-inner,
.brand:hover .brand-logo-hex,
.brand:hover .brand-logo-core,
.brand:hover .brand-logo-spark {
    animation-duration: 1.6s;
}
.brand:hover .brand-logo-pulse {
    animation-duration: 1.8s;
}
.brand:hover .brand-logo-ai {
    animation-duration: 2s;
}
.footer-logo {
    display: inline-block;
    margin-bottom: 0.65rem;
}
.footer-logo .brand-logo-brain { width: 34px; height: 34px; }
.footer-logo .brand-logo-glyph { width: 34px; height: 34px; }
.footer-logo .brand-logo-pulse { display: none; }
.footer-logo .brand-logo-glyph {
    animation: brandLogoGlowHue 6s ease-in-out infinite;
}
.footer-logo .brand-logo-glyph-inner,
.footer-logo .brand-logo-hex,
.footer-logo .brand-logo-spark {
    animation-duration: 5s;
}
.footer-logo .brand-logo-text { font-size: 1.1rem; letter-spacing: 0.12em; }
.footer-logo .brand-logo-scan { display: none; }
.nav-toggle {
    display: none;
    flex-shrink: 0;
    background: none;
    border: 0;
    padding: 0.4rem;
    cursor: pointer;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
}
.nav-toggle span {
    display: block;
    width: 24px; height: 2px;
    margin: 5px 0;
    background: var(--text);
}
.site-nav {
    justify-self: center;
    min-width: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    overflow: visible;
}
.nav-list {
    display: inline-flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.1rem;
    list-style: none;
    margin: 0;
    padding: 0.3rem;
    max-width: 100%;
    overflow: visible;
    border-radius: 999px;
    background: color-mix(in srgb, var(--text) 4%, transparent);
    border: 1px solid var(--line);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.nav-list > li {
    display: flex;
    align-items: center;
}
.nav-list a {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    padding: 0.42rem 0.72rem;
    border-radius: 999px;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
    transition: color 0.15s ease, background 0.15s ease;
}
.nav-list a:hover {
    color: var(--text);
    background: color-mix(in srgb, var(--accent) 10%, transparent);
}
.nav-has-drop { position: relative; }
.nav-has-drop::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 0.5rem;
}
.nav-drop-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    padding: 0.42rem 0.72rem;
    border: 0;
    border-radius: 999px;
    background: none;
    color: var(--muted);
    font: inherit;
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
    cursor: pointer;
    transition: color 0.15s ease, background 0.15s ease;
}
.nav-drop-btn:hover,
.nav-has-drop.is-open .nav-drop-btn {
    color: var(--text);
    background: color-mix(in srgb, var(--accent) 10%, transparent);
}
.nav-drop-caret {
    width: 0.42rem;
    height: 0.42rem;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-1px);
    opacity: 0.75;
    transition: transform 0.15s ease;
}
.nav-has-drop.is-open .nav-drop-caret {
    transform: rotate(-135deg) translateY(1px);
}
.nav-drop {
    list-style: none;
    margin: 0;
    padding: 0.4rem;
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    min-width: 210px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.15s ease, visibility 0.15s ease, transform 0.15s ease;
    z-index: 60;
}
.nav-drop a {
    display: block;
    padding: 0.5rem 0.75rem;
    border-radius: 10px;
    color: var(--muted);
    font-size: 0.84rem;
    white-space: nowrap;
}
.nav-drop a:hover {
    color: var(--text);
    background: var(--bg-soft);
}
.nav-has-drop.is-open .nav-drop,
.nav-has-drop:hover .nav-drop {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}
.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}
.nav-actions .theme-switch {
    flex-shrink: 0;
}
.nav-actions .theme-btn {
    min-width: 36px;
    min-height: 36px;
    font-size: 0.92rem;
}

.nav-mobile-actions {
    display: none !important;
}

.site-footer {
    position: relative;
    margin-top: 3rem;
    border-top: 1px solid var(--line);
    background: var(--bg);
}
.footer-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.35rem 0;
    border-bottom: 1px solid var(--line);
}
.footer-cta__title {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(1rem, 2vw, 1.2rem);
    font-weight: 600;
    line-height: 1.35;
    color: var(--text);
}
.footer-cta__link {
    flex-shrink: 0;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    transition: color 0.2s ease;
}
.footer-cta__link:hover {
    color: var(--accent-hover);
}
.footer-main {
    padding: 0;
}
.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr));
    gap: 2rem 2.5rem;
    align-items: start;
}
.footer-grid--contacts {
    grid-template-columns: minmax(0, 1.35fr) repeat(3, minmax(0, 1fr));
    gap: 0;
    align-items: stretch;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: color-mix(in srgb, var(--card) 72%, transparent);
}
.footer-grid__cell {
    position: relative;
    padding: 2rem 1.75rem;
}
.footer-grid__cell + .footer-grid__cell::before {
    content: "";
    position: absolute;
    top: 18%;
    bottom: 18%;
    left: 0;
    width: 1px;
    background: var(--line);
}
.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-width: none;
    text-align: left;
    align-items: flex-start;
    justify-content: center;
}
.footer-contact-cell {
    display: flex;
    align-items: center;
    justify-content: center;
}
.footer-contact-cell__btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
    text-align: center;
    transition: opacity 0.2s ease;
}
.footer-contact-cell__btn:hover {
    opacity: 0.92;
}
.footer-contact-cell__btn.is-revealed .footer-contact-cell__hint {
    display: none;
}
.footer-contact-cell__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    height: 2.4rem;
    color: var(--brand-blue);
}
.footer-contact-cell__icon svg {
    display: block;
    width: 2rem;
    height: 2rem;
}
.footer-contact-cell__label {
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--brand-blue);
}
.footer-contact-cell__value {
    min-height: 1.1em;
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.35;
    word-break: break-word;
}
.footer-contact-cell__value:empty {
    display: none;
}
.footer-contact-cell__hint {
    color: color-mix(in srgb, var(--muted) 88%, transparent);
    font-size: 0.76rem;
    line-height: 1.35;
}
.footer-contact-cell__status {
    min-height: 0.95em;
    color: var(--accent);
    font-size: 0.72rem;
    line-height: 1.3;
}
.footer-contact-cell__status:empty {
    display: none;
}
.footer-tagline {
    margin: 0;
    color: var(--muted);
    font-size: 0.88rem;
    font-weight: 500;
    line-height: 1.45;
}
.footer-disclaimer {
    margin: 0;
    color: color-mix(in srgb, var(--muted) 85%, transparent);
    font-size: 0.76rem;
    line-height: 1.55;
}
.footer-methods {
    margin: 1.5rem 0 0;
    padding: 1.25rem 0 1.75rem;
    border-top: 1px solid var(--line);
    color: color-mix(in srgb, var(--muted) 75%, transparent);
    font-size: 0.72rem;
    line-height: 1.6;
    letter-spacing: 0.01em;
}
.footer-col-title {
    display: block;
    margin: 0 0 1rem;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.footer-col-list,
.footer-contact-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.65rem;
}
.footer-col-list a {
    color: var(--text);
    font-size: 0.88rem;
    line-height: 1.4;
    opacity: 0.82;
    transition: opacity 0.2s ease, color 0.2s ease;
}
.footer-col-list a:hover {
    opacity: 1;
    color: var(--accent-hover);
}
.footer-contact-link,
.footer-contact-hours {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--text);
    font-size: 0.88rem;
    line-height: 1.4;
    opacity: 0.82;
}
.footer-contact-link {
    transition: opacity 0.2s ease, color 0.2s ease;
}
.footer-contact-link:hover {
    opacity: 1;
    color: var(--accent-hover);
}
.footer-contact-hours {
    opacity: 0.65;
    cursor: default;
}
.footer-contact-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
    color: var(--muted);
}
.footer-contact-icon svg {
    display: block;
    width: 0.95rem;
    height: 0.95rem;
}
.footer-bottom {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 1rem 1.5rem;
    padding: 1.15rem 0 1.5rem;
    border-top: 1px solid var(--line);
}
.footer-copy {
    margin: 0;
    color: var(--muted);
    font-size: 0.78rem;
    white-space: nowrap;
}
.footer-legal-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.5rem;
}
.footer-legal-nav a {
    color: var(--muted);
    font-size: 0.76rem;
    line-height: 1.4;
    transition: color 0.2s ease;
}
.footer-legal-nav a:hover {
    color: var(--text);
}
.footer-legal-sep {
    color: color-mix(in srgb, var(--muted) 50%, transparent);
    font-size: 0.76rem;
    user-select: none;
}
.footer-top {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 500;
    white-space: nowrap;
    transition: color 0.2s ease;
}
.footer-top:hover {
    color: var(--text);
}

@media (max-width: 1024px) {
    .footer-grid--contacts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .footer-brand.footer-grid__cell {
        grid-column: 1 / -1;
    }
    .footer-grid__cell + .footer-grid__cell::before {
        display: none;
    }
    .footer-grid--contacts .footer-grid__cell {
        border-top: 1px solid var(--line);
    }
    .footer-grid--contacts .footer-brand.footer-grid__cell {
        border-top: 0;
    }
    .footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.75rem 2rem;
    }
    .footer-brand {
        grid-column: 1 / -1;
        max-width: none;
    }
    .footer-bottom {
        grid-template-columns: 1fr;
        justify-items: start;
        gap: 0.85rem;
    }
    .footer-legal-nav {
        justify-content: flex-start;
    }
}
@media (max-width: 768px) {
    .footer-cta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.65rem;
    }
    .footer-grid--contacts {
        grid-template-columns: 1fr;
    }
    .footer-grid__cell {
        padding: 1.5rem 1.25rem;
    }
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .footer-methods {
        margin-top: 1.5rem;
        padding-top: 1.25rem;
        font-size: 0.7rem;
    }
}

@media (max-width: 1024px) {
    .hero-grid, .pay-columns, .contact-layout, .widget-demo, .docs-layout,
    .showcase-row, .product-layout, .product-grid, .integration-layout,
    .pay-columns-visual { grid-template-columns: 1fr; }
    .showcase-row.is-reverse .showcase-copy,
    .showcase-row.is-reverse .showcase-visual,
    .product-layout.is-reverse .product-demo,
    .product-layout.is-reverse .product-copy { order: unset; }
    .card-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hero-stats, .steps-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .news-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 1100px) {
    .nav-list a,
    .nav-drop-btn {
        padding: 0.38rem 0.55rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 768px) {
    .brand-logo-brain { width: 34px; height: 34px; }
    .brand-logo-glyph { width: 34px; height: 34px; }
    .brand-logo-text { font-size: 1.1rem; letter-spacing: 0.1em; }
    .header-inner {
        grid-template-columns: 1fr auto;
        gap: 0.5rem 0.75rem;
    }
    .header-brand { grid-column: 1; }
    .header-end {
        grid-column: 2;
        grid-row: 1;
        gap: 0.35rem;
        max-width: 100%;
    }
    .nav-toggle {
        display: inline-flex;
        margin-left: 0.1rem;
    }
    .nav-actions .btn {
        display: none;
    }
    .nav-mobile-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
        margin-top: 0.75rem;
        padding-top: 0.75rem;
        border-top: 1px solid var(--line);
    }
    .nav-mobile-actions .btn {
        width: 100%;
        min-height: 44px;
    }
    .site-nav {
        grid-column: 1 / -1;
        grid-row: 2;
        justify-self: stretch;
        position: fixed;
        inset: 72px 0 auto 0;
        background: rgba(7, 11, 16, 0.96);
        border-bottom: 1px solid var(--line);
        flex-direction: column;
        align-items: stretch;
        padding: 1rem;
        transform: translateY(-120%);
        opacity: 0;
        pointer-events: none;
        transition: 0.2s ease;
        z-index: 55;
        display: flex;
    }
    .site-nav.is-open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }
    .nav-list {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        border-radius: var(--radius);
        padding: 0.5rem;
        gap: 0.15rem;
    }
    .nav-list > li { width: 100%; }
    .nav-list a,
    .nav-drop-btn {
        width: 100%;
        justify-content: space-between;
        padding: 0.65rem 0.85rem;
        font-size: 0.92rem;
        border-radius: 10px;
    }
    .nav-drop {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: 0;
        background: transparent;
        padding: 0 0 0 0.75rem;
        display: none;
        min-width: 0;
    }
    .nav-has-drop.is-open .nav-drop {
        display: block;
        pointer-events: auto;
    }
    .nav-has-drop:hover .nav-drop { display: none; }
    .nav-has-drop.is-open:hover .nav-drop { display: block; }
    .nav-actions {
        gap: 0.25rem;
    }
    .nav-actions .theme-btn {
        min-width: 32px;
        min-height: 32px;
        font-size: 0.85rem;
        padding: 0 0.35rem;
    }
    .theme-switch {
        flex-shrink: 0;
    }
    .card-grid-3, .card-grid-4, .channel-grid, .news-grid, .hero-stats, .steps-row {
        grid-template-columns: 1fr;
    }
}