/*
Theme Name: NRNA Portugal
Theme URI: https://nrnportugal.org
Author: NRNA NCC Portugal Technical Team
Author URI: https://nrnportugal.org
Description: Official WordPress theme for Non-Resident Nepali Association (NRNA) National Coordination Council Portugal. Featuring high-performance responsive UI, dynamic WordPress Customizer management, emergency helpdesks, and diaspora welfare portals.
Version: 1.0.1
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nrn
Tags: responsive-layout, custom-menu, custom-logo, featured-images, theme-options, translation-ready
*/

/* ==========================================================================
   Base Styles, Animations & Swiper Overrides
   ========================================================================== */

.ticker-wrap {
    overflow: hidden;
    white-space: nowrap;
}

.ticker-move {
    display: inline-block;
    animation: ticker 32s linear infinite;
}

.ticker-move:hover {
    animation-play-state: paused;
}

@keyframes ticker {
    0% { transform: translate3d(100%, 0, 0); }
    100% { transform: translate3d(-100%, 0, 0); }
}

.tab-btn.active {
    background-color: #0d3b66;
    color: #ffffff;
    border-color: #0d3b66;
}

/* Swiper Mobile Sliders - Desktop CSS Grid Overrides */
@media (min-width: 768px) {
    .services-swiper.swiper,
    .projects-swiper.swiper {
        overflow: visible !important;
    }
    .services-swiper > .swiper-wrapper {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 2rem !important;
        transform: none !important;
        width: auto !important;
        box-sizing: border-box !important;
    }
    @media (min-width: 1024px) {
        .services-swiper > .swiper-wrapper {
            grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        }
    }
    .projects-swiper > .swiper-wrapper {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        gap: 2rem !important;
        transform: none !important;
        width: auto !important;
        box-sizing: border-box !important;
    }
    .services-swiper .swiper-slide,
    .projects-swiper .swiper-slide {
        width: auto !important;
        margin: 0 !important;
        height: 100% !important;
    }
}

@media (min-width: 640px) {
    .team-swiper.swiper {
        overflow: visible !important;
    }
    .team-swiper > .swiper-wrapper {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 1rem !important;
        transform: none !important;
        width: auto !important;
        box-sizing: border-box !important;
    }
    @media (min-width: 768px) {
        .team-swiper > .swiper-wrapper {
            grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
            gap: 1rem !important;
        }
    }
    @media (min-width: 1024px) {
        .team-swiper > .swiper-wrapper {
            grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
            gap: 1rem !important;
        }
    }
    .team-swiper .swiper-slide {
        width: auto !important;
        margin: 0 !important;
        height: 100% !important;
    }
}

/* Guaranteed visibility for slider cards and slides */
.team-swiper .swiper-slide,
.services-swiper .swiper-slide,
.projects-swiper .swiper-slide {
    opacity: 1 !important;
    visibility: visible !important;
}

.team-card,
.service-card,
.project-card {
    opacity: 1;
    visibility: visible;
}

/* Swiper Custom Pagination Bullets */
.services-swiper-pagination .swiper-pagination-bullet,
.projects-swiper-pagination .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    background-color: #cbd5e1;
    opacity: 1;
    margin: 0 3px !important;
    transition: all 0.3s ease;
    display: inline-block;
    cursor: pointer;
}

.services-swiper-pagination .swiper-pagination-bullet-active,
.projects-swiper-pagination .swiper-pagination-bullet-active {
    width: 24px;
    background-color: #0d3b66;
}

.team-swiper-pagination .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    background-color: #cbd5e1;
    opacity: 1;
    margin: 0 3px !important;
    transition: all 0.3s ease;
    display: inline-block;
    cursor: pointer;
}

.team-swiper-pagination .swiper-pagination-bullet-active {
    width: 24px;
    background-color: #d90429;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #0d3b66;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d90429;
}
.no-scrollbar::-webkit-scrollbar {
    display: none;
}
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Lenis Smooth Scroll Recommended Base */
html.lenis, html.lenis body {
    height: auto;
}
.lenis.lenis-smooth {
    scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}
.lenis.lenis-stopped {
    overflow: hidden;
}
.lenis.lenis-scrolling iframe {
    pointer-events: none;
}

/* Genjutsu 3D Spatial & Perspective Tokens */
.perspective-1000 {
    perspective: 1000px;
}
.preserve-3d {
    transform-style: preserve-3d;
}
.genjutsu-glow-hover {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.genjutsu-glow-hover:hover {
    box-shadow: 0 14px 30px -10px rgba(13, 59, 102, 0.25), 0 0 20px rgba(217, 4, 41, 0.15);
}

/* Fixed Navigation on Scroll with Smooth Slide Down Effect */
.main-bar-wraper.is-fixed {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    z-index: 990 !important;
    background-color: rgba(13, 59, 102, 0.96) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3) !important;
    animation: slideDownNav 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

@keyframes slideDownNav {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Performance: Content-Visibility Optimization for Below-the-Fold Sections */
.content-visibility-auto {
    content-visibility: auto;
    contain-intrinsic-size: 1px 600px;
}

/* Footer Quick Links Widget & Navigation Menu Styling */
.nrn-footer-quick-links-col ul,
.nrn-footer-quick-links-col .menu {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.nrn-footer-quick-links-col ul li,
.nrn-footer-quick-links-col .menu li {
    margin-bottom: 0.5rem;
    font-size: 0.8125rem;
    line-height: 1.25rem;
}

.nrn-footer-quick-links-col ul li:last-child,
.nrn-footer-quick-links-col .menu li:last-child {
    margin-bottom: 0;
}

.nrn-footer-quick-links-col a {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

.nrn-footer-quick-links-col a:hover,
.nrn-footer-quick-links-col a:focus {
    color: #ffffff !important;
    text-decoration: underline !important;
}

.nrn-footer-quick-links-col .sub-menu {
    padding-left: 0.75rem !important;
    margin-top: 0.375rem !important;
    border-left: 1px solid rgba(255, 255, 255, 0.15);
}

.nrn-footer-quick-links-col .widget {
    margin-bottom: 1.25rem;
}

.nrn-footer-quick-links-col .widget:last-child {
    margin-bottom: 0;
}

/* ==========================================================================
   Mobile Bottom Floating Dock & Mobile Drawer Sticky Footer
   ========================================================================== */
@media (max-width: 767.98px) {
    /* Mobile Floating Quick Action Dock - Pinned to Bottom Viewport */
    .nrn-mobile-dock {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 45 !important;
        width: 100% !important;
        max-width: 100vw !important;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.12) !important;
    }

    body {
        padding-bottom: 68px !important;
    }
}

/* Mobile Off-Canvas Drawer (100dvh & Sticky Drawer Footer) */
#mobile-menu-drawer {
    height: 100% !important;
    height: 100dvh !important;
    display: flex !important;
    flex-direction: column !important;
}

#mobile-menu-drawer .drawer-links-container {
    flex: 1 1 0% !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    overscroll-behavior: contain !important;
}

#mobile-menu-drawer .drawer-footer-actions {
    flex-shrink: 0 !important;
    position: sticky !important;
    bottom: 0 !important;
    z-index: 10 !important;
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.3) !important;
}

/* ==========================================================================
   WordPress Native Gallery Blocks & Shortcodes
   ========================================================================== */
.wp-block-gallery,
.blocks-gallery-grid,
.gallery {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)) !important;
    gap: 16px !important;
    margin: 24px 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.wp-block-gallery.columns-2,
.gallery-columns-2 {
    grid-template-columns: repeat(2, 1fr) !important;
}

.wp-block-gallery.columns-3,
.gallery-columns-3 {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)) !important;
}

.wp-block-gallery.columns-4,
.gallery-columns-4 {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) !important;
}

.wp-block-gallery .wp-block-image,
.blocks-gallery-item,
.gallery-item {
    margin: 0 !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    background-color: #f1f5f9 !important;
    position: relative !important;
}

.wp-block-gallery .wp-block-image:hover,
.blocks-gallery-item:hover,
.gallery-item:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 12px 25px rgba(13, 59, 102, 0.15) !important;
}

.wp-block-gallery .wp-block-image img,
.blocks-gallery-item img,
.gallery-item img {
    width: 100% !important;
    height: 220px !important;
    object-fit: cover !important;
    display: block !important;
    transition: transform 0.4s ease !important;
}

.wp-block-gallery .wp-block-image:hover img,
.blocks-gallery-item:hover img,
.gallery-item:hover img {
    transform: scale(1.04) !important;
}

.wp-block-gallery figcaption,
.blocks-gallery-item figcaption,
.gallery-caption {
    font-size: 11px !important;
    color: #475569 !important;
    padding: 8px 12px !important;
    text-align: center !important;
    background: #ffffff !important;
    line-height: 1.4 !important;
}

/* ==========================================================================
   About Page Dashboard Content Custom Typography (.nrn-about-content)
   ========================================================================== */
.nrn-about-content {
    font-size: 0.95rem;
    line-height: 1.85;
    color: #334155;
}

.nrn-about-content h1,
.nrn-about-content h2,
.nrn-about-content h3,
.nrn-about-content h4 {
    color: #0d3b66;
    font-weight: 800;
    line-height: 1.3;
/*     margin-top: 2rem; */
    margin-bottom: 0.75rem;
    letter-spacing: -0.015em;
}

.nrn-about-content h2 {
    font-size: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.nrn-about-content h3 {
    font-size: 1.25rem;
}

.nrn-about-content h4 {
    font-size: 1.1rem;
}

.nrn-about-content p {
    margin-bottom: 1.25rem;
    line-height: 1.85;
    color: #334155;
    text-align: justify;
}

.nrn-about-content strong,
.nrn-about-content b {
    color: #0d3b66;
    font-weight: 700;
}

.nrn-about-content ul {
    list-style: none !important;
    padding-left: 0 !important;
    margin: 1.25rem 0 !important;
}

.nrn-about-content ul > li {
    position: relative;
    padding: 0.65rem 1rem 0.65rem 2.4rem;
    margin-bottom: 0.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.85rem;
    color: #334155;
    font-size: 0.92rem;
    line-height: 1.6;
    transition: all 0.2s ease;
}

.nrn-about-content ul > li:hover {
    background: #ffffff;
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(13, 59, 102, 0.06);
    transform: translateX(3px);
}

.nrn-about-content ul > li::before {
    content: "✓";
    position: absolute;
    left: 0.85rem;
    top: 0.65rem;
    font-weight: 800;
    color: #d90429;
    font-size: 0.85rem;
}

.nrn-about-content ol {
    counter-reset: nrn-item;
    list-style: none !important;
    padding-left: 0 !important;
    margin: 1.25rem 0 !important;
}

.nrn-about-content ol > li {
    counter-increment: nrn-item;
    position: relative;
    padding: 0.75rem 1rem 0.75rem 3rem;
    margin-bottom: 0.6rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.85rem;
    color: #334155;
    font-size: 0.92rem;
    line-height: 1.6;
    transition: all 0.2s ease;
}

.nrn-about-content ol > li:hover {
    background: #ffffff;
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(13, 59, 102, 0.06);
    transform: translateX(3px);
}

.nrn-about-content ol > li::before {
    content: counter(nrn-item, decimal-leading-zero);
    position: absolute;
    left: 0.75rem;
    top: 0.75rem;
    font-size: 0.7rem;
    font-weight: 800;
    font-family: monospace;
    color: #0d3b66;
    background: #e2e8f0;
    padding: 0.15rem 0.4rem;
    border-radius: 0.4rem;
    line-height: 1;
}

.nrn-about-content blockquote {
    border-left: 4px solid #d90429 !important;
    background: linear-gradient(to right, #fef2f2, #ffffff) !important;
    padding: 1.25rem 1.5rem !important;
    border-radius: 0 1rem 1rem 0 !important;
    font-style: italic !important;
    color: #0d3b66 !important;
    font-weight: 600 !important;
    margin: 1.5rem 0 !important;
}

.nrn-about-content a {
    color: #0d3b66;
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 600;
    transition: color 0.2s ease;
}

.nrn-about-content a:hover {
    color: #d90429;
}

.gt_selector.notranslate {
  background: transparent;
  width: 100px;
  background: red;
  padding: 6px 7px;
  font-size: 14px;
}

