/* ================================================================
   BRANDFOLIO WEB — PAGE-SPECIFIC STYLES
   Inspired by Bazil.fr/design layout
   ================================================================ */

body {
    opacity: 0;
    animation: simpleFadeIn 0.8s ease forwards;
}

@keyframes simpleFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ========== HERO ========== */
/* Hide Navbar when project modal is active */
body.modal-open .bfw-nav, 
body.modal-open .bfw-logo,
body.modal-open .lang-switcher,
body.modal-open .burger-menu {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.bfw-hero {
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8rem 2rem 4rem;
    background: linear-gradient(180deg, #f5f0eb 0%, #fcfcfc 100%);
    position: relative;
    z-index: 10;
    box-sizing: border-box;
}

.bfw-hero-label {
    font-family: var(--font-body);
    font-size: 0.75rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--accent-color);
    margin-bottom: 2rem;
}

.bfw-hero-heading {
    font-family: var(--font-heading);
    font-size: clamp(2.4rem, 5vw, 4.5rem);
    line-height: 1.1;
    color: #131313;
    max-width: 900px;
    margin: 0 auto 2.5rem;
    text-transform: none;
}

.bfw-hero-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: #0a0a0a;
    text-decoration: none;
    border: 2px solid #131313;
    padding: 1.1rem 2.8rem;
    border-radius: 999px;
    position: relative;
    overflow: hidden;
    transition: color 0.4s ease, border-color 0.3s ease;
}

.bfw-hero-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: #131313;
    transform: translateY(100%);
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 0;
}

.bfw-hero-btn:hover::before {
    transform: translateY(0);
}

.bfw-hero-btn:hover {
    color: #fcfcfc;
}

.bfw-hero-btn span {
    position: relative;
    z-index: 1;
}

/* ========== MOCKUP CONVERGENT GALLERY ========== */
.bfw-mockup-gallery {
    background: #131313;
    padding: 4rem 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    z-index: 10;
}

.bfw-mockup-container {
    display: flex;
    gap: 40px;
    width: 100%;
    padding: 0 2rem;
    box-sizing: border-box;
    justify-content: center;
}

.bfw-mockup-item {
    flex: 1;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: #131313;
    border-radius: 8px;
    box-sizing: border-box;
}

.bfw-mockup-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ========== VALUE PROPOSITION ========== */
.bfw-value-section {
    padding: 10rem 2rem;
    background: #f5f0eb;
    position: relative;
    z-index: 10;
}

.bfw-value-heading {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.2;
    color: #131313;
    max-width: 900px;
    margin-bottom: 4rem;
}

.bfw-strike {
    position: relative;
    text-decoration: none;
    color: rgba(19, 19, 19, 0.35);
    display: inline-block;
}

.bfw-strike::after {
    content: "";
    position: absolute;
    left: 0;
    top: 55%;
    width: 100%;
    height: 4px;
    background: #c50022; /* Syams Red */
    transform: scaleX(var(--strike-scale, 0));
    transform-origin: left;
}

.bfw-value-body {
    max-width: 750px;
}

.bfw-value-body p {
    font-family: var(--font-body);
    font-size: 1.15rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 1.5rem;
}

.bfw-value-body strong {
    color: #131313;
    font-weight: 700;
}

/* ========== LATEST PROJECTS ========== */
.bfw-projects-section {
    padding: 8rem 2rem;
    background: #131313;
    position: relative;
    z-index: 10;
}

.bfw-section-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: #fcfcfc;
    margin-bottom: 4rem;
    text-transform: uppercase;
}

.bfw-projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
}

.bfw-project-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 20px;
    overflow: hidden;
    background: #131313;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.bfw-project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
}

.bfw-project-img {
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.bfw-project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.bfw-project-card:hover .bfw-project-img img {
    transform: scale(1.06);
}

.bfw-project-info {
    padding: 2rem 2rem 2.5rem;
}

.bfw-project-name {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 2.5vw, 2.2rem);
    color: #fcfcfc;
    margin-bottom: 0.8rem;
}

.bfw-project-desc {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: rgba(252, 252, 252, 0.55);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.bfw-project-action {
    display: flex;
    align-items: center;
}

.bfw-btn-outline {
    display: inline-block;
    padding: 0.6rem 1.5rem;
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: #fcfcfc;
    border: 1px solid rgba(252, 252, 252, 0.3);
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
}

.bfw-project-card:hover .bfw-btn-outline {
    background: #fcfcfc;
    color: #131313;
    border-color: #fcfcfc;
}

/* ========== SERVICES / APPROACH ========== */
.bfw-approach-section {
    padding: 8rem 2rem;
    background: #f5f0eb;
    position: relative;
    z-index: 10;
}

.bfw-approach-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.bfw-approach-card {
    padding: 3rem 2.5rem;
    border: 1px solid rgba(10, 10, 10, 0.1);
    border-radius: 20px;
    background: #fcfcfc;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bfw-approach-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08);
}

.bfw-approach-icon {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    background: var(--accent-color);
    color: #fcfcfc;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
}

.bfw-approach-card h3 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: #131313;
    margin-bottom: 1.2rem;
    line-height: 1.3;
    text-transform: none;
}

.bfw-approach-card p {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: #555;
    line-height: 1.7;
}

/* ========== TESTIMONIALS ========== */
.bfw-testi-section {
    padding: 8rem 2rem;
    background: #131313;
    position: relative;
    z-index: 10;
}

.bfw-testi-slider {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.bfw-testi-track {
    position: relative;
    min-height: 280px;
}

.bfw-testi-card {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    background: #161616;
    border: 1px solid rgba(252, 252, 252, 0.06);
    border-radius: 20px;
    padding: 3rem;
    pointer-events: none;
}

.bfw-testi-card.bfw-active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    position: relative;
}

.bfw-testi-quote {
    font-family: var(--font-serif);
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    line-height: 1.7;
    color: rgba(252, 252, 252, 0.85);
    margin-bottom: 2rem;
}

.bfw-testi-author {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.bfw-testi-author strong {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: #fcfcfc;
}

.bfw-testi-author span {
    font-size: 0.85rem;
    color: rgba(252, 252, 252, 0.4);
    letter-spacing: 0.05em;
}

.bfw-testi-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.bfw-testi-prev,
.bfw-testi-next {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 1px solid rgba(252, 252, 252, 0.15);
    background: transparent;
    color: #fcfcfc;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.bfw-testi-prev:hover,
.bfw-testi-next:hover {
    background: #fcfcfc;
    color: #131313;
    border-color: #fcfcfc;
}

/* ========== FAQ ========== */
.bfw-faq-section {
    padding: 8rem 2rem;
    background: #f5f0eb;
    position: relative;
    z-index: 10;
}

.bfw-faq-section .bfw-section-title {
    color: #131313;
}

.bfw-faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.bfw-faq-item {
    border-bottom: 1px solid rgba(10, 10, 10, 0.1);
}

.bfw-faq-q {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
    border: none;
    font-family: var(--font-heading);
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    color: #131313;
    padding: 2rem 0;
    cursor: pointer;
    text-align: left;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.bfw-faq-q:hover {
    color: var(--accent-color);
}

.bfw-faq-arrow {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(10, 10, 10, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 1.5rem;
    transition: background 0.3s ease, color 0.3s ease, transform 0.3s ease;
}

.bfw-faq-item.is-open .bfw-faq-arrow {
    background: var(--accent-color);
    border-color: var(--accent-color);
    color: #fcfcfc;
    transform: rotate(90deg);
}

.bfw-faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.25, 1, 0.5, 1), padding 0.4s ease;
}

.bfw-faq-item.is-open .bfw-faq-a {
    max-height: 300px;
    padding-bottom: 2rem;
}

.bfw-faq-a p {
    font-family: var(--font-body);
    font-size: 1rem;
    color: #555;
    line-height: 1.7;
    max-width: 85%;
}

/* ========== CTA ========== */
.bfw-cta-section {
    padding: 10rem 2rem;
    background: #131313;
    text-align: center;
    position: relative;
    z-index: 10;
}

.bfw-cta-heading {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 5.5vw, 5rem);
    color: #fcfcfc;
    margin-bottom: 2rem;
    line-height: 1.1;
}

.bfw-cta-sub {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: rgba(252, 252, 252, 0.5);
    max-width: 550px;
    margin: 0 auto 3.5rem;
    line-height: 1.7;
}

.bfw-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: #131313;
    background: #fcfcfc;
    text-decoration: none;
    padding: 1.2rem 3rem;
    border-radius: 999px;
    position: relative;
    overflow: hidden;
    transition: background 0.4s ease, transform 0.3s ease;
}

.bfw-cta-btn:hover {
    background: var(--accent-color);
    color: #fcfcfc;
    transform: scale(1.05);
}

.bfw-cta-btn span,
.bfw-cta-btn svg {
    position: relative;
    z-index: 1;
}

/* ========== IFRAME POPUP MODAL ========== */
.bfw-iframe-modal {
    position: fixed;
    inset: 0;
    z-index: 200000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.bfw-iframe-modal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.bfw-iframe-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5); /* 50% Opacity */
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px); /* Softer blur for better transparency */
    cursor: zoom-out;
}

.bfw-iframe-container {
    position: relative;
    width: 96vw;
    height: 94vh;
    max-width: 100%;
    background: #fff; /* Match project white bg */
    border: none;
    border-radius: 0; /* Sharp edges for full-screen feel */
    overflow: hidden;
    box-shadow: 0 60px 120px rgba(0, 0, 0, 0.9);
    transform: scale(0.98) translateY(10px);
    opacity: 0;
    transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.4s ease;
    z-index: 2;
}

.bfw-iframe-modal.is-open .bfw-iframe-container {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Hide parent navbar when modal is open */
.modal-open .navbar .logo,
.modal-open .navbar .lang-toggle,
.modal-open .navbar .menu-btn {
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden;
}

.bfw-iframe-close {
    position: relative;
    z-index: 10;
    align-self: flex-end;
    margin: 12px 20px 8px 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #cc0000; 
    color: #ffffff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(0,0,0,0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    flex-shrink: 0;
}

.bfw-iframe-modal.is-open .bfw-iframe-close {
    opacity: 1;
    pointer-events: auto !important;
}

.bfw-iframe-close:hover {
    background: #fcfcfc;
    color: #131313;
}

.bfw-iframe-close svg {
    width: 22px;
    height: 22px;
    pointer-events: none;
}

#project-iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
    background: #fcfcfc;
}

#project-iframe.is-loaded {
    opacity: 1;
}

/* Loader */
.bfw-iframe-loader {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111;
    z-index: 3;
    opacity: 1;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.bfw-iframe-loader.is-hidden {
    opacity: 0;
}

.loader-spinner {
    width: 44px;
    height: 44px;
    border: 3px solid rgba(252, 252, 252, 0.08);
    border-top-color: #fcfcfc;
    border-radius: 50%;
    animation: bfwSpin 0.9s linear infinite;
}

@keyframes bfwSpin {
    to { transform: rotate(360deg); }
}

/* ========== RESPONSIVE ========== */

@media (max-width: 1024px) {
    .bfw-approach-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .bfw-mockup-container {
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .bfw-projects-section {
        padding: 5rem 1.5rem;
    }
    .bfw-hero {
        padding: 10rem 1.5rem 5rem;
        min-height: 0;
    }
    .bfw-hero-heading {
        font-size: clamp(2.2rem, 8vw, 3.5rem);
    }
    .bfw-hero-label {
        font-size: 0.7rem;
        letter-spacing: 0.15em;
    }
    .bfw-mockup-container {
        flex-direction: column;
        gap: 12px;
        padding: 0 5%;
    }
    .bfw-mockup-item {
        width: 100%;
        border-radius: 6px;
    }
    /* Reorder mockups on mobile: Nouna, LPK, Riko, Surya Kencana */
    .bfw-mockup-item:nth-child(1) { order: 4; } /* Surya Kencana → last */
    .bfw-mockup-item:nth-child(2) { order: 1; } /* Nouna → first */
    .bfw-mockup-item:nth-child(3) { order: 2; } /* LPK → second */
    .bfw-mockup-item:nth-child(4) { order: 3; } /* Riko → third */
    .bfw-mockup-gallery {
        padding: 2rem 0;
    }
    .bfw-value-section {
        padding: 5rem 1.5rem;
    }
    .bfw-value-heading {
        font-size: clamp(1.8rem, 6vw, 2.8rem);
    }
    .bfw-projects-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    .bfw-approach-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .bfw-approach-section {
        padding: 5rem 1.5rem;
    }
    .bfw-approach-card {
        padding: 2rem 1.5rem;
    }
    .bfw-testi-section {
        padding: 5rem 1.5rem;
    }
    .bfw-testi-card {
        padding: 2rem 1.5rem;
    }
    .bfw-faq-section {
        padding: 5rem 1.5rem;
    }
    .bfw-faq-q {
        font-size: 1rem;
        padding: 1.5rem 0;
    }
    .bfw-faq-arrow {
        width: 36px;
        height: 36px;
        margin-left: 1rem;
    }
    .bfw-cta-section {
        padding: 5rem 1.5rem;
    }
    .bfw-cta-heading {
        font-size: clamp(2rem, 7vw, 3rem);
    }
}

@media (max-width: 480px) {
    .bfw-hero {
        padding: 9rem 1rem 4rem;
    }
    .bfw-hero-heading {
        font-size: clamp(1.8rem, 9vw, 2.5rem);
    }
    .bfw-hero-btn {
        font-size: 0.95rem;
        padding: 1rem 2rem;
    }
    .bfw-mockup-item {
        width: 100%;
    }
    .bfw-value-section {
        padding: 4rem 1rem;
    }
    .bfw-value-body p {
        font-size: 1rem;
    }
    .bfw-project-info {
        padding: 1.5rem;
    }
    .bfw-project-name {
        font-size: 1.3rem;
    }
    .bfw-testi-card {
        padding: 1.5rem 1.2rem;
    }
    .bfw-testi-quote {
        font-size: 1rem;
    }
    .bfw-cta-btn {
        font-size: 1.1rem;
        padding: 1rem 2rem;
    }
}
/* === Custom Font Faces === */
