/* =============================================
   HERO SECTION — Tamannika
   Supplier Tanaman & Jasa Landscape Profesional
   ============================================= */

/* ─── Import Google Fonts ─── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Poppins:wght@600;700;800&display=swap');

/* ─── CSS Variables ─── */
:root {
    --hero-primary: #2E7D32;
    --hero-secondary: #43A047;
    --hero-accent: #66BB6A;
    --hero-bg: #F8FAF8;
    --hero-dark: #222222;
    --hero-text: #555555;
    --hero-radius: 24px;
    --hero-font-heading: 'Poppins', sans-serif;
    --hero-font-body: 'Inter', sans-serif;
    --hero-transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ─── Hero Section ─── */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--hero-bg);
    font-family: var(--hero-font-body);
    padding: 120px 24px 80px;
}

/* ─── Background ─── */
.hero-bg {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(135deg, rgba(46,125,50,0.04) 0%, transparent 50%),
        var(--hero-bg-image, url('/images/bg-hero.webp')) center / cover no-repeat;
    filter: blur(2px);
    z-index: 0;
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(248,250,248,0.92) 0%,
        rgba(248,250,248,0.70) 40%,
        rgba(248,250,248,0.92) 100%
    );
}

/* ─── Container ─── */
.hero-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1320px;
    display: grid;
    grid-template-columns: 45% 1fr;
    gap: 60px;
    align-items: center;
}

/* =============================================
   LEFT CONTENT
   ============================================= */

.hero-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ─── Badge ─── */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: rgba(46,125,50,0.08);
    border: 1px solid rgba(46,125,50,0.15);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--hero-primary);
    letter-spacing: 0.02em;
    width: fit-content;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    animation: heroFadeUp 0.6s ease both;
}

.hero-badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--hero-primary);
    animation: heroPulse 2s ease-in-out infinite;
}

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

/* ─── Heading ─── */
.hero-heading {
    font-family: var(--hero-font-heading);
    font-size: clamp(2.2rem, 4.5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--hero-dark);
    letter-spacing: -0.02em;
    animation: heroFadeUp 0.6s 0.12s ease both;
}

.hero-heading-gradient {
    background: linear-gradient(135deg, var(--hero-primary), var(--hero-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ─── Description ─── */
.hero-desc {
    font-size: clamp(0.95rem, 1.1vw, 1.1rem);
    line-height: 1.75;
    color: var(--hero-text);
    max-width: 520px;
    animation: heroFadeUp 0.6s 0.24s ease both;
}

/* =============================================
   BUTTONS
   ============================================= */

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    animation: heroFadeUp 0.6s 0.36s ease both;
}

/* ─── Primary Button ─── */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    background: linear-gradient(135deg, var(--hero-primary), var(--hero-secondary));
    color: #fff;
    font-family: var(--hero-font-body);
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 60px;
    text-decoration: none;
    cursor: pointer;
    transition: transform var(--hero-transition), box-shadow var(--hero-transition);
    box-shadow: 0 4px 20px rgba(46,125,50,0.25);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 36px rgba(46,125,50,0.35);
}

.btn-primary .btn-icon {
    transition: transform var(--hero-transition);
}

.btn-primary:hover .btn-icon {
    transform: translateX(4px);
}

/* ─── Secondary Button ─── */
.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    background: transparent;
    color: var(--hero-dark);
    font-family: var(--hero-font-body);
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid rgba(0,0,0,0.12);
    border-radius: 60px;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--hero-transition), color var(--hero-transition), border-color var(--hero-transition), transform var(--hero-transition);
}

.btn-secondary:hover {
    background: var(--hero-primary);
    color: #fff;
    border-color: var(--hero-primary);
    transform: translateY(-3px);
}

/* =============================================
   COUNTER STATS
   ============================================= */

.hero-stats {
    display: flex;
    align-items: center;
    gap: 32px;
    padding-top: 16px;
    animation: heroFadeUp 0.6s 0.48s ease both;
}

.stat-item {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 2px;
}

.stat-number {
    font-family: var(--hero-font-heading);
    font-size: clamp(1.6rem, 2.5vw, 2.2rem);
    font-weight: 700;
    color: var(--hero-primary);
}

.stat-plus {
    font-family: var(--hero-font-heading);
    font-size: clamp(1.2rem, 1.8vw, 1.6rem);
    font-weight: 700;
    color: var(--hero-accent);
    margin-right: 4px;
}

.stat-label {
    display: block;
    width: 100%;
    font-size: 0.8rem;
    color: var(--hero-text);
    font-weight: 500;
    margin-top: 2px;
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: rgba(0,0,0,0.08);
    flex-shrink: 0;
}

/* =============================================
   RIGHT VISUAL
   ============================================= */

.hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    perspective: 1000px;
}

/* ─── Main Image ─── */
.hero-image-wrapper {
    position: relative;
    width: 100%;
    max-width: 600px;
    aspect-ratio: 4 / 3;
    border-radius: var(--hero-radius);
    overflow: hidden;
    box-shadow:
        0 20px 60px rgba(46,125,50,0.15),
        0 0 0 1px rgba(46,125,50,0.06);
    animation: heroZoomIn 0.8s 0.3s ease both;
    transform-style: preserve-3d;
}

.hero-image-glow {
    position: absolute;
    inset: -20px;
    background: radial-gradient(ellipse at 30% 40%, rgba(46,125,50,0.12), transparent 70%);
    z-index: 0;
    pointer-events: none;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    position: relative;
    z-index: 1;
    transition: transform 0.1s ease-out;
    will-change: transform;
}

/* ─── Slider ─── */
.hero-slider {
    position: relative;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-slider .hero-image {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.08);
    transition: opacity 1s ease, transform 1.4s ease;
    z-index: 1;
}

.hero-slider .hero-image.active {
    opacity: 1;
    transform: scale(1);
    z-index: 2;
}

.hero-slider-dots {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 5;
}

.hero-slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    border: none;
    padding: 0;
    background: rgba(46, 125, 50, 0.25);
    cursor: pointer;
    transition: background 0.3s ease, width 0.3s ease;
}

.hero-slider-dot:hover {
    background: rgba(46, 125, 50, 0.45);
}

.hero-slider-dot.active {
    width: 28px;
    background: var(--hero-primary);
}

/* =============================================
   FLOATING CARDS
   ============================================= */

.floating-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: rgba(255,255,255,0.75);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.06), 0 1px 0 rgba(255,255,255,0.5) inset;
    border: 1px solid rgba(255,255,255,0.6);
    max-width: 220px;
    pointer-events: none;
    animation: heroFadeUp 0.6s 0.6s ease both;
    will-change: transform;
}

.floating-card-icon {
    font-size: 1.4rem;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(46,125,50,0.08);
    border-radius: 10px;
}

.floating-card-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.floating-card-text strong {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--hero-dark);
}

.floating-card-text span {
    font-size: 0.72rem;
    color: var(--hero-text);
    line-height: 1.3;
}

/* Card Positions */
.card-1 {
    top: 6%;
    right: -8%;
}

.card-2 {
    bottom: 12%;
    right: -12%;
}

.card-3 {
    bottom: 2%;
    left: -6%;
}

/* =============================================
   ANIMATIONS
   ============================================= */

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

@keyframes heroZoomIn {
    from {
        opacity: 0;
        transform: scale(0.92);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* =============================================
   RESPONSIVE — LAPTOP
   ============================================= */

@media (max-width: 1200px) {
    .hero-container {
        gap: 40px;
    }

    .card-1 { right: -4%; }
    .card-2 { right: -6%; }
    .card-3 { left: -4%; }
}

/* =============================================
   RESPONSIVE — TABLET
   ============================================= */

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

    .hero-container {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }

    .hero-heading {
        font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    }

    .floating-card {
        max-width: 180px;
        padding: 10px 16px;
    }

    .floating-card-icon {
        width: 30px;
        height: 30px;
        font-size: 1.1rem;
    }

    .card-1 { top: 4%; right: 2%; }
    .card-2 { bottom: 10%; right: 0; }
    .card-3 { bottom: 0; left: 0; }
}

/* =============================================
   RESPONSIVE — MOBILE
   ============================================= */

@media (max-width: 768px) {
    .hero {
        min-height: auto;
        padding: 100px 20px 60px;
    }

    .hero-container {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .hero-content {
        order: 1;
    }

    .hero-visual {
        order: 0;
    }

    .hero-image-wrapper {
        max-width: 100%;
        aspect-ratio: 4 / 3;
    }

    .hero-heading {
        font-size: clamp(1.6rem, 6vw, 2.2rem);
    }

    .hero-desc {
        font-size: 0.95rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .hero-stats {
        flex-direction: column;
        gap: 24px;
        align-items: center;
    }

    .stat-divider {
        width: 40px;
        height: 1px;
    }

    .stat-item {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .stat-label {
        text-align: center;
    }

    /* Floating cards reposition on mobile */
    .floating-card {
        position: relative;
        inset: auto;
        max-width: 100%;
        animation: heroFadeUp 0.6s 0.6s ease both;
        pointer-events: none;
        margin-top: 12px;
    }

    .card-1, .card-2, .card-3 {
        top: auto;
        right: auto;
        bottom: auto;
        left: auto;
    }

    .hero-visual {
        display: flex;
        flex-direction: column;
    }
}

/* =============================================
   RESPONSIVE — SMALL MOBILE
   ============================================= */

@media (max-width: 400px) {
    .hero {
        padding: 80px 16px 40px;
    }

    .hero-badge {
        font-size: 0.75rem;
        padding: 8px 14px;
    }

    .hero-heading {
        font-size: 1.4rem;
    }

    .btn-primary,
    .btn-secondary {
        padding: 14px 24px;
        font-size: 0.9rem;
    }

    .stat-number {
        font-size: 1.4rem;
    }
}
