/* ========================================
   PODCAST FACTORY - Main Stylesheet
   Design replica of mediaproductions.ro
   ======================================== */

/* ---------- CSS Reset & Variables ---------- */
:root {
    --primary: #e8751a;
    --primary-dark: #c9610f;
    --primary-light: #f5923d;
    --dark: #1a1a1a;
    --darker: #111111;
    --dark-gray: #2a2a2a;
    --medium-gray: #888888;
    --light-gray: #cccccc;
    --white: #ffffff;
    --off-white: #f5f5f5;
    --font-main: 'Montserrat', sans-serif;
    --transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --shadow: 0 10px 40px rgba(0,0,0,0.15);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.25);
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    font-family: var(--font-main);
    background: var(--darker);
    color: var(--white);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ---------- Preloader ---------- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--darker);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#preloader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    width: 50px;
    height: 50px;
    border: 3px solid var(--dark-gray);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ---------- Header / Navigation ---------- */
#header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999;
    padding: 20px 0;
    transition: var(--transition);
    background: transparent;
}

#header.scrolled {
    background: rgba(17, 17, 17, 0.97);
    padding: 12px 0;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 2px 30px rgba(0,0,0,0.3);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
}

.header-logo img {
    height: 80px;
    width: auto;
    transition: var(--transition);
}

#header.scrolled .header-logo img {
    height: 50px;
}

/* Desktop Navigation */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-top: 10px;
}

.nav-menu a {
    color: var(--white);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 10px 18px;
    position: relative;
    transition: var(--transition);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 60%;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
    padding: 5px;
    z-index: 10001;
}

.hamburger span {
    width: 28px;
    height: 2px;
    background: var(--white);
    transition: var(--transition);
    transform-origin: center;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: rgba(17, 17, 17, 0.98);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    z-index: 10000;
    transition: right 0.5s cubic-bezier(0.77, 0, 0.175, 1);
}

.mobile-menu-close {
    position: absolute;
    top: 30px;
    right: 30px;
    color: var(--white);
    font-size: 2rem;
    cursor: pointer;
    z-index: 10001;
    transition: var(--transition);
}

.mobile-menu-close:hover {
    color: var(--primary);
    transform: rotate(90deg);
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu a {
    color: var(--white);
    font-size: 1.4rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    padding: 15px 20px;
    transition: var(--transition);
    opacity: 0;
    transform: translateY(20px);
}

.mobile-menu.active a {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.active a:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu.active a:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu.active a:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu.active a:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu.active a:nth-child(5) { transition-delay: 0.3s; }
.mobile-menu.active a:nth-child(6) { transition-delay: 0.35s; }

.mobile-menu a:hover {
    color: var(--primary);
}

/* ---------- Hero Section ---------- */
#hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(17, 17, 17, 0.5) 0%,
        rgba(17, 17, 17, 0.65) 50%,
        rgba(17, 17, 17, 0.85) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 0 20px;
}

.hero-content .hero-logo {
    max-width: 500px;
    width: 80%;
    margin: 0 auto;
    animation: fadeInUp 1.2s ease;
}

.hero-content h1 {
    display: none;
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--white);
    letter-spacing: 2px;
    margin: 20px 0 10px;
    text-transform: uppercase;
    text-shadow: 0 4px 15px rgba(0,0,0,0.5);
    animation: fadeInUp 1.4s ease;
}

.hero-content .hero-subtitle {
    font-size: 1.2rem;
    color: var(--light-gray);
    letter-spacing: 4px;
    text-transform: uppercase;
    animation: fadeInUp 1.6s ease;
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    animation: bounce 2s infinite;
}

.hero-scroll-indicator span {
    display: block;
    width: 24px;
    height: 24px;
    border-right: 2px solid var(--white);
    border-bottom: 2px solid var(--white);
    transform: rotate(45deg);
    opacity: 0.5;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-15px); }
    60% { transform: translateX(-50%) translateY(-7px); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ---------- Section Common ---------- */
.section {
    padding: 100px 0;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 60px;
    position: relative;
    color: var(--white);
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--primary);
    margin: 20px auto 0;
}

/* ---------- About Section ---------- */
#despre {
    background: var(--darker);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text p {
    color: var(--light-gray);
    font-size: 0.95rem;
    line-height: 1.9;
    margin-bottom: 20px;
    text-align: justify;
}

.about-slider-container {
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.about-card-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: #0a0a0a;
    cursor: pointer;
}

.about-card-slider:hover .card-slider-prev,
.about-card-slider:hover .card-slider-next {
    opacity: 1;
}

/* ---------- Services Section ---------- */
#servicii {
    background: var(--dark);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-card {
    background: var(--dark-gray);
    padding: 40px 25px;
    border-radius: 4px;
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card .service-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    display: block;
}

.service-card h3.service-title-sub {
    font-size: 1.05rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    color: var(--white);
}

.service-card p.service-desc-text {
    font-size: 0.9rem;
    color: var(--medium-gray);
    line-height: 1.6;
}

/* ---------- Studio Section (Card Grid) ---------- */
#studio {
    background: var(--darker);
    overflow: hidden;
}

.studio-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.studio-card {
    background: var(--dark-gray);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

.studio-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4), 0 0 0 1px rgba(232, 117, 26, 0.15);
}

/* Card Slider */
.studio-card-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: #0a0a0a;
    cursor: pointer;
}

.card-slider-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.card-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.card-slide.active {
    opacity: 1;
}

.card-slider-prev, .card-slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: rgba(255,255,255,0.8);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    z-index: 5;
    transition: var(--transition);
    opacity: 0;
    user-select: none;
}

.studio-card:hover .card-slider-prev,
.studio-card:hover .card-slider-next {
    opacity: 1;
}

.card-slider-prev { left: 10px; }
.card-slider-next { right: 10px; }

.card-slider-prev:hover, .card-slider-next:hover {
    background: var(--primary);
    color: #fff;
}

/* Dots */
.card-slider-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 5;
}

.card-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
    cursor: pointer;
    transition: var(--transition);
}

.card-dot.active {
    background: var(--primary);
    transform: scale(1.3);
}

.card-dot:hover {
    background: rgba(255,255,255,0.7);
}

/* Card Body */
.studio-card-body {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.studio-card-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--white);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 12px 0;
}

.studio-card-desc {
    font-size: 0.88rem;
    color: var(--light-gray);
    line-height: 1.7;
    margin: 0 0 20px 0;
    flex: 1;
}

.studio-card-btn {
    display: inline-block;
    padding: 12px 28px;
    background: transparent;
    color: var(--primary);
    font-family: var(--font-main);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: 2px solid var(--primary);
    border-radius: 3px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    text-decoration: none;
    align-self: flex-start;
}

.studio-card-btn:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(232, 117, 26, 0.3);
}

/* ---------- Buttons (General) ---------- */
.btn-primary {
    display: inline-block;
    padding: 14px 40px;
    background: var(--primary);
    color: var(--white);
    font-family: var(--font-main);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: 2px solid var(--primary);
    border-radius: 3px;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    margin-top: 15px;
    text-decoration: none;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(232, 117, 26, 0.35);
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-outline {
    display: inline-block;
    padding: 14px 40px;
    background: transparent;
    color: var(--white);
    font-family: var(--font-main);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    border: 2px solid var(--white);
    border-radius: 3px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-outline:hover {
    background: var(--white);
    color: var(--dark);
    transform: translateY(-2px);
}

/* ---------- Portfolio Section ---------- */
#portofoliu {
    background: var(--dark);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    cursor: pointer;
    aspect-ratio: 16/10;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.portfolio-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(232, 117, 26, 0.0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.portfolio-item .overlay i {
    color: var(--white);
    font-size: 2rem;
    opacity: 0;
    transform: scale(0.5);
    transition: var(--transition);
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-item:hover .overlay {
    background: rgba(232, 117, 26, 0.5);
}

.portfolio-item:hover .overlay i {
    opacity: 1;
    transform: scale(1);
}

/* ---------- CTA Section ---------- */
#cta {
    position: relative;
    padding: 120px 0;
    overflow: hidden;
}

.cta-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.cta-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(17, 17, 17, 0.85);
}

.cta-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.cta-content h2 {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 35px;
    color: var(--white);
}

.cta-content p {
    color: var(--light-gray);
    font-size: 0.95rem;
    line-height: 1.9;
    margin-bottom: 15px;
}

.cta-content .btn-primary {
    margin-top: 25px;
}

/* ---------- Contact / Footer Section ---------- */
#contact {
    background: var(--darker);
    padding: 80px 0 0;
}

.contact-grid {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
    padding-bottom: 60px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-nav-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 30px;
}

.contact-col h4 {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 25px;
    color: var(--primary);
}

.contact-col a,
.contact-col p {
    display: block;
    color: var(--light-gray);
    font-size: 0.9rem;
    margin-bottom: 12px;
    transition: var(--transition);
}

.contact-col a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.contact-col .social-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-col .social-links a {
    display: flex;
    align-items: center;
    gap: 10px;
}

.contact-col .social-links a svg {
    width: 18px;
    height: 18px;
    fill: var(--primary);
    flex-shrink: 0;
}

.footer-bottom {
    padding: 25px 0;
    text-align: center;
}

.footer-bottom p {
    color: var(--medium-gray);
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.footer-bottom a {
    color: var(--primary);
}

.footer-bottom a:hover {
    text-decoration: underline;
}

/* ---------- Lightbox ---------- */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    cursor: zoom-out;
}

.lightbox.active {
    display: flex;
}

.lightbox img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-prev, .lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--white);
    font-size: 3rem;
    cursor: pointer;
    z-index: 100000;
    transition: var(--transition);
    user-select: none;
    padding: 20px;
}
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }
.lightbox-prev:hover, .lightbox-next:hover { color: var(--primary); }

.lightbox-close {
    position: absolute;
    top: 25px;
    right: 35px;
    color: var(--white);
    font-size: 2rem;
    cursor: pointer;
    z-index: 100000;
    transition: var(--transition);
}

.lightbox-close:hover {
    color: var(--primary);
    transform: rotate(90deg);
}

/* ---------- Scroll Animations ---------- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Back to Top ---------- */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    background: var(--primary);
    border: none;
    border-radius: 50%;
    color: var(--white);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 9990;
    box-shadow: 0 4px 15px rgba(232, 117, 26, 0.4);
}

#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

#back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
}

/* ---------- WhatsApp Button ---------- */
.whatsapp-float {
    position: fixed;
    bottom: 90px;
    right: 30px;
    width: 45px;
    height: 60px;
    background-color: transparent;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    z-index: 100;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.whatsapp-float:hover {
    transform: scale(1.1) translateY(-2px);
    filter: drop-shadow(0 5px 20px rgba(37, 211, 102, 0.8));
}

.whatsapp-float svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 15px rgba(37, 211, 102, 0.6));
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .studio-cards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .section {
        padding: 70px 0;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .header-inner {
        padding: 0 20px;
    }

    .header-logo img {
        height: 60px;
    }

    .hero-content .hero-logo {
        max-width: 320px;
    }

    .hero-content h1 {
        font-size: 2.2rem;
    }

    .hero-content .hero-subtitle {
        font-size: 0.9rem;
        letter-spacing: 2px;
    }

    .section-title {
        font-size: 1.5rem;
        letter-spacing: 2px;
        margin-bottom: 40px;
    }

    .section {
        padding: 60px 0;
    }

    .services-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }

    .service-card {
        padding: 25px 15px;
    }

    .service-card .service-icon {
        font-size: 2rem;
    }

    .service-card h3 {
        font-size: 0.8rem;
    }

    .portfolio-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .contact-grid {
        flex-direction: column;
        gap: 30px;
    }

    .cta-content h2 {
        font-size: 1.5rem;
    }

    .studio-cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .about-text p {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .services-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .hero-content .hero-logo {
        max-width: 260px;
    }

    .btn-primary,
    .btn-outline {
        padding: 12px 30px;
        font-size: 0.8rem;
    }

    .cta-content h2 {
        font-size: 1.3rem;
    }
}


/* ---------- Latest Posts Carousel ---------- */
.latest-posts-section {
    position: relative;
    background: var(--darker);
    overflow: hidden;
}

.latest-posts-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: min(1180px, calc(100% - 40px));
    height: 1px;
    transform: translateX(-50%);
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.16), transparent);
}

.latest-posts-heading {
    text-align: center;
    margin-bottom: 34px;
}

.latest-posts-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: var(--primary);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.latest-posts-kicker::before,
.latest-posts-kicker::after {
    content: '';
    width: 28px;
    height: 1px;
    background: currentColor;
    opacity: 0.55;
}

.latest-posts-subtitle {
    max-width: 680px;
    margin: -18px auto 0;
    color: var(--light-gray);
    font-size: 0.98rem;
    line-height: 1.8;
    text-align: center;
}

.latest-posts-carousel {
    position: relative;
    --posts-gap: 18px;
}

.latest-posts-viewport {
    overflow: hidden;
    width: 100%;
}

.latest-posts-track {
    display: flex;
    align-items: flex-start;
    gap: var(--posts-gap);
    transition: transform 560ms cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
}

.latest-post-card {
    flex: 0 0 calc((100% - (var(--posts-gap) * 4)) / 5);
    min-width: 0;
    color: var(--white);
    text-decoration: none;
    outline: none;
}

.latest-post-media {
    position: relative;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 9 / 16;
    background: #050505;
    border-radius: 7px;
    box-shadow: 0 18px 42px rgba(0,0,0,0.35);
    transform: translateZ(0);
}

.latest-post-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.98;
    transform: scale(1.001);
    transition: transform 520ms ease, opacity 520ms ease, filter 520ms ease;
}

.latest-post-card:hover .latest-post-media img,
.latest-post-card:focus-visible .latest-post-media img {
    opacity: 1;
    transform: scale(1.045);
    filter: saturate(1.05) contrast(1.06);
}

.latest-post-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.12) 0%, transparent 42%, rgba(0,0,0,0.70) 100%);
    pointer-events: none;
}

.latest-post-badge {
    position: absolute;
    top: 9px;
    left: 9px;
    z-index: 2;
    padding: 4px 7px;
    border-radius: 4px;
    background: #fe2c55;
    color: var(--white);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1;
}

.latest-post-views {
    position: absolute;
    left: 10px;
    bottom: 10px;
    z-index: 2;
    color: var(--white);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1;
    text-shadow: 0 2px 8px rgba(0,0,0,0.72);
}

.latest-post-views::before {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    margin-right: 5px;
    border-left: 6px solid currentColor;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    transform: translateY(1px);
}

.latest-post-caption {
    display: -webkit-box;
    margin-top: 9px;
    overflow: hidden;
    color: rgba(255,255,255,0.82);
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.latest-post-date {
    margin-top: 6px;
    color: rgba(255,255,255,0.42);
    font-size: 0.64rem;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.latest-posts-arrow {
    position: absolute;
    top: 42%;
    z-index: 5;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255,255,255,0.13);
    border-radius: 999px;
    background: rgba(17,17,17,0.78);
    color: var(--white);
    font-size: 1.7rem;
    line-height: 1;
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(12px);
}

.latest-posts-arrow:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.latest-posts-prev { left: -18px; }
.latest-posts-next { right: -18px; }

.latest-posts-status {
    display: none;
    margin-top: 20px;
    color: rgba(255,255,255,0.58);
    font-size: 0.86rem;
    text-align: center;
}

.latest-posts-section.is-empty {
    display: none;
}
@media (max-width: 900px) {
    .latest-posts-carousel {
        --posts-gap: 14px;
    }

    .latest-post-card {
        flex-basis: calc((100% - var(--posts-gap)) / 2);
    }

    .latest-posts-prev { left: 6px; }
    .latest-posts-next { right: 6px; }

    .latest-posts-arrow {
        top: 34%;
        width: 38px;
        height: 38px;
        font-size: 1.45rem;
    }

    .latest-posts-subtitle {
        margin-top: -18px;
        font-size: 0.9rem;
    }
}
