/* --- 1. GLOBAL VARIABLES & RESET --- */
:root {
    --bg-dark: #0b0f19;       
    --bg-card: #111827;       
    --bg-hover: #1f2937;      
    --primary: #2359E0;       
    --secondary: #06b6d4;     
    --accent-offline: #f59e0b;
    --accent-cloud: #3b82f6;  
    --text-main: #f8fafc;     
    --text-muted: #94a3b8;    
    --glass: rgba(11, 15, 25, 0.9); 
    --border: rgba(255,255,255,0.08); 
    --container-max: 1200px; 
}

body.light-mode {
    --bg-dark: #ffffff;
    --bg-card: #f8fafc;
    --bg-hover: #e2e8f0;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --glass: rgba(255, 255, 255, 0.95);
    --border: rgba(0,0,0,0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; transition: background-color 0.3s, color 0.3s; }

html { font-size: 16px; scroll-behavior: smooth; }

body { background-color: var(--bg-dark); color: var(--text-main); min-height: 100vh; display: flex; flex-direction: column; overflow-x: hidden; position: relative; }

/* CONTAINER RESPONSIF */
.container { 
    width: 100%; 
    max-width: var(--container-max); 
    margin: 0 auto; 
    padding: 0 24px; 
}

/* Navigasi Halaman */
.main-page-content { display: none; animation: fadeIn 0.5s ease; }
.main-page-content.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* --- 2. HEADER --- */
header { background-color: var(--glass); backdrop-filter: blur(12px); position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--border); }
.header-content { display: flex; justify-content: space-between; align-items: center; height: 70px; }

.logo { 
    font-family: 'Outfit', sans-serif; 
    font-size: 1.5rem; 
    font-weight: 700; 
    display: inline-block;
    color: var(--text-main);
}
.logo span {
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-actions { display: flex; gap: 10px; align-items: center; }
.page-nav-btn { background: transparent; color: var(--text-main); padding: 8px 12px; border-radius: 8px; border: 1px solid transparent; font-weight: 600; cursor: pointer; font-size: 0.9rem; }
.page-nav-btn:hover, .page-nav-btn.active { background: var(--bg-hover); color: var(--primary); }
.icon-btn { background: transparent; border: 1px solid var(--border); color: var(--text-main); width: 36px; height: 36px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; }

/* --- 3. HERO & STATS --- */
.hero { text-align: center; padding: 4rem 0 2rem; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; margin-bottom: 1rem; line-height: 1.2; }
.hero h1 span { color: var(--primary); }
.hero p { color: var(--text-muted); font-size: 1.1rem; max-width: 600px; margin: 0 auto 2rem; line-height: 1.6; }

/* Stats Grid Responsive */
.stats-container { 
    display: inline-flex; flex-wrap: wrap; 
    justify-content: center;
    gap: 2px; 
    background: var(--border); 
    padding: 1px; 
    border-radius: 16px; 
    overflow: hidden; 
    margin-bottom: 2rem;
    max-width: 100%;
}
.stat-item { 
    background: var(--bg-card); 
    padding: 1rem 2rem; 
    text-align: center; 
    min-width: 120px;
    flex: 1; 
}
.stat-number { font-size: 2rem; font-weight: 800; color: var(--text-main); display: block; line-height: 1; margin-bottom: 5px; }
.stat-label { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; text-transform: uppercase; }

/* Kontributor */
.contributors { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 1rem; flex-wrap: wrap; }
.avatars { display: flex; }
.avatar-img { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--bg-dark); margin-left: -10px; object-fit: cover; }
.avatar-img:first-child { margin-left: 0; }

/* --- 4. MODEL CARDS --- */
.model-section { padding: 2rem 0; }
.section-title { display: flex; align-items: center; gap: 12px; margin-bottom: 1.5rem; }
.section-title h2 { font-size: 1.5rem; font-weight: 700; }
.section-title i { color: var(--secondary); font-size: 1.2rem; }

.model-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 1.5rem; 
}
.model-card { 
    background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px; padding: 1.5rem; 
    transition: 0.3s; cursor: pointer; position: relative; overflow: hidden;
}
.model-card:hover { transform: translateY(-5px); border-color: var(--primary); box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5); }
.model-card.active { border-color: var(--primary); background: rgba(139, 92, 246, 0.05); }

.model-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin-bottom: 1rem; }
.cloud-icon { background: rgba(59, 130, 246, 0.15); color: var(--accent-cloud); }
.local-icon { background: rgba(245, 158, 11, 0.15); color: var(--accent-offline); }

.tag-list { display: flex; gap: 8px; margin-top: 1.5rem; flex-wrap: wrap; }
.tag { font-size: 0.75rem; padding: 4px 10px; border-radius: 20px; background: var(--bg-hover); color: var(--text-muted); font-weight: 500; }
.info-spec-btn { margin-top: 1rem; width: 100%; background: transparent; border: 1px dashed var(--accent-offline); color: var(--accent-offline); padding: 10px; border-radius: 8px; cursor: pointer; font-size: 0.9rem; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 8px; transition: 0.2s; }
.info-spec-btn:hover { background: rgba(245, 158, 11, 0.1); }

/* --- 5. GALLERY SLIDER --- */
.gallery-wrapper { padding-bottom: 2rem; }
.controls-bar { 
    display: flex; gap: 1rem; margin-bottom: 2rem; background: var(--bg-hover); padding: 0.8rem; border-radius: 12px; border: 1px solid var(--border); 
    flex-wrap: wrap; 
}
.search-box { flex: 1; position: relative; min-width: 200px; }
.search-box input { width: 100%; padding: 12px 12px 12px 40px; border-radius: 8px; border: 1px solid transparent; background: var(--bg-dark); color: var(--text-main); font-size: 0.95rem; }
.search-box i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); }

.gallery-section-block { margin-bottom: 3rem; position: relative; }
.gallery-header { font-size: 1.2rem; font-weight: 700; margin-bottom: 1rem; display: flex; align-items: center; gap: 10px; }

.gallery-slider-container {
    display: flex; overflow-x: auto; gap: 16px; padding: 5px;
    scroll-behavior: smooth; scrollbar-width: none;
    -webkit-overflow-scrolling: touch; 
}
.gallery-slider-container::-webkit-scrollbar { display: none; }

.slider-btn {
    position: absolute; top: 55%; transform: translateY(-50%); width: 40px; height: 40px; border-radius: 50%;
    background: var(--bg-card); border: 1px solid var(--border); color: var(--text-main); cursor: pointer; z-index: 10;
    display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(0,0,0,0.3); transition: 0.2s;
}
.slider-prev { left: -15px; } .slider-next { right: -15px; }

.gallery-item {
    flex: 0 0 280px; 
    background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px; overflow: hidden; cursor: pointer; transition: 0.3s; position: relative;
}
.gallery-item:hover { transform: translateY(-5px); }
.gallery-img { width: 100%; height: 180px; object-fit: cover; }
.badge-model { position: absolute; top: 12px; left: 12px; padding: 4px 10px; background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); border: 1px solid rgba(255,255,255,0.2); color: white; border-radius: 20px; font-size: 0.65rem; font-weight: 600; text-transform: uppercase; }
.btn-fav { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 50%; background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); border: 1px solid rgba(255,255,255,0.2); color: white; cursor: pointer; transition: 0.2s; display: grid; place-items: center; }
.btn-fav.active { background: red; color: white; border-color: red; }
.item-content { padding: 1rem; }
.item-title { font-weight: 700; font-size: 1rem; margin-bottom: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-preview { font-size: 0.85rem; color: var(--text-muted); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* UPDATE BRIGHT MODEL TEXT */
.item-model {
    color: var(--secondary) !important;
    font-weight: 700;
    font-size: 0.85rem;
    margin-top: 8px;
    display: block;
    letter-spacing: 0.5px;
}

/* --- 6. TESTIMONIALS & FOOTER --- */
.bottom-section-wrapper {
    background: transparent; color: var(--text-main);
    padding-top: 3rem; margin-top: 3rem; padding-bottom: 3rem;
}

.testimonials-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 20px;
}
.testimonial-card {
    background: white; color: #0f172a; padding: 1.5rem; 
    border-radius: 16px; box-shadow: 0 10px 30px -10px rgba(0,0,0,0.3); border: none;
    height: 100%; display: flex; flex-direction: column; justify-content: space-between;
}
.testimonial-quote { font-size: 1rem; font-weight: 600; line-height: 1.5; margin-bottom: 1.5rem; color: #1e293b; }
.testimonial-user { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }

.white-footer-section {
    background-color: #f8fafc; color: #0f172a; width: 100%; padding-top: 1rem;
}
.cta-box {
    display: flex; justify-content: space-between; align-items: center;
    padding: 3rem 0; border-bottom: 1px solid #e2e8f0; margin-bottom: 3rem; flex-wrap: wrap; gap: 20px;
}
.btn-black { background: #0f172a; color: white; padding: 12px 24px; border-radius: 8px; font-weight: 600; cursor: pointer; border: none; }
.btn-outline { background: transparent; color: #0f172a; border: 1px solid #cbd5e1; padding: 12px 24px; border-radius: 8px; font-weight: 600; cursor: pointer; }

.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 30px; padding-bottom: 3rem; }
.footer-col h5 { font-size: 1rem; margin-bottom: 1rem; color: #0f172a; font-weight: 700; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: #64748b; text-decoration: none; font-size: 0.9rem; }
.footer-col .logo { color: #0f172a; }

/* --- 7. MODAL & FIGMA --- */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.85); z-index: 2000; display: none; justify-content: center; align-items: center; padding: 20px; backdrop-filter: blur(5px); }
.modal-overlay.active { display: flex; }
.modal-content { background: var(--bg-card); width: 100%; max-width: 900px; height: auto; max-height: 90vh; border-radius: 15px; display: flex; overflow: hidden; flex-direction: row; }
.modal-preview { flex: 1.5; background: black; display: flex; align-items: center; justify-content: center; position: relative; }
.modal-preview img, .modal-preview video { max-width: 100%; max-height: 100%; object-fit: contain; }
.modal-info { flex: 1; padding: 1.5rem; display: flex; flex-direction: column; overflow-y: auto; color: #fff; min-width: 300px; }
.nav-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.1); color: white; border: none; padding: 0.8rem; cursor: pointer; font-size: 1.2rem; border-radius: 50%; }
.nav-prev { left: 10px; } .nav-next { right: 10px; }
.prompt-text { background: var(--bg-hover); padding: 1rem; border-radius: 8px; font-family: monospace; margin: 1rem 0; flex-grow: 1; overflow-y: auto; color: var(--text-main); font-size: 0.9rem; }
.btn-action { width: 100%; padding: 10px; margin-top: 10px; border: none; border-radius: 8px; cursor: pointer; font-weight: 600; }
.btn-primary { background: var(--primary); color: white; }
.btn-secondary { background: transparent; border: 1px solid var(--text-muted); color: var(--text-main); }

.sys-req-card { background: #1e293b; width: 100%; max-width: 600px; border-radius: 20px; padding: 2rem; box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); border: 1px solid rgba(255,255,255,0.1); color: white; position: relative; }
.sys-req-header { display: flex; justify-content: space-between; margin-bottom: 1.5rem; }
.specs-container { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.spec-box { padding: 1rem; border-radius: 12px; border: 1px solid rgba(255,255,255,0.1); background: rgba(0,0,0,0.2); }
.warning-banner { margin-top: 1.5rem; background: rgba(245, 158, 11, 0.15); border: 1px solid var(--accent-offline); color: #fbbf24; padding: 10px; border-radius: 8px; display: flex; align-items: center; gap: 10px; font-size: 0.85rem; }

.figma-layout-wrapper { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; padding-top: 20px; flex-wrap: wrap; }
.figma-content-col { flex: 1; min-width: 300px; display: flex; flex-direction: column; gap: 20px; }
.figma-image-col { flex: 1; min-width: 300px; display: flex; justify-content: center; }
.figma-image { width: 100%; border-radius: 12px; object-fit: cover; aspect-ratio: 4/5; }
.figma-form { display: flex; flex-direction: column; gap: 15px; padding: 20px; background: var(--bg-card); border-radius: 16px; border: 1px solid var(--border); }
.form-input { width: 100%; padding: 10px; border-radius: 8px; border: 1px solid var(--border); background-color: var(--bg-dark); color: var(--text-main); }
.form-submit-btn { background-color: #000; color: white; padding: 12px; border-radius: 8px; font-weight: 600; cursor: pointer; width: 100%; border: 1px solid #fff; }

/* --- 8. TOMBOL SCROLL TO TOP --- */
#scrollTopBtn {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99;
    font-size: 1.2rem;
    border: none;
    outline: none;
    background-color: var(--primary);
    color: white;
    cursor: pointer;
    padding: 12px 18px;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: 0.3s;
}
#scrollTopBtn:hover {
    background-color: var(--secondary);
    transform: translateY(-3px);
}

/* --- 9. MOBILE RESPONSIVE MEDIA QUERIES --- */
@media (max-width: 768px) {
    .header-content { height: 60px; }
    .logo { font-size: 1.2rem; }
    .header-actions .page-nav-btn { display: none; } /* Tetap sembunyikan teks menu di HP agar rapi */
    
    .hero h1 { font-size: 2.2rem; }
    .stats-container { display: flex; width: 100%; }
    .stat-item { border-bottom: 1px solid var(--border); width: 100%; border-right: none !important; border-left: none !important; }
    
    .cta-box { flex-direction: column; text-align: center; }
    .cta-buttons { width: 100%; display: flex; flex-direction: column; gap: 10px; }
    
    .modal-content { flex-direction: column; height: 90vh; }
    .modal-preview { flex: 1; height: 40%; }
    .modal-info { flex: 1; height: 60%; }
    
    .specs-container { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 20px; }
    
    .figma-layout-wrapper { flex-direction: column-reverse; }
}

/* Toast */
.toast { visibility: hidden; min-width: 250px; background-color: var(--bg-card); color: var(--text-main); border: 1px solid var(--primary); text-align: center; border-radius: 8px; padding: 16px; position: fixed; z-index: 3000; left: 50%; bottom: 30px; transform: translateX(-50%); font-size: 1rem; display: flex; align-items: center; gap: 10px; justify-content: center; box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.toast.show { visibility: visible; animation: fadein 0.5s, fadeout 0.5s 2.5s; }
@keyframes fadein { from {bottom: 0; opacity: 0;} to {bottom: 30px; opacity: 1;} }
@keyframes fadeout { from {bottom: 30px; opacity: 1;} to {bottom: 0; opacity: 0;} }


/* --- GOOGLE TRANSLATE CUSTOM STYLE --- */

/* 1. Hapus Banner Google di Atas */
.goog-te-banner-frame { display: none !important; }
body { top: 0px !important; }

/* 2. Wadah Widget */
#google_translate_element {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    margin-right: 8px;
}

/* 3. Style Tombolnya */
.goog-te-gadget-simple {
    background-color: transparent !important;
    border: 1px solid var(--border) !important;
    padding: 6px 12px !important;
    border-radius: 20px !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 0.85rem !important;
    line-height: 20px !important;
    display: flex !important;
    align-items: center;
    cursor: pointer;
    transition: 0.3s;
}

.goog-te-gadget-simple:hover {
    border-color: var(--primary) !important;
    background-color: var(--bg-hover) !important;
}

/* 4. Warna Teks Link */
.goog-te-gadget-simple a {
    color: var(--text-main) !important;
    text-decoration: none !important;
    font-weight: 600;
}
.goog-te-gadget-simple a:hover {
    color: var(--primary) !important;
}

/* 5. Sembunyikan Logo G Google */
.goog-te-gadget-icon {
    display: none !important;
}

/* --- KUNCI: GANTI TULISAN "Pilih Bahasa" MENJADI "English" --- */

/* A. Sembunyikan tulisan asli "Pilih Bahasa" */
.goog-te-gadget-simple .goog-te-menu-value span:first-child {
    display: none !important;
}

/* B. Suntikkan tulisan baru "English" */
.goog-te-gadget-simple .goog-te-menu-value::before {
    content: "English";  /* <--- GANTI TEKS DISINI */
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    margin-right: 4px;
}

/* C. Hapus garis pemisah | */
.goog-te-gadget-simple .goog-te-menu-value span {
    color: var(--text-muted) !important;
    border-left: none !important;
}