/* =============================================
   AgriLinker Landing Page — Custom Styles
   ============================================= */

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

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* ---- Hero Gradient ---- */
.hero-gradient {
    background: linear-gradient(135deg, #0a1405 0%, #14280a 20%, #1E3A0E 40%, #2D5016 70%, #1a3d12 100%);
}

.hero-pattern {
    background-image:
        radial-gradient(circle at 20% 50%, rgba(76, 175, 80, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(139, 105, 20, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 60% 80%, rgba(76, 175, 80, 0.1) 0%, transparent 40%);
}

/* ---- CTA Gradient ---- */
.cta-gradient {
    background: linear-gradient(135deg, #14280a 0%, #1E3A0E 30%, #2D5016 60%, #4A7C28 100%);
}

/* ---- Video Poster ---- */
.video-poster-gradient {
    background: linear-gradient(135deg, #1E3A0E 0%, #2D5016 40%, #4A7C28 70%, #8B6914 100%);
}

/* ---- Navigation ---- */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* Nav links — transparent state */
.nav-link {
    color: rgba(255, 255, 255, 0.8);
}

.nav-link:hover {
    color: rgba(255, 255, 255, 1);
}

.nav-logo-agri {
    color: white;
}

.nav-logo-linker {
    color: #9ec585;
}

/* Nav links — scrolled state */
#navbar.scrolled .nav-link {
    color: #4b5563;
}

#navbar.scrolled .nav-link:hover {
    color: #2D5016;
}

#navbar.scrolled .nav-logo-agri {
    color: #1a1a1a;
}

#navbar.scrolled .nav-logo-linker {
    color: #2D5016;
}

/* ---- Animations ---- */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
}

@keyframes float-slow {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-delayed 8s ease-in-out infinite;
    animation-delay: 2s;
}

.animate-float-slow {
    animation: float-slow 7s ease-in-out infinite;
    animation-delay: 1s;
}

/* ---- Photo Cards ---- */
.photo-card {
    min-height: 200px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.photo-card:hover {
    transform: scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

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

/* ---- Smooth section transitions ---- */
section {
    position: relative;
}

/* ---- Button hover effects ---- */
a[href="#cta"],
a[href="#"] {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

::-webkit-scrollbar-track {
    background: #f5f5f5;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #4A7C28;
}

/* ---- Selection Color ---- */
::selection {
    background-color: rgba(45, 80, 22, 0.2);
    color: #1E3A0E;
}

/* ---- Mobile Menu Animation ---- */
#mobile-menu {
    transition: all 0.3s ease;
}

#mobile-menu.active {
    display: block;
}

/* ---- Responsive Adjustments ---- */
@media (max-width: 640px) {
    .hero-gradient {
        background: linear-gradient(160deg, #0a1405 0%, #1E3A0E 50%, #2D5016 100%);
    }

    .photo-card {
        min-height: 150px;
    }
}

@media (max-width: 1024px) {
    #navbar.scrolled {
        background: rgba(255, 255, 255, 0.98);
    }
}

/* ---- Video container play state ---- */
#video-container.playing .video-poster-gradient,
#video-container.playing > div:not(video) {
    display: none;
}

#video-container.playing video {
    display: block !important;
}

/* ---- Loading animation for counter ---- */
@keyframes count-up {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.counter.animated {
    animation: count-up 0.6s ease-out;
}

/* ---- Focus styles for accessibility ---- */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #4A7C28;
    outline-offset: 2px;
    border-radius: 4px;
}

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

    section {
        page-break-inside: avoid;
    }

    .hero-gradient {
        background: white !important;
        color: black !important;
    }
}
