/* ============================================================
   Cyberaxis Technology — theme stylesheet
   Graphite / signal-orange system, bento-grid homepage.
   ============================================================ */

:root {
    --ink: #0E0F13;
    --ink-2: #17181F;
    --surface: #FFFFFF;
    --paper: #F6F5F3;
    --accent: #FF5A36;
    --accent-light: #FF8B6B;
    --text: #14151A;
    --muted: #62636B;
    --line: rgba(20, 21, 26, .10);
    --danger: #DC2626;
    --font-display: 'Sora', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

body {
    background: var(--surface);
    color: var(--text);
    font-family: var(--font-body);
}

a {
    transition: color .2s;
}

.cut-corner {
    clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
}

/* ---------- Header ---------- */
.header {
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    padding: 14px 0;
}

.brand {
    text-decoration: none;
    gap: .7rem;
}

.brand-mark {
    color: var(--ink);
    display: flex;
    flex-shrink: 0;
}

.brand-word {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-word strong {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.28rem;
    color: var(--ink);
}

.brand-word small {
    font-family: var(--font-mono);
    font-size: .62rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--muted);
}

#navbar ul {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

#navbar ul li a {
    font-family: var(--font-body);
    font-weight: 500;
    font-size: .93rem;
    color: var(--text);
    text-decoration: none;
    position: relative;
    padding-bottom: 4px;
}

#navbar ul li a:hover,
#navbar ul li a.active {
    color: var(--accent);
}

#navbar ul li a.active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -6px;
    height: 2px;
    background: var(--accent);
}

#navbar ul li a.nav-cta {
    background: var(--ink);
    color: #fff !important;
    padding: .55rem 1.3rem;
    border-radius: 4px;
    font-weight: 600;
}

#navbar ul li a.nav-cta:hover {
    background: var(--accent);
    color: #fff !important;
}

/* ---------- Mobile nav toggle ---------- */
.mobile-nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 4px;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    background: var(--paper);
    border: 1px solid var(--line);
    color: var(--ink);
    transition: background .2s, border-color .2s, color .2s;
}

.mobile-nav-toggle:hover,
.mobile-nav-toggle:focus-visible {
    border-color: var(--accent);
    outline: none;
}

.mobile-nav-toggle.mobile-nav-hide {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

@media (max-width: 991.98px) {
    .mobile-nav-toggle {
        display: flex;
    }

    /*
      The header must sit ABOVE the full-screen nav overlay (z-index 9998)
      and stay visible while the menu is open — otherwise the button that
      closes it disappears from view.
    */
    .header {
        position: sticky;
        top: 0;
        z-index: 9999;
    }

    #navbar {
        position: fixed;
        inset: 0;
        z-index: 9998;
        display: flex;
        align-items: center;
        justify-content: center;
        background: var(--ink);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: opacity .25s ease, transform .25s ease, visibility 0s linear .25s;
    }

    #navbar.navbar-mobile-active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        transition: opacity .25s ease, transform .25s ease, visibility 0s;
    }

    #navbar ul {
        flex-direction: column;
        gap: 0;
        text-align: center;
        width: 100%;
        max-width: 340px;
    }

    #navbar ul li {
        border-bottom: 1px solid rgba(255, 255, 255, .1);
    }

    #navbar ul li:last-child {
        border-bottom: none;
        margin-top: 1.6rem;
    }

    #navbar ul li a {
        display: block;
        padding: 1.05rem 0;
        font-size: 1.15rem;
        font-weight: 600;
        color: #fff !important;
    }

    #navbar ul li a.active,
    #navbar ul li a:hover {
        color: var(--accent-light) !important;
    }

    #navbar ul li a.active::after {
        display: none;
    }

    #navbar ul li a.nav-cta {
        display: inline-block;
        padding: .9rem 2rem;
        background: var(--accent);
        color: #fff !important;
        border-radius: 4px;
    }

    body.mobile-nav-open {
        overflow: hidden;
    }
}

/* ---------- Buttons ---------- */
.btn-primary-cta {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: .85rem 1.8rem;
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
    transition: transform .2s, background .2s;
}

.btn-primary-cta:hover {
    background: var(--accent-light);
    color: var(--ink);
    transform: translateY(-2px);
}

.btn-ghost-cta {
    border: 1px solid rgba(255, 255, 255, .28);
    color: #fff;
    border-radius: 4px;
    padding: .85rem 1.8rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    margin-left: .8rem;
}

.btn-ghost-cta:hover {
    border-color: var(--accent);
    color: var(--accent-light);
}

.btn-dark-cta {
    background: var(--ink);
    color: #fff;
    border-radius: 4px;
    padding: .85rem 1.8rem;
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
    transition: transform .2s, background .2s;
}

.btn-dark-cta:hover {
    background: var(--ink-2);
    color: #fff;
    transform: translateY(-2px);
}

/* ---------- Bento grid system ---------- */
.bento-section {
    padding: 3.5rem 0;
}

.bento-section.section-alt {
    background: var(--paper);
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(150px, auto);
    gap: 1.25rem;
}

.span-1x1 {
    grid-column: span 1;
}

.span-2x1 {
    grid-column: span 2;
}

.span-2x2 {
    grid-column: span 2;
    grid-row: span 2;
}

.span-4x1 {
    grid-column: span 4;
}

.bento-cell {
    padding: 1.8rem;
    border: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.bento-cell.variant-light {
    background: var(--surface);
    color: var(--text);
}

.bento-cell.variant-dark {
    background: var(--ink);
    color: #fff;
    border-color: var(--ink);
}

.bento-cell.variant-accent {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* Hero cell */
.hero-cell {
    justify-content: center;
}

.hero-eyebrow {
    font-family: var(--font-mono);
    font-size: .78rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent-light);
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: 1rem;
}

.hero-eyebrow::before {
    content: '//';
    color: var(--accent);
    font-weight: 700;
}

.hero-cell h1 {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(1.9rem, 3vw, 2.6rem);
    color: #fff;
    line-height: 1.15;
    margin-bottom: 1rem;
}

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

.hero-cell p {
    color: rgba(255, 255, 255, .68);
    font-size: 1rem;
    line-height: 1.7;
    max-width: 480px;
    margin-bottom: 1.8rem;
}

.bento-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
}

.bento-cta-row .btn-ghost-cta {
    margin-left: 0;
}

/* Stat cell */
.stat-cell {
    text-align: center;
    align-items: center;
}

.stat-cell strong {
    display: block;
    font-family: var(--font-display);
    font-size: 1.9rem;
    margin-bottom: .3rem;
}

.stat-cell small {
    font-family: var(--font-mono);
    font-size: .68rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    opacity: .75;
}

/* Threat map decorative cell */
.threat-map-cell {
    position: relative;
    background: var(--paper);
    padding: 1.2rem;
}

.threat-map-svg {
    width: 100%;
    height: auto;
}

.threat-map-label {
    font-family: var(--font-mono);
    font-size: .66rem;
    letter-spacing: .08em;
    color: var(--muted);
    margin-top: .6rem;
    display: block;
}

/* Services intro (above the services bento grid) */
.services-intro {
    max-width: 640px;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.eyebrow {
    font-family: var(--font-mono);
    font-size: .72rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: .8rem;
    display: block;
}

.eyebrow::before {
    content: '// ';
}

.services-intro h2 {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--ink);
    font-size: clamp(1.6rem, 2.4vw, 2.1rem);
    margin-bottom: .9rem;
}

.services-intro .lead-text {
    color: var(--muted);
    line-height: 1.7;
}

/* Service cell */
.service-cell {
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    transition: transform .2s, box-shadow .2s, border-color .2s;
}

.service-cell:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 36px -18px rgba(14, 15, 19, .22);
    border-color: var(--accent);
    color: var(--text);
}

.service-cell .service-code {
    font-family: var(--font-mono);
    font-size: .66rem;
    letter-spacing: .05em;
    color: var(--muted);
    display: block;
    margin-bottom: 1rem;
}

.service-cell .service-icon {
    width: 42px;
    height: 42px;
    background: var(--paper);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.service-cell h3 {
    font-family: var(--font-display);
    font-size: 1.02rem;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: .5rem;
}

.service-cell-featured h3 {
    font-size: 1.2rem;
}

.service-cell p {
    color: var(--muted);
    font-size: .9rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.service-cell .service-link {
    font-family: var(--font-mono);
    font-size: .72rem;
    color: var(--ink);
    font-weight: 500;
    margin-top: auto;
}

.service-cell:hover .service-link {
    color: var(--accent);
}

/* View-all cell */
.view-all-cell {
    background: var(--paper);
    border: 1px dashed var(--line);
    align-items: center;
    justify-content: center;
    flex-direction: row;
    gap: .6rem;
    text-decoration: none;
    font-family: var(--font-mono);
    font-size: .82rem;
    font-weight: 600;
    color: var(--ink);
    transition: border-color .2s, color .2s;
}

.view-all-cell:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.view-all-arrow {
    transition: transform .2s;
}

.view-all-cell:hover .view-all-arrow {
    transform: translateX(4px);
}

/* Quote cell */
.exec-quote {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 500;
    color: #fff;
    line-height: 1.6;
    border-left: 3px solid var(--accent);
    padding-left: 1.1rem;
    margin: 0 0 1rem;
}

.signature-label {
    display: block;
    font-family: var(--font-mono);
    font-size: .68rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--accent-light);
    font-weight: 600;
}

/* Closing CTA cell */
.cta-cell .cta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.cta-cell h2 {
    font-family: var(--font-display);
    color: #fff;
    font-size: clamp(1.3rem, 2.4vw, 1.8rem);
    margin: 0;
    max-width: 500px;
}

/* ---------- Footer ---------- */
.footer {
    background: var(--ink);
    color: rgba(255, 255, 255, .68);
    font-family: var(--font-body);
}

.footer-content {
    padding: 5rem 0 3rem;
}

.footer .footer-brand {
    display: flex;
    align-items: center;
    gap: .7rem;
    margin-bottom: 1.1rem;
}

.footer .footer-brand .brand-mark {
    color: var(--accent);
}

.footer .footer-brand strong {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.15rem;
    color: #fff;
    display: block;
    line-height: 1.1;
}

.footer .footer-brand small {
    font-family: var(--font-mono);
    font-size: .6rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .5);
}

.footer p.footer-blurb {
    max-width: 320px;
    line-height: 1.7;
    font-size: .9rem;
    margin-bottom: 1.5rem;
}

.footer .footer-meta {
    list-style: none;
    padding: 0;
    margin: 0 0 1.6rem;
    font-size: .86rem;
}

.footer .footer-meta li {
    display: flex;
    gap: .6rem;
    margin-bottom: .6rem;
}

.footer .footer-meta li i {
    color: var(--accent);
    margin-top: .2rem;
}

.footer .social-links a {
    width: 36px;
    height: 36px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, .16);
    color: rgba(255, 255, 255, .75);
    margin-right: .6rem;
    transition: border-color .2s, color .2s;
}

.footer .social-links a:hover {
    border-color: var(--accent);
    color: var(--accent-light);
}

.footer h4 {
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .9);
    margin-bottom: 1.3rem;
}

.footer .footer-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer .footer-links ul li {
    margin-bottom: .7rem;
}

.footer .footer-links ul li a {
    color: rgba(255, 255, 255, .68);
    text-decoration: none;
    font-size: .88rem;
    transition: color .2s;
}

.footer .footer-links ul li a:hover {
    color: var(--accent-light);
}

.footer-cta-card {
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .12);
    padding: 1.6rem;
}

.footer-cta-card p {
    font-size: .86rem;
    line-height: 1.6;
    margin-bottom: 1.1rem;
    color: rgba(255, 255, 255, .68);
}

.footer-cta-card a.btn-footer-cta {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    font-size: .86rem;
    padding: .65rem 1.2rem;
    border-radius: 4px;
    text-decoration: none;
}

.footer-cta-card a.btn-footer-cta:hover {
    background: var(--accent-light);
    color: var(--ink);
}

.footer-legal {
    background: var(--ink-2);
    padding: 1.3rem 0;
    border-top: 1px solid rgba(255, 255, 255, .08);
}

.footer-legal .copyright,
.footer-legal .credits {
    font-size: .8rem;
    color: rgba(255, 255, 255, .5);
}

.scroll-top {
    background: var(--accent) !important;
    color: #fff !important;
}

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {

    .bento-grid,
    .bento-grid-services {
        grid-template-columns: repeat(2, 1fr);
    }

    .span-4x1 {
        grid-column: span 2;
    }
}

@media (max-width: 575.98px) {

    .bento-grid,
    .bento-grid-services {
        grid-template-columns: 1fr;
    }

    .span-1x1,
    .span-2x1,
    .span-2x2,
    .span-4x1 {
        grid-column: span 1;
    }

    .span-2x2 {
        grid-row: span 1;
    }

    .cta-cell .cta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .bento-section {
        padding: 2.5rem 0;
    }
}
