/* =====================================================
   Elvis Mao Style - Martin Šimek Landing Page
   ===================================================== */

/* Reset & Base */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Space Mono', 'Courier New', monospace;
    background-color: #000000;
    color: #ffffff;
    overflow-x: hidden;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #6366F1;
}

/* =====================================================
   Canvas & Background
   ===================================================== */
#ascii-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    pointer-events: none;
}

.glow-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    background: radial-gradient(circle at 50% 50%, rgba(10, 20, 40, 0.3) 0%, rgba(0, 0, 0, 1) 70%);
    pointer-events: none;
}

/* =====================================================
   Navigation
   ===================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
}

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

.nav-links a {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.nav-links a:hover {
    opacity: 1;
    color: #ffffff;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    width: 25px;
    height: 2px;
    background: #fff;
    transition: all 0.3s ease;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    padding: 30px;
    gap: 20px;
    z-index: 999;
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu a {
    font-size: 1.25rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* =====================================================
   Hero Section
   ===================================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 120px 20px;
    z-index: 10;
}

.logo-background {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: clamp(12rem, 25vw, 20rem);
    font-weight: 900;
    color: rgba(255, 255, 255, 0.08);
    z-index: 2;
    pointer-events: none;
    user-select: none;
    letter-spacing: -0.05em;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 900px;
}

.hero-tagline {
    font-size: clamp(0.75rem, 1.5vw, 1rem);
    letter-spacing: 4px;
    color: #888;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.hero-title {
    font-size: clamp(3rem, 10vw, 7rem);
    font-weight: 700;
    line-height: 1;
    margin-bottom: 30px;
    letter-spacing: -0.02em;
}

.hero-title .highlight {
    background: linear-gradient(135deg, #6366F1, #8B5CF6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: clamp(0.9rem, 2vw, 1.25rem);
    line-height: 1.8;
    margin-bottom: 50px;
    color: #ccc;
}

.text-gray {
    color: #888;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 15px 40px;
    font-family: 'Space Mono', monospace;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: 2px solid #fff;
    background: transparent;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #fff;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
}

.btn:hover {
    color: #000;
}

.btn:hover::before {
    left: 0;
}

.btn-primary {
    border-color: #6366F1;
}

.btn-primary::before {
    background: #6366F1;
}

.btn-primary:hover {
    color: #fff;
}

.btn-secondary {
    opacity: 0.8;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.5;
    animation: bounce 2s infinite;
}

.scroll-indicator span {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, #fff 0%, transparent 100%);
}

@keyframes bounce {

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

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

/* =====================================================
   Stats Section
   ===================================================== */
.stats {
    position: relative;
    padding: 100px 20px;
    z-index: 10;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.stat-item {
    text-align: center;
    padding: 40px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: border-color 0.3s ease;
}

.stat-item:hover {
    border-color: #6366F1;
}

.stat-number {
    display: block;
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #fff, #888);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.75rem;
    letter-spacing: 2px;
    color: #888;
    text-transform: uppercase;
}

/* =====================================================
   About Section
   ===================================================== */
.about {
    position: relative;
    padding: 150px 20px;
    z-index: 10;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.terminal-block {
    margin-bottom: 40px;
    padding: 30px;
    border-left: 2px solid #6366F1;
    background: rgba(99, 102, 241, 0.05);
}

.terminal-prompt {
    display: block;
    font-size: 0.875rem;
    color: #6366F1;
    margin-bottom: 10px;
    font-weight: 700;
}

.terminal-text {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: #ccc;
    line-height: 1.8;
}

.about-cta {
    margin-top: 60px;
    text-align: center;
}

/* =====================================================
   Services Section
   ===================================================== */
.services {
    position: relative;
    padding: 150px 20px;
    z-index: 10;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    text-align: center;
    margin-bottom: 80px;
    letter-spacing: 4px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    padding: 40px 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover {
    border-color: #6366F1;
    transform: translateY(-10px);
    background: rgba(99, 102, 241, 0.05);
}

.service-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 20px;
}

.service-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.service-desc {
    font-size: 0.875rem;
    color: #888;
    line-height: 1.6;
}

/* =====================================================
   Footer
   ===================================================== */
.footer {
    position: relative;
    padding: 80px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 10;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 30px;
    letter-spacing: 4px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 30px;
}

.footer-links a {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
}

.footer-copyright {
    font-size: 0.75rem;
    color: #666;
    letter-spacing: 1px;
}

/* =====================================================
   Scroll Animations
   ===================================================== */
.fade-in {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delay for grid items */
.stats-grid .fade-in:nth-child(1) {
    transition-delay: 0s;
}

.stats-grid .fade-in:nth-child(2) {
    transition-delay: 0.1s;
}

.stats-grid .fade-in:nth-child(3) {
    transition-delay: 0.2s;
}

.stats-grid .fade-in:nth-child(4) {
    transition-delay: 0.3s;
}

.services-grid .fade-in:nth-child(1) {
    transition-delay: 0s;
}

.services-grid .fade-in:nth-child(2) {
    transition-delay: 0.1s;
}

.services-grid .fade-in:nth-child(3) {
    transition-delay: 0.2s;
}

.services-grid .fade-in:nth-child(4) {
    transition-delay: 0.3s;
}

.about-content .fade-in:nth-child(1) {
    transition-delay: 0s;
}

.about-content .fade-in:nth-child(2) {
    transition-delay: 0.15s;
}

.about-content .fade-in:nth-child(3) {
    transition-delay: 0.3s;
}

.about-content .fade-in:nth-child(4) {
    transition-delay: 0.45s;
}

/* =====================================================
   Responsive Design
   ===================================================== */
@media (max-width: 1024px) {

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

@media (max-width: 768px) {
    .navbar {
        padding: 15px 20px;
    }

    .nav-links {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero {
        padding: 100px 20px;
    }

    .logo-background {
        font-size: clamp(8rem, 30vw, 12rem);
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

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

    .footer-links {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-item {
        padding: 30px 20px;
    }

    .terminal-block {
        padding: 20px;
    }
}

/* =====================================================
   Right Side Scroll Animation
   ===================================================== */
#right-scroll-animation {
    position: fixed;
    top: 0;
    right: 0;
    width: 40vw;
    height: 100vh;
    z-index: 5;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

#right-scroll-animation img,
#right-scroll-animation canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
    mask-image: linear-gradient(to left, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.8) 60%, rgba(0, 0, 0, 0) 100%);
    -webkit-mask-image: linear-gradient(to left, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.8) 60%, rgba(0, 0, 0, 0) 100%);
}

/* Adjust main content to avoid overlap with right animation */
.hero-content,
.about-content,
.stats-grid,
.services-grid,
.footer-content {
    margin-right: auto;
    margin-left: 5%;
    max-width: 55%;
}

.hero {
    align-items: flex-start;
    text-align: left;
}

.hero-buttons {
    justify-content: flex-start;
}

.scroll-indicator {
    left: 25%;
}

.section-title {
    text-align: left;
    margin-left: 5%;
}

/* Responsive adjustments for right animation */
@media (max-width: 1200px) {
    #right-scroll-animation {
        width: 35vw;
    }

    .hero-content,
    .about-content,
    .stats-grid,
    .services-grid,
    .footer-content {
        max-width: 60%;
    }
}

@media (max-width: 1024px) {
    #right-scroll-animation {
        width: 30vw;
        opacity: 0.6;
    }

    .hero-content,
    .about-content,
    .stats-grid,
    .services-grid,
    .footer-content {
        max-width: 65%;
    }
}

@media (max-width: 768px) {
    #right-scroll-animation {
        display: none;
    }

    .hero-content,
    .about-content,
    .stats-grid,
    .services-grid,
    .footer-content {
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

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

    .hero-buttons {
        justify-content: center;
    }

    .scroll-indicator {
        left: 50%;
    }

    .section-title {
        text-align: center;
        margin-left: 0;
    }
}