/* --- CONFIGURATION --- */
:root {
    --bg-dark: #050508;
    /* darker black */
    --bg-card: #0f1015;
    --accent: #a645b5;
    /* Pagisto Purple */
    --neon-cyan: #00f7ff;
    /* Complementary Cyberpunk color */
    --text-main: #e0e0e0;
    --text-muted: #8892b0;
    --font-cyber: 'Orbitron', sans-serif;
    --font-mono: 'Roboto Mono', monospace;
}

/* --- RESET & BASE --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-mono);
    /* Default to mono for terminal feel */
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Skip link for accessibility */
.skip-link:focus {
    position: fixed !important;
    left: 10px !important;
    top: 10px !important;
    background: var(--accent);
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 3px;
    z-index: 9999;
    font-weight: bold;
    box-shadow: 0 0 10px var(--accent);
}

/* CRT Scanline Overlay */
body::after {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            rgba(0, 0, 0, 0.15),
            rgba(0, 0, 0, 0.15) 1px,
            transparent 1px,
            transparent 2px);
    pointer-events: none;
    z-index: 999;
}

/* Glowing Grid Background */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(166, 69, 181, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(166, 69, 181, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    background-position: center center;
    transform: perspective(500px) rotateX(60deg) scale(2);
    opacity: 0.3;
    z-index: -1;
    pointer-events: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s ease;
    -webkit-tap-highlight-color: rgba(166, 69, 181, 0.3);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

/* --- TYPOGRAPHY & NEON --- */
h1,
h2,
h3,
h4 {
    font-family: var(--font-cyber);
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    /* Cyberpunk Text Glow */
    text-shadow: 0 0 10px rgba(166, 69, 181, 0.7), 0 0 20px rgba(166, 69, 181, 0.4);
}

h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
}

.mono-tag {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 8px var(--neon-cyan);
    margin-bottom: 1rem;
    display: inline-block;
}

.mono-tag::before {
    content: ">_ ";
    color: #555;
}

.mono-tag::after {
    content: "_";
    color: var(--neon-cyan);
    animation: cursor-blink 1.2s infinite;
    margin-left: 2px;
}

@keyframes cursor-blink {

    0%,
    49% {
        opacity: 1;
    }

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

.accent-text {
    color: var(--accent);
    text-shadow: 0 0 10px var(--accent);
}

/* --- UI ELEMENTS --- */
/* Cyberpunk Angled Buttons */
.btn {
    display: inline-block;
    padding: 14px 28px;
    font-family: var(--font-cyber);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    /* Angled corners */
    clip-path: polygon(10% 0, 100% 0, 100% 70%, 90% 100%, 0 100%, 0 30%);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.btn-primary {
    background: var(--accent);
    color: white;
    border: none;
    box-shadow: 0 0 20px rgba(166, 69, 181, 0.5);
}

.btn-primary:hover,
.btn-primary:active {
    background: var(--neon-cyan);
    box-shadow: 0 0 30px var(--neon-cyan), 0 0 10px white;
    color: var(--bg-dark);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-ghost {
    background: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
    box-shadow: inset 0 0 10px rgba(166, 69, 181, 0.2);
}

.btn-ghost:hover,
.btn-ghost:active {
    background: var(--accent);
    color: white;
    box-shadow: 0 0 20px var(--accent);
}

.btn-ghost:active {
    transform: scale(0.98);
}

/* --- HEADER --- */
header {
    padding: 25px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid rgba(166, 69, 181, 0.2);
    background: rgba(5, 5, 8, 0.8);
    backdrop-filter: blur(5px);
}

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

.logo {
    font-family: var(--font-cyber);
    font-size: 1.8rem;
    color: white;
    display: flex;
    align-items: center;
    gap: 10px;
    text-shadow: 0 0 10px var(--accent);
}

.logo img {
    height: 32px;
    width: auto;
}

/* Glitching Dot Animation */
@keyframes glitch-flicker {
    0% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.8;
        transform: scale(1.1) skewX(5deg);
    }

    52% {
        opacity: 0.2;
        transform: scale(0.9);
    }

    54% {
        opacity: 1;
        transform: scale(1);
    }

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

.logo-dot {
    height: 12px;
    width: 12px;
    background-color: var(--neon-cyan);
    box-shadow: 0 0 15px var(--neon-cyan), 0 0 5px white;
    animation: glitch-flicker 3s infinite alternate-reverse;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-family: var(--font-cyber);
    text-transform: uppercase;
}

.nav-links a:hover {
    color: var(--neon-cyan);
    text-shadow: 0 0 10px var(--neon-cyan);
}

/* --- HERO SECTION --- */
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    padding-top: 140px;
    gap: 60px;
}

.hero-content {
    max-width: 700px;
    z-index: 2;
    flex: 1;
}

.globe-container {
    position: relative;
    width: 500px;
    height: 500px;
    flex-shrink: 0;
}

#dataGlobe {
    width: 100%;
    height: 100%;
}

/* Data Web Background */
#dataWeb {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 60px;
    border-top: 2px solid rgba(166, 69, 181, 0.3);
    padding-top: 30px;
    position: relative;
}

/* Decorative glow line */
.hero-stats::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--neon-cyan);
    box-shadow: 0 0 10px var(--neon-cyan);
}

.stat .stat-number {
    font-size: 2rem;
    color: var(--neon-cyan);
    margin-bottom: 5px;
    font-family: var(--font-cyber);
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
}

.stat p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* --- CONTENT SECTIONS --- */
.section-padding {
    padding: 100px 0;
}

.content-section {
    max-width: 900px;
    margin: 0 auto;
    padding-top: 140px;
}

.content-section p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: var(--text-main);
}

.content-section ul {
    list-style: disc;
    margin-left: 2rem;
    margin-bottom: 1.5rem;
}

.content-section ul li {
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.content-section strong {
    color: var(--neon-cyan);
}

/* --- SERVICES (Angled Cards) --- */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.card {
    background-color: rgba(15, 16, 21, 0.8);
    border: 1px solid rgba(166, 69, 181, 0.3);
    padding: 40px;
    transition: 0.3s;
    position: relative;
    /* Angled Card corners */
    clip-path: polygon(0 0, 100% 0, 100% 85%, 85% 100%, 0 100%);
}

.card:hover {
    border-color: var(--neon-cyan);
    box-shadow: inset 0 0 20px rgba(0, 247, 255, 0.2);
}

.card-icon {
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 20px;
    text-shadow: 0 0 15px var(--accent);
}

.card:hover .card-icon {
    color: var(--neon-cyan);
    text-shadow: 0 0 15px var(--neon-cyan);
}

.card h3 {
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* --- SPLIT SECTION --- */
.split-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.cyber-terminal {
    background: #000;
    border: 2px solid var(--accent);
    padding: 30px;
    position: relative;
    box-shadow: 0 0 30px rgba(166, 69, 181, 0.2);
}

.cyber-terminal::before {
    content: "SYSTEM MONITOR // HOST: DE-FRA-01";
    position: absolute;
    top: -15px;
    left: 20px;
    background: var(--bg-dark);
    padding: 0 10px;
    color: var(--accent);
    font-size: 0.8rem;
}

.chart-bar-group {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    height: 150px;
    justify-content: center;
    border-bottom: 2px solid #333;
}

.bar {
    width: 25px;
    background: rgba(166, 69, 181, 0.3);
    border: 1px solid var(--accent);
    position: relative;
}

.bar.active {
    background: var(--neon-cyan);
    border-color: white;
    box-shadow: 0 0 25px var(--neon-cyan);
}

.bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
}

.bar-animated {
    height: 0%;
    transition: height 0.8s ease-out;
}

#cursor {
    animation: blink 1s infinite;
}

@keyframes blink {

    0%,
    50% {
        opacity: 1;
    }

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

.check-list li {
    margin-bottom: 15px;
    color: var(--text-main);
}

.check-marker {
    color: var(--neon-cyan);
    margin-right: 10px;
    text-shadow: 0 0 10px var(--neon-cyan);
}

/* --- CONTACT --- */
.contact-section {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.footer-simple {
    margin-top: 100px;
    padding: 50px 0;
    background: #020203;
    border-top: 2px solid var(--accent);
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    position: relative;
}

/* Decorative glowing line on footer */
.footer-simple::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 2px;
    background: var(--neon-cyan);
    box-shadow: 0 0 20px var(--neon-cyan);
}

.footer-links {
    margin-bottom: 30px;
}

.footer-links a {
    margin: 0 20px;
    color: var(--text-main);
    font-family: var(--font-cyber);
    text-transform: uppercase;
    font-size: 0.8rem;
}

.footer-links a:hover {
    color: var(--accent);
    text-shadow: 0 0 10px var(--accent);
}

/* --- MOBILE --- */
@media (max-width: 768px) {

    /* Typography */
    h1 {
        font-size: 2.8rem;
        line-height: 1.2;
        word-break: break-word;
        hyphens: auto;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    .mono-tag {
        font-size: 0.9rem;
    }

    /* Container padding for mobile */
    .container {
        max-width: 100%;
        padding: 0 24px !important;
    }

    body {
        padding: 0 !important;
        margin: 0 !important;
    }

    /* Hero section */
    .hero {
        padding-top: 160px;
        margin-top: 120px;
        min-height: auto;
        align-items: flex-start;
        flex-direction: column;
        gap: 40px;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-content p {
        font-size: 1.1rem !important;
        max-width: 100% !important;
        line-height: 1.8;
    }

    .hero-stats {
        flex-direction: column;
        gap: 25px;
        width: 100%;
        padding-top: 20px;
    }

    .stat .stat-number {
        font-size: 1.5rem;
    }

    .globe-container {
        display: none;
    }

    /* Content sections */
    .content-section {
        padding-top: 160px;
        margin-top: 120px;
    }

    /* Buttons - larger touch targets */
    .btn {
        padding: 16px 32px;
        font-size: 0.85rem;
        width: 100%;
        text-align: center;
        display: block;
    }

    .btn-ghost {
        margin-left: 0 !important;
        margin-top: 15px;
    }

    /* Navigation */
    .nav-links {
        display: none;
    }

    .logo {
        font-size: 1.4rem;
    }

    .logo img {
        height: 24px;
    }

    /* Services section spacing */
    #services {
        padding-top: 80px !important;
    }

    /* Services Grid */
    .grid-3 {
        grid-template-columns: 1fr;
        gap: 20px;
        width: 100%;
    }

    .card {
        padding: 30px 20px;
        box-sizing: border-box;
    }

    .card-icon {
        font-size: 2rem;
    }

    .card p {
        font-size: 1rem;
        line-height: 1.7;
    }

    /* Approach section spacing */
    #approach {
        padding-top: 80px !important;
    }

    /* Split sections */
    .split-section {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    /* Terminal */
    .cyber-terminal {
        padding: 20px;
        box-sizing: border-box;
    }

    .cyber-terminal::before {
        font-size: 0.7rem;
        top: -12px;
        left: 15px;
    }

    #terminalOutput {
        font-size: 0.8rem !important;
        min-height: 80px !important;
    }

    .chart-bar-group {
        height: 100px;
    }

    .bar {
        width: 20px;
    }

    /* Contact section */
    #contact {
        padding-top: 80px !important;
    }

    .contact-section {
        padding: 0;
    }

    .contact-section p {
        font-size: 1.1rem;
        line-height: 1.7;
    }

    /* Footer */
    .footer-links {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .footer-links a {
        margin: 0;
        font-size: 0.75rem;
    }

    .footer-simple p {
        font-size: 0.75rem;
        line-height: 1.6;
    }

    /* Sections padding */
    .section-padding {
        padding: 60px 0;
    }

    /* Remove scanlines on mobile for better performance */
    body::after {
        display: none;
    }

    /* Reduce grid background opacity on mobile */
    body::before {
        opacity: 0.15;
    }
}

/* Small phones optimization */
@media (max-width: 480px) {
    h1 {
        font-size: 2.4rem;
        word-break: break-word;
    }

    h2 {
        font-size: 1.8rem;
    }

    .container {
        max-width: 100%;
        padding: 0 20px;
    }

    .hero {
        padding-top: 140px;
        margin-top: 110px;
    }

    .content-section {
        padding-top: 140px;
        margin-top: 110px;
    }

    .stat .stat-number {
        font-size: 1.5rem;
    }

    .btn {
        padding: 16px 32px;
        font-size: 0.9rem;
    }

    .card {
        padding: 30px 24px;
    }

    .section-padding {
        padding: 50px 0;
    }

    .hero-content p {
        font-size: 1rem !important;
    }

    .card p {
        font-size: 0.95rem;
    }

    .logo img {
        height: 20px;
    }
}
