/* Custom styles for the SaaS website 
Author: hadsonpar.com
Date: 2024-06-12
Version: 1.0.0
Documentation: www.hadsonpar.com/devtemplates/templates/free/saas/documentation.html
*/
/* ========== Base ========== */
body,
html {
    font-family: "Lato", sans-serif;
    scroll-behavior: smooth !important;
}

/* ========== Colors ========== */
.text-purple {
    color: #a855f7 !important;
}

.bg-purple {
    background-color: #a855f7 !important;
}

.btn-purple {
    background-color: #a855f7 !important;
    border-color: #a855f7 !important;
    color: #fff !important;
}

.btn-purple:hover {
    background-color: #9333ea !important;
    border-color: #9333ea !important;
}

.hover-purple-dark:hover {
    background-color: #9333ea !important;
    border-color: #9333ea !important;
}

/* ========== Sticky header (offset for anchor scroll) ========== */
.sticky-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* Offset anchor targets so the sticky header doesn't overlap the section title */
section[id] {
    scroll-margin-top: 100px;
}

/* ========== Hero ========== */
.hero-section {
    background: linear-gradient(to bottom, #000000, #020617);
}

.hero-content h2 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
}

/* ========== Gradient Projects ========== */
.gradiant-articles {
    background-color: #ffffff;
    background-image: radial-gradient(#db80ff 0.5px, transparent 0.5px),
        radial-gradient(#db80ff 0.5px, #ffffff 0.5px);
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
}

/* ========== Video Block ========== */
.video-block {
    background-image: url(../../assets/img/test.png);
    background-size: cover;
    background-position: center;
    border: 1px solid #000;
}

.video-block:hover span i {
    color: #fff;
}

/* ========== Nav links ========== */
.nav-link-custom {
    color: #4b5563 !important;
    transition: color 0.2s ease;
}

.nav-link-custom:hover {
    color: #ffffff !important;
}

.nav-link-custom.active-nav {
    color: #ffffff !important;
}

/* ========== Language switcher ========== */
.lang-switcher {
    font-size: 0.875rem;
    font-weight: 600;
}

.lang-btn {
    background: transparent;
    border: none;
    color: #6c757d;
    padding: 0.25rem 0.4rem;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    font-size: 0.875rem;
}

.lang-btn:hover {
    color: #a855f7;
}

.lang-btn.active {
    color: #a855f7;
    background-color: rgba(168, 85, 247, 0.15);
}

/* ========== CTA gradient ========== */
.cta-gradient {
    background: linear-gradient(to bottom, #ffffff, #d1d5db);
}

/* ========== Footer ========== */
.footer-link {
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: #a855f7 !important;
    text-decoration: underline !important;
}

.footer-social {
    transition: color 0.2s ease;
}

.footer-social:hover {
    color: #a855f7 !important;
}

/* ========== Project/Article images ========== */
.article-img {
    transition: transform 0.3s ease;
}

.article-img:hover {
    transform: scale(1.25);
}

.article-title {
    transition: color 0.2s ease;
}

.article-title:hover {
    color: #9333ea !important;
    text-decoration: underline !important;
}

.author-link {
    transition: color 0.2s ease;
}

.author-link:hover {
    color: #9333ea !important;
    text-decoration: underline !important;
}

/* ========== Icons ========== */
.icon-lg {
    width: 2rem;
    height: 2rem;
}

/* ========== Scroll marquee ========== */
.scroll {
    position: relative;
    display: flex;
    width: 100%;
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #fff 20%, #fff 80%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #fff 20%, #fff 80%, transparent);
}

.scroll div {
    display: flex;
    white-space: nowrap;
    animation: scroll var(--time) linear infinite;
    animation-delay: calc(var(--time) * -1);
}

.scroll div:nth-child(2) {
    animation: scroll2 var(--time) linear infinite;
    animation-delay: calc(var(--time) / -2);
}

@keyframes scroll {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

@keyframes scroll2 {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-200%);
    }
}

.imgBox div {
    display: flex;
    align-items: center;
    justify-content: center;
}

.imgBox img {
    max-width: 100px;
    scale: 0.8;
}

.grayscale {
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.grayscale:hover {
    filter: grayscale(0%);
}

/* ========== Back to top button ========== */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 999;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    border: none;
    background-color: #a855f7;
    color: #fff;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background-color 0.2s ease;
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.4);
}

.back-to-top:hover {
    background-color: #9333ea;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .hero-content {
        padding-bottom: 5rem !important;
    }

    .video-hero {
        margin-top: -100px !important;
    }
}

/*****************************************/
/* ========== Dashboard Layout ========== */
#wrapper {
    min-height: 100vh;
    overflow-x: hidden;
}

/* ========== Sidebar ========== */
.sidebar {
    width: 60px;
    background-color: #ffffff;
    border-right: 1px solid #e5e7eb;
    transition: all 0.3s;
}

.sidebar .nav-link {
    padding: 12px 0;
    border-radius: 8px;
    margin: 0 8px;
    transition: all 0.2s;
}

.sidebar .nav-link:hover {
    background-color: #f3f4f6;
    color: #a855f7 !important;
}

.sidebar .nav-link.active-icon {
    background-color: #e0f2fe; /* Azul claro para el ícono activo según la imagen */
    color: #0ea5e9 !important;
}

/* ========== Custom Purple Backgrounds ========== */
.bg-purple-light {
    background-color: rgba(168, 85, 247, 0.1);
}

.cursor-pointer {
    cursor: pointer;
}

.cursor-grab {
    cursor: grab;
}

/* ========== Page List ========== */
.custom-list-group .list-group-item {
    border: 1px solid #e5e7eb;
    margin-bottom: 8px;
    border-radius: 8px !important;
    transition: all 0.2s;
}

.custom-list-group .list-group-item:hover {
    border-color: #d1d5db;
    background-color: #f9fafb;
}

/* El primer elemento (Home) tiene un ligero fondo azul en la imagen */
.custom-list-group .list-group-item:first-child {
    background-color: #f0f7ff;
    border-color: #bfdbfe;
}

/* ========== Context Menu (Dropdown) ========== */
.context-menu {
    position: absolute;
    width: 250px;
    z-index: 1050;
    display: none;
    top: 0;
    left: 100%; /* Aparece a la derecha */
    margin-left: 10px;
}

.context-menu.show {
    display: block;
}

.context-item a {
    display: flex;
    align-items: center;
    padding: 8px 16px;
    color: #374151;
    text-decoration: none;
    font-size: 0.875rem;
    transition: background-color 0.2s;
}

.context-item a:hover {
    background-color: #f3f4f6;
}

.context-item.text-danger a {
    color: #ef4444;
}

.context-item.text-danger a:hover {
    background-color: #fef2f2;
}

.context-divider {
    height: 1px;
    background-color: #e5e7eb;
    margin: 6px 0;
}

/* ========== Utilities ========== */
.btn-sm i {
    font-size: 1.1rem;
    color: #9ca3af;
}

.btn-sm i:hover {
    color: #4b5563;
}

/* Scrollbar styling (opcional) */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1; 
}
::-webkit-scrollbar-thumb {
    background: #c1c1c1; 
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8; 
}