/* ============================================
   ARISE TECH ACADEMY - Custom Styles
   ============================================ */

/* CSS Variables */
:root {
    --maroon-primary: #8B2635;
    --maroon-dark: #6B1E2B;
    --maroon-deep: #4A1219;
    --maroon-light: #CB2D55;
    --white: #ffffff;
    --gray-100: #f5f5f5;
    --gray-200: #e5e5e5;
    --gray-800: #262626;
    --gray-900: #171717;
    --gray-950: #0a0a0a;
    
    /* Glass effect variables */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--gray-950);
}

::-webkit-scrollbar-thumb {
    background: var(--maroon-dark);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--maroon-primary);
}

/* Selection Color */
::selection {
    background: var(--maroon-primary);
    color: white;
}

/* ============================================
   GLASS MORPHISM COMPONENTS
   ============================================ */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.glass-card {
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.1) 0%,
        rgba(255, 255, 255, 0.05) 100%
    );
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.glass-card-maroon {
    background: linear-gradient(
        135deg,
        rgba(139, 38, 53, 0.2) 0%,
        rgba(139, 38, 53, 0.1) 100%
    );
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(139, 38, 53, 0.3);
    border-radius: 24px;
}

/* ============================================
   3D PERSPECTIVE & TRANSFORMS
   ============================================ */
.perspective-container {
    perspective: 1000px;
    transform-style: preserve-3d;
}

.card-3d {
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.card-3d:hover {
    transform: translateZ(20px) rotateX(5deg) rotateY(-5deg);
}

.float-3d {
    animation: float3d 6s ease-in-out infinite;
}

@keyframes float3d {
    0%, 100% {
        transform: translateY(0) translateZ(0) rotateX(0);
    }
    50% {
        transform: translateY(-15px) translateZ(20px) rotateX(2deg);
    }
}

/* ============================================
   GRADIENT BACKGROUNDS
   ============================================ */
.gradient-maroon {
    background: linear-gradient(135deg, var(--maroon-primary) 0%, var(--maroon-deep) 100%);
}

.gradient-text {
    background: linear-gradient(135deg, var(--white) 0%, var(--gray-200) 50%, var(--maroon-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gradient-text-maroon {
    background: linear-gradient(135deg, var(--maroon-light) 0%, var(--maroon-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.animated-gradient-bg {
    background: linear-gradient(-45deg, 
        var(--gray-950), 
        var(--maroon-deep), 
        var(--gray-900), 
        var(--maroon-dark)
    );
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
}

@keyframes gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ============================================
   BUTTON STYLES
   ============================================ */
.btn-primary {
    position: relative;
    padding: 16px 32px;
    background: linear-gradient(135deg, var(--maroon-primary) 0%, var(--maroon-dark) 100%);
    border: none;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 
        0 4px 15px rgba(139, 38, 53, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: left 0.5s;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 
        0 8px 25px rgba(139, 38, 53, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-secondary {
    position: relative;
    padding: 16px 32px;
    background: transparent;
    border: 2px solid var(--maroon-primary);
    border-radius: 12px;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--maroon-primary);
    transition: width 0.3s ease;
    z-index: -1;
}

.btn-secondary:hover {
    color: white;
}

.btn-secondary:hover::before {
    width: 100%;
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav-link {
    position: relative;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--maroon-primary);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: white;
}

.nav-link:hover::after {
    width: 100%;
}

/* ============================================
   CODE ANIMATION STYLES
   ============================================ */
.code-block {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-family: 'JetBrains Mono', monospace;
    overflow: hidden;
}

.code-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.code-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.code-dot.red { background: #ff5f56; }
.code-dot.yellow { background: #ffbd2e; }
.code-dot.green { background: #27ca40; }

.code-content {
    padding: 20px;
    font-size: 14px;
    line-height: 1.8;
}

.code-line {
    opacity: 0;
    transform: translateX(-20px);
}

.code-line.visible {
    opacity: 1;
    transform: translateX(0);
    transition: all 0.5s ease;
}

.code-keyword { color: #c792ea; }
.code-function { color: #82aaff; }
.code-string { color: #c3e88d; }
.code-variable { color: #f78c6c; }
.code-comment { color: #546e7a; }
.code-bracket { color: #89ddff; }

/* Typing cursor effect */
.typing-cursor::after {
    content: '|';
    animation: blink 1s step-end infinite;
    color: var(--maroon-primary);
}

@keyframes blink {
    50% { opacity: 0; }
}

/* ============================================
   LAPTOP ILLUSTRATION
   ============================================ */
.laptop-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    perspective: 1500px;
}

.laptop-screen {
    position: relative;
    background: linear-gradient(180deg, #1a1a1a 0%, #0d0d0d 100%);
    border-radius: 16px 16px 0 0;
    border: 3px solid #333;
    border-bottom: none;
    padding: 20px;
    transform-origin: bottom center;
    transform: rotateX(0deg);
    transition: transform 1s cubic-bezier(0.23, 1, 0.32, 1);
}

.laptop-screen.closed {
    transform: rotateX(-90deg);
}

.laptop-base {
    background: linear-gradient(180deg, #2a2a2a 0%, #1a1a1a 100%);
    height: 20px;
    border-radius: 0 0 16px 16px;
    position: relative;
}

.laptop-base::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: #444;
    border-radius: 0 0 4px 4px;
}

.laptop-notch {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 8px;
    background: #333;
    border-radius: 50%;
}

/* ============================================
   CHART ANIMATIONS
   ============================================ */
.chart-bar {
    background: linear-gradient(180deg, var(--maroon-primary) 0%, var(--maroon-deep) 100%);
    border-radius: 4px 4px 0 0;
    transform-origin: bottom;
    transform: scaleY(0);
    transition: transform 1s cubic-bezier(0.23, 1, 0.32, 1);
}

.chart-bar.animated {
    transform: scaleY(1);
}

.chart-line {
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    transition: stroke-dashoffset 2s ease-in-out;
}

.chart-line.animated {
    stroke-dashoffset: 0;
}

/* ============================================
   FLOATING ICONS
   ============================================ */
.floating-icon {
    position: absolute;
    opacity: 0.6;
    animation: floatIcon 6s ease-in-out infinite;
}

.floating-icon:nth-child(1) { animation-delay: 0s; }
.floating-icon:nth-child(2) { animation-delay: 1s; }
.floating-icon:nth-child(3) { animation-delay: 2s; }
.floating-icon:nth-child(4) { animation-delay: 3s; }
.floating-icon:nth-child(5) { animation-delay: 4s; }

@keyframes floatIcon {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

.orbit-icon {
    position: absolute;
    animation: orbitAnimation 20s linear infinite;
}

@keyframes orbitAnimation {
    from {
        transform: rotate(0deg) translateX(150px) rotate(0deg);
    }
    to {
        transform: rotate(360deg) translateX(150px) rotate(-360deg);
    }
}

/* ============================================
   STAT CARDS
   ============================================ */
.stat-card {
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle,
        rgba(139, 38, 53, 0.1) 0%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.5s ease;
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

/* ============================================
   TESTIMONIAL CARDS
   ============================================ */
.testimonial-card {
    position: relative;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.testimonial-card:hover {
    transform: translateY(-10px);
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -20px;
    left: 20px;
    font-size: 120px;
    font-family: Georgia, serif;
    color: var(--maroon-primary);
    opacity: 0.2;
    line-height: 1;
}

/* ============================================
   SCROLL INDICATOR
   ============================================ */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-mouse {
    width: 30px;
    height: 50px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 20px;
    position: relative;
}

.scroll-wheel {
    width: 4px;
    height: 10px;
    background: var(--maroon-primary);
    border-radius: 2px;
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollWheel 2s ease-in-out infinite;
}

@keyframes scrollWheel {
    0%, 100% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
    50% {
        opacity: 0.5;
        transform: translateX(-50%) translateY(15px);
    }
}

/* ============================================
   CURSOR EFFECTS
   ============================================ */
.custom-cursor {
    width: 20px;
    height: 20px;
    border: 2px solid var(--maroon-primary);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: all 0.1s ease;
    mix-blend-mode: difference;
}

.custom-cursor-dot {
    width: 6px;
    height: 6px;
    background: var(--maroon-primary);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: all 0.05s ease;
}

/* ============================================
   SECTION DIVIDERS
   ============================================ */
.section-divider {
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(139, 38, 53, 0.5),
        transparent
    );
    margin: 0 auto;
    max-width: 600px;
}

/* ============================================
   RESPONSIVE UTILITIES
   ============================================ */
@media (max-width: 768px) {
    .stat-number {
        font-size: 2rem;
    }
    
    .laptop-container {
        transform: scale(0.8);
    }
    
    .floating-icon {
        display: none;
    }
}

/* ============================================
   LOADING ANIMATION
   ============================================ */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gray-950);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    text-align: center;
}

.loader-logo {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.loader-bar {
    width: 200px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.loader-progress {
    height: 100%;
    background: var(--maroon-primary);
    border-radius: 2px;
    animation: loading 1.5s ease-in-out;
}

@keyframes loading {
    0% { width: 0; }
    100% { width: 100%; }
}

/* ============================================
   GLOW EFFECTS
   ============================================ */
.glow {
    box-shadow: 0 0 40px rgba(139, 38, 53, 0.3);
}

.glow-text {
    text-shadow: 0 0 40px rgba(139, 38, 53, 0.5);
}

/* ============================================
   NOISE TEXTURE OVERLAY
   ============================================ */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9998;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%' height='100%' filter='url(%23noise)'/%3E%3C/svg%3E");
}