/* ========================================
   MIRIS.TECH - HOLOGRAPHIC DESIGN SYSTEM
   ======================================== */

:root {
    /* Color Palette */
    --color-substrate: #08080F;
    --color-grid: #1A1A2E;
    --color-light: #F0F2F8;
    --color-primary-blue: #6B8AFF;
    --color-accent-pink: #FF6B8A;
    --color-accent-purple: #C47AFF;
    --color-accent-gold: #FFD93D;
    --color-accent-green: #8AFFA0;
    --color-text-muted: #C0C8D8;

    /* Aurora Colors for rotation */
    --aurora-1: #6B8AFF;
    --aurora-2: #C47AFF;
    --aurora-3: #FF6B8A;
    --aurora-4: #FFD93D;
    --aurora-5: #8AFFA0;

    /* Typography */
    --font-display: 'Rajdhani', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --spacing-unit: 1rem;
    --spacing-xl: calc(var(--spacing-unit) * 4);
    --spacing-lg: calc(var(--spacing-unit) * 3);
    --spacing-md: calc(var(--spacing-unit) * 2);
    --spacing-sm: var(--spacing-unit);

    /* Depth and parallax */
    --layer-0-translate: 0;
    --layer-1-translate: 0;
    --layer-2-translate: 0;
    --layer-3-translate: 0;
    --layer-4-translate: 0;
    --layer-5-translate: 0;
}

/* ========================================
   GLOBAL STYLES
   ======================================== */

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-substrate);
    color: var(--color-light);
    overflow-x: hidden;
    position: relative;
    perspective: 1000px;
}

/* ========================================
   SUBSTRATE & GRID
   ======================================== */

.substrate {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--color-substrate);
    z-index: 1;
    overflow: hidden;
}

.grid-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(0deg, transparent 24%, rgba(26, 26, 46, 0.2) 25%, rgba(26, 26, 46, 0.2) 26%, transparent 27%, transparent 74%, rgba(26, 26, 46, 0.2) 75%, rgba(26, 26, 46, 0.2) 76%, transparent 77%, transparent),
        linear-gradient(90deg, transparent 24%, rgba(26, 26, 46, 0.2) 25%, rgba(26, 26, 46, 0.2) 26%, transparent 27%, transparent 74%, rgba(26, 26, 46, 0.2) 75%, rgba(26, 26, 46, 0.2) 76%, transparent 77%, transparent);
    background-size: 60px 60px;
    opacity: 0;
    animation: grid-fade-in 1s ease-out 0.3s forwards;
}

@keyframes grid-fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ========================================
   AMBIENT GLOW LAYER
   ======================================== */

.ambient-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
    background: radial-gradient(ellipse at 50% 50%, rgba(107, 138, 255, 0.08) 0%, transparent 70%);
    opacity: 0;
    animation: glow-fade-in 1.5s ease-out 0.5s forwards;
}

@keyframes glow-fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ========================================
   PARALLAX CONTAINER & LAYERS
   ======================================== */

.parallax-container {
    position: relative;
    z-index: 3;
    min-height: 300vh;
}

.layer {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl);
    transform: translateY(var(--translate-y, 0));
    will-change: transform;
}

.layer-0 {
    transform: translateY(calc(var(--layer-0-translate) * 0.1px));
}

.layer-1 {
    transform: translateY(calc(var(--layer-1-translate) * 0.25px));
}

.layer-2 {
    transform: translateY(calc(var(--layer-2-translate) * 0.4px));
}

.layer-3 {
    transform: translateY(calc(var(--layer-3-translate) * 0.55px));
}

.layer-4 {
    transform: translateY(calc(var(--layer-4-translate) * 0.7px));
}

.layer-5 {
    transform: translateY(calc(var(--layer-5-translate) * 0.85px));
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero-section {
    position: relative;
    background: linear-gradient(135deg, rgba(107, 138, 255, 0.05) 0%, rgba(196, 122, 255, 0.05) 100%);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(107, 138, 255, 0.2);
}

.hero-content {
    text-align: center;
    z-index: 10;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 8vw, 7rem);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: linear-gradient(90deg, var(--color-primary-blue) 0%, var(--color-accent-purple) 50%, var(--color-accent-pink) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-md);
    animation: title-glow-shift 4s ease-in-out infinite;
}

@keyframes title-glow-shift {
    0%, 100% {
        filter: drop-shadow(0 0 20px rgba(107, 138, 255, 0.3));
    }
    50% {
        filter: drop-shadow(0 0 30px rgba(196, 122, 255, 0.4));
    }
}

.hero-subtitle {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 3vw, 2rem);
    font-weight: 500;
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-lg);
    letter-spacing: 0.04em;
}

.hero-grid {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    gap: var(--spacing-sm);
    justify-content: center;
    margin-top: var(--spacing-lg);
}

.grid-cell {
    width: 100px;
    height: 100px;
    background: rgba(107, 138, 255, 0.1);
    border: 1px solid var(--color-primary-blue);
    border-radius: 4px;
    animation: grid-cell-pulse 2s ease-in-out infinite;
}

.grid-cell:nth-child(2) {
    animation-delay: 0.2s;
}

.grid-cell:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes grid-cell-pulse {
    0%, 100% {
        background: rgba(107, 138, 255, 0.1);
        box-shadow: 0 0 8px rgba(107, 138, 255, 0.2);
    }
    50% {
        background: rgba(107, 138, 255, 0.2);
        box-shadow: 0 0 16px rgba(107, 138, 255, 0.4);
    }
}

/* ========================================
   AURORA BORDER ANIMATION
   ======================================== */

.aurora-border-demo {
    position: absolute;
    top: 50%;
    right: 5%;
    width: 300px;
    height: 200px;
    border-radius: 12px;
    --border-angle: 0deg;
    border: 1px solid;
    border-image: conic-gradient(from var(--border-angle), var(--aurora-1), var(--aurora-2), var(--aurora-3), var(--aurora-4), var(--aurora-5), var(--aurora-1)) 1;
    box-shadow: 0 0 20px rgba(107, 138, 255, 0.3);
    background: rgba(26, 26, 46, 0.3);
    backdrop-filter: blur(10px);
    animation: aurora-border-rotate 4s linear infinite;
}

@keyframes aurora-border-rotate {
    from {
        --border-angle: 0deg;
    }
    to {
        --border-angle: 360deg;
    }
}

/* ========================================
   CONTENT PANELS
   ======================================== */

.content-panel {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.4) 0%, rgba(107, 138, 255, 0.05) 100%);
    backdrop-filter: blur(15px);
    border-radius: 16px;
    border: 1px solid rgba(107, 138, 255, 0.15);
    max-width: 1200px;
    margin: 0 auto;
    width: 90%;
}

.panel-inner {
    padding: var(--spacing-xl);
}

.panel-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: var(--spacing-lg);
    color: var(--color-light);
}

/* ========================================
   TECHNOLOGY CARDS
   ======================================== */

.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.tech-card {
    padding: var(--spacing-md);
    background: rgba(196, 122, 255, 0.08);
    border: 1px solid rgba(196, 122, 255, 0.25);
    border-radius: 12px;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
}

.tech-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, var(--aurora-1), transparent);
    opacity: 0;
    animation: card-shimmer 6s linear infinite;
}

.tech-card:hover {
    border-color: var(--color-accent-purple);
    box-shadow: 0 0 20px rgba(196, 122, 255, 0.3);
    transform: translateY(-4px);
}

.tech-label {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent-purple);
    margin-bottom: var(--spacing-sm);
    position: relative;
    z-index: 1;
}

.tech-card p {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

@keyframes card-shimmer {
    0% {
        transform: rotate(0deg);
        opacity: 0;
    }
    50% {
        opacity: 0.3;
    }
    100% {
        transform: rotate(360deg);
        opacity: 0;
    }
}

/* ========================================
   TIMELINE
   ======================================== */

.projects-timeline {
    position: relative;
    padding-left: var(--spacing-lg);
}

.projects-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--color-accent-purple), transparent);
}

.timeline-item {
    margin-bottom: var(--spacing-lg);
    position: relative;
    opacity: 0;
    animation: timeline-item-fade 0.8s ease-out forwards;
}

.timeline-item:nth-child(1) {
    animation-delay: 0.2s;
}

.timeline-item:nth-child(2) {
    animation-delay: 0.4s;
}

.timeline-item:nth-child(3) {
    animation-delay: 0.6s;
}

@keyframes timeline-item-fade {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.timeline-marker {
    position: absolute;
    left: -13px;
    top: 8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--color-substrate);
    border: 2px solid var(--color-accent-purple);
    box-shadow: 0 0 12px rgba(196, 122, 255, 0.5);
}

.timeline-content h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--color-light);
}

.timeline-content p {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* ========================================
   FRAMEWORK SPECIFICATIONS
   ======================================== */

.framework-specs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.spec-card {
    padding: var(--spacing-md);
    background: linear-gradient(135deg, rgba(138, 255, 160, 0.08) 0%, rgba(255, 211, 61, 0.08) 100%);
    border: 1px solid rgba(138, 255, 160, 0.2);
    border-radius: 12px;
    transition: all 0.4s ease;
}

.spec-card:hover {
    border-color: var(--color-accent-green);
    box-shadow: 0 0 20px rgba(138, 255, 160, 0.25);
}

.spec-header {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent-green);
    margin-bottom: var(--spacing-sm);
}

.spec-list {
    list-style: none;
}

.spec-list li {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.8;
    padding-left: var(--spacing-sm);
    position: relative;
}

.spec-list li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--color-accent-green);
}

/* ========================================
   FLOATING LABELS
   ======================================== */

.floating-labels {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.label-cloud {
    position: relative;
    width: 100%;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
}

.research-label {
    position: absolute;
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(255, 211, 61, 0.1);
    border: 1px solid rgba(255, 211, 61, 0.4);
    border-radius: 20px;
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-accent-gold);
    letter-spacing: 0.04em;
    opacity: 0;
    animation: label-float 4s ease-in-out infinite;
    backdrop-filter: blur(8px);
}

.label-1 {
    animation-delay: 0s;
    left: 10%;
    top: 20%;
}

.label-2 {
    animation-delay: 0.3s;
    right: 15%;
    top: 10%;
}

.label-3 {
    animation-delay: 0.6s;
    left: 20%;
    bottom: 25%;
}

.label-4 {
    animation-delay: 0.9s;
    right: 10%;
    bottom: 30%;
}

.label-5 {
    animation-delay: 1.2s;
    left: 40%;
    top: 15%;
}

.label-6 {
    animation-delay: 1.5s;
    right: 35%;
    bottom: 15%;
}

.label-7 {
    animation-delay: 1.8s;
    left: 50%;
    bottom: 10%;
    transform: translateX(-50%);
}

.label-8 {
    animation-delay: 2.1s;
    right: 30%;
    top: 35%;
}

@keyframes label-float {
    0%, 100% {
        opacity: 0.4;
        transform: translateY(0px);
    }
    50% {
        opacity: 0.9;
        transform: translateY(-20px);
    }
}

/* ========================================
   PARTICLE FIELD
   ======================================== */

.particle-field {
    position: relative;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-primary-blue);
    border-radius: 50%;
    left: var(--x);
    top: var(--y);
    opacity: 0;
    box-shadow: 0 0 8px rgba(107, 138, 255, 0.6);
    animation: particle-drift 6s ease-in-out infinite;
}

.particle:nth-child(1) {
    animation-delay: 0s;
}

.particle:nth-child(2) {
    animation-delay: 0.5s;
    background: var(--color-accent-purple);
}

.particle:nth-child(3) {
    animation-delay: 1s;
    background: var(--color-accent-pink);
}

.particle:nth-child(4) {
    animation-delay: 1.5s;
    background: var(--color-accent-green);
}

.particle:nth-child(5) {
    animation-delay: 2s;
    background: var(--color-accent-gold);
}

.particle:nth-child(6) {
    animation-delay: 2.5s;
    background: var(--color-primary-blue);
}

.particle:nth-child(7) {
    animation-delay: 3s;
    background: var(--color-accent-purple);
}

.particle:nth-child(8) {
    animation-delay: 3.5s;
    background: var(--color-accent-pink);
}

@keyframes particle-drift {
    0%, 100% {
        opacity: 0;
        transform: translateY(0) translateX(0);
    }
    50% {
        opacity: 0.8;
        transform: translateY(-100px) translateX(40px);
    }
}

/* ========================================
   FOOTER
   ======================================== */

.footer {
    position: relative;
    z-index: 10;
    background: linear-gradient(180deg, transparent 0%, rgba(8, 8, 15, 0.8) 100%);
    padding: var(--spacing-xl);
    border-top: 1px solid rgba(107, 138, 255, 0.1);
    text-align: center;
}

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

.footer-content p {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-md);
    letter-spacing: 0.03em;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: var(--spacing-lg);
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--color-primary-blue);
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    transition: all 0.3s ease;
    position: relative;
}

.footer-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-accent-purple);
    transition: width 0.3s ease;
}

.footer-links a:hover::after {
    width: 100%;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
    .hero-grid {
        grid-template-columns: repeat(2, 80px);
    }

    .grid-cell {
        width: 80px;
        height: 80px;
    }

    .aurora-border-demo {
        position: relative;
        right: auto;
        width: 100%;
        height: 150px;
        margin-top: var(--spacing-lg);
    }

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

    .framework-specs {
        grid-template-columns: 1fr;
    }

    .panel-inner {
        padding: var(--spacing-lg);
    }

    .label-cloud {
        height: 400px;
    }

    .research-label {
        position: static;
        margin: var(--spacing-sm);
        animation: none;
        opacity: 0.7;
    }
}

@media (max-width: 480px) {
    :root {
        --spacing-unit: 0.75rem;
    }

    .hero-section {
        min-height: auto;
        padding: var(--spacing-lg);
    }

    .hero-grid {
        grid-template-columns: repeat(2, 60px);
        gap: var(--spacing-sm);
    }

    .grid-cell {
        width: 60px;
        height: 60px;
    }

    .panel-title {
        font-size: 1.5rem;
    }

    .footer-links {
        gap: var(--spacing-md);
    }
}
