/* ========================================
   CSS Variables for Theming
   ======================================== */
:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-glass: rgba(255, 255, 255, 0.7);
    --bg-glass-card: rgba(255, 255, 255, 0.5);
    --text-primary: #111111;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    --border-color: rgba(0, 0, 0, 0.05);
    --border-hover: rgba(0, 0, 0, 0.1);
    --shadow-color: rgba(0, 0, 0, 0.03);
    --grid-color: #e5e7eb;
    --accent: #000000;
    --accent-hover: #333333;
}

.dark {
    --bg-primary: #000000;
    --bg-secondary: #111111;
    --bg-glass: #000000;
    /* Solid black for navbar */
    --bg-glass-card: rgba(26, 26, 26, 0.6);
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --shadow-color: rgba(0, 0, 0, 0.3);
    --grid-color: #1f1f1f;
    --accent: #ffffff;
    --accent-hover: #e5e5e5;
}

/* ========================================
   Base Styles
   ======================================== */
body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Canvas Background */
#gridCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* ========================================
   Glass Effects
   ======================================== */
.glass-panel {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 30px var(--shadow-color);
    transition: background 0.3s ease, border-color 0.3s ease;
}

.glass-card {
    background: var(--bg-glass-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.glass-card:hover {
    background: var(--bg-primary);
    transform: translateY(-5px);
    border-color: var(--border-hover);
    box-shadow: 0 20px 40px var(--shadow-color);
}

/* ========================================
   Buttons
   ======================================== */
.btn-black {
    background: var(--accent);
    color: var(--bg-primary);
    transition: all 0.3s ease;
}

.btn-black:hover {
    background: var(--accent-hover);
    transform: scale(1.02);
    box-shadow: 0 10px 20px var(--shadow-color);
}

/* Outline Button - adapts to dark mode */
.btn-outline {
    background: var(--bg-primary);
    color: var(--text-primary);
    border-color: var(--border-hover);
}

.btn-outline:hover {
    background: var(--bg-secondary);
}

/* ========================================
   Animations
   ======================================== */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   Navigation
   ======================================== */
.nav-link {
    position: relative;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--text-primary);
}

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

.nav-link:hover::after {
    width: 100%;
}

/* ========================================
   Logo Hover Effects
   ======================================== */
.logo-icon {
    font-size: 1.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    filter: grayscale(100%);
    opacity: 0.5;
}

.logo-icon:hover {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.1);
}

.hover-stripe:hover {
    color: #635BFF;
}

.hover-aws:hover {
    color: #FF9900;
}

.hover-google:hover {
    color: #4285F4;
}

/* ========================================
   Dark Mode Toggle Button
   ======================================== */
.theme-toggle {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--accent);
    color: var(--bg-primary);
    border: none;
    cursor: pointer;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Custom Cursor
   ======================================== */
@media (pointer: fine) {
    body:not(.touch-device) {
        cursor: none;
    }

    body:not(.touch-device) a,
    body:not(.touch-device) button,
    body:not(.touch-device) input,
    body:not(.touch-device) textarea,
    body:not(.touch-device) select {
        cursor: none;
    }
}

.custom-cursor {
    display: none;
    /* Hiding the circle, keeping only the dot */
}

.custom-cursor.visible {
    display: none;
}

.custom-cursor.hover {
    display: none;
}

.cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.cursor-dot.visible {
    opacity: 1;
}

/* ========================================
   Typing Effect
   ======================================== */
.typed-word {
    display: inline-block;
    border-right: 3px solid var(--accent);
    animation: blink 0.7s steps(1) infinite;
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

/* ========================================
   Process Section
   ======================================== */
.process-step {
    text-align: center;
    padding: 2rem;
}

.process-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
    transition: all 0.3s ease;
}

.process-step:hover .process-icon {
    background: var(--accent);
    color: var(--bg-primary);
    transform: scale(1.1);
}

.tech-marquee {
    overflow: hidden;
    white-space: nowrap;
    padding: 2rem 0;
}

.tech-marquee-inner {
    display: inline-flex;
    gap: 3rem;
    animation: marquee 20s linear infinite;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

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

.tech-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 600;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.tech-item:hover {
    opacity: 1;
}

/* ========================================
   Case Study Modal
   ======================================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 5000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

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

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: var(--bg-primary);
    border-radius: 2rem;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    z-index: 5001;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 2.5rem;
}

.modal-overlay.active+.modal-content,
.modal-content.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: var(--accent);
    color: var(--bg-primary);
}

.modal-stat {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 1rem;
    margin-bottom: 1rem;
}

.modal-stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
}

/* ========================================
   Section Background Colors
   ======================================== */
.bg-section {
    background-color: var(--bg-secondary);
    transition: background-color 0.3s ease;
}

/* ========================================
   Dark Mode Overrides
   ======================================== */
.dark .btn-black {
    background: #ffffff;
    color: #000000;
}

.dark .btn-black:hover {
    background: #e5e5e5;
}

/* Logo Blend Modes to hide white background */
img[src*="logo.png"] {
    mix-blend-mode: multiply;
    /* White becomes transparent in light mode */
}

.dark img {
    filter: brightness(0.95);
}

/* Dark Mode Logo Handling */
.dark img[src*="logo.png"] {
    /* Extreme tuning to force off-white background to PURE black */
    /* contrast(2000%) hard-clips values to min/max */
    filter: brightness(1.5) contrast(2000%) grayscale(100%) invert(1);
    mix-blend-mode: screen;
    background: transparent;
}

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

.dark .text-gray-500 {
    color: var(--text-secondary);
}

.dark .text-gray-600 {
    color: var(--text-secondary);
}

.dark .border-gray-100,
.dark .border-gray-200 {
    border-color: var(--border-color);
}

.dark .bg-gray-50,
.dark .bg-gray-100 {
    background-color: var(--bg-secondary);
}

/* Removed: .dark .bg-white override - now handled by Tailwind dark:bg-black classes */

.dark input,
.dark textarea,
.dark select {
    background-color: var(--bg-secondary) !important;
    border-color: var(--border-color) !important;
    color: var(--text-primary) !important;
}

.dark input::placeholder,
.dark textarea::placeholder {
    color: var(--text-muted);
}

/* ========================================
   Custom Notification Modal
   ======================================== */
.notification-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

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

.notification-content {
    background: var(--bg-primary);
    border-radius: 2rem;
    padding: 3rem;
    max-width: 420px;
    width: 90%;
    text-align: center;
    transform: scale(0.9) translateY(20px);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.notification-overlay.active .notification-content {
    transform: scale(1) translateY(0);
}

.notification-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
}

.notification-icon.success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.notification-icon.error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.notification-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.notification-message {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.notification-btn {
    background: var(--accent);
    color: var(--bg-primary);
    padding: 1rem 3rem;
    border-radius: 1rem;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.notification-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}


/* Capabilities Label - Dark/Light Mode */
.capabilities-label {
    color: #000000;
}

.dark .capabilities-label {
    color: #ffffff;
}


/* FAQ Question Text - Dark/Light Mode */
.faq-question-text {
    color: #000000;
}

.dark .faq-question-text {
    color: #ffffff;
}
/* FAQ Button Background - Dark/Light Mode */
.faq-button-bg {
    background-color: #ffffff;
}

.dark .faq-button-bg {
    background-color: #000000;
}


/* Nav Link Hover - Dark Mode */
.dark .nav-link:hover {
    color: #ffffff !important;
}


/* FAQ Container Styling - Light/Dark Mode */
.faq-container {
    border: 1px solid #d1d5db;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.faq-container:hover {
    border-color: #9ca3af;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.dark .faq-container {
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.dark .faq-container:hover {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}


/* Footer Styling - Light/Dark Mode */
.footer-bg {
    background-color: #ffffff;
    border-color: #f3f4f6;
}

.dark .footer-bg {
    background-color: #000000;
    border-color: rgba(255, 255, 255, 0.1);
}

.footer-link {
    color: #9ca3af;
}

.footer-link:hover {
    color: #000000;
}

.dark .footer-link:hover {
    color: #ffffff;
}

