/* 
  BANI ROIS MUNAWAROH - Ultra Premium Gallery
  Theme: Royal Heritage Neon × Gold
  Designer: A.D.A COMPUTER 2026
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;800&family=Playfair+Display:ital,wght@0,700;0,900;1,700&family=Outfit:wght@400;700&display=swap');

:root {
    --gold: #d4af37;
    --gold-light: #f5d97e;
    --neon-cyan: #00f2ff;
    --neon-pink: #ff2d95;
    --bg-primary: #000000;
    --bg-secondary: #0a0a0a;
    --bg-card: rgba(255,255,255,0.04);
    --glass: rgba(255,255,255,0.06);
    --glass-border: rgba(255,255,255,0.08);
    --text-white: #ffffff;
    --text-dim: #999;
    --radius: 20px;
    --transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    background: var(--bg-primary);
    color: var(--text-white);
    font-family: 'Inter', sans-serif;
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: 'Playfair Display', serif; }

/* ============ NAVBAR ============ */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%; z-index: 9000;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(212,175,55,0.15);
    padding: 0.8rem 5%;
    display: flex; justify-content: space-between; align-items: center;
}

.nav-brand {
    font-family: 'Playfair Display', serif;
    font-size: 1.4rem; font-weight: 900;
    color: var(--gold);
    text-shadow: 0 0 20px rgba(212,175,55,0.3);
}

.nav-menu { display: flex; gap: 2rem; align-items: center; }

.nav-menu a {
    color: rgba(255,255,255,0.7); text-decoration: none;
    font-size: 0.85rem; font-weight: 600; letter-spacing: 1px;
    text-transform: uppercase; transition: var(--transition);
    position: relative;
}

.nav-menu a::after {
    content: ''; position: absolute; bottom: -5px; left: 0;
    width: 0; height: 2px; background: var(--neon-cyan);
    transition: var(--transition); box-shadow: 0 0 10px var(--neon-cyan);
}

.nav-menu a:hover { color: var(--neon-cyan); text-shadow: 0 0 15px rgba(0,242,255,0.5); }
.nav-menu a:hover::after { width: 100%; }

.hamburger { display: none; background: none; border: none; cursor: pointer; padding: 5px; }
.hamburger span { display: block; width: 25px; height: 2px; background: white; margin: 6px 0; transition: var(--transition); }

/* ============ HERO SECTION ============ */
.hero {
    min-height: 100vh; display: flex; flex-direction: column;
    justify-content: center; align-items: center; text-align: center;
    padding: 0 5%;
    background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.9) 80%),
                url('https://images.unsplash.com/photo-1609220136736-443140cffec6?q=80&w=2070&auto=format&fit=crop') center/cover fixed;
    position: relative;
}

.hero::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(212,175,55,0.08) 0%, transparent 60%);
}

.hero-badge {
    display: inline-block; padding: 8px 20px;
    background: rgba(212,175,55,0.1); border: 1px solid rgba(212,175,55,0.3);
    border-radius: 50px; font-size: 0.75rem; font-weight: 600;
    color: var(--gold-light); letter-spacing: 3px; text-transform: uppercase;
    margin-bottom: 2rem; animation: fadeIn 1s ease-out;
}

.hero h1 {
    font-size: clamp(2.5rem, 10vw, 5.5rem);
    font-weight: 900; line-height: 1.05;
    background: linear-gradient(135deg, #fff 20%, var(--gold) 50%, var(--gold-light) 80%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem; animation: fadeInUp 1s ease-out;
    position: relative; z-index: 1;
}

.hero-subtitle {
    font-family: 'Outfit', sans-serif;
    font-size: 1.15rem; color: rgba(255,255,255,0.6);
    max-width: 550px; margin-bottom: 3rem;
    animation: fadeInUp 1.2s ease-out;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; animation: fadeInUp 1.4s ease-out; }

.btn-primary {
    padding: 14px 35px; background: var(--gold); color: #000;
    border: none; border-radius: 50px; font-weight: 800;
    font-size: 0.9rem; cursor: pointer; text-transform: uppercase;
    letter-spacing: 1px; transition: var(--transition);
    box-shadow: 0 8px 30px rgba(212,175,55,0.3);
    text-decoration: none;
}

.btn-primary:hover { transform: translateY(-4px); box-shadow: 0 15px 40px rgba(212,175,55,0.5); }

.btn-outline {
    padding: 14px 35px; background: transparent;
    border: 2px solid rgba(255,255,255,0.2); color: white;
    border-radius: 50px; font-weight: 700; font-size: 0.9rem;
    cursor: pointer; transition: var(--transition); text-decoration: none;
}

.btn-outline:hover { border-color: var(--neon-cyan); color: var(--neon-cyan); text-shadow: 0 0 10px var(--neon-cyan); }

/* ============ SECTION TITLE ============ */
.section-header {
    text-align: center; padding: 80px 5% 40px;
}

.section-header h2 {
    font-size: clamp(1.8rem, 5vw, 3rem);
    margin-bottom: 1rem; color: var(--gold);
}

.section-header p { color: var(--text-dim); max-width: 500px; margin: 0 auto; }

.divider {
    width: 60px; height: 3px; background: linear-gradient(90deg, var(--gold), var(--neon-cyan));
    margin: 1.5rem auto 0; border-radius: 3px;
}

/* ============ GALLERY GRID ============ */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px; padding: 0 5% 80px;
}

.gallery-card {
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    overflow: hidden; position: relative;
    transition: var(--transition);
    animation: fadeInUp 0.6s ease-out both;
}

.gallery-card:hover {
    transform: translateY(-12px);
    border-color: var(--gold);
    box-shadow: 0 20px 60px rgba(212,175,55,0.15), 0 0 30px rgba(212,175,55,0.05);
}

.card-media {
    position: relative; width: 100%; height: 400px;
    background: #111; overflow: hidden; cursor: pointer;
}

.card-media img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.6s ease;
}

.gallery-card:hover .card-media img { transform: scale(1.08); }

.card-media iframe { width: 100%; height: 100%; border: none; }

.card-badge {
    position: absolute; top: 15px; left: 15px;
    padding: 5px 12px; background: rgba(0,0,0,0.6);
    backdrop-filter: blur(10px); border-radius: 50px;
    font-size: 0.65rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: 2px; color: var(--neon-cyan);
    border: 1px solid rgba(0,242,255,0.2);
    pointer-events: none;
}

.tags-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    z-index: 5; pointer-events: none;
}
.tags-overlay .face-label { pointer-events: auto; }

.card-info {
    padding: 1.5rem;
}

.card-info h3 {
    font-size: 1.25rem; margin-bottom: 0.4rem;
    font-family: 'Playfair Display', serif;
}

.card-info p { color: var(--text-dim); font-size: 0.85rem; }

/* ============ FACE LABEL (Nama langsung tampil, tanpa circle) ============ */
.face-label {
    position: absolute; transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.7); color: var(--neon-cyan);
    padding: 4px 10px; border-radius: 6px;
    font-size: 0.7rem; font-weight: 700;
    white-space: nowrap; cursor: grab;
    border: 1px solid rgba(0,242,255,0.3);
    backdrop-filter: blur(5px);
    z-index: 10; transition: background 0.3s, color 0.3s, box-shadow 0.3s;
    text-shadow: 0 0 8px rgba(0,242,255,0.3);
    touch-action: none; user-select: none;
}

.face-label:hover {
    background: var(--neon-cyan); color: #000;
    box-shadow: 0 0 20px rgba(0,242,255,0.5);
    text-shadow: none;
}

/* ============ FOOTER ============ */
.site-footer {
    background: var(--bg-secondary);
    border-top: 1px solid rgba(212,175,55,0.15);
    padding: 60px 5% 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px; margin-bottom: 40px;
}

.footer-col h3 { color: var(--gold); margin-bottom: 1rem; font-size: 1.1rem; }

.footer-col p { font-size: 0.85rem; color: var(--text-dim); line-height: 1.8; }

.footer-col a {
    display: block; color: rgba(255,255,255,0.6); text-decoration: none;
    margin-bottom: 0.7rem; font-size: 0.85rem; transition: var(--transition);
    position: relative; padding-left: 0;
}

.footer-col a:hover {
    color: var(--neon-cyan); padding-left: 8px;
    text-shadow: 0 0 15px rgba(0,242,255,0.4);
}

.btn-wa {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 12px 25px; background: #25D366; color: white;
    border-radius: 50px; text-decoration: none; font-weight: 700;
    transition: var(--transition); font-size: 0.85rem;
}

.btn-wa:hover { box-shadow: 0 0 30px rgba(37,211,102,0.4); transform: scale(1.05); }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.05);
    padding-top: 25px; text-align: center;
    font-size: 0.75rem; color: rgba(255,255,255,0.3);
}

/* ============ ADMIN MODAL ============ */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.92);
    backdrop-filter: blur(10px); z-index: 10000;
    display: none; align-items: center; justify-content: center;
    padding: 20px;
}

.modal-overlay.active { display: flex; }

.modal-box {
    background: #0c0c0c;
    border: 1px solid rgba(212,175,55,0.3);
    border-radius: 25px; padding: 2.5rem;
    width: 100%; max-width: 650px;
    max-height: 90vh; overflow-y: auto;
    box-shadow: 0 30px 80px rgba(0,0,0,0.8), 0 0 40px rgba(212,175,55,0.1);
}

.modal-box h2 { color: var(--gold); margin-bottom: 1.5rem; }

.form-group { margin-bottom: 1.2rem; }

.form-group label {
    display: block; font-size: 0.8rem; font-weight: 600;
    color: var(--text-dim); margin-bottom: 0.5rem;
    text-transform: uppercase; letter-spacing: 1px;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 14px 18px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: white; border-radius: 12px;
    font-size: 0.95rem; transition: var(--transition);
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    border-color: var(--gold); outline: none;
    box-shadow: 0 0 20px rgba(212,175,55,0.15);
}

.btn-submit {
    width: 100%; padding: 16px; background: var(--gold);
    border: none; border-radius: 12px; color: #000;
    font-weight: 800; font-size: 1rem; cursor: pointer;
    text-transform: uppercase; letter-spacing: 2px;
    transition: var(--transition);
}

.btn-submit:hover { box-shadow: 0 10px 30px rgba(212,175,55,0.4); }

.btn-close {
    width: 100%; margin-top: 10px; padding: 12px;
    background: none; border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-dim); border-radius: 12px;
    cursor: pointer; transition: var(--transition);
}

.btn-close:hover { border-color: var(--neon-pink); color: var(--neon-pink); }

.admin-list-item {
    display: flex; justify-content: space-between; align-items: center;
    padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 0.85rem;
}

.btn-delete {
    background: none; border: none; color: var(--neon-pink);
    cursor: pointer; font-weight: 700; font-size: 0.8rem;
    transition: var(--transition);
}

.btn-delete:hover { text-shadow: 0 0 10px var(--neon-pink); }

/* ============ ANIMATIONS ============ */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============ MOBILE RESPONSIVE ============ */
@media (max-width: 768px) {
    .nav-menu { 
        position: fixed; top: 0; right: -100%; width: 75%;
        height: 100vh; background: rgba(0,0,0,0.98);
        backdrop-filter: blur(20px); flex-direction: column;
        justify-content: center; gap: 2rem;
        transition: var(--transition); padding: 2rem;
    }
    .nav-menu.open { right: 0; }
    .hamburger { display: block; z-index: 9999; }
    .gallery-grid { grid-template-columns: 1fr; }
    .card-media { height: 300px; }
    .hero-actions { flex-direction: column; align-items: center; }
}

/* ============ FAMILY TREE ============ */
.tree-wrapper { padding: 120px 20px 80px; overflow-x: auto; text-align: center; }

.tree ul {
    padding-top: 20px; position: relative;
    display: flex; justify-content: center;
}

.tree li {
    float: left; text-align: center; list-style: none;
    position: relative; padding: 20px 8px 0;
}

.tree li::before, .tree li::after {
    content: ''; position: absolute; top: 0; right: 50%;
    border-top: 2px solid var(--gold); width: 50%; height: 20px;
}
.tree li::after { right: auto; left: 50%; border-left: 2px solid var(--gold); }
.tree li:only-child::after, .tree li:only-child::before { display: none; }
.tree li:only-child { padding-top: 0; }
.tree li:first-child::before, .tree li:last-child::after { border: 0 none; }
.tree li:last-child::before { border-right: 2px solid var(--gold); border-radius: 0 5px 0 0; }
.tree li:first-child::after { border-radius: 5px 0 0 0; }
.tree ul ul::before {
    content: ''; position: absolute; top: 0; left: 50%;
    border-left: 2px solid var(--gold); width: 0; height: 20px;
}

.tree-node {
    display: inline-block; padding: 12px 22px;
    background: rgba(212,175,55,0.08); border: 2px solid var(--gold);
    border-radius: 15px; color: white; font-weight: 600;
    font-size: 0.85rem; position: relative; transition: var(--transition);
    min-width: 130px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.4);
}

.tree-node:hover { background: var(--gold); color: #000; transform: scale(1.08); }

.tree-add {
    position: absolute; bottom: -14px; left: 50%; transform: translateX(-50%);
    width: 28px; height: 28px; border-radius: 50%;
    background: var(--neon-cyan); border: none; color: #000;
    font-size: 1.2rem; font-weight: 900; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 15px var(--neon-cyan); z-index: 50;
    transition: var(--transition);
}

.tree-add:hover { transform: translateX(-50%) scale(1.3); }

/* Print A3 */
@media print {
    body { background: white !important; color: black !important; }
    .navbar, .print-controls, .tree-add, .site-footer, .hero { display: none !important; }
    .tree-wrapper { padding: 20px !important; }
    .tree-node { border-color: #333 !important; color: #000 !important; background: #f9f9f9 !important; box-shadow: none !important; }
    .tree li::before, .tree li::after, .tree ul ul::before { border-color: #333 !important; }
    @page { size: A3 landscape; margin: 1cm; }
}
