/* Hero Section Background Image - Responsive & Optimized */
.hero-section {
    background-attachment: fixed;
    background-color: #1a1a1a; /* Fallback color while loading */
}

/* Lazy loading optimization - blur-up technique */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: inherit;
    background-size: cover;
    background-position: center;
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.hero-section.loaded::before {
    opacity: 0;
}

/* Mobile optimization - disable parallax on small screens */
@media (max-width: 768px) {
    .hero-section {
        background-attachment: scroll;
        background-position: center center;
    }
}

/* Tablet optimization */
@media (min-width: 769px) and (max-width: 1200px) {
    .hero-section {
        background-position: center center;
    }
}

/* Section 2 Background Image - Blind Spot Section */
section[style*="stepping-over-money.jpg"] {
    background-attachment: fixed;
}

@media (max-width: 768px) {
    section[style*="stepping-over-money.jpg"] {
        background-attachment: scroll;
        background-position: center center;
    }
}

/* Ensure purple buttons stay white text on hover */
.btn-primary:hover {
    color: white !important;
}

/* Gold buttons stay dark text on hover */
.btn:not(.btn-primary):hover {
    color: #1a1a1a !important;
}

/* Footer link hover states */
footer a:hover {
    color: #ffffff !important;
}

/* Logo hover effects - subtle scale up */
img[alt*="Martial Arts"]:hover,
img[alt*="Jiu-Jitsu"]:hover,
img[alt*="Gracie"]:hover,
img[alt*="Academy"]:hover {
    transform: scale(1.05);
}

/* Login link hover effect */
nav a[href*="login"]:hover {
    color: var(--primary-600) !important;
}

/* Footer Grid Styling */
.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-xl);
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--space-l);
    }
}

/* Proof Section Styles */
.hero-story {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 0;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--surface-border);
    overflow: hidden;
    box-shadow: var(--shadow-3);
    margin-bottom: var(--space-xl);
}

.story-visual {
    position: relative;
    min-height: 420px;
    background: linear-gradient(135deg, #5F4690 0%, var(--primary-600) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--space-xl);
}

.photo-placeholder,
.story-photo {
    position: absolute;
    top: var(--space-xl);
    left: var(--space-xl);
    right: var(--space-xl);
    bottom: 100px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.2);
    object-fit: cover;
    object-position: center;
    display: block;
}

.story-photo {
    filter: brightness(1.2) contrast(1.1);
}

.photo-placeholder {
    background-image: url('../images/deluca.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
}

.story-visual-info {
    position: relative;
    z-index: 1;
    color: white;
}

.owner-name {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.school-name {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: 8px;
}

.school-name::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #10b981;
    border-radius: 50%;
}

.story-content {
    padding: var(--space-xxl);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.result-card {
    background: white;
    border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    transition: all 0.3s ease;
}

.result-card:hover {
    border-color: var(--primary-600);
    box-shadow: var(--shadow-3);
    transform: translateY(-4px);
}

.result-card-amount {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-600);
    margin-bottom: 4px;
    line-height: 1.2;
}

.result-card-type {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-tertiary);
    margin-bottom: var(--space-m);
}

.result-card-owner {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.result-card-location {
    font-size: 0.875rem;
    color: var(--text-tertiary);
}

.result-card-detail {
    margin-top: var(--space-m);
    padding-top: var(--space-m);
    border-top: 1px solid var(--surface-border);
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

@media (max-width: 900px) {
    .hero-story {
        grid-template-columns: 1fr;
    }
    .story-visual {
        min-height: 280px;
    }
    .photo-placeholder {
        bottom: 80px;
    }
    .story-content {
        padding: var(--space-xl) var(--space-l);
    }
}

/* Hidden Profit Scan Section Styles */
.scan-section {
    position: relative;
    padding: 120px 24px;
    background-image: linear-gradient(135deg, rgba(95, 70, 144, 0.95) 0%, rgba(106, 13, 173, 0.95) 50%, rgba(91, 33, 182, 0.95) 100%), url('images/xray-vision.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.scan-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridPulse 8s ease-in-out infinite;
}

@keyframes gridPulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 20s ease-in-out infinite;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: #FFD700;
    top: -100px;
    right: -100px;
    animation-delay: 0s;
}

.orb-2 {
    width: 300px;
    height: 300px;
    background: #00D4FF;
    bottom: -50px;
    left: -50px;
    animation-delay: -5s;
}

.orb-3 {
    width: 200px;
    height: 200px;
    background: #FF6B6B;
    top: 50%;
    left: 30%;
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -30px) scale(1.1); }
    50% { transform: translate(-20px, 20px) scale(0.9); }
    75% { transform: translate(20px, 10px) scale(1.05); }
}

.scan-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 12px 28px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 100px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #FFD700;
    margin-bottom: 24px;
    backdrop-filter: blur(10px);
}

.scan-badge::before {
    content: '';
    width: 10px;
    height: 10px;
    background: #FFD700;
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.8);
    flex-shrink: 0;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        box-shadow: 0 0 8px rgba(255, 215, 0, 0.8);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.3);
        box-shadow: 0 0 16px rgba(255, 215, 0, 1);
    }
}

.profit-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 3s ease-in-out infinite;
    animation-delay: 2s;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.opportunity-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    background: linear-gradient(135deg, #F5EBFF 0%, #F8F4FF 100%);
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--primary-600);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.opportunity-row:hover {
    transform: translateX(8px);
    box-shadow: 0 4px 20px rgba(106, 13, 173, 0.15);
}

.opportunity-row::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, rgba(106, 13, 173, 0.1), transparent);
    width: var(--progress, 0%);
    transition: width 1.5s ease-out;
}

.opportunity-row:nth-child(1) { --progress: 32%; }
.opportunity-row:nth-child(2) { --progress: 47%; }
.opportunity-row:nth-child(3) { --progress: 21%; }

.total-section {
    background: transparent;
    border-radius: var(--radius-lg);
    padding: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    overflow: visible;
    isolation: isolate;
}

.total-section::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(90deg, #FFD700, var(--primary-600), #FFD700);
    background-size: 200% 100%;
    border-radius: calc(var(--radius-lg) + 2px);
    z-index: -1;
    animation: borderGlow 3s linear infinite;
}

.total-section::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: linear-gradient(135deg, var(--primary-600) 0%, #4C1D95 100%);
    border-radius: calc(var(--radius-lg) - 2px);
    z-index: -1;
}

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

.sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #FFD700;
    border-radius: 50%;
    animation: sparkle 2s ease-in-out infinite;
}

.sparkle:nth-child(1) { top: 20%; right: 30%; animation-delay: 0s; }
.sparkle:nth-child(2) { top: 60%; right: 15%; animation-delay: 0.5s; }
.sparkle:nth-child(3) { top: 40%; right: 45%; animation-delay: 1s; }

@keyframes sparkle {
    0%, 100% { opacity: 0; transform: scale(0); }
    50% { opacity: 1; transform: scale(1); }
}

/* CTA Button Hover Effects */
.scan-section .btn-gold {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #FFD700 0%, #E5A600 100%) !important;
    color: #1a1a1a !important;
    transition: all 0.3s ease !important;
}

.scan-section .btn-gold svg {
    transition: transform 0.3s ease;
}

/* Shimmer effect on hover */
.scan-section .btn-gold::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    transition: left 0.5s ease;
    pointer-events: none;
    z-index: 1;
}

.scan-section .btn-gold:hover::before {
    left: 100%;
}

/* Glow expansion on hover */
.scan-section .btn-gold:hover {
    background: linear-gradient(135deg, #FFD700 0%, #F5A623 100%) !important;
    color: #1a1a1a !important;
    box-shadow:
        0 4px 15px rgba(255, 215, 0, 0.4),
        0 0 30px rgba(255, 215, 0, 0.3),
        0 0 0 4px rgba(255, 215, 0, 0.1) !important;
    transform: translateY(-2px) !important;
}

/* Arrow slide animation on hover */
.scan-section .btn-gold:hover svg {
    transform: translateX(4px);
}

@media (max-width: 640px) {
    .scan-section {
        padding: 80px 16px;
    }
    .total-section {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

/* Responsive layout for scan section */
@media (max-width: 1024px) {
    .scan-section > div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
    }
    .scan-section header,
    .scan-section div[style*="text-align: left"] {
        text-align: center !important;
    }
}
