/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    color: #ffffff;
    overflow-x: hidden;
    position: relative;
    overscroll-behavior-y: contain;
}

/* AI-themed Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 30%, rgba(0, 212, 255, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(168, 85, 247, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 50% 20%, rgba(0, 255, 157, 0.1) 0%, transparent 30%),
        linear-gradient(135deg,
        transparent 0%,
        rgba(0, 212, 255, 0.05) 25%,
        transparent 50%,
        rgba(168, 85, 247, 0.05) 75%,
        transparent 100%
        );
    z-index: -3;
}

/* Animated Circuit Pattern */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        repeating-linear-gradient(
            45deg,
            transparent,
            transparent 2px,
            rgba(0, 212, 255, 0.02) 2px,
            rgba(0, 212, 255, 0.02) 4px
        ),
        repeating-linear-gradient(
            -45deg,
            transparent,
            transparent 2px,
            rgba(168, 85, 247, 0.02) 2px,
            rgba(168, 85, 247, 0.02) 4px
        );
    z-index: -2;
    animation: circuitPulse 10s ease-in-out infinite;
}

@keyframes circuitPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

/* Neural Network Background Animation */
.neural-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -2;
    opacity: 0.7;
    will-change: transform;
    display: block;
}

.neural-node {
    position: absolute;
    width: 3px;
    height: 3px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.8) 0%, transparent 70%);
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(0, 212, 255, 0.5);
    will-change: transform, opacity;
}

.neural-node.primary {
    width: 4px;
    height: 4px;
    background: radial-gradient(circle, rgba(0, 212, 255, 1) 0%, transparent 70%);
    animation: pulsePrimary 3s infinite;
}

.neural-node.secondary {
    width: 2px;
    height: 2px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.8) 0%, transparent 70%);
    animation: pulseSecondary 4s infinite;
}

.neural-node.tertiary {
    width: 2px;
    height: 2px;
    background: radial-gradient(circle, rgba(0, 255, 157, 0.6) 0%, transparent 70%);
    animation: pulseTertiary 5s infinite;
}

@keyframes pulsePrimary {
    0%, 100% {
        opacity: 0.4;
        transform: scale(0.8);
        filter: blur(0px);
    }
    50% {
        opacity: 1;
        transform: scale(1.2);
        filter: blur(0.5px);
    }
}

@keyframes pulseSecondary {
    0%, 100% {
        opacity: 0.3;
        transform: scale(0.9);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

@keyframes pulseTertiary {
    0%, 100% {
        opacity: 0.2;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

.neural-connection {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.3), transparent);
    pointer-events: none;
    opacity: 0;
    transform-origin: left center;
    animation: connectionPulse 3s infinite;
}

@keyframes connectionPulse {
    0%, 100% {
        opacity: 0;
    }
    50% {
        opacity: 0.6;
    }
}

@keyframes floatNode {
    0%, 100% {
        transform: translate(0, 0);
    }
    33% {
        transform: translate(10px, -10px);
    }
    66% {
        transform: translate(-10px, 5px);
    }
}

.neural-node:nth-child(3n) {
    animation: pulsePrimary 3s infinite, floatNode 10s infinite;
}

.neural-node:nth-child(3n+1) {
    animation: pulseSecondary 4s infinite, floatNode 12s infinite;
}

.neural-node:nth-child(3n+2) {
    animation: pulseTertiary 5s infinite, floatNode 15s infinite;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    padding: 180px 20px 80px;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h2 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #00d4ff, #ffffff, #a855f7);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: #b3b3b3;
    margin-bottom: 30px;
    line-height: 1.6;
}

.hero-description {
    font-size: 1.1rem;
    color: #cccccc;
    margin-bottom: 40px;
    line-height: 1.8;
}

.cta-button {
    background: linear-gradient(45deg, #00d4ff, #a855f7);
    color: white;
    padding: 18px 40px;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.4);
}

/* Features Section */
.features {
    padding: 100px 20px;
    max-width: 1200px;
    margin: 0 auto;
    background: transparent;
}

.features h3 {
    text-align: center;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #00d4ff, #ffffff, #a855f7);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
}

.features-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: #b3b3b3;
    margin-bottom: 60px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.06), rgba(168, 85, 247, 0.06));
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.feature-card::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, rgba(0, 212, 255, 0.2), rgba(168, 85, 247, 0.2), rgba(0, 212, 255, 0.2));
    border-radius: 20px;
    opacity: 0;
    z-index: -1;
    transition: opacity 0.3s ease;
    background-size: 300% 300%;
    animation: gradientShift 6s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.feature-card:hover {
    transform: translateY(-8px);
    border-color: rgba(0, 212, 255, 0.3);
    box-shadow:
        0 12px 25px rgba(0, 212, 255, 0.08),
        0 6px 12px rgba(168, 85, 247, 0.04);
}

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

.feature-card:hover::after {
    opacity: 0.3;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
    z-index: 2;
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) translateY(-3px);
}

.feature-icon svg {
    width: 80px;
    height: 80px;
    filter: drop-shadow(0 4px 8px rgba(0, 212, 255, 0.2));
    transition: filter 0.4s ease;
}

.feature-card:hover .feature-icon svg {
    filter: drop-shadow(0 6px 12px rgba(0, 212, 255, 0.3));
}

.feature-card h4 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #ffffff;
    position: relative;
    z-index: 2;
    transition: color 0.3s ease;
}

.feature-card:hover h4 {
    color: rgba(255, 255, 255, 1);
}

.feature-card p {
    color: #b3b3b3;
    line-height: 1.6;
    position: relative;
    z-index: 2;
    transition: color 0.3s ease, transform 0.3s ease;
}

.feature-card:hover p {
    color: rgba(255, 255, 255, 0.75);
    transform: translateY(-2px);
}

/* Demo Section */
.demo-section {
    padding: 100px 20px;
    background: transparent;
    text-align: center;
}

.demo-content {
    max-width: 800px;
    margin: 0 auto;
}

.demo-section h3 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #00d4ff, #ffffff, #a855f7);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
}

.demo-section p {
    font-size: 1.2rem;
    color: #b3b3b3;
    margin-bottom: 40px;
    line-height: 1.8;
}

/* Terms specific styles */
.privacy-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.privacy-contact-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 30px 25px;
    border-radius: 20px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.35s ease;
    backdrop-filter: blur(10px);
}

.privacy-contact-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 212, 255, 0.3);
    box-shadow: 0 10px 20px rgba(0, 212, 255, 0.15);
}

.privacy-contact-card h4 {
    color: #ffffff;
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.privacy-contact-card p {
    color: #b3b3b3;
    margin-bottom: 15px;
}

.privacy-summary {
    margin-top: 60px;
    background: rgba(255, 255, 255, 0.03);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    text-align: left;
}

.privacy-summary h4 {
    color: #ffffff;
    font-size: 1.8rem;
    margin-bottom: 30px;
    text-align: center;
}

.privacy-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.summary-item {
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.summary-item h5 {
    color: #00d4ff;
    font-size: 1.1rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.summary-item p {
    color: #cccccc;
    line-height: 1.6;
    margin: 0;
}

.summary-item ul {
    color: #cccccc;
    line-height: 1.6;
    margin: 10px 0;
    padding-left: 20px;
}

.summary-item li {
    margin-bottom: 5px;
}

.last-updated {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #b3b3b3;
    font-size: 0.9rem;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero {
        padding: 120px 20px 60px;
        min-height: auto;
    }

    .hero h2 {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .cta-button {
        padding: 15px 30px;
        font-size: 1rem;
    }

    .features,
    .demo-section {
        padding: 80px 20px;
    }

    .features h3,
    .demo-section h3 {
        font-size: 2.5rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .privacy-contact-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .privacy-summary-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .privacy-summary {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 100px 20px 60px;
    }

    .hero h2 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-description {
        font-size: 0.95rem;
        margin-bottom: 30px;
    }

    .features,
    .demo-section {
        padding: 60px 20px;
    }

    .features h3,
    .demo-section h3 {
        font-size: 2rem;
    }

    .feature-card {
        padding: 30px 20px;
    }
}

/* SVG Animation Styles */
.feature-icon svg,
.privacy-contact-card .feature-icon svg {
    transition: all 0.4s ease;
}

.feature-card:hover .feature-icon svg,
.privacy-contact-card:hover .feature-icon svg {
    transform: scale(1.05);
}

/* Advanced SVG Animations */
.feature-icon svg {
    animation: subtleGlow 4s ease-in-out infinite;
}

.privacy-contact-card .feature-icon svg {
    animation: subtleGlow 3s ease-in-out infinite;
}

/* Individual SVG animations */
.feature-icon svg #agreementGrad stop {
    animation: documentAuthentication 4.5s ease-in-out infinite;
}

.feature-icon svg #userGrad stop {
    animation: holoShimmer 5s ease-in-out infinite;
}

.feature-icon svg #ipGrad stop {
    animation: copyrightPulse 4s ease-in-out infinite;
}

.feature-icon svg #paymentGrad stop {
    animation: paymentFlow 3.5s ease-in-out infinite;
}

.feature-icon svg #liabilityGrad stop {
    animation: securityAlert 4s ease-in-out infinite;
}

.feature-icon svg #terminationGrad stop {
    animation: terminationWarning 3.8s ease-in-out infinite;
}

/* Contact SVG animations */
.privacy-contact-card svg #legalGrad stop {
    animation: documentAuthentication 4.5s ease-in-out infinite;
}

.privacy-contact-card svg #contractGrad stop {
    animation: contractValidation 4s ease-in-out infinite;
}

.privacy-contact-card svg #supportGrad stop {
    animation: supportBeacon 3.5s ease-in-out infinite;
}

.privacy-contact-card svg #complianceGrad stop {
    animation: complianceVerification 4.2s ease-in-out infinite;
}

/* Line and path animations */
.feature-icon svg path,
.feature-icon svg line {
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: drawLine 3s ease-in-out infinite;
}

.feature-icon svg circle:not([fill]) {
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    animation: drawCircle 2.5s ease-in-out infinite;
}

/* Text animations */
.feature-icon svg text {
    animation: textGlow 2s ease-in-out infinite;
}

/* Rectangle data animations */
.feature-icon svg rect[fill="#00ff9d"] {
    animation: dataChunk 1.5s ease-in-out infinite;
}

/* Keyframe Animations */
@keyframes subtleGlow {
    0%, 100% {
        filter: drop-shadow(0 4px 8px rgba(0, 212, 255, 0.2));
    }
    50% {
        filter: drop-shadow(0 8px 16px rgba(0, 212, 255, 0.4));
    }
}

@keyframes documentAuthentication {
    0%, 100% {
        stop-color: #00d4ff;
    }
    33% {
        stop-color: #00ff9d;
    }
    66% {
        stop-color: #a855f7;
    }
}

@keyframes holoShimmer {
    0%, 100% {
        stop-color: #00d4ff;
        stop-opacity: 1;
    }
    25% {
        stop-color: #a855f7;
        stop-opacity: 0.9;
    }
    50% {
        stop-color: #00ff9d;
        stop-opacity: 0.8;
    }
    75% {
        stop-color: #a855f7;
        stop-opacity: 0.9;
    }
}

@keyframes copyrightPulse {
    0%, 100% {
        stop-color: #00d4ff;
        stop-opacity: 1;
    }
    50% {
        stop-color: #a855f7;
        stop-opacity: 0.8;
    }
}

@keyframes paymentFlow {
    0% {
        stop-color: #00d4ff;
    }
    25% {
        stop-color: #00ff9d;
    }
    50% {
        stop-color: #a855f7;
    }
    75% {
        stop-color: #ffaa00;
    }
    100% {
        stop-color: #00d4ff;
    }
}

@keyframes securityAlert {
    0%, 100% {
        stop-color: #00d4ff;
    }
    25% {
        stop-color: #ff4444;
    }
    50% {
        stop-color: #a855f7;
    }
    75% {
        stop-color: #00ff9d;
    }
}

@keyframes terminationWarning {
    0%, 100% {
        stop-color: #00d4ff;
        stop-opacity: 1;
    }
    25% {
        stop-color: #ff6666;
        stop-opacity: 0.9;
    }
    50% {
        stop-color: #ffaa00;
        stop-opacity: 0.8;
    }
    75% {
        stop-color: #a855f7;
        stop-opacity: 0.9;
    }
}

@keyframes contractValidation {
    0%, 100% {
        stop-color: #00d4ff;
        stop-opacity: 1;
    }
    33% {
        stop-color: #00ff9d;
        stop-opacity: 0.9;
    }
    66% {
        stop-color: #a855f7;
        stop-opacity: 0.8;
    }
}

@keyframes supportBeacon {
    0%, 100% {
        stop-color: #00d4ff;
        stop-opacity: 1;
    }
    50% {
        stop-color: #00ff9d;
        stop-opacity: 0.7;
    }
}

@keyframes complianceVerification {
    0%, 100% {
        stop-color: #00d4ff;
    }
    20% {
        stop-color: #00ff9d;
    }
    40% {
        stop-color: #a855f7;
    }
    60% {
        stop-color: #00ff9d;
    }
    80% {
        stop-color: #00d4ff;
    }
}

@keyframes drawLine {
    0% {
        stroke-dashoffset: 200;
        opacity: 0.3;
    }
    50% {
        stroke-dashoffset: 0;
        opacity: 1;
    }
    100% {
        stroke-dashoffset: -200;
        opacity: 0.3;
    }
}

@keyframes drawCircle {
    0% {
        stroke-dashoffset: 100;
        opacity: 0.4;
    }
    50% {
        stroke-dashoffset: 0;
        opacity: 1;
    }
    100% {
        stroke-dashoffset: -100;
        opacity: 0.4;
    }
}

@keyframes textGlow {
    0%, 100% {
        fill-opacity: 0.8;
        filter: drop-shadow(0 0 4px rgba(0, 212, 255, 0.3));
    }
    50% {
        fill-opacity: 1;
        filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.6));
    }
}

@keyframes dataChunk {
    0%, 100% {
        opacity: 0.6;
        transform: scaleX(1);
    }
    50% {
        opacity: 1;
        transform: scaleX(1.1);
    }
}

/* Hover enhancement animations */
.feature-card:hover .feature-icon svg {
    animation: enhancedGlow 2s ease-in-out infinite;
}

.privacy-contact-card:hover .feature-icon svg {
    animation: enhancedGlow 1.5s ease-in-out infinite;
}

@keyframes enhancedGlow {
    0%, 100% {
        filter: drop-shadow(0 8px 16px rgba(0, 212, 255, 0.4));
        transform: scale(1.05);
    }
    50% {
        filter: drop-shadow(0 12px 24px rgba(0, 212, 255, 0.6));
        transform: scale(1.08);
    }
}

/* Stagger animation delays for visual interest */
.feature-card:nth-child(1) .feature-icon svg {
    animation-delay: 0s;
}

.feature-card:nth-child(2) .feature-icon svg {
    animation-delay: 0.5s;
}

.feature-card:nth-child(3) .feature-icon svg {
    animation-delay: 1s;
}

.feature-card:nth-child(4) .feature-icon svg {
    animation-delay: 1.5s;
}

.feature-card:nth-child(5) .feature-icon svg {
    animation-delay: 2s;
}

.feature-card:nth-child(6) .feature-icon svg {
    animation-delay: 2.5s;
}

.privacy-contact-card:nth-child(1) .feature-icon svg {
    animation-delay: 0.2s;
}

.privacy-contact-card:nth-child(2) .feature-icon svg {
    animation-delay: 0.6s;
}

.privacy-contact-card:nth-child(3) .feature-icon svg {
    animation-delay: 1s;
}

.privacy-contact-card:nth-child(4) .feature-icon svg {
    animation-delay: 1.4s;
}

/* Mobile animation optimizations */
@media (max-width: 768px) {
    .feature-card::after {
        animation: none !important;
        display: none;
    }

    .feature-card:hover {
        transform: none !important;
    }

    .feature-card:hover .feature-icon {
        transform: none !important;
    }
}

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

    .feature-icon svg {
        animation: none !important;
    }

    .feature-card:hover {
        transform: none !important;
    }
}
