/* reTHINKit - Distinctive Frontend Design */
/* Aesthetic: Tech-luxe meets neural networks - sophisticated, bold, memorable */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Space+Mono:wght@400;700&display=swap');

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

/* Design Tokens */
:root {
    /* Colors - Bold orange against deep space */
    --orange: #FF9500;
    --orange-light: #FFB347;
    --orange-glow: rgba(255, 149, 0, 0.4);
    --orange-subtle: rgba(255, 149, 0, 0.1);
    
    --bg-deep: #050810;
    --bg-surface: #0a0f1a;
    --bg-card: rgba(15, 22, 36, 0.7);
    --bg-elevated: rgba(20, 30, 50, 0.8);
    
    --text-primary: #ffffff;
    --text-secondary: #8b95a8;
    --text-muted: #4a5568;
    
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(255, 149, 0, 0.3);
    
    /* Typography */
    --font-display: 'Outfit', sans-serif;
    --font-mono: 'Space Mono', monospace;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 2rem;
    --space-xl: 4rem;
    --space-2xl: 8rem;
    
    /* Animation */
    --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-display);
    background: var(--bg-deep);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Animated Background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: 
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(255, 149, 0, 0.15), transparent),
        radial-gradient(ellipse 60% 40% at 100% 100%, rgba(139, 69, 19, 0.2), transparent),
        radial-gradient(ellipse 40% 30% at 0% 80%, rgba(255, 100, 0, 0.1), transparent);
    pointer-events: none;
    z-index: -1;
}

/* Grain Texture Overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    opacity: 0.03;
    pointer-events: none;
    z-index: 1000;
}

/* Navigation - Floating glass effect */
.navbar {
    position: fixed;
    top: var(--space-md);
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - var(--space-lg));
    max-width: 1400px;
    background: rgba(10, 15, 26, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border-subtle);
    border-radius: 1rem;
    padding: 0.75rem 1.5rem;
    z-index: 100;
    animation: slideDown 0.8s var(--ease-out-expo);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-lg);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
}

.logo-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px var(--orange-glow));
    transition: transform 0.4s var(--ease-bounce);
}

.nav-logo:hover .logo-icon {
    transform: rotate(10deg) scale(1.1);
}

.logo-text {
    color: var(--text-primary);
}

.logo-highlight {
    color: var(--orange);
    font-weight: 800;
}

.nav-links {
    display: flex;
    gap: var(--space-xs);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    padding: 0.5rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 0.5rem;
    transition: all 0.3s var(--ease-out-expo);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--orange);
    transition: all 0.3s var(--ease-out-expo);
    transform: translateX(-50%);
    border-radius: 2px;
}

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

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

.nav-link.active {
    color: var(--orange);
    background: var(--orange-subtle);
}

.nav-icon {
    font-size: 1rem;
    opacity: 0.8;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.icon-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: 0.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.icon-btn:hover {
    border-color: var(--orange);
    color: var(--orange);
    background: var(--orange-subtle);
}

/* Hero Section - Dramatic entrance */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-2xl) var(--space-lg);
    position: relative;
}

/* Compact Hero for homepage */
.hero-compact {
    min-height: auto;
    padding: 120px var(--space-lg) var(--space-lg);
}

.hero-content {
    max-width: 900px;
}

.hero-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
    animation: fadeInUp 1s var(--ease-out-expo) 0.2s both;
}

.hero-icon {
    width: 100px;
    height: 100px;
    object-fit: contain;
    filter: drop-shadow(0 0 40px var(--orange-glow));
    animation: pulse 3s ease-in-out infinite;
}

/* Compact hero icon */
.hero-compact .hero-icon {
    width: 70px;
    height: 70px;
}

.product-hero-icon {
    font-size: 5rem;
    filter: drop-shadow(0 0 40px var(--orange-glow));
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { filter: drop-shadow(0 0 40px var(--orange-glow)); }
    50% { filter: drop-shadow(0 0 60px var(--orange-glow)) brightness(1.1); }
}

.hero-title {
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1;
}

/* Compact hero title */
.hero-compact .hero-title {
    font-size: clamp(2.5rem, 6vw, 3.5rem);
}

.title-highlight {
    color: var(--orange);
    position: relative;
}

.hero-cta {
    margin-top: var(--space-xl);
}

.product-hero {
    min-height: auto;
    padding: 120px var(--space-lg) var(--space-2xl);
}

.hero-tagline-large {
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: var(--text-primary);
    margin-bottom: var(--space-md);
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: var(--space-xl);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-md);
    max-width: 700px;
    margin: 0 auto var(--space-xl);
}

.feature-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-md);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 0.75rem;
    transition: all 0.3s ease;
}

.feature-item:hover {
    border-color: var(--orange-primary);
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 1.5rem;
}

.feature-text {
    font-size: 0.95rem;
    color: var(--text-primary);
}

.hero-subtext {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: var(--space-lg);
}

.hero-tagline {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    color: var(--text-secondary);
    margin-top: var(--space-lg);
    font-weight: 300;
    line-height: 1.7;
    animation: fadeInUp 1s var(--ease-out-expo) 0.4s both;
}

/* Compact hero tagline */
.hero-compact .hero-tagline {
    font-size: clamp(0.95rem, 2vw, 1.2rem);
    margin-top: var(--space-md);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Product Hero (for individual pages) */
.product-hero {
    min-height: calc(100vh - 100px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-2xl) var(--space-lg);
}

.product-hero-content {
    max-width: 700px;
    animation: fadeInUp 0.8s var(--ease-out-expo);
}

.product-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: var(--space-lg);
}

.product-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: var(--space-lg);
}

.product-pricing {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--orange);
    margin-bottom: var(--space-lg);
    opacity: 0.8;
}

/* Products Section */
.products {
    padding: var(--space-xl) var(--space-lg) var(--space-2xl);
    max-width: 1400px;
    margin: 0 auto;
}

/* Compact Products for homepage */
.products-compact {
    padding: var(--space-lg) var(--space-lg) var(--space-lg);
}

.products-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: var(--space-lg);
}

/* 3-column layout for homepage */
.products-compact .products-container {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
}

/* Equal height cards on homepage */
.products-compact .product-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.products-compact .card-description {
    flex-grow: 1;
}

.product-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.product-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-subtle);
    border-radius: 1.25rem;
    padding: var(--space-lg);
    position: relative;
    overflow: hidden;
    transition: all 0.5s var(--ease-out-expo);
    animation: fadeInUp 0.8s var(--ease-out-expo) both;
}

/* Compact product cards for homepage */
.products-compact .product-card {
    padding: var(--space-md);
}

.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }

.product-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, var(--orange-subtle), transparent 70%);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.product-card:hover {
    transform: translateY(-8px);
    border-color: var(--border-glow);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        0 0 60px var(--orange-subtle);
}

.product-card:hover::before {
    opacity: 1;
}

.card-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-md);
    position: relative;
    z-index: 1;
}

.card-icon {
    font-size: 1.75rem;
    filter: grayscale(0.3);
    transition: all 0.3s ease;
}

.product-card:hover .card-icon {
    filter: grayscale(0);
    transform: scale(1.1);
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--orange);
    letter-spacing: -0.02em;
}

/* Compact card titles */
.products-compact .card-title {
    font-size: 1.25rem;
}

.card-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: var(--space-md);
    position: relative;
    z-index: 1;
}

/* Compact card descriptions */
.products-compact .card-description {
    font-size: 0.85rem;
    line-height: 1.6;
    margin-bottom: var(--space-sm);
}

.card-pricing {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
    position: relative;
    z-index: 1;
}

/* CTA Section */
.cta {
    text-align: center;
    padding: var(--space-xl) var(--space-lg) var(--space-2xl);
}

/* Compact CTA for homepage */
.cta-compact {
    padding: var(--space-lg) var(--space-lg) var(--space-xl);
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    background: linear-gradient(135deg, var(--orange) 0%, #FF6B00 100%);
    color: white;
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 600;
    padding: 1.25rem 2.5rem;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    transition: all 0.4s var(--ease-out-expo);
    box-shadow: 
        0 10px 30px rgba(255, 149, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.cta-button::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(255, 255, 255, 0.2) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cta-button:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        0 20px 40px rgba(255, 149, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.cta-button:hover::before {
    opacity: 1;
}

.cta-button:active {
    transform: translateY(-2px) scale(1);
}

/* Footer */
.footer {
    text-align: center;
    padding: var(--space-xl) var(--space-lg);
    color: var(--text-muted);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-subtle);
}

/* Compact footer for homepage */
.products-compact ~ .cta ~ .footer {
    padding: var(--space-lg) var(--space-lg);
}

/* Responsive */
@media (max-width: 1200px) {
    /* 2-column layout for tablets */
    .products-compact .products-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 1024px) {
    .nav-links {
        display: none;
    }
    
    .navbar {
        width: calc(100% - var(--space-md));
    }
    
    .products-container {
        grid-template-columns: 1fr;
    }
    
    .products-compact .products-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero {
        padding: calc(var(--space-2xl) + 60px) var(--space-md) var(--space-xl);
    }
    
    .hero-compact {
        padding: 100px var(--space-md) var(--space-md);
    }
    
    .hero-icon {
        width: 70px;
        height: 70px;
    }
    
    .product-hero {
        padding: calc(var(--space-2xl) + 60px) var(--space-md) var(--space-xl);
    }
    
    .products {
        padding: var(--space-lg) var(--space-md);
    }
    
    .products-compact {
        padding: var(--space-md) var(--space-md) var(--space-md);
    }
    
    /* Single column on mobile */
    .products-compact .products-container {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }
    
    .product-card {
        padding: var(--space-md);
    }
    
    .products-compact .product-card {
        padding: var(--space-sm);
    }
    
    .cta-button {
        padding: 1rem 2rem;
        font-size: 1rem;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-deep);
}

::-webkit-scrollbar-thumb {
    background: var(--border-subtle);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--orange);
}

/* Selection */
::selection {
    background: var(--orange);
    color: var(--bg-deep);
}
