:root {
    /* Colors */
    --color-primary: #F7931A;
    --color-primary-dark: #D67A0E;
    --color-bg-dark: #0A0A0A;
    --color-bg-anthracite: #1A1A1A;
    --color-text-main: #FFFFFF;
    --color-text-muted: #A0A0A0;
    --color-white: #FFFFFF;
    --color-black: #000000;

    /* Typography */
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 2rem;
    --space-lg: 4rem;
    --space-xl: 8rem;
    --section-padding: 120px 0;

    /* Transitions */
    --transition-fast: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 1s cubic-bezier(0.4, 0, 0.2, 1);

    /* Shadows & Effects */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow-premium: 0 20px 40px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--color-bg-dark);
    color: var(--color-text-main);
    font-family: var(--font-main);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;

    /* Premium Background System */
    background-image:
        linear-gradient(rgba(247, 147, 26, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(247, 147, 26, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
}

/* Orbital Glows */
.orbital-glow {
    position: fixed;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(247, 147, 26, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: -1;
    animation: orbit 20s infinite linear;
}

@keyframes orbit {
    0% {
        transform: translate(-10%, -10%);
    }

    25% {
        transform: translate(110%, 10%);
    }

    50% {
        transform: translate(100%, 110%);
    }

    75% {
        transform: translate(-10%, 100%);
    }

    100% {
        transform: translate(-10%, -10%);
    }
}

h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: var(--section-padding);
}

/* Utilities */
.text-primary {
    color: var(--color-primary);
}

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

.bg-anthracite {
    background-color: var(--color-bg-anthracite);
}

.brand-text {
    color: var(--color-primary);
    font-weight: 700;
}

.brand-num {
    color: var(--color-white);
}

.logo img {
    border-radius: 20px;
}

.flex {
    display: flex;
}

.grid {
    display: grid;
}

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

.justify-between {
    justify-content: space-between;
}

.gap-md {
    gap: var(--space-md);
}

.gap-lg {
    gap: var(--space-lg);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-black);
}

.btn-primary:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
}

.btn-secondary {
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--color-white);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Glassmorphism Refinement */
.glass-pane {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-premium);
}

/* Hero Image Specifics */
.hero-image-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: perspective(1000px) rotateY(-5deg);
    transition: var(--transition-slow);
}

.hero-image-container:hover {
    transform: perspective(1000px) rotateY(0deg);
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
    mix-blend-mode: luminosity;
    transition: var(--transition-slow);
}

.hero-image-container:hover .hero-image {
    mix-blend-mode: normal;
}

/* Architecture Diagram Refinement */
.arch-diagram-container {
    margin: var(--space-lg) 0;
    padding: 0;
    background: none;
    border: none;
    display: flex;
    justify-content: center;
}

.arch-diagram {
    width: 100%;
    max-width: 1000px;
    filter: drop-shadow(0 0 40px rgba(0, 0, 0, 0.8));
    transition: var(--transition-slow);
}

.arch-node {
    border-left: 1px solid rgba(255, 255, 255, 0.05) !important;
    background: rgba(255, 255, 255, 0.01) !important;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.arch-node:hover {
    border-left-color: var(--color-primary) !important;
    background: rgba(247, 147, 26, 0.02) !important;
}

/* Advanced Animations */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

.float-anim {
    animation: float 6s ease-in-out infinite;
}

[data-reveal] {
    opacity: 0;
    transform: translateY(40px);
    transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered entry classes */
.stagger-1 {
    transition-delay: 0.1s;
}

.stagger-2 {
    transition-delay: 0.2s;
}

.stagger-3 {
    transition-delay: 0.3s;
}

.stagger-4 {
    transition-delay: 0.4s;
}

/* Glowing Text */
.glow-text {
    text-shadow: 0 0 20px rgba(247, 147, 26, 0.4);
}

/* Hero Visual (Ported from 3.0) */
/* Hero Visual Refinement: 3D Rotation Flow */
/* Hero Visual Refinement: 3D Rotation with HUD Rings */
.hero-visual {
    position: relative;
    width: 100%;
    max-width: 440px;
    aspect-ratio: 1/1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    perspective: 1200px;
    transform-style: preserve-3d;
}

/* Core Node: 3D Rotating Object */
.core-node {
    z-index: 10;
    position: relative;
    width: 200px;
    height: 200px;
    /* Container size */
    display: flex;
    align-items: center;
    justify-content: center;
    transform-style: preserve-3d;
    /* Rotation applied here */
    animation: rotate3D 12s linear infinite;
}

/* 3D Mac Mini Container */
.mac-mini-3d {
    width: 140px;
    height: 140px;
    position: relative;
    transform-style: preserve-3d;
    transform: rotateX(0deg);
}

/* Face Common Styles */
.face {
    position: absolute;
    background: rgba(255, 255, 255, 0.2);
    /* Increased opacity for whiter look */
    /* Border removed for phantom look */
    border: none;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3) inset;
    /* Stronger inner glow */
    display: flex;
    align-items: center;
    justify-content: center;
    backface-visibility: visible;
    backdrop-filter: blur(6px) brightness(1.2);
    /* Added brightness boost */
}

/* Face Dimensions & Transforms */
/* Top & Bottom: 140x140 */
.face.top,
.face.bottom {
    width: 140px;
    height: 140px;
    border-radius: 20px;
}

.face.top {
    transform: rotateX(90deg) translateZ(15px);
    background: radial-gradient(circle, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.2) 80%);
    /* Brighter gradient */
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.4) inset;
}

.face.bottom {
    transform: rotateX(-90deg) translateZ(15px);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

/* Sides: 140x30 */
.face.front,
.face.back,
.face.left,
.face.right {
    width: 110px;
    height: 30px;
    left: 15px;
    top: 55px;
    background: rgba(255, 255, 255, 0.18);
    /* Whiter sides */
    border: none;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.25) inset;
}

.face.front {
    transform: rotateY(0deg) translateZ(68px);
}

.face.back {
    transform: rotateY(180deg) translateZ(68px);
}

.face.left {
    transform: rotateY(-90deg) translateZ(68px);
}

.face.right {
    transform: rotateY(90deg) translateZ(68px);
}

.corner-bl {
    transform: rotateY(225deg) translateZ(76px);
}

/* Details */
.face-content {
    /* Logo removed, but keep class if needed later */
    display: none;
}

.power-led {
    width: 4px;
    height: 4px;
    background-color: var(--color-white);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--color-white);
    position: absolute;
    right: 15px;
}

/* Hover Effects */
.hero-visual:hover .core-node {
    animation-play-state: paused;
}

.hero-visual:hover .face {
    border-color: var(--color-primary);
    box-shadow: 0 0 20px rgba(247, 147, 26, 0.3) inset;
}

.hero-visual:hover .power-led {
    background-color: var(--color-primary);
    box-shadow: 0 0 15px var(--color-primary);
}

/* 3D Rotation Keyframes */
@keyframes rotate3D {
    0% {
        transform: rotateY(0deg) rotateX(15deg);
    }

    100% {
        transform: rotateY(360deg) rotateX(15deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.6;
        /* Boosted brightness */
    }

    50% {
        transform: scale(1.1);
        opacity: 0.9;
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* --- HUD Rings & Glow (Restored & Isolated) --- */

.core-glow {
    position: absolute;
    width: 70%;
    height: 70%;
    background: radial-gradient(circle, rgba(247, 147, 26, 0.4) 0%, transparent 70%);
    filter: blur(50px);
    animation: pulse 4s ease-in-out infinite both;
    transform: translateZ(-60px);
    z-index: 1;
}

.core-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    animation: rotate 25s linear infinite;
    z-index: 2;
    pointer-events: none;
}

/* CRITICAL FIX: Prevent black disc artifact */
.core-ring svg {
    width: 100%;
    height: 100%;
    overflow: visible;
    fill: none !important;
}

.ring-path {
    fill: none !important;
    stroke: rgba(247, 147, 26, 0.2);
    stroke-width: 0.5;
}

.core-ring:nth-child(2) {
    animation-duration: 40s;
    animation-direction: reverse;
}

.core-ring:nth-child(2) .ring-path {
    stroke: rgba(255, 255, 255, 0.1);
    stroke-width: 0.6;
    stroke-dasharray: 1 16;
    stroke-linecap: round;
}

.core-ring:nth-child(3) {
    animation-duration: 18s;
}

.core-ring:nth-child(3) .ring-path {
    stroke: rgba(247, 147, 26, 0.5);
    stroke-width: 1.2;
    stroke-dasharray: 0.1 22;
    stroke-linecap: round;
}

.core-ring:nth-child(4) {
    animation-duration: 60s;
}

.core-ring:nth-child(4) .ring-path {
    stroke: rgba(255, 255, 255, 0.02);
    stroke-width: 0.4;
}

.core-ring:nth-child(5) {
    animation-duration: 30s;
    animation-direction: reverse;
}

.core-ring:nth-child(5) .ring-path {
    stroke: rgba(247, 147, 26, 0.3);
    stroke-width: 0.8;
    stroke-dasharray: 0.1 15;
    stroke-linecap: round;
}

/* CRITICAL FIX: Prevent black disc artifact */
.core-ring svg {
    width: 100%;
    height: 100%;
    overflow: visible;
    fill: none !important;
}

.ring-path {
    fill: none !important;
    /* CRITICAL FIX: Ensure no fill */
    stroke: rgba(247, 147, 26, 0.4);
    /* Increased visibility */
    stroke-width: 0.8;
}

/* Data Flow Animation */
.data-stream {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
    transform-style: preserve-3d;
}

.data-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-primary);
    border-radius: 50%;
    filter: blur(1px);
    box-shadow: 0 0 8px var(--color-primary);
    opacity: 0;
}

/* Inward Flow */
@keyframes data-in {
    0% {
        transform: translate(var(--start-x), var(--start-y)) scale(0.5);
        opacity: 0;
    }

    20% {
        opacity: 0.8;
    }

    80% {
        opacity: 0.8;
    }

    100% {
        transform: translate(0, 0) scale(0.2);
        opacity: 0;
    }
}

/* Outward Flow */
@keyframes data-out {
    0% {
        transform: translate(0, 0) scale(0.2);
        opacity: 0;
    }

    20% {
        opacity: 0.8;
    }

    80% {
        opacity: 0.8;
    }

    100% {
        transform: translate(var(--end-x), var(--end-y)) scale(1);
        opacity: 0;
    }
}

.data-particle.in {
    background: var(--color-primary);
    box-shadow: 0 0 8px var(--color-primary);
    animation: data-in var(--duration) linear infinite;
    animation-delay: var(--delay);
}

.data-particle.out {
    background: var(--color-white);
    box-shadow: 0 0 8px var(--color-white);
    animation: data-out var(--duration) linear infinite;
    animation-delay: var(--delay);
}

.core-ring:nth-child(2) {
    animation-duration: 40s;
    animation-direction: reverse;
    width: 120%;
    /* visual variance */
    height: 120%;
}

.core-ring:nth-child(2) .ring-path {
    stroke: rgba(255, 255, 255, 0.08);
    /* Balanced visibility between ghost and prominent */
    stroke-width: 0.6;
    stroke-dasharray: 1 12;
    stroke-linecap: round;
}

.core-ring:nth-child(3) {
    animation-duration: 18s;
    width: 80%;
    height: 80%;
}

.core-ring:nth-child(3) .ring-path {
    stroke: rgba(247, 147, 26, 0.6);
    /* Increased visibility */
    stroke-width: 1.5;
    stroke-dasharray: 0.1 22;
    stroke-linecap: round;
}

.core-ring:nth-child(4) {
    animation-duration: 60s;
    width: 140%;
    height: 140%;
    /* Hidden per user request */
    display: none;
}

.core-ring:nth-child(4) .ring-path {
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 0.5;
}

/* Capability Cards Refinement */
.capability-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-left: 3px solid var(--color-primary) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 2.5rem;
    border-radius: 8px;
    transition: var(--transition-fast);
}

.capability-card:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Section Specific Spacing */
#capabilities .flex-col li {
    font-size: 1.1rem;
    color: var(--color-text-muted);
}

/* Animations */
[data-reveal] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Visual Panes & Background Effects */
.visual-pane {
    transition: var(--transition-slow);
    position: relative;
    box-shadow: var(--shadow-premium);
}

.visual-pane:hover {
    transform: translateY(-5px) scale(1.02);
}

.visual-pane img:hover {
    filter: none !important;
}

/* Section Specific Spacing */
.shift-section {
    position: relative;
}

.gap-xl {
    gap: 6rem;
}

/* Stagger Animation Trigger */
[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Vision Section Enhancement */
.vision-section {
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.vision-bg {
    transition: transform 10s linear;
}

.vision-section:hover .vision-bg {
    transform: scale(1.1);
}

/* Capabilities Glass Cards */
.glass-pane {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    transition: var(--transition-base);
}

.glass-pane:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-primary-semi);
    transform: translateY(-8px);
}

/* Base Styles Refinement */
h1,
h2 {
    letter-spacing: -0.04em;
}

section {
    position: relative;
    overflow: hidden;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-slow);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--color-bg-anthracite);
    width: 90%;
    max-width: 500px;
    padding: 3rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    transform: translateY(20px);
    transition: var(--transition-slow);
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: var(--color-text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition-fast);
}

.modal-close:hover {
    color: var(--color-white);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
    margin-bottom: 0.5rem;
}

.form-control {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 0.8rem 1rem;
    color: var(--color-white);
    font-family: var(--font-main);
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-control:focus {
    outline: none;
    border-color: var(--color-primary);
    background: rgba(255, 255, 255, 0.05);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

.form-success {
    text-align: center;
    display: none;
}

.form-success.active {
    display: block;
}

.form-success h3 {
    color: var(--color-primary);
    margin-bottom: 1rem;
}

/* Architecture Diagram */
.arch-diagram-container {
    margin-bottom: 4rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(247, 147, 26, 0.1);
}

.arch-diagram {
    width: 100%;
    display: block;
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
}

/* Paradigm Shift Visual */
.paradigm-visual {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
}

.paradigm-visual img {
    filter: sepia(1) hue-rotate(320deg) saturate(1.5);
    transition: all var(--transition-slow);
    border-radius: 24px;
    /* Ensure radius is kept on image if container has it */
}

.paradigm-visual:hover {
    border: none !important;
    transform: none !important;
    /* Disable container shift */
}

.paradigm-visual:hover img {
    filter: none;
    transform: scale(1.02);
}

/* Hero Section Redesign */
.hero {
    padding-top: 140px;
    padding-bottom: 140px;
    text-align: left;
    display: flex;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
}

.hero .container {
    max-width: 1300px;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    margin-bottom: var(--space-sm);
    max-width: none;
    margin-left: 0;
    margin-right: 0;
    line-height: 1.1;
}

.hero .text-muted {
    margin-left: 0;
    margin-right: 0;
    max-width: 540px;
}

.hero-visual {
    position: relative;
    perspective: 1000px;
}

.hero-image-container {
    margin-top: 0;
    position: relative;
    max-width: none;
    width: 100%;
    animation: float 6s ease-in-out infinite;
}

.hero-image {
    width: 100%;
    border-radius: 12px;
    box-shadow:
        0 30px 60px -12px rgba(0, 0, 0, 0.7),
        0 18px 36px -18px rgba(0, 0, 0, 0.5),
        0 0 80px rgba(247, 147, 26, 0.15);
    /* Stronger thematic glow */
    border: 1px solid rgba(255, 255, 255, 0.08);
}

@keyframes float {
    0% {
        transform: translateY(0px) rotateX(0deg);
    }

    50% {
        transform: translateY(-20px) rotateX(2deg);
    }

    100% {
        transform: translateY(0px) rotateX(0deg);
    }
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero {
        text-align: center;
        padding-top: 100px;
    }

    .hero .text-muted {
        margin: 0 auto 3rem auto;
    }

    .hero h1 {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 80px 0;
    }

    header nav ul {
        display: none;
    }

    .grid {
        grid-template-columns: 1fr !important;
    }

    .modal-content {
        padding: 2rem;
    }
}

/* Manifesto Section Styles */
.manifesto-section {
    position: relative;
    overflow: hidden;
}

.manifesto-content h2 {
    color: var(--color-white);
    letter-spacing: -0.01em;
    text-shadow: 0 0 30px rgba(247, 147, 26, 0.1);
}

.manifesto-content p {
    color: var(--color-text-muted);
    line-height: 1.8;
}

.manifesto-section::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 80%;
    background: radial-gradient(circle, rgba(247, 147, 26, 0.03) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}