:root {
    --color-background: #f5f7fa;
    --color-surface: #ffffff;
    --color-surface-alt: #edf2f7;
    --color-text: #17212b;
    --color-text-muted: #667085;
    --color-border: #dfe5ec;
    --color-primary: #2563eb;
    --color-primary-dark: #1d4ed8;
    --color-accent: #dc2638;
    --color-footer: #18212b;

    --container-width: 1200px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--color-text);
    background: var(--color-background);
}

body {
    margin: 0;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(100% - 40px, var(--container-width));
    margin: 0 auto;
}

.site-main {
    min-height: calc(100vh - 145px);
}


/* =========================================================
   Header
   ========================================================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--color-border);
    backdrop-filter: blur(10px);
}

.header-inner {
    min-height: 72px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 40px;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--color-primary);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

.site-nav a {
    color: var(--color-text-muted);
    font-size: 15px;

    transition:
        color 0.2s ease,
        opacity 0.2s ease;
}

.site-nav a:hover {
    color: var(--color-primary);
}


/* =========================================================
   Shared
   ========================================================= */

.eyebrow {
    margin: 0 0 10px;

    color: var(--color-primary);

    font-size: 13px;
    font-weight: 700;

    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section {
    padding: 60px 0;
}

.section-alt {
    background: var(--color-surface-alt);
}

.section-heading {
    max-width: 720px;
}

.section-heading h2 {
    margin: 0 0 16px;

    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.12;

    letter-spacing: -1px;
}

.section-heading > p:not(.eyebrow) {
    margin: 0;

    color: var(--color-text-muted);
    font-size: 17px;
}


/* =========================================================
   Hero
   ========================================================= */

.hero {
    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #f8fafc 0%,
            #eef4fb 100%
        );

    border-bottom: 1px solid var(--color-border);
}

.hero-inner {
    min-height: 620px;

    display: grid;

    grid-template-columns:
        minmax(0, 1.05fr)
        minmax(420px, 0.95fr);

    align-items: center;

    gap: 60px;
}

.hero-content {
    max-width: 680px;
}

.hero h1 {
    margin: 0;

    max-width: 700px;

    font-size: clamp(46px, 6vw, 76px);
    line-height: 0.98;

    letter-spacing: -3px;
}

.hero h1 span {
    color: var(--color-primary);
}

.hero-text {
    max-width: 620px;

    margin: 28px 0 0;

    color: var(--color-text-muted);
    font-size: 20px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;

    gap: 14px;

    margin-top: 34px;
}

.button {
    display: inline-flex;

    min-height: 48px;

    align-items: center;
    justify-content: center;

    padding: 0 22px;

    border-radius: 8px;

    font-weight: 700;

    transition:
        transform 0.2s ease,
        background 0.2s ease,
        color 0.2s ease;
}

.button:hover {
    transform: translateY(-2px);
}

.button-primary {
    color: #ffffff;
    background: var(--color-primary);
}

.button-primary:hover {
    background: var(--color-primary-dark);
}

.button-secondary {
    color: var(--color-text);

    background: var(--color-surface);

    border: 1px solid var(--color-border);
}

/* =========================================================
   Hero Carousel
   ========================================================= */

.hero-visual {
    position: relative;

    width: 100%;
    min-height: 430px;

    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-carousel {
    position: relative;

    width: 100%;
    height: 430px;

    overflow: hidden;

    border-radius: 18px;

    background: #eaf1f9;

    box-shadow:
        0 24px 60px rgba(23, 33, 43, 0.08);
}

.hero-slide {
    position: absolute;
    inset: 0;

    overflow: hidden;

    opacity: 0;

    animation: heroSlide 18s infinite;
}

.hero-slide img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
    object-position: center;
}

.slide-engineering {
    animation-delay: 0s;
}

.slide-design {
    animation-delay: 6s;
}

.slide-development {
    animation-delay: 12s;
}

.hero-slide-label {
    position: absolute;

    left: 22px;
    bottom: 22px;

    display: inline-flex;

    min-height: 42px;

    align-items: center;

    padding: 0 16px;

    border: 1px solid rgba(223, 229, 236, 0.9);

    border-radius: 8px;

    background: rgba(255, 255, 255, 0.92);

    color: var(--color-text);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 0.12em;
    text-transform: uppercase;

    box-shadow:
        0 8px 20px rgba(23, 33, 43, 0.08);

    backdrop-filter: blur(8px);
}

.hero-carousel-dots {
    position: absolute;

    right: 22px;
    bottom: 24px;

    z-index: 5;

    display: flex;
    align-items: center;

    gap: 8px;
}

.hero-carousel-dots span {
    width: 8px;
    height: 8px;

    display: block;

    border-radius: 50%;

    background: rgba(37, 99, 235, 0.35);

    animation: heroDot 18s infinite;
}

.hero-carousel-dots span:nth-child(1) {
    animation-delay: 0s;
}

.hero-carousel-dots span:nth-child(2) {
    animation-delay: 6s;
}

.hero-carousel-dots span:nth-child(3) {
    animation-delay: 12s;
}

/* Image movement */

.hero-slide img {
    transform: scale(1.02);

    animation: heroImageZoom 18s infinite;
}

.slide-engineering img {
    animation-delay: 0s;
}

.slide-design img {
    animation-delay: 6s;
}

.slide-development img {
    animation-delay: 12s;
}

/* Carousel animation */

@keyframes heroSlide {

    0% {
        opacity: 0;
    }

    4% {
        opacity: 1;
    }

    30% {
        opacity: 1;
    }

    34% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

@keyframes heroImageZoom {

    0% {
        transform: scale(1.02);
    }

    30% {
        transform: scale(1.08);
    }

    34% {
        transform: scale(1.08);
    }

    100% {
        transform: scale(1.02);
    }
}

@keyframes heroDot {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.35;
    }

    4%,
    30% {
        transform: scale(1.35);
        opacity: 1;
    }

    34% {
        transform: scale(1);
        opacity: 0.35;
    }
}

/* =========================================================
   Cards
   ========================================================= */

.card-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 22px;

    margin-top: 42px;
}

.feature-card,
.news-card,
.info-panel {
    background: var(--color-surface);

    border: 1px solid var(--color-border);

    border-radius: 12px;

    box-shadow:
        0 8px 28px rgba(23, 33, 43, 0.04);
}

.feature-card {
    min-height: 260px;

    padding: 28px;
}

.feature-card-muted {
    background: transparent;

    border-style: dashed;
}

.card-label,
.news-meta {
    color: var(--color-primary);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.feature-card h3,
.news-card h3 {
    margin: 14px 0 10px;

    font-size: 24px;
}

.feature-card p,
.news-card p {
    margin: 0;

    color: var(--color-text-muted);
}

.feature-card a,
.news-card a,
.text-link {
    display: inline-block;

    margin-top: 22px;

    color: var(--color-primary);

    font-weight: 700;
}

/* =========================================================
   Tool Card Image
   ========================================================= */

.tool-card-image {
    height: 150px;
    margin-bottom: 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}

.tool-card-image img {
    max-width: 150px;
    max-height: 150px;

    width: auto;
    height: auto;

    object-fit: contain;

    display: block;

    transition:
        transform 0.25s ease,
        filter 0.25s ease;
}


/* Hover effect */

.feature-card:hover .tool-card-image img {
    transform: translateY(-5px) scale(1.03);
}


/* Muted / Coming Soon card */

.feature-card-muted .tool-card-image img {
    opacity: 0.75;
}

.feature-card-muted:hover .tool-card-image img {
    opacity: 0.9;
}

/* =========================================================
   Split Sections
   ========================================================= */

.split-section {
    display: grid;

    grid-template-columns: 1fr 1fr;

    align-items: center;

    gap: 70px;
}

.info-panel {
    overflow: hidden;
}

.info-item {
    display: grid;

    gap: 4px;

    padding: 24px 28px;

    border-bottom: 1px solid var(--color-border);
}

.info-item:last-child {
    border-bottom: 0;
}

.info-item span {
    color: var(--color-text-muted);
}

/* =========================================================
   Documentation technical background
   ========================================================= */

.documentation-section {
    position: relative;
    overflow: hidden;
}

.documentation-tech-bg {
    position: absolute;
    inset: 0;
    z-index: 0;

    pointer-events: none;
    overflow: hidden;
}

.documentation-section::before {
    content: "";
    position: absolute;
    inset: 0;

    background-image:
        linear-gradient(
            rgba(120, 140, 160, 0.035) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(120, 140, 160, 0.035) 1px,
            transparent 1px
        );

    background-size: 48px 48px;

    pointer-events: none;
    z-index: 0;
}

.documentation-tech-bg .tech-item {
    position: absolute;

    color: #8c99a8;
    opacity: 0;

    font-family: "Courier New", Courier, monospace;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 1.5px;
    white-space: nowrap;

    user-select: none;

    /*
     * Text appears from left to right,
     * like documentation/code is being written.
     */
    clip-path: inset(0 100% 0 0);

    animation:
        documentationWrite 14s ease-in-out infinite;
}


/* =========================================================
   Background positions
   ========================================================= */

.documentation-tech-bg .tech-api {
    top: 12%;
    left: 4%;
    animation-delay: 0s;
}

.documentation-tech-bg .tech-class {
    top: 27%;
    left: 11%;
    animation-delay: 1.1s;
}

.documentation-tech-bg .tech-method {
    top: 47%;
    left: 3%;
    animation-delay: 2.2s;
}

.documentation-tech-bg .tech-parameter {
    top: 64%;
    left: 10%;
    animation-delay: 3.3s;
}

.documentation-tech-bg .tech-return {
    top: 78%;
    left: 3%;
    animation-delay: 4.4s;
}

.documentation-tech-bg .tech-example {
    top: 82%;
    left: 25%;
    animation-delay: 5.5s;
}

.documentation-tech-bg .tech-service {
    top: 20%;
    right: 6%;
    animation-delay: 1.7s;
}

.documentation-tech-bg .tech-create-sheet {
    top: 43%;
    right: 6%;
    animation-delay: 3.0s;
}

.documentation-tech-bg .tech-create-view {
    top: 61%;
    right: 4%;
    animation-delay: 4.2s;
}

.documentation-tech-bg .tech-place-viewport {
    top: 79%;
    right: 8%;
    animation-delay: 5.4s;
}


/* =========================================================
   Writing animation
   ========================================================= */

@keyframes documentationWrite {

    0% {
        opacity: 0;
        clip-path: inset(0 100% 0 0);
    }

    8% {
        opacity: 0.10;
        clip-path: inset(0 75% 0 0);
    }

    18% {
        opacity: 0.30;
        clip-path: inset(0 0 0 0);
    }

    42% {
        opacity: 0.30;
        clip-path: inset(0 0 0 0);
    }

    58% {
        opacity: 0.10;
        clip-path: inset(0 0 0 0);
    }

    70% {
        opacity: 0;
        clip-path: inset(0 0 0 0);
    }

    100% {
        opacity: 0;
        clip-path: inset(0 100% 0 0);
    }
}


/* =========================================================
   Keep main documentation content above background
   ========================================================= */

.documentation-section .container {
    position: relative;
    z-index: 2;
}

/* ============================================================
   Development
   ============================================================ */

.development-section {
    align-items: center;
}

.development-visual {
    position: relative;

    min-height: 360px;

    display: flex;
    align-items: center;
    justify-content: center;
}


/* Code window */

.code-window {
    width: min(100%, 560px);

    background: rgba(255, 255, 255, 0.78);

    border: 1px solid rgba(70, 100, 130, 0.18);
    border-radius: 14px;

    box-shadow:
        0 18px 45px rgba(40, 70, 100, 0.08);

    overflow: hidden;
}


/* Window header */

.code-window-header {
    height: 42px;

    display: flex;
    align-items: center;

    gap: 7px;

    padding: 0 16px;

    background: rgba(47, 49, 53, 0.92);

    border-bottom: 1px solid rgba(70, 100, 130, 0.12);
}

.code-window-header span {
    width: 9px;
    height: 9px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.5);
}


/* Code area */

.code-window-body {
    min-height: 290px;

    padding: 28px 30px;

    display: flex;
    align-items: flex-start;

    overflow: hidden;

    background: rgba(193, 199, 208, 0.55);
}

.code-window-body pre {
    margin: 0;

    white-space: pre-wrap;
    word-break: break-word;

    font-family:
        "Cascadia Code",
        "SFMono-Regular",
        Consolas,
        monospace;

    font-size: 14px;
    line-height: 1.75;

    color: rgba(25, 45, 65, 0.72);
}

.code-window-body code {
    font-family: inherit;
}


/* Typing cursor */

.code-cursor {
    display: inline-block;

    width: 7px;
    height: 17px;

    margin-left: 3px;

    vertical-align: -2px;

    background: rgba(37, 99, 235, 0.65);

    animation: codeCursorBlink 1s steps(1) infinite;
}

@keyframes codeCursorBlink {

    0%,
    50% {
        opacity: 1;
    }

    51%,
    100% {
        opacity: 0;
    }
}


/* Mobile */

@media (max-width: 900px) {

    .development-visual {
        min-height: 300px;
    }

    .code-window-body {
        min-height: 250px;

        padding: 24px;
    }

    .code-window-body pre {
        font-size: 13px;
    }
}

/* =========================================================
   News & Updates
   ========================================================= */

.news-heading {
    margin-bottom: 42px;
}


/* Carousel */

.news-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
}


.news-track {
    display: flex;
    gap: 24px;

    transition: transform 0.55s ease;
    will-change: transform;
}


.news-slide {
    flex: 0 0 min(780px, calc(100% - 100px));
}


/* News card */

.news-card {
    min-height: 285px;

    display: flex;
    flex-direction: column;

    padding: 34px 36px;

    background: #ffffff;

    border: 1px solid #d9e1ea;
    border-radius: 14px;

    box-shadow:
        0 12px 30px rgba(20, 45, 75, 0.06);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease;
}


.news-card:hover {
    transform: translateY(-3px);

    border-color: #cbd7e5;

    box-shadow:
        0 16px 36px rgba(20, 45, 75, 0.09);
}


/* Category */

.news-meta {
    display: inline-block;

    margin-bottom: 18px;

    color: #165cff;

    font-size: 13px;
    font-weight: 700;

    letter-spacing: 1.2px;
    text-transform: uppercase;
}


/* Title */

.news-card h3 {
    margin: 0 0 16px;

    color: var(--color-text);

    font-size: 28px;
    line-height: 1.18;
    letter-spacing: -0.6px;
}


/* Description */

.news-card p {
    max-width: 680px;

    margin: 0;

    color: var(--color-text-muted);

    font-size: 16px;
    line-height: 1.65;
}


/* Footer */

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: auto;
    padding-top: 28px;
}


.news-date {
    color: var(--color-text-muted);

    font-size: 13px;
    font-weight: 600;

    letter-spacing: 0.4px;
}


.news-card a {
    color: #165cff;

    font-size: 15px;
    font-weight: 700;

    text-decoration: none;

    transition: color 0.2s ease;
}


.news-card a:hover {
    color: #0d43c7;
}


/* Carousel controls */

.news-carousel-controls {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 22px;

    margin-top: 30px;
}


/* Arrows */

.news-arrow {
    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 1px solid #d5dee8;
    border-radius: 50%;

    background: #ffffff;

    color: #17324d;

    font-size: 18px;
    line-height: 1;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease;
}


.news-arrow:hover {
    background: #f4f8fc;
    border-color: #bfcddd;

    transform: translateY(-1px);
}


.news-arrow:active {
    transform: translateY(0);
}


/* Dots */

.news-dots {
    display: flex;
    align-items: center;

    gap: 8px;
}


.news-dot {
    width: 7px;
    height: 7px;

    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #c6d1de;

    cursor: pointer;

    transition:
        width 0.25s ease,
        background-color 0.25s ease;
}


.news-dot.active {
    width: 22px;

    border-radius: 10px;

    background: #165cff;
}


/* =========================================================
   News responsive
   ========================================================= */

@media (max-width: 900px) {

    .news-slide {
        flex: 0 0 100%;
    }

    .news-card {
        min-height: 260px;
    }

}


@media (max-width: 600px) {

    .news-heading {
        margin-bottom: 30px;
    }

    .news-card {
        min-height: 280px;

        padding: 28px 24px;
    }

    .news-card h3 {
        font-size: 24px;
    }

    .news-card-footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 16px;
    }

    .news-carousel-controls {
        gap: 16px;
    }

}


/* =========================================================
   About
   ========================================================= */

.about-section {
    background: #17212b;

    color: #ffffff;
}

.about-inner {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 70px;

    align-items: center;
}

.about-inner h2 {
    margin: 0;

    font-size: clamp(30px, 4vw, 46px);
    line-height: 1.1;

    letter-spacing: -1px;
}

.about-inner > p {
    margin: 0;

    color: #c9d2dc;

    font-size: 18px;
}


/* =========================================================
   Footer
   ========================================================= */

.site-footer {
    background: var(--color-footer);

    color: #d7dde5;

    padding: 30px 0;
}

.footer-inner {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 30px;
}

.site-footer strong {
    font-size: 17px;
}

.site-footer p {
    margin: 4px 0 0;

    font-size: 14px;
}

.footer-copy {
    text-align: right;
}


/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 1000px) {

    .hero-inner {
        grid-template-columns: 1fr;

        gap: 40px;

        padding-top: 70px;
        padding-bottom: 70px;
    }

    .hero-content {
        max-width: 720px;
    }

    .hero-visual {
        min-height: 380px;
    }

    .hero-carousel {
        height: 380px;
    }

    .split-section,
    .development-section,
    .about-inner {
        grid-template-columns: 1fr;
    }

    .split-section,
    .about-inner {
        gap: 40px;
    }
}


@media (max-width: 900px) {

    .card-grid {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }
}


@media (max-width: 700px) {

    .container {
        width: min(100% - 28px, var(--container-width));
    }

    .header-inner {
        min-height: 64px;

        align-items: flex-start;

        padding: 16px 0;

        flex-direction: column;

        gap: 12px;
    }

    .site-nav {
        width: 100%;

        gap: 16px;

        overflow-x: auto;

        padding-bottom: 2px;
    }

    .site-nav a {
        white-space: nowrap;

        font-size: 14px;
    }

    .section {
        padding: 68px 0;
    }

    .hero {
        overflow: hidden;
    }

    .hero-inner {
        padding-top: 60px;
        padding-bottom: 60px;
    }

    .hero h1 {
        font-size: 48px;

        letter-spacing: -2px;
    }

    .hero-text {
        font-size: 17px;
    }

    .hero-visual {
        min-height: 280px;
    }

    .hero-carousel {
        height: 280px;

        border-radius: 14px;
    }

    .hero-slide-label {
        left: 14px;
        bottom: 14px;

        min-height: 36px;

        padding: 0 12px;

        font-size: 10px;
    }

    .hero-carousel-dots {
        right: 14px;
        bottom: 19px;
    }

    .hero-carousel-dots span {
        width: 7px;
        height: 7px;
    }

    .footer-inner {
        align-items: flex-start;

        flex-direction: column;
    }

    .footer-copy {
        text-align: left;
    }
}


/* =========================================================
   Reduced motion
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    .hero-slide,
    .hero-slide img,
    .hero-carousel-dots span {
        animation: none;
    }

    .hero-slide:first-child {
        opacity: 1;
    }

    .hero-slide img {
        transform: none;
    }
}