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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    background-color: #0a0a0f;
    color: #f0f0f0;
}

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

::-webkit-scrollbar-track {
    background: #0a0a0f;
}

::-webkit-scrollbar-thumb {
    background: #22d76a;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #16a34a;
}

/* Typography */
.section-label {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    display: inline-block;
}

/* Navigation */
#navbar {
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease;
}

#navbar.scrolled {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-link {
    position: relative;
    font-size: 0.95rem;
}

.nav-link.active {
    color: #22d76a;
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
}

/* Mobile menu styling */
details summary {
    cursor: pointer;
}

details[open] summary svg {
    transform: rotate(90deg);
}

details > div {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero Section */
#hero {
    background-color: #0a0a0f;
}

/* Animated Glow Blobs */
.glow-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    animation: drift 8s ease-in-out infinite alternate;
    pointer-events: none;
}

@keyframes drift {
    from {
        transform: translate(0, 0) scale(1);
    }
    to {
        transform: translate(30px, -20px) scale(1.1);
    }
}

/* Cards */
.app-card {
    perspective: 1000px;
}

.app-card:hover {
    transform: translateY(-6px);
}

@media (hover: hover) {
    .app-card {
        position: relative;
    }

    .app-card::before {
        content: '';
        position: absolute;
        inset: 0;
        pointer-events: none;
    }
}

/* Feature Cards */
.feature-card {
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background-color: rgba(19, 19, 28, 0.8);
}

/* Counter Animation */
.counter {
    font-variant-numeric: tabular-nums;
}

/* Transitions */
a {
    transition: all 0.3s ease;
}

button {
    transition: all 0.3s ease;
}

/* AOS Customization */
[data-aos] {
    opacity: 0;
}

[data-aos].aos-animate {
    opacity: 1;
}

/* Responsive Typography with clamp */
@media (max-width: 640px) {
    .section-label {
        font-size: 0.7rem;
    }
}

/* Smooth transitions for all interactive elements */
*[href],
button,
input[type="button"],
input[type="submit"] {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Gradient text effect for hero (optional enhancement) */
.gradient-text {
    background: linear-gradient(135deg, #22d76a 0%, #ff2600 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Focus states for accessibility */
a:focus-visible,
button:focus-visible,
details summary:focus-visible {
    outline: 2px solid #22d76a;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Image optimization */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Print styles */
@media print {
    nav,
    footer {
        display: none;
    }
}

/* Dark mode (already in place, but reinforcing) */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #0a0a0f;
        color: #f0f0f0;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* Card 3D Tilt Effect (applied via JS) */
.app-card[style*="perspective"] {
    transform-style: preserve-3d;
    transition: transform 0.1s ease-out;
}

/* Utility classes for card tilt */
.card-tilting {
    transform-style: preserve-3d;
}

/* Additional decorative effects */
.content-wrapper {
    position: relative;
    z-index: 1;
}

/* Overlay blending */
section {
    position: relative;
}

/* Border gradients for accent */
.accent-border {
    position: relative;
}

.accent-border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(34, 215, 106, 0.5), transparent);
}

/* Link hover effects */
a[target="_blank"]::after {
    content: '';
}

/* Badge styles */
.badge {
    display: inline-block;
    padding: 0.375rem 1rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-green {
    background-color: rgba(34, 215, 106, 0.15);
    border: 1px solid rgba(34, 215, 106, 0.3);
    color: #22d76a;
}

.badge-red {
    background-color: rgba(255, 38, 0, 0.15);
    border: 1px solid rgba(255, 38, 0, 0.3);
    color: #ff2600;
}

/* Loading state */
[aria-busy="true"] {
    opacity: 0.6;
    pointer-events: none;
}

/* Disabled state */
:disabled,
[aria-disabled="true"] {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Utility spacing */
.gap-4 {
    gap: 1rem;
}

.gap-8 {
    gap: 2rem;
}

.gap-12 {
    gap: 3rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mb-6 {
    margin-bottom: 1.5rem;
}

.mb-8 {
    margin-bottom: 2rem;
}

.mb-12 {
    margin-bottom: 3rem;
}

.pt-8 {
    padding-top: 2rem;
}

.pt-20 {
    padding-top: 5rem;
}

.py-20 {
    padding-top: 5rem;
    padding-bottom: 5rem;
}

/* Responsive padding */
@media (min-width: 1024px) {
    .py-32 {
        padding-top: 8rem;
        padding-bottom: 8rem;
    }

    .lg\:py-32 {
        padding-top: 8rem;
        padding-bottom: 8rem;
    }
}

/* Grid utilities */
.grid {
    display: grid;
}

.grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 768px) {
    .grid-cols-3 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .md\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1024px) {
    .lg\:grid-cols-2 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .lg\:grid-cols-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .lg\:grid-cols-3 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }
}

/* Flex utilities */
.flex {
    display: flex;
}

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

.items-start {
    align-items: flex-start;
}

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

.justify-between {
    justify-content: space-between;
}

.flex-col {
    flex-direction: column;
}

@media (min-width: 640px) {
    .sm\:flex-row {
        flex-direction: row;
    }
}

/* Text utilities */
.text-center {
    text-align: center;
}

.text-muted {
    color: #8a8a9a;
}

.text-white {
    color: #f0f0f0;
}

.font-bold {
    font-weight: 700;
}

.font-semibold {
    font-weight: 600;
}

.text-sm {
    font-size: 0.875rem;
}

.text-lg {
    font-size: 1.125rem;
}

.text-xl {
    font-size: 1.25rem;
}

.text-2xl {
    font-size: 1.5rem;
}

.text-4xl {
    font-size: 2.25rem;
}

/* Display font */
.font-display {
    font-family: 'Playfair Display', Georgia, serif;
}

/* SVG fill utilities */
svg {
    fill: currentColor;
}

/* Hover brightness for buttons */
.hover\:brightness-110:hover {
    filter: brightness(1.1);
}

/* Transition utilities */
.transition-all {
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 300ms;
}

.duration-300 {
    transition-duration: 300ms;
}

/* Border utilities */
.border {
    border-width: 1px;
}

.border-t {
    border-top-width: 1px;
}

.border-b {
    border-bottom-width: 1px;
}

.border-y {
    border-top-width: 1px;
    border-bottom-width: 1px;
}

.rounded-lg {
    border-radius: 0.5rem;
}

.rounded-full {
    border-radius: 999px;
}

/* Display utilities */
.block {
    display: block;
}

.inline-block {
    display: inline-block;
}

.inline-flex {
    display: inline-flex;
}

.hidden {
    display: none !important;
}

@media (min-width: 768px) {
    .md\:hidden {
        display: none !important;
    }

    .md\:block {
        display: block;
    }

    .md\:flex {
        display: flex;
    }
}

/* Width and height utilities */
.w-full {
    width: 100%;
}

.w-16 {
    width: 4rem;
}

.h-16 {
    height: 4rem;
}

.h-64 {
    height: 16rem;
}

/* Max width utilities */
.max-w-2xl {
    max-width: 42rem;
}

.max-w-3xl {
    max-width: 48rem;
}

.max-w-4xl {
    max-width: 56rem;
}

.max-w-7xl {
    max-width: 80rem;
}

/* Padding utilities */
.px-4 {
    padding-left: 1rem;
    padding-right: 1rem;
}

.px-6 {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.px-8 {
    padding-left: 2rem;
    padding-right: 2rem;
}

.py-2 {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.py-3 {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.py-4 {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.p-8 {
    padding: 2rem;
}

/* Margin utilities */
.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

/* Min height */
.min-h-screen {
    min-height: 100vh;
}

/* Position utilities */
.relative {
    position: relative;
}

.absolute {
    position: absolute;
}

.sticky {
    position: sticky;
}

.top-0 {
    top: 0;
}

.inset-0 {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
}

/* Z-index utilities */
.z-0 {
    z-index: 0;
}

.z-10 {
    z-index: 10;
}

.z-50 {
    z-index: 50;
}

/* Shadow utilities */
.shadow-xl {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.shadow-2xl {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Opacity utilities */
.opacity-20 {
    opacity: 0.2;
}

.opacity-30 {
    opacity: 0.3;
}

.opacity-85 {
    opacity: 0.85;
}

/* Backdrop filter */
.backdrop-blur-md {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Background utilities */
.bg-bg-dark {
    background-color: #0a0a0f;
}

.bg-bg-card {
    background-color: #13131c;
}

.bg-bg-section {
    background-color: #0f0f18;
}

.bg-black {
    background-color: #000;
}

.bg-brand-green {
    background-color: #22d76a;
}

.bg-brand-red {
    background-color: #ff2600;
}

.bg-brand-green\/20 {
    background-color: rgba(34, 215, 106, 0.2);
}

.bg-brand-red\/20 {
    background-color: rgba(255, 38, 0, 0.2);
}

/* Color utilities */
.text-brand-green {
    color: #22d76a;
}

.text-brand-red {
    color: #ff2600;
}

.text-bg-dark {
    color: #0a0a0f;
}

/* Background opacity */
.bg-opacity-20 {
    opacity: 0.2;
}

.bg-opacity-85 {
    opacity: 0.85;
}

/* Border color utilities */
.border-brand-green {
    border-color: #22d76a;
}

.border-brand-red {
    border-color: #ff2600;
}

.border-white\/10 {
    border-color: rgba(255, 255, 255, 0.1);
}

.border-opacity-30 {
    opacity: 0.3;
}

/* Transform utilities */
.translate-y-0 {
    transform: translateY(0);
}

.-translate-y-1\.5 {
    transform: translateY(-0.375rem);
}

/* Object fit utilities */
.object-cover {
    object-fit: cover;
}

/* Overflow utilities */
.overflow-hidden {
    overflow: hidden;
}

.overflow-x-hidden {
    overflow-x: hidden;
}

/* Line clamp utilities */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Leading utilities */
.leading-relaxed {
    line-height: 1.625;
}

.leading-none {
    line-height: 1;
}

/* Truncate utility */
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Font mono */
.font-mono {
    font-family: 'Courier New', monospace;
}
