/* slider */
.nft-hero {
    background-size: cover;
    height: 100vh;
    background-position: center;
    padding: 222px 0 150px 0;
}
.p{
    font-size: 16px;
}
.button-hero {
    background-color: #ff5722;
    border-color: #ff5722;
    padding: 12px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s ease;
}
.section {
    padding: 90px 0;
    background-color: white;
    position: relative;
}

.button-hero:hover {
    background-color: #ff5722; /* contoh warna hover */
    border-color: #ff5722;
    transform: translateY(-3px);
}
.hero-title {
    font-family: "Gantari", sans-serif;
    font-size: 55px;
    font-weight: bold;
    color: #fff;
    text-transform: uppercase;
    line-height: 65px;
    text-align: left;
    background: transparent;
    margin: 0;
}
.section-bg {
    background: linear-gradient(156deg, #3f4b91 0%, #2f2b39 50%, #1c2581 100%);
}
.stats-section {
    background-color: #1d1d1d;
    color: #fff;
}

.stat-card {
    background-color: #262626;
    border-radius: 12px;
    padding: 40px 20px; /* tambah padding */
    min-height: 23vh; /* tinggi minimum biar seragam */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, background 0.3s;
}
.stat-card i {
    font-size: 2.5rem; /* icon lebih besar */
    margin-bottom: 15px;
    color: #ff5722;
}
.stat-card:hover {
    transform: translateY(-5px);
}
.stat-card h3 {
    font-size: 2rem; /* angka lebih besar */
    margin-bottom: 5px;
}

.stat-card:hover {
    transform: translateY(-5px);
    background: #333; /* efek hover */
}

.cta-card {
    background: linear-gradient(
            135deg,
            rgba(255, 255, 255, 0.05),
            rgba(255, 255, 255, 0.02)
        ),
        url("https://reactheme.com/products/wordpress/elever/renovation/wp-content/uploads/sites/3/2025/03/01-7.webp")
            center/cover no-repeat;
    border-radius: 10px;
    color: #fff;
    position: relative;
    min-width: 43vh;
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

.cta-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 10px;
}

.cta-card > * {
    position: relative;
    z-index: 2;
}
.info-box {
    border-radius: 12px;
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    justify-content: center; /* teks ada di tengah vertikal */
    height: 100%; /* biar ikut tinggi kolom */
}

.info-box h3 {
    font-weight: 700;
    margin-bottom: 20px;
}

.info-box p {
    margin-bottom: 15px;
    line-height: 1.6;
    color: #ccc;
}
.icon-circle {
    background: #ff5722;
    color: #fff;
    border-radius: 50%;
    padding: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.counter {
    font-size: 2rem;
    font-weight: bold;
    transition: all 0.3s ease-in-out;
}
.text-muted {
    font-size: 17px;
}

/* sweetalert */
.small-toast {
    padding: 6px 10px !important;
    border-radius: 8px !important;
    font-size: 13px !important;
    min-height: auto !important;
}

.small-toast-title {
    font-size: 13px !important;
    font-weight: 500 !important;
}

.small-toast-icon {
    font-size: 14px !important;
}

.services-section {
    position: relative;
    padding: 0;
}
.text-heading {
    color: var(--e-global-color-primary);
    font-size: 54px;
    font-weight: 700;
    line-height: 1.2em;
}
.services-bg {
    position: relative;
    min-height: 500px; /* tinggi background */
    overflow: hidden;
}
.heading-title {
    font-size: 30px;
    font-weight: 700;
    line-height: 1.2em;
    color: #FFF;
}
.services-bg img,
.services-bg video {
    width: 100%;
    min-height: 500px; /* tinggi background */
    height: 100%;
    object-fit: cover;
}

.services-cards {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: -100px; /* supaya melayang */
    position: relative;
    z-index: 2;
    flex-wrap: wrap;
}

.card-service {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    flex: 1 1 300px;
    max-width: 350px;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.card-service .icon {
    background: #ff4d00;
    color: #fff;
    padding: 10px;
    display: inline-block;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 24px;
}

.card-service h3 {
    margin: 0 0 10px;
}

.card-service p {
    color: #555;
    font-size: 15px;
}

.card-service a {
    color: #ff4d00;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    margin-top: 10px;
}

.card-number {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 40px;
    font-weight: bold;
    color: #f3f0ed;
}

/* dropzone */
.custom-dropzone {
    border: 2px dashed #ced4da;
    border-radius: 8px;
    padding: 30px 20px;
    text-align: center;
    background: #fafbfc;
    cursor: pointer;
    transition: border-color 0.2s;
}
.custom-dropzone.dragover {
    border-color: #3b76e1;
    background: #f0f6ff;
}
.custom-dropzone-message {
    cursor: pointer;
}
.gallery-preview-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}
.gallery-preview-item {
    position: relative;
    width: 120px;
    height: 120px;
    border: 1px solid #e3e3e3;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: box-shadow 0.2s, border-color 0.2s;
}
.gallery-preview-item.dragging {
    opacity: 0.5;
}
.gallery-preview-item.drag-over {
    border: 2px dashed #3b76e1;
    box-shadow: 0 0 0 2px #3b76e1;
}
.gallery-preview-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
}
.gallery-preview-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(255,255,255,0.8);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #dc3545;
    font-size: 18px;
    cursor: pointer;
    z-index: 2;
}
.gallery-preview-item .drag-handle {
    position: absolute;
    left: 5px;
    top: 5px;
    background: rgba(0,0,0,0.08);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 16px;
    cursor: grab;
    z-index: 2;
}

.gallery-thumb {
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.gallery-thumb:hover {
    transform: scale(1.05);
}

.gallery-thumb.dragging {
    opacity: 0.5;
    cursor: grabbing !important;
    transform: scale(1.1);
}

.gallery-thumb[draggable="true"] {
    cursor: grab;
}

.gallery-thumb[draggable="true"]:active {
    cursor: grabbing;
}

/* show product */
.bg-background-blackOnWhite {
    background-color: #ffffff;
}

.pro_contain {
    padding: 122px 0 150px 0;
}

.content-loc {
    display: flex;
    color: rgba(51, 51, 51, .6);
}

.merchant-loc {
    color: #333;
    font-weight: 400;
    margin-left: 6px;
    line-height: 1.4;
    display: inline-block;
}

.sj-text-h3 {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.5rem;
}

/* End Showproduct */

/* Enhanced Mobile Menu Styles */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: white;
    z-index: 1060;
    transition: left 0.3s ease;
    overflow-y: auto;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
}

.mobile-menu.open {
    left: 0;
}

.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1055;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-overlay.show {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #dee2e6;
    background: #f8f9fa;
}

.close-mobile-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-list {
    padding: 0.5rem 0;
}

.mobile-parent-item, 
.mobile-child-item {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s ease;
}

.mobile-parent-item:hover,
.mobile-child-item:hover {
    background-color: #f8f9fa;
}

.mobile-child-list,
.mobile-grandchild-list {
    background-color: #fafafa;
}

.mobile-grandchild-list {
    padding-left: 1rem;
}

.mobile-grandchild-item {
    display: block;
    padding: 0.6rem 1rem;
    color: #495057;
    text-decoration: none;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.mobile-grandchild-item:hover {
    background-color: #e9ecef;
    color: #495057;
}

.mobile-auth-buttons {
    padding: 1rem;
    margin-top: 1rem;
    border-top: 1px solid #dee2e6;
}

.arrow {
    transition: transform 0.2s ease;
}

.collapse.show .arrow {
    transform: rotate(90deg);
}

/* Desktop Mega Menu Full Width Styles */
.mega-dropdown {
    position: static !important;
}

.mega-menu {
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    max-width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    border-radius: 0 !important;
    border-top: 1px solid #dee2e6 !important;
    /* Add gap between navbar and mega menu */
    margin-top: 0px !important;
}

.dropdown-menu.mega-menu {
    transform: none !important;
    top: 100% !important;
}

/* Create a gap between navbar and mega menu */
.mega-dropdown .dropdown-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 0;
    right: 0;
    height: 8px;
    background: transparent;
}

/* Desktop Grandchild Styles dengan Click */
.submenu-item {
    position: relative;
}

.submenu-link {
    display: block;
    padding: 0.5rem 1rem;
    color: #495057;
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 6px;
    margin-bottom: 0.25rem;
    cursor: pointer;
}

.submenu-link:hover {
    color: #0d6efd;
    background-color: #f8f9fa;
}

.submenu-link.active {
    color: #0d6efd;
    background-color: #e7f1ff;
    transform: translateX(5px);
    font-weight: 500;
}

.clickable-submenu {
    cursor: pointer !important;
}

.clickable-submenu:hover {
    background-color: #f8f9fa;
}

.grandchild-panel {
    animation: fadeIn 0.2s ease;
}

.grandchild-list li a {
    display: block;
    padding: 0.5rem 0;
    transition: all 0.2s ease;
    border-bottom: 1px solid transparent;
}

.grandchild-list li a:hover {
    color: #0d6efd;
    padding-left: 0.5rem;
    border-bottom-color: #e9ecef;
}

.hover-text-primary:hover {
    color: #0d6efd !important;
}

.bg-light {
    background-color: #f8f9fa !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateX(10px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Desktop Styles - Fixed hover behavior */
@media (min-width: 992px) {
    .mobile-menu,
    .mobile-overlay {
        display: none;
    }
    
    /* Improved hover behavior */
    .mega-dropdown:hover .dropdown-menu,
    .mega-dropdown .dropdown-menu:hover {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }
    
    /* Smooth transitions */
    .dropdown-menu.mega-menu {
        transition: opacity 0.2s ease, visibility 0.2s ease;
    }
}

/* Ensure full width on larger screens */
@media (min-width: 1200px) {
    .mega-menu .container-fluid {
        max-width: 100%;
        padding: 37px;
        margin: 0px 0px 0px 100px;
        background-color: #fff;
    }
}

/* End Menu  */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 8px;
    height: 24px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    font-family: 'Ubuntu', sans-serif;
}

.badge-pdn {
    background-color: #E5F0E9;
    color: #157631;
}

.badge-ppn {
    background-color: #E6F4F7;
    color: #007E87;
}

.badge-pph22 {
    background-color: #F3F5FC;
    color: #132146;
}

.badge-pkp {
    background-color: #E6F4F7;
    color: #007E87;
}

.delivery-estimate {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
    border-left: 4px solid #0d6efd;
}

/* Container untuk card product */
.card-product {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    transition: all 0.3s ease;
    overflow: hidden;
}

.card-product:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #007bff;
}

/* Fixed height untuk image container */
.card-image-container {
    height: 200px; /* Sesuaikan tinggi sesuai kebutuhan */
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Pastikan gambar cover area tanpa distorsi */
    transition: transform 0.3s ease;
}

.card-product:hover .product-image {
    transform: scale(1.05);
}

/* Badges styling */
.badges-container {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.badge {
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 500;
    border-radius: 4px;
    white-space: nowrap;
}

.badge-cod {
    background-color: #E5F0E9;
    color: #157631;
}

.badge-ppn {
    background-color: #E6F4F7;
    color: #007E87;
}

.badge-sameday {
    background-color: #F3F5FC;
    color: #132146;
}

.badge-pkp {
    background-color: #E6F4F7;
    color: #007E87;
}

/* Product title */
.product-title {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Batasi 2 baris */
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.6em; /* Konsisten tinggi untuk 2 baris */
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .card-image-container {
        height: 180px;
    }
    
    .product-title {
        font-size: 13px;
    }
}

@media (max-width: 576px) {
    .card-image-container {
        height: 160px;
    }
}
.room-card {
    padding: 1rem;
    border-radius: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    height: 100%;
    width: 200px;

}

.room-card:hover {
    transform: translateY(-5px);
    background: white;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.image-wrapper {
    width: 150px;
    height: 150px;
    margin: 0 auto;
    transition: transform 0.3s ease;
}

.room-card:hover .image-wrapper {
    transform: scale(1.1);
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.room-title {
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.room-card:hover .room-title {
    color: var(--bs-primary);
}

.room-desc {
    font-size: 0.85rem;
    line-height: 1.4;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .room-card {
        padding: 0.75rem;
    }
    
    .image-wrapper {
        width: 80px;
        height: 80px;
    }
}

@media (max-width: 576px) {
    .room-card {
        padding: 0.5rem;
    }
    
    .image-wrapper {
        width: 70px;
        height: 70px;
    }
}


.contact-section {
    position: relative;
    min-height: 700px;
}

/* Modern Map Styling */
.map-container {
    position: relative;
    width: 100%;
    height: 700px;
    overflow: hidden;
}

.modern-map {
    filter: grayscale(0.2) contrast(1.1) saturate(1.2);
    transition: filter 0.3s ease;
}

.map-container:hover .modern-map {
    filter: grayscale(0) contrast(1) saturate(1);
}

.map-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(15, 23, 42, 0.1) 0%,
        rgba(15, 23, 42, 0) 50%,
        rgba(15, 23, 42, 0.8) 100%
    );
    pointer-events: none;
    z-index: 2;
}

.map-controls {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 3;
}

.map-control-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 8px;
    background: white;
    color: #1f2937;
    font-size: 16px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-control-btn:hover {
    background: #3b82f6;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

/* Floating Cards Bottom */
.floating-cards-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 0 20px 40px;
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.floating-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    min-width: 320px;
    max-width: 380px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.floating-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color), var(--secondary-color));
}

.floating-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.25);
}

/* Card Types */
.contact-card::before {
    background: linear-gradient(90deg, #f59e0b, #d97706);
}

.delivery-card::before {
    background: linear-gradient(90deg, #10b981, #059669);
}

.operational-card::before {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

/* Card Header */
.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.contact-card .card-icon {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.delivery-card .card-icon {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.operational-card .card-icon {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

/* Contact Card Specific */
.contact-link {
    text-decoration: none;
    color: inherit;
    display: block;
    margin: 15px 0;
}

.card-phone {
    font-size: 2rem;
    font-weight: 800;
    margin: 0;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.card-desc {
    color: #6b7280;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.card-actions {
    display: flex;
    gap: 10px;
}

.action-btn {
    flex: 1;
    padding: 10px 16px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.whatsapp-btn {
    background: #25d366;
    color: white;
}

.whatsapp-btn:hover {
    background: #128c7e;
    transform: translateY(-2px);
}

.call-btn {
    background: #3b82f6;
    color: white;
}

.call-btn:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
}

/* Time Slots */
.time-slots {
    space-y: 16px;
}

.time-slot {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    border-radius: 12px;
    background: rgba(249, 250, 251, 0.8);
    border-left: 4px solid #e5e7eb;
    transition: all 0.3s ease;
}

.time-slot:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateX(5px);
}

.time-slot.highlight {
    background: rgba(16, 185, 129, 0.1);
    border-left-color: #10b981;
}

.time-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.time-slot.highlight .time-icon {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.time-info {
    flex: 1;
}

.time-info strong {
    display: block;
    color: #1f2937;
    font-size: 0.95rem;
    margin-bottom: 4px;
}

.time-info span {
    display: block;
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.time-info small {
    color: #9ca3af;
    font-size: 0.85rem;
}

.time-info em {
    display: block;
    color: #ef4444;
    font-size: 0.8rem;
    font-style: italic;
    margin-top: 4px;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .floating-cards-bottom {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 20px;
        scrollbar-width: none;
    }
    
    .floating-cards-bottom::-webkit-scrollbar {
        display: none;
    }
    
    .floating-card {
        min-width: 300px;
        flex-shrink: 0;
    }
}

@media (max-width: 768px) {
    .map-container {
        height: 500px;
    }
    
    .floating-cards-bottom {
        padding: 0 15px 20px;
        gap: 16px;
    }
    
    .floating-card {
        min-width: 280px;
        padding: 20px;
    }
    
    .card-phone {
        font-size: 1.75rem;
    }
    
    .card-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .map-container {
        height: 400px;
    }
    
    .floating-cards-bottom {
        padding: 0 10px 15px;
    }
    
    .floating-card {
        min-width: 100%;
        max-width: 100%;
    }
    
    .card-phone {
        font-size: 1.5rem;
    }
    
    .map-controls {
        top: 10px;
        right: 10px;
    }
    
    .map-control-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}

/* Animations */
@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.floating-card {
    animation: slideUpFade 0.6s ease forwards;
}

.floating-card:nth-child(1) { animation-delay: 0.1s; }
.floating-card:nth-child(2) { animation-delay: 0.2s; }
.floating-card:nth-child(3) { animation-delay: 0.3s; }


.toc-container {
    background: #2c3e50;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.toc-container.sticky-top {
    position: -webkit-sticky;
    position: sticky;
    top: 98px; /* Jarak dari atas saat menjadi sticky */
    z-index: 1000;
}

/* .toc-content {
    max-height: 400px;
    overflow-y: auto;
} */

.toc-content ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}

.toc-content li {
    margin-bottom: 8px;
}

.toc-content a {
    color: #ecf0f1;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.toc-content a:hover {
    color: #3498db;
}

.sticky-sidebar {
    position: -webkit-sticky;
    position: sticky;
    top: 100px; /* Jarak dari atas */
    height: fit-content;
    max-height: calc(100vh - 40px); /* Maksimal tinggi viewport minus margin */
    overflow-y: auto;
}

/* Style untuk TOC */
.toc-container {
    background: #ffffff;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
}

.toc-content ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toc-content li {
    margin-bottom: 0;
}

.toc-content a {
    color: #2c3e50;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
    display: block;
    padding: 4px 0;
    line-height: 1.4;
}

.toc-content a:hover {
    color: #3498db;
    background-color: #f8f9fa;
    padding-left: 8px;
    border-radius: 4px;
}

/* Style untuk different heading levels */
.toc-content .toc-level-h2 {
    padding-left: 0;
    font-weight: 600;
}

.toc-content .toc-level-h3 {
    padding-left: 15px;
    font-size: 13px;
}

.toc-content .toc-level-h4 {
    padding-left: 30px;
    font-size: 12px;
    color: #6c757d;
}

/* Optional: Jika ingin kedua card memiliki tinggi maksimal dan scroll internal */
@media (min-height: 800px) {
    .sticky-sidebar {
        max-height: 80vh;
    }
}

.article-card {
    transition: all 0.3s ease;
    border-radius: 16px;
    overflow: hidden;
}

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

.article-image {
    height: 220px;
    background: #f8f9fa;
}

.article-image img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .article-image img {
    transform: scale(1.05);
}

.article-overlay {
    transition: all 0.3s ease;
}

.article-card:hover .article-overlay {
    background: rgba(0,0,0,0.2);
}

.article-meta .avatar-xs {
    width: 36px;
    height: 36px;
}

.article-title {
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-card:hover .article-title {
    color: var(--bs-primary) !important;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bookmark-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.bookmark-btn:hover {
    background: rgba(59, 130, 246, 0.1);
    color: var(--bs-primary);
}

.bookmark-btn.active {
    background: var(--bs-primary);
    color: white;
}

.read-more {
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.read-more:hover {
    transform: translateX(5px);
}

.article-stats {
    font-size: 0.8rem;
}

.btn-hover {
    transition: all 0.3s ease;
}

.btn-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
}

/* Badge styling */
.badge {
    font-size: 0.7rem;
    padding: 4px 8px;
    border-radius: 6px;
    backdrop-filter: blur(10px);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .article-image {
        height: 180px;
    }
    
    .article-title {
        font-size: 1.1rem;
    }
    
    .d-flex.align-items-center.mb-5 {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .d-flex.align-items-center.mb-5 .btn {
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 576px) {
    .article-image {
        height: 160px;
    }
    
    .article-meta {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .article-footer .d-flex {
        flex-direction: column;
        gap: 0.5rem;
        align-items: start !important;
    }
}

/* Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.article-card {
    animation: fadeInUp 0.6s ease forwards;
}

.article-card:nth-child(1) { animation-delay: 0.1s; }
.article-card:nth-child(2) { animation-delay: 0.2s; }
.article-card:nth-child(3) { animation-delay: 0.3s; }
