/* Hero Section - Enhanced with Slider */
.hero-section {
    position: relative;
    min-height: 60vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    background-color: transparent !important;
}

.hero-slide.active {
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(0,0,0,0) 0%, rgba(0,0,0,0.15) 50%, rgba(0,0,0,0.35) 100%);
    z-index: 2;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.text-shadow {
    text-shadow: 2px 4px 12px rgba(0,0,0,0.6), 0 0 40px rgba(0,0,0,0.3);
}

/* Breadcrumb Custom */
.breadcrumb-custom {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: inline-block;
}

.breadcrumb-custom .breadcrumb {
    margin: 0;
    background: transparent;
}

.breadcrumb-custom .breadcrumb-item a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-custom .breadcrumb-item a:hover {
    color: white;
}

.breadcrumb-custom .breadcrumb-item.active {
    color: white;
}

.breadcrumb-custom .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.7);
}

/* Section Padding */
.section-padding {
    padding: 5rem 0;
}

@media (max-width: 768px) {
    .section-padding {
        padding: 3rem 0;
    }
}

/* Table Custom - Enhanced with animations */
.table-custom {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);
    background: white;
}

.table-custom thead {
    background: linear-gradient(135deg, #1976d2, #42a5f5, #64b5f6);
    color: white;
    position: relative;
}

.table-custom thead::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
}

.table-custom thead th {
    border: none;
    padding: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 1.2px;
    position: relative;
}

.table-custom tbody tr {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.table-custom tbody tr::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    background: linear-gradient(90deg, #e3f2fd, transparent);
    transition: width 0.4s ease;
}

.table-custom tbody tr:hover::before {
    width: 100%;
}

.table-custom tbody tr:hover {
    transform: translateX(10px) scale(1.01);
    box-shadow: -5px 0 15px rgba(25, 118, 210, 0.2);
    z-index: 1;
}

.table-custom tbody td {
    padding: 1.25rem 1.5rem;
    vertical-align: middle;
    position: relative;
    z-index: 1;
}

.table-custom .table-primary {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb) !important;
}

/* Climate Data Cards - Enhanced */
.card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 20px !important;
    overflow: visible;
    background: white;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15) !important;
}

.card-header {
    border-radius: 20px 20px 0 0 !important;
    padding: 1.5rem;
    font-weight: 600;
    position: relative;
    overflow: hidden;
}

.card-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.6s ease;
}

.card:hover .card-header::before {
    left: 100%;
}

/* Climate Stats - Animated - FIXED untuk readability */
.border.rounded {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: visible;
    background: white;
    border: 2px solid #e0e0e0 !important;
}

.border.rounded::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    height: 4px;
    background: linear-gradient(90deg, #1976d2, #42a5f5, #64b5f6);
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: 8px 8px 0 0;
}

.border.rounded:hover::before {
    opacity: 1;
}

.border.rounded:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 28px rgba(25, 118, 210, 0.15);
    border-color: #1976d2 !important;
}

.border.rounded .display-6 {
    transition: all 0.3s ease;
    font-weight: 900;
    color: #1976d2;
}

.border.rounded:hover .display-6 {
    transform: scale(1.08);
    color: #0d47a1 !important;
}

.border.rounded p {
    color: #424242;
    font-weight: 500;
}

/* Ecosystem Description Cards - FIXED untuk readability */
.card-body {
    padding: 2rem;
    position: relative;
    background: white;
}

.card-body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 0;
    background: linear-gradient(180deg, #1976d2, #42a5f5);
    transition: height 0.4s ease;
    border-radius: 0 4px 4px 0;
}

.card.ecosystem-card:hover .card-body::before {
    height: 100%;
}

.card-body h5 {
    transition: color 0.3s ease;
    position: relative;
    display: inline-block;
    color: #1976d2;
    font-weight: 700;
}

.card-body h5::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #1976d2, #42a5f5);
    transition: width 0.4s ease;
    border-radius: 2px;
}

.card.ecosystem-card:hover .card-body h5 {
    color: #0d47a1;
}

.card.ecosystem-card:hover .card-body h5::after {
    width: 100%;
}

.card-body p {
    color: #424242;
    line-height: 1.8;
    font-size: 0.95rem;
}

/* Badge Enhancements */
.badge {
    padding: 0.6rem 1.2rem;
    font-weight: 600;
    border-radius: 25px;
    font-size: 0.875rem;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.badge.bg-warning {
    background: linear-gradient(135deg, #ffc107, #ffb300) !important;
    box-shadow: 0 4px 12px rgba(255, 193, 7, 0.3);
}

.badge.bg-warning:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(255, 193, 7, 0.4);
}

/* Hero badges */
.hero-content .badge {
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.hero-content .badge:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.3);
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(40px);
    animation: fadeInUp 0.8s ease forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-40px);
    animation: fadeInLeft 0.8s ease forwards;
}

@keyframes fadeInLeft {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.fade-in-right {
    opacity: 0;
    transform: translateX(40px);
    animation: fadeInRight 0.8s ease forwards;
}

@keyframes fadeInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }
.delay-6 { animation-delay: 0.6s; }

/* Pulse animation for numbers */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.display-6 {
    animation: pulse 2s ease-in-out infinite;
}

/* Smooth scroll */
html {
    scroll-behavior: smooth;
}

/* Section titles with animated underline */
h2 {
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, #1976d2, #42a5f5, #64b5f6);
    border-radius: 2px;
    transition: width 0.6s ease;
}

h2.visible::after {
    width: 100px;
}

.text-center h2::after {
    left: 50%;
}

/* Responsive Hero */
@media (max-width: 768px) {
    .hero-section {
        min-height: 50vh;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-content .lead {
        font-size: 1rem;
    }
}

/* Enhanced shadows */
.shadow-sm {
    box-shadow: 0 6px 20px rgba(0,0,0,0.1) !important;
}

.shadow-sm:hover {
    box-shadow: 0 15px 40px rgba(0,0,0,0.15) !important;
}

/* Floating animation - DISABLED untuk ecosystem cards */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Ecosystem cards: simple lift without floating */
.card.ecosystem-card {
    border: 1px solid #e0e0e0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card.ecosystem-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(25, 118, 210, 0.12) !important;
    border-color: #1976d2;
    /* NO floating animation - just static lift */
}

/* Shimmer effect for table header */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.table-custom thead {
    background-size: 200% 100%;
    animation: shimmer 3s linear infinite;
}

/* Icon animations */
.card-header i {
    transition: transform 0.3s ease;
    display: inline-block;
}

.card:hover .card-header i {
    transform: rotate(360deg) scale(1.2);
}
