/* ============================================ */
/* INTERACTIVE QUICK LINKS STYLES               */
/* ============================================ */

.quick-links {
    gap: 20px;
}

.quick-link-item {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: white;
    padding: 12px 24px;
    border-radius: 60px;
    box-shadow: 0 5px 15px -5px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    text-decoration: none;
    overflow: hidden;
    isolation: isolate;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

/* Hover effect: lift, shadow, scale */
.quick-link-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 20px 30px -12px rgba(0, 0, 0, 0.15);
    border-color: transparent;
}

/* Icon animation on hover */
.quick-link-item:hover .link-icon i {
    transform: translateY(-2px) scale(1.1);
    transition: transform 0.2s ease;
}

/* Arrow slide-in on hover */
.link-arrow {
    opacity: 0;
    width: 0;
    transition: all 0.25s ease;
    overflow: hidden;
    white-space: nowrap;
}

.quick-link-item:hover .link-arrow {
    opacity: 1;
    width: 20px;
    margin-left: 5px;
}

/* Link text color transition */
.link-text {
    font-weight: 600;
    transition: color 0.2s ease;
}

/* Individual hover colors */
.quick-link-item:hover .link-icon i {
    color: white;
}

.quick-link-item:hover .link-text {
    color: white;
}

/* Different hover backgrounds */
.quick-link-item:hover {
    background: #1e3a8a; /* default primary */
}
.quick-link-item:hover .link-icon i {
    color: white;
}

/* Custom hover backgrounds per link */
.quick-link-item:nth-child(1):hover { background: #1e3a8a; }  /* e-Participation */
.quick-link-item:nth-child(2):hover { background: #9333ea; }  /* Sentuhan Kasih */
.quick-link-item:nth-child(3):hover { background: #0d9488; }  /* Ekonomi Biru */
.quick-link-item:nth-child(4):hover { background: #db2777; }  /* Galeri Media */
.quick-link-item:nth-child(5):hover { background: #0f172a; }  /* Carta Organisasi */

/* Tooltip style */
.quick-link-item[data-tooltip] {
    position: relative;
}

.quick-link-item[data-tooltip]::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: #0f172a;
    color: white;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 20px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.2s ease;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.quick-link-item[data-tooltip]:hover::before {
    opacity: 1;
    transform: translateX(-50%) translateY(-12px);
}

/* Ripple effect (requires JS) */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: scale(0);
    animation: ripple-animation 0.6s linear;
    pointer-events: none;
    z-index: 1;
}

@keyframes ripple-animation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Loading state on click */
.quick-link-item.loading {
    pointer-events: none;
    opacity: 0.7;
    transform: scale(0.98);
}

.quick-link-item.loading .link-text::after {
    content: "...";
    animation: dots 1s steps(3, end) infinite;
    display: inline-block;
    width: 20px;
}

@keyframes dots {
    0%, 20% { content: ""; }
    40% { content: "."; }
    60% { content: ".."; }
    80%, 100% { content: "..."; }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .quick-link-item {
        padding: 10px 20px;
        gap: 8px;
        width: 100%;
        justify-content: center;
    }

    .link-arrow {
        display: none;
    }

    .quick-link-item[data-tooltip]::before {
        display: none;
    }
}