/* =========================================================
   CORPORA — Premium One-Page Template
   ========================================================= */

/* ---------- CSS VARIABLES (overridden by PHP) ---------- */
:root {
    --primary: #b87b2f;
    --primary-hover: #956322;
    --primary-light: #d4963a;
    --secondary: #536942;
    --bg-light: #f6f8f5;
    --dark: #1a1a1a;
    --dark-section: #1e2a1a;
    --footer-bg: #111111;
    --header-bg-normal: #1a1a1a;
    --header-bg-sticky: rgba(20,20,20,0.97);
    --header-bg-transparent: transparent;
    --header-text: #ffffff;
    --header-text-sticky: #ffffff;
    --text: #444444;
    --text-light: #6b6b6b;
    --white: #ffffff;
    --font-main: 'DM Sans', sans-serif;
    --font-heading: 'Forum', serif;
    --transition: all 0.3s ease;
    --shadow: 0 8px 30px rgba(0,0,0,0.10);
    --shadow-hover: 0 16px 45px rgba(0,0,0,0.18);
    --radius: 12px;
    --logo-height: 48px;
    --logo-height-sticky: 40px;
    --header-social-nav: #ffffff;
    --header-social-nav-sticky: #ffffff;
    --header-social-nav-hover: var(--primary);
}

/* ---------- RESET & BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { 
    overflow-x: hidden; 
    width: 100%;
}
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-main);
    color: var(--text);
    background: var(--white);
    overflow-x: hidden;
    line-height: 1.7;
}
img { max-width: 100%; height: auto; display: block; }
h1,h2,h3,h4,h5,h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--dark);
    line-height: 1.25;
}
a { text-decoration: none; transition: var(--transition); }

/* ---------- UTILITY ---------- */
.section-padding { padding: 100px 0; }
.section-padding-sm { padding: 70px 0; }
.text-primary-custom { color: var(--primary) !important; }
.bg-light-custom { background-color: var(--bg-light); }
.bg-dark-section { background-color: var(--dark-section); }
.bg-dark-custom { background-color: var(--dark); }

/* ---------- BUTTONS ---------- */
.btn-primary-custom {
    background: var(--primary);
    color: var(--white);
    border: 2px solid var(--primary);
    border-radius: 50px;
    padding: 13px 34px;
    font-weight: 600;
    font-size: 0.88rem;
    letter-spacing: 0.06em;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.btn-primary-custom:hover, .btn-primary-custom:focus {
    background: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}
.btn-outline-primary-custom {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    border-radius: 50px;
    padding: 13px 34px;
    font-weight: 600;
    font-size: 0.88rem;
    letter-spacing: 0.06em;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.btn-outline-primary-custom:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}
.btn-outline-white {
    background: transparent;
    color: var(--white);
    border: 2px solid rgba(255,255,255,0.7);
    border-radius: 50px;
    padding: 13px 34px;
    font-weight: 600;
    font-size: 0.88rem;
    letter-spacing: 0.06em;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.btn-outline-white:hover {
    background: rgba(255,255,255,0.15);
    border-color: var(--white);
    color: var(--white);
    transform: translateY(-2px);
}

/* ---------- SECTION TYPOGRAPHY ---------- */
.section-eyebrow {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 10px;
    display: block;
}
.section-eyebrow-light {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--primary-light);
    margin-bottom: 10px;
    display: block;
}

.section-divider-pro {
    height: 3px;
    width: 80px;
    background: linear-gradient(to right, var(--primary), rgba(121, 36, 210, 0));
    margin-bottom: 24px;
}
.section-divider-pro.mx-auto {
    background: linear-gradient(to right, rgba(121, 36, 210, 0), var(--primary) 50%, rgba(121, 36, 210, 0));
}
.section-title {
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--dark);
}
.section-title-light {
    font-size: clamp(1.85rem, 3.5vw, 2.8rem);
    font-weight: 700;
    color: var(--white);
    margin-bottom: 20px;
    line-height: 1.2;
}
.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-light);
    line-height: 1.8;
    max-width: 680px;
}
.section-subtitle-light {
    font-size: 1.05rem;
    color: rgba(255,255,255,0.75);
    line-height: 1.8;
    max-width: 680px;
}
.section-divider {
    width: 60px;
    height: 4px;
    background: var(--primary);
    border-radius: 4px;
    margin: 1.5rem 0 24px 0;
}
.section-divider.mx-auto { margin-left: auto; margin-right: auto; }

/* =========================================================
   HEADER / NAVBAR
   ========================================================= */
#mainNav {
    background: transparent;
    padding: 6px 0;
    transition: background 0.4s ease, padding 0.4s ease, box-shadow 0.4s ease;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1050;
}
#mainNav.nav-transparent {
    background: var(--header-bg-transparent) !important;
    padding: 6px 0;
}
#mainNav.nav-normal {
    background: var(--header-bg-normal) !important;
    padding: 0px 0;
}
#mainNav.nav-scrolled {
    background: var(--header-bg-sticky) !important;
    padding: 0;
    box-shadow: 0 4px 24px rgba(0,0,0,0.22);
}

/* Logo logic */
.navbar-brand { display: flex; align-items: center; gap: 12px; }
.site-logo-img {
    height: var(--logo-height);
    width: auto;
    object-fit: contain;
    transition: height 0.35s ease, opacity 0.3s ease;
}
#mainNav:not(.nav-scrolled) .logo-sticky { display: none !important; }
#mainNav.nav-scrolled .logo-main { display: none !important; }
#mainNav.nav-scrolled .logo-sticky { display: block !important; height: var(--logo-height-sticky); }
.logo-text-wrap { display: flex; flex-direction: column; line-height: 1.2; }
.logo-name {
    font-size: 1.22rem;
    font-weight: 700;
    color: var(--header-text);
    letter-spacing: 0.02em;
    transition: color 0.3s;
}
.logo-subtitle {
    font-size: 0.63rem;
    color: var(--primary-light);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
#mainNav.nav-scrolled .logo-name { color: var(--header-text-sticky); }

/* Nav links */
.navbar-nav .nav-link {
    font-weight: 500;
    font-size: 0.9rem;
    padding: 6px 12px !important;
    transition: color 0.25s, opacity 0.25s;
    opacity: 0.9;
}
/* States are now handled by render_dynamic_css() injected styles */

#mainNav.nav-scrolled .navbar-nav .nav-link {
    opacity: 0.9;
}

.navbar-toggler:focus, .navbar-toggler:active {
    outline: none !important;
    box-shadow: none !important;
}
#mainNav.nav-scrolled .navbar-toggler i { color: var(--header-text-sticky) !important; }

/* Dropdown */
.dropdown-menu {
    background: #1e1e1e;
    border: none;
    border-top: 3px solid var(--primary);
    border-radius: 0 0 10px 10px;
    box-shadow: var(--shadow);
    min-width: 220px;
    padding: 6px 0;
    animation: dropIn 0.2s ease;
}
@keyframes dropIn { from{opacity:0;transform:translateY(-6px)} to{opacity:1;transform:translateY(0)} }
.dropdown-item {
    color: rgba(255,255,255,0.82);
    font-size: 0.88rem;
    padding: 9px 20px;
    transition: var(--transition);
}
.dropdown-item:hover { background: rgba(255,255,255,0.08); color: var(--primary-light); }

/* Social icons in header */
.header-social { display: flex; align-items: center; gap: 4px; margin-left: 8px; }
.header-social a {
    font-size: 0.95rem;
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}
#mainNav:not(.nav-scrolled) .header-social a { color: var(--header-social-nav); }
#mainNav.nav-scrolled .header-social a { color: var(--header-social-nav-sticky); }
.header-social a:hover { 
    color: var(--header-social-nav-hover) !important; 
    background: rgba(255,255,255,0.1); 
}

/* CTA button nav */
.nav-cta {
    background: var(--primary);
    color: var(--white) !important;
    border-radius: 50px;
    padding: 9px 22px !important;
    font-weight: 600;
    font-size: 0.84rem !important;
    letter-spacing: 0.05em;
    margin-left: 8px;
    opacity: 1 !important;
}
.nav-cta:hover {
    background: var(--primary-hover) !important;
    color: var(--white) !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

/* Offcanvas mobile */
.offcanvas-menu { background: #1a1a1a; z-index: 1100 !important; }
.offcanvas-menu .nav-link {
    color: rgba(255,255,255,0.88) !important;
    font-size: 1.05rem;
    padding: 12px 0 !important;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}
.offcanvas-menu .nav-link:hover { color: var(--primary-light) !important; }
.offcanvas-menu .nav-cta {
    background: var(--primary);
    border-radius: 50px;
    text-align: center;
    margin-top: 8px;
    padding: 12px !important;
}
.offcanvas-menu .header-social { justify-content: center; padding: 16px 0; }
.offcanvas-menu .header-social a { width: 42px; height: 42px; font-size: 1.1rem; }

/* =========================================================
   HERO SECTION — SWIPER
   ========================================================= */
.hero-swiper {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    position: relative;
    overflow: hidden;
}
.hero-slide {
    height: 100vh;
    height: 100dvh;
    background: linear-gradient(135deg, var(--dark-section) 0%, var(--dark) 100%);
    background-size: cover;
    background-position: center center;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
    will-change: transform;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    /* Removed fixed background-gradient to allow dynamic control */
    z-index: 1;
}
.hero-slide .container { position: relative; z-index: 2; padding-top: 100px; padding-bottom: 60px; }

/* Alignment Support */
.hero-align-left { text-align: left; }
.hero-align-center { text-align: center; }
.hero-align-right { text-align: right; }

.hero-align-center .hero-subtitle { margin-left: auto !important; margin-right: auto !important; }
.hero-align-right .hero-subtitle { margin-left: auto !important; margin-right: 0 !important; }
.hero-align-center .hero-buttons { justify-content: center !important; }
.hero-align-right .hero-buttons { justify-content: flex-end !important; }

/* Video hero */
.hero-video-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}
.hero-video-wrap video,
.hero-video-wrap iframe {
    position: absolute;
    top: 50%; left: 50%;
    min-width: 100%; min-height: 100%;
    width: auto; height: auto;
    transform: translate(-50%, -50%);
    pointer-events: none;
}
.hero-video-wrap iframe { width: 100vw; height: 56.25vw; min-height: 100vh; min-width: 177.78vh; }

.hero-eyebrow {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--primary-light);
    margin-bottom: 18px;
    display: block;
}
.hero-title {
    font-size: clamp(2.4rem, 5.5vw, 4.2rem);
    font-weight: 700;
    color: var(--white);
    line-height: 1.12;
    margin-bottom: 24px;
    max-width: 100%; /* Allow it to be horizontal */
}
.hero-subtitle {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.82);
    max-width: 700px;
    line-height: 1.8;
    margin-bottom: 40px;
}
.hero-buttons { display: flex; flex-wrap: wrap; gap: 14px; }

/* Swiper navigation */
.hero-swiper .swiper-button-next,
.hero-swiper .swiper-button-prev {
    color: var(--primary-light);
    background: rgba(0,0,0,0.35);
    width: 50px; height: 50px;
    border-radius: 50%;
    backdrop-filter: blur(6px);
}
.hero-swiper .swiper-button-next::after,
.hero-swiper .swiper-button-prev::after { font-size: 1.1rem; font-weight: 900; }
.hero-swiper .swiper-pagination-bullet { background: rgba(255,255,255,0.5); opacity: 1; }
.hero-swiper .swiper-pagination-bullet-active { background: var(--primary-light); transform: scale(1.3); }

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}
.scroll-indicator a {
    color: rgba(255,255,255,0.5);
    font-size: 1.7rem;
    animation: bounce 2.2s infinite;
    display: block;
}
@keyframes bounce {
    0%,100%{transform:translateY(0);opacity:.5}
    50%{transform:translateY(9px);opacity:1}
}

/* =========================================================
   STATS BAR
   ========================================================= */
.stats-section {
    background: var(--primary);
    padding: 30px 0;
}
.stat-item { padding: 16px 24px; }
.stat-number {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 800;
    color: var(--white);
    line-height: 1;
    display: inline;
}
.stat-suffix {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    vertical-align: top;
    margin-top: 6px;
    display: inline;
}
.stat-label {
    font-size: 0.72rem;
    font-weight: 500;
    color: rgba(255,255,255,0.85);
    margin-top: 8px;
    margin-bottom: 0;
    letter-spacing: 0.04em;
}
.stat-sep { width: 1px; background: rgba(255,255,255,0.25); margin: 10px 0; }
.has-separator {
    position: relative;
}
@media (min-width: 992px) {
    .has-separator::after {
        content: "";
        position: absolute;
        top: 50%;
        right: -15px;
        transform: translateY(-50%);
        width: 1px;
        height: 60px;
        background: rgba(255,255,255,0.25);
    }
}

/* =========================================================
   ABOUT / QUIÉNES SOMOS — Modern Carousel Design
   ========================================================= */
.about-section { background: var(--white); }

/* Left carousel wrapper */
.about-carousel-wrap {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.14);
}
.about-swiper { border-radius: 20px; overflow: hidden; }
.about-swiper .swiper-slide img {
    width: 100%;
    height: 520px;
    object-fit: cover;
    display: block;
}
.about-swiper .swiper-pagination { bottom: 16px; }
.about-swiper .swiper-pagination-bullet {
    background: rgba(255,255,255,0.6);
    opacity: 1;
    width: 8px; height: 8px;
}
.about-swiper .swiper-pagination-bullet-active {
    background: var(--primary-light);
    width: 22px;
    border-radius: 4px;
}

/* Floating badge */
.about-badge {
    position: absolute;
    bottom: 24px;
    right: -20px;
    z-index: 10;
    background: var(--primary);
    color: var(--white);
    padding: 18px 22px;
    border-radius: var(--radius);
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    min-width: 110px;
}
.about-badge-num { display: block; font-size: 2.2rem; font-weight: 800; line-height: 1; }
.about-badge-text { font-size: 0.76rem; line-height: 1.3; font-weight: 500; }

/* Right content */
.about-content { padding-left: 20px; }
.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    margin-bottom: 10px;
    border-radius: 10px;
    background: var(--bg-light);
    font-size: 0.95rem;
    color: var(--text);
    transition: var(--transition);
}
.feature-item:hover { background: color-mix(in srgb, var(--primary) 8%, white); }
.feature-item i { color: var(--primary); font-size: 1.1rem; flex-shrink: 0; }

/* CTA Button in About */
.about-cta-wrap { margin-top: 32px; display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.about-cta-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 500;
}
.about-cta-divider::before,
.about-cta-divider::after {
    content: '';
    display: block;
    width: 30px;
    height: 1px;
    background: var(--text-light);
    opacity: 0.4;
}

/* =========================================================
   SERVICES SECTION
   ========================================================= */
.service-card {
    background: #0c0c0c;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--primary) 20%, transparent);
}
.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-light);
    box-shadow: 0 15px 45px color-mix(in srgb, var(--primary) 15%, transparent);
}
.service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(to right, var(--primary), var(--primary-light));
    opacity: 0;
    transition: opacity 0.4s;
}
.service-card:hover::before { opacity: 1; }


.service-icon-wrap {
    width: 68px; height: 68px;
    background: rgba(var(--primary-rgb, 184,123,47), 0.1);
    background: color-mix(in srgb, var(--primary) 12%, transparent);
    border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 22px;
    font-size: 1.7rem;
    color: var(--primary);
    transition: var(--transition);
}
.service-card:hover .service-icon-wrap {
    background: var(--primary);
    color: var(--white);
}
.service-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
    transition: color 0.3s;
}
.service-card:hover .service-card-title { color: var(--primary-light); }
.service-card-text {
    font-size: 0.92rem;
    color: rgba(255,255,255,0.7) !important;
    line-height: 1.7;
    margin-bottom: 24px;
    flex: 1;
}
.service-link {
    font-weight: 700;
    color: var(--primary-light) !important;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    margin-top: 20px;
}
.service-link:hover { color: var(--primary) !important; gap: 12px; }

/* =========================================================
   SERVICE DETAIL PAGE
   ========================================================= */
.service-detail-hero {
    background: var(--dark-section);
    padding: 140px 0 80px;
    position: relative;
    overflow: hidden;
}
.service-detail-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.6), rgba(0,0,0,0.3));
}
.service-detail-hero .container { position: relative; z-index: 1; }

.service-content-section { padding: 90px 0; }
.service-text-block p {
    font-size: 1.02rem;
    line-height: 1.85;
    color: var(--text);
    margin-bottom: 18px;
}
.service-img-block {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-hover);
}
.service-img-block img {
    width: 100%;
    height: 480px;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.service-img-block:hover img { transform: scale(1.03); }

.service-video-wrap {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-hover);
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    background: #000;
}
.service-video-wrap iframe,
.service-video-wrap video {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}

.team-card {
    background: #000000;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(121, 36, 210, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
}
.team-card:hover {
    box-shadow: 0 15px 45px color-mix(in srgb, var(--primary) 25%, transparent);
    transform: translateY(-10px);
    border-color: var(--primary-light);
}
.team-img-wrap {
    position: relative;
    width: 100%;
    padding-bottom: 110%;
    overflow: hidden;
    background: #050505;
}
.team-img-wrap img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center;
    transition: transform 0.45s ease;
    display: block;
}
.team-card:hover .team-img-wrap img { transform: scale(1.05); }

/* Social icons visible by default, subtle */
.team-social {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transform: translateX(50px);
    opacity: 0;
    transition: all 0.3s ease;
}
.team-card:hover .team-social { transform: translateX(0); opacity: 1; }
.team-social a {
    width: 36px; height: 36px;
    background: rgba(121, 36, 210, 0.8);
    color: #fff;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem;
    transition: all 0.3s;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.1);
}
.team-social a:hover { background: #3bb4ec; color: #fff; transform: scale(1.15) rotate(5deg); }

.team-info {
    padding: 20px;
    text-align: center;
    border-top: 1px solid rgba(121, 36, 210, 0.1);
}
.team-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 5px;
    letter-spacing: 0.5px;
}
.team-role {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    color: #3bb4ec;
    margin-bottom: 0;
}
.team-bio {
    font-size: 0.78rem;
    color: var(--text-light);
    line-height: 1.5;
    margin-top: 6px;
    margin-bottom: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Social row below info (Mobile only) */
.team-social-row {
    display: none;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(0,0,0,0.06);
}
.team-social-row a {
    width: 30px; height: 30px;
    background: var(--bg-light);
    color: var(--text-light);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.78rem;
    transition: var(--transition);
}
.team-social-row a:hover { background: var(--primary); color: var(--white); }

/* Responsive Toggles for Team Socials */
@media (max-width: 991px) {
    .team-social { display: none !important; }
    .team-social-row { display: flex !important; }
}

/* =========================================================
   GALLERY SECTION
   ========================================================= */
.gallery-grid { 
    display: grid; 
    grid-template-columns: repeat(4, 1fr); 
    gap: 16px; 
}

@media (max-width: 1200px) {
    .gallery-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 991px) {
    .gallery-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 576px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
}

.gallery-item {
    border-radius: var(--radius);
    overflow: hidden;
    position: relative;
    cursor: pointer;
    aspect-ratio: 1 / 1;
    background: var(--dark);
}
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}
.gallery-item-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent 55%);
    opacity: 0;
    transition: opacity 0.35s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.gallery-item:hover img { transform: scale(1.08); }
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-zoom-icon { 
    width: 52px; height: 52px; 
    background: var(--primary); 
    color: var(--white); 
    border-radius: 50%; 
    display: flex; align-items: center; justify-content: center; 
    font-size: 1.3rem; 
    transform: scale(0.7); 
    transition: transform 0.3s ease; 
}
.gallery-item:hover .gallery-zoom-icon { transform: scale(1); }
.gallery-title-label { display: none; }

/* Gallery filter tabs */
.gallery-filters { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 40px; }
.gallery-filter-btn {
    padding: 8px 22px;
    border-radius: 50px;
    border: 2px solid rgba(0,0,0,0.12);
    background: transparent;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition);
}
.gallery-filter-btn.active,
.gallery-filter-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

/* =========================================================
   PORTFOLIO SECTION — Modern Cards
   ========================================================= */
.portfolio-card {
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: block;
    text-decoration: none;
    background: var(--white);
    border: 1px solid rgba(0,0,0,0.06);
}
.portfolio-card:hover {
    box-shadow: 0 16px 48px rgba(0,0,0,0.18);
    transform: translateY(-8px);
}
.portfolio-img-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/3;
    background: var(--dark);
}
.portfolio-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.portfolio-card:hover .portfolio-img-wrap img { transform: scale(1.08); }

/* Overlay with gradient */
.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0,0,0,0.85) 0%,
        rgba(0,0,0,0.4) 45%,
        transparent 70%
    );
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.portfolio-card:hover .portfolio-overlay { opacity: 1; }
.portfolio-overlay-link {
    color: var(--white);
    font-size: 0.9rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--primary);
    padding: 9px 20px;
    border-radius: 50px;
    width: fit-content;
    transition: var(--transition);
}
.portfolio-overlay-link:hover { background: var(--primary-hover); gap: 12px; }

/* Category tag on top */
.portfolio-cat-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(255,255,255,0.95);
    color: var(--primary);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 5px 12px;
    border-radius: 50px;
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 2;
}

.portfolio-info {
    padding: 18px 20px 20px;
    background: var(--white);
}
.portfolio-cat {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 6px;
}
.portfolio-title {
    font-size: 1.08rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0;
    line-height: 1.3;
}

/* =================== SERVICE PAGE REDESIGN =================== */
.service-banner {
    position: relative;
    height: 480px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--white);
    text-align: center;
}
.service-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 50%, transparent) 0%, color-mix(in srgb, var(--primary-light) 30%, transparent) 50%, rgba(12, 12, 12, 0.8) 100%);
    z-index: 1;
}
.service-banner-content { position: relative; z-index: 2; padding-top: 80px; }
.service-banner-title { font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 800; margin-bottom: 15px; color: #ffffff !important; }

.service-detail-section { padding: 90px 0; background: var(--white); }
.service-text-content { font-size: 1.12rem; color: #555; line-height: 1.8; }
.service-text-content h3 { margin-bottom: 25px; font-weight: 700; color: var(--dark); position: relative; padding-bottom: 12px; }
.service-text-content h3::after { content: ''; position: absolute; bottom: 0; left: 0; width: 60px; height: 3px; background: var(--primary); }

.service-gallery-wrap { position: sticky; top: 120px; }
.service-swiper { border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-hover); }
.service-swiper .swiper-slide img { width: 100%; height: 550px; object-fit: cover; }
.service-swiper .swiper-button-next, .service-swiper .swiper-button-prev { background: rgba(0,0,0,0.4); width: 40px; height: 40px; border-radius: 50%; color: var(--white); }
.service-swiper .swiper-button-next::after, .service-swiper .swiper-button-prev::after { font-size: 1rem; }

/* YouTube Section */
.service-video-section { padding: 80px 0; background: var(--bg-light); border-top: 1px solid #eee; }
.video-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; border-radius: 20px; box-shadow: var(--shadow-hover); max-width: 1000px; margin: 0 auto; }
.video-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0; }

/* Admin Gallery Grid */
.gallery-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 15px; margin-top: 15px; }
.gallery-admin-item { position: relative; border-radius: 10px; overflow: hidden; border: 1px solid #eee; height: 130px; }
.gallery-admin-item img { width: 100%; height: 100%; object-fit: cover; }
.btn-del-gal { position: absolute; top: 5px; right: 5px; width: 26px; height: 26px; background: #e74c3c; color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .8rem; transition: .2s; }
.btn-del-gal:hover { background: #c0392b; transform: scale(1.1); }

/* Portfolio detail page */
.portfolio-detail-hero {
    background: var(--dark);
    padding: 140px 0 80px;
    position: relative;
}
.portfolio-detail-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.65), rgba(0,0,0,0.35));
}
.portfolio-detail-hero .container { position: relative; z-index: 1; }
.portfolio-detail-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; margin-top: 40px; }
.portfolio-detail-gallery a {
    border-radius: var(--radius);
    overflow: hidden;
    display: block;
    aspect-ratio: 4/3;
}
.portfolio-detail-gallery img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}
.portfolio-detail-gallery a:hover img { transform: scale(1.06); }

/* =========================================================
   CONTACT SECTION — Modern Design
   ========================================================= */
.contact-section-wrap {
    background: linear-gradient(135deg, var(--dark-section) 0%, var(--dark) 100%);
    position: relative;
    overflow: hidden;
}


.contact-form-wrap {
    background: #0c0c0c;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 48px 44px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    position: relative;
    z-index: 1;
}
.contact-info-box {
    transition: all 0.4s ease;
    border-radius: 20px;
    padding: 44px 36px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    z-index: 1;
}
.contact-info-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(121, 36, 210, 0.3);
}
.contact-info-box::before {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 200px; height: 200px;
    background: rgba(255,255,255,0.07);
    border-radius: 50%;
    pointer-events: none;
}
.contact-info-box::after {
    content: '';
    position: absolute;
    bottom: -50px; left: -30px;
    width: 180px; height: 180px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    pointer-events: none;
}
.contact-info-title { color: var(--white); font-size: 1.4rem; font-weight: 700; margin-bottom: 10px; }
.contact-info-subtitle { color: rgba(255,255,255,0.78); font-size: 0.95rem; line-height: 1.7; margin-bottom: 32px; }
.contact-info-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 22px;
    color: rgba(255,255,255,0.9);
    position: relative;
    z-index: 1;
}
.contact-info-item .ci-icon {
    width: 40px; height: 40px;
    background: rgba(255,255,255,0.15);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.05rem;
    flex-shrink: 0;
}
.contact-info-item span { font-size: 0.93rem; line-height: 1.6; padding-top: 8px; }
.contact-social {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: auto;
    padding-top: 28px;
    border-top: 1px solid rgba(255,255,255,0.2);
    position: relative;
    z-index: 1;
}
.contact-social a {
    width: 40px; height: 40px;
    background: rgba(255,255,255,0.15);
    color: var(--white);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.95rem;
    transition: var(--transition);
}
.contact-social a:hover { background: rgba(255,255,255,0.3); transform: translateY(-3px); }

/* Form elements */
.form-control-custom {
    width: 100%;
    padding: 13px 18px;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    font-family: var(--font-main);
    font-size: 0.93rem;
    color: var(--white);
    transition: all 0.25s;
    background: rgba(255,255,255,0.03);
    outline: none;
    -webkit-appearance: none;
}
.form-control-custom:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 20%, transparent);
    background: rgba(255,255,255,0.07);
}
.form-control-custom::placeholder { color: rgba(255,255,255,0.3); }
.form-group { margin-bottom: 18px; }
.form-label-custom { display: block; font-size: 0.82rem; font-weight: 700; color: rgba(255,255,255,0.8); margin-bottom: 6px; letter-spacing: 0.03em; }
.form-alert {
    padding: 14px 18px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.form-alert-success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.form-alert-error { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

/* Submit button full width */
.btn-contact-submit {
    width: 100%;
    background: var(--primary);
    transition: all 0.3s ease;
    color: var(--white);
    border: none;
    border-radius: 12px;
    padding: 15px 34px;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
}
.btn-contact-submit:hover {
    background: var(--primary-hover);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px color-mix(in srgb, var(--primary) 40%, transparent);
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
    background: var(--footer-bg);
    padding: 70px 0 30px;
    color: rgba(255,255,255,0.7);
}
.footer-brand-text { color: var(--white); font-size: 1.15rem; font-weight: 700; margin-bottom: 4px; }
.footer-brand-sub { font-size: 0.8rem; color: var(--primary-light); letter-spacing: 0.08em; text-transform: uppercase; }
.footer-desc { font-size: 0.9rem; color: rgba(255,255,255,0.6); line-height: 1.75; margin-top: 14px; }
.footer-heading { color: var(--white); font-size: 0.88rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 20px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}
.footer-links a:hover { color: var(--primary-light); gap: 10px; }
.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
}
.footer-contact-item i { color: var(--primary-light); flex-shrink: 0; margin-top: 2px; }
.footer-social { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.footer-social a {
    width: 38px; height: 38px;
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.7);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem;
    transition: var(--transition);
}
.footer-social a:hover { background: var(--primary); color: var(--white); transform: translateY(-3px); }
.footer-divider { border-color: rgba(255,255,255,0.1); margin: 40px 0 24px; }
.footer-bottom { font-size: 0.82rem; color: rgba(255,255,255,0.45); }
.footer-logo-img { height: 44px; width: auto; object-fit: contain; filter: brightness(0) invert(1); opacity: 0.85; }

/* =========================================================
   WHATSAPP FLOAT
   ========================================================= */
.whatsapp-float {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 9999;
    width: 58px; height: 58px;
    background: #25d366;
    color: var(--white);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.7rem;
    box-shadow: 0 6px 24px rgba(37,211,102,0.45);
    transition: var(--transition);
    animation: waPulse 3s infinite;
}
.whatsapp-float:hover {
    background: #1ebe5d;
    color: var(--white);
    transform: scale(1.1) translateY(-3px);
    box-shadow: 0 10px 30px rgba(37,211,102,0.55);
    animation: none;
}
@keyframes waPulse {
    0%,100%{box-shadow:0 6px 24px rgba(37,211,102,.45)}
    50%{box-shadow:0 6px 32px rgba(37,211,102,.7),0 0 0 10px rgba(37,211,102,.12)}
}

/* =========================================================
   MAP SECTION
   ========================================================= */
.map-embed-wrap { border-radius: var(--radius); overflow: hidden; height: 380px; }
.map-embed-wrap iframe { width: 100%; height: 100%; border: none; }

/* =========================================================
   BREADCRUMB
   ========================================================= */
.breadcrumb-custom {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.65);
    list-style: none;
    padding: 0;
    margin: 0;
}
.breadcrumb-custom li::after { content: '/'; margin-left: 8px; opacity: 0.5; }
.breadcrumb-custom li:last-child::after { content: ''; }
.breadcrumb-custom a { color: rgba(255,255,255,0.75); }
.breadcrumb-custom a:hover { color: var(--primary-light); }

/* =========================================================
   ALERT MESSAGES (onpage)
   ========================================================= */
.alert-fixed {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    min-width: 320px;
    max-width: 90vw;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 22px;
    font-weight: 500;
    animation: slideUp 0.4s ease;
}
@keyframes slideUp { from{transform:translateX(-50%) translateY(30px);opacity:0} to{transform:translateX(-50%) translateY(0);opacity:1} }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 991.98px) {
    .hero-slide { background-attachment: scroll; }
    .about-swiper .swiper-slide img { height: 380px; }
    .about-badge { right: 10px; bottom: 16px; }
    .about-content { padding-left: 0; margin-top: 40px; }
    .service-img-block img { height: 320px; }
    .contact-form-wrap { padding: 32px 28px; }
    .contact-info-box { padding: 32px 28px; }
    .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
}
@media (max-width: 767.98px) {
    .section-padding { padding: 70px 0; }
    .hero-title { font-size: 2.1rem; }
    .hero-subtitle { font-size: 1rem; }
    .about-swiper .swiper-slide img { height: 300px; }
    .about-badge { right: 8px; padding: 12px 16px; }
    .about-badge-num { font-size: 1.7rem; }
    .team-img-wrap img { height: 100%; }
    .contact-form-wrap { padding: 28px 20px; }
    .contact-info-box { padding: 28px 20px; }
    .footer-brand-text { font-size: 1rem; }
    .hero-swiper .swiper-button-next,
    .hero-swiper .swiper-button-prev { display: none; }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
    .portfolio-detail-gallery { grid-template-columns: repeat(2, 1fr); }
    .contact-section-wrap::before,
    .contact-section-wrap::after { display: none; }
}
@media (max-width: 575.98px) {
    .gallery-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .contact-form-wrap { padding: 22px 16px; }
    .stat-item { padding: 12px 10px; }
    .btn-primary-custom, .btn-outline-primary-custom, .btn-outline-white { padding: 11px 24px; font-size: 0.85rem; }
    .portfolio-card { border-radius: 12px; }
    .team-card { border-radius: 12px; }
    .btn-contact-submit { font-size: 0.9rem; padding: 13px 20px; }
}
