/* ==========================================
   BM REBORN - AUTOMOTIVE LINK TREE STYLESHEET
   Responsive Web Design (RWD) & High Aesthetics
   ========================================== */

/* ---------------- CSS Variables ---------------- */
:root {
    --bg-dark: #090b0e;
    --card-bg: rgba(18, 22, 29, 0.85);
    --card-hover-bg: rgba(28, 35, 46, 0.95);
    --border-color: rgba(255, 255, 255, 0.1);
    
    /* Brand & Accent Colors */
    --accent-red: #ff2e43;
    --accent-red-glow: rgba(255, 46, 67, 0.4);
    --accent-orange: #ff6b00;
    
    /* Specific Platform Accent Colors */
    --tokopedia-color: #42b549;
    --tokopedia-glow: rgba(66, 181, 73, 0.4);
    
    --shopee-color: #ee4d2d;
    --shopee-glow: rgba(238, 77, 45, 0.4);
    
    --instagram-color: #e1306c;
    --instagram-glow: rgba(225, 48, 108, 0.4);

    --tiktok-color: #ff0050;
    --tiktok-glow: rgba(255, 0, 80, 0.4);

    --whatsapp-color: #25d366;
    --whatsapp-glow: rgba(37, 211, 102, 0.4);

    --maps-color: #ea4335;
    --maps-glow: rgba(234, 67, 53, 0.4);

    --text-primary: #ffffff;
    --text-secondary: #9aa8b9;
    --text-muted: #627284;

    /* Fonts */
    --font-heading: 'Orbitron', sans-serif;
    --font-subheading: 'Rajdhani', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Shadows & Effects */
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 20px rgba(255, 46, 67, 0.3);
    --radius-main: 16px;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* ---------------- Reset & Base ---------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
}

/* ---------------- Dynamic Background ---------------- */
.bg-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.bg-image {
    position: absolute;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    background-image: url('https://images.glints.com/unsafe/glints-dashboard.oss-ap-southeast-1.aliyuncs.com/company-logo/a855f830cd5d374bdca6564f8225838b.jpg');
    background-size: cover;
    background-position: center;
    filter: blur(12px) brightness(0.25) contrast(1.2);
    transform: scale(1.05);
    animation: slowZoom 20s infinite alternate ease-in-out;
}

@keyframes slowZoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.08); }
}

.bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 30%, rgba(15, 20, 28, 0.75) 0%, rgba(9, 11, 14, 0.95) 100%);
}

/* Carbon Fiber Pattern Overlay */
.carbon-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(27deg, #151515 5px, transparent 5px) 0 5px,
        linear-gradient(207deg, #151515 5px, transparent 5px) 10px 0px,
        linear-gradient(27deg, #222 5px, transparent 5px) 0px 10px,
        linear-gradient(207deg, #222 5px, transparent 5px) 10px 5px,
        linear-gradient(90deg, #1b1b1b 10px, transparent 10px),
        linear-gradient(#1d1d1d 25%, #1a1a1a 25%, #1a1a1a 50%, transparent 50%, transparent 75%, #242424 75%, #242424);
    background-size: 20px 20px;
    opacity: 0.12;
    pointer-events: none;
}

/* Ambient Neon Lights */
.ambient-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.35;
    pointer-events: none;
}

.glow-red {
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 450px;
    height: 450px;
    background: var(--accent-red);
}

.glow-orange {
    bottom: -10%;
    right: 10%;
    width: 350px;
    height: 350px;
    background: var(--accent-orange);
}

#spark-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* ---------------- Layout & Container ---------------- */
.container {
    width: 100%;
    max-width: 540px;
    padding: 24px 20px 40px 20px;
    margin: 0 auto;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ---------------- Top Control Bar ---------------- */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.badge-status {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    padding: 6px 14px;
    border-radius: 20px;
    font-family: var(--font-subheading);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: #a8b8cc;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-red);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-red);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 46, 67, 0.7); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 8px rgba(255, 46, 67, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 46, 67, 0); }
}

.top-actions {
    display: flex;
    gap: 10px;
}

.icon-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1rem;
}

.icon-btn:hover {
    background: var(--accent-red);
    border-color: var(--accent-red);
    box-shadow: 0 0 15px var(--accent-red-glow);
    transform: translateY(-2px);
}

.icon-btn.active {
    background: var(--accent-red);
    color: #fff;
    box-shadow: 0 0 12px var(--accent-red-glow);
}

/* ---------------- Profile Section ---------------- */
.profile-card {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.avatar-wrapper {
    position: relative;
    width: 104px;
    height: 104px;
    margin-bottom: 4px;
}

.avatar-ring {
    position: absolute;
    top: -6px;
    left: -6px;
    width: 116px;
    height: 116px;
    border-radius: 50%;
    border: 2px dashed var(--accent-red);
    animation: rotateRing 25s linear infinite;
}

@keyframes rotateRing {
    100% { transform: rotate(360deg); }
}

.avatar-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.8), 0 0 15px var(--accent-red-glow);
    background-color: #151921;
}

.verified-badge {
    position: absolute;
    bottom: 2px;
    right: 2px;
    background: linear-gradient(135deg, #ff2e43, #ff6b00);
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.75rem;
    border: 2px solid var(--bg-dark);
    box-shadow: 0 0 8px rgba(0,0,0,0.5);
}

.brand-title {
    font-family: var(--font-heading);
    font-size: 1.85rem;
    font-weight: 900;
    letter-spacing: 2px;
    background: linear-gradient(180deg, #ffffff 30%, #a0aec0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 4px 15px rgba(0,0,0,0.6);
    text-transform: uppercase;
}

.brand-subtitle {
    font-family: var(--font-subheading);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--accent-red);
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
}

.badge-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
}

.badge-item {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 4px 10px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.badge-item i {
    color: var(--accent-red);
}

/* ---------------- Links Container & Cards ---------------- */
.links-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    margin-top: 6px;
}

.link-card {
    position: relative;
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-main);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    text-decoration: none;
    color: var(--text-primary);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-soft);
}

/* Carbon weave effect inside card */
.link-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    transform: skewX(-20deg);
    transition: 0.6s ease;
}

.link-card:hover::before {
    left: 150%;
}

.link-card:hover {
    transform: translateY(-4deg) scale(1.01);
    background: var(--card-hover-bg);
    border-color: rgba(255, 255, 255, 0.25);
}

/* Card Elements */
.card-icon-wrapper {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.brand-svg {
    width: 26px;
    height: 26px;
    transition: var(--transition);
}

.card-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.card-text h2 {
    font-family: var(--font-subheading);
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.card-text p {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-weight: 400;
}

.card-arrow {
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.link-card:hover .card-arrow {
    color: var(--text-primary);
    transform: translateX(4px);
}

/* --- Brand Color Accents --- */

/* 1. Tokopedia */
.card-tokopedia:hover {
    border-color: var(--tokopedia-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--tokopedia-glow);
}
.card-tokopedia .card-icon-wrapper {
    color: var(--tokopedia-color);
}
.card-tokopedia:hover .card-icon-wrapper {
    background: var(--tokopedia-color);
    color: #ffffff;
    box-shadow: 0 0 15px var(--tokopedia-glow);
}

/* 2. Shopee */
.card-shopee:hover {
    border-color: var(--shopee-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--shopee-glow);
}
.card-shopee .card-icon-wrapper {
    color: var(--shopee-color);
}
.card-shopee:hover .card-icon-wrapper {
    background: var(--shopee-color);
    color: #ffffff;
    box-shadow: 0 0 15px var(--shopee-glow);
}

/* 3. Instagram */
.card-instagram:hover {
    border-color: var(--instagram-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--instagram-glow);
}
.card-instagram .card-icon-wrapper {
    color: var(--instagram-color);
}
.card-instagram:hover .card-icon-wrapper {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    color: #ffffff;
    box-shadow: 0 0 15px var(--instagram-glow);
}

/* 4. TikTok */
.card-tiktok:hover {
    border-color: var(--tiktok-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--tiktok-glow);
}
.card-tiktok .card-icon-wrapper {
    color: var(--tiktok-color);
}
.card-tiktok:hover .card-icon-wrapper {
    background: linear-gradient(45deg, #00f2fe, #ff0050);
    color: #ffffff;
    box-shadow: 0 0 15px var(--tiktok-glow);
}

/* 5. WhatsApp */
.card-whatsapp:hover {
    border-color: var(--whatsapp-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--whatsapp-glow);
}
.card-whatsapp .card-icon-wrapper {
    color: var(--whatsapp-color);
}
.card-whatsapp:hover .card-icon-wrapper {
    background: var(--whatsapp-color);
    color: #ffffff;
    box-shadow: 0 0 15px var(--whatsapp-glow);
}

/* 5. Google Maps */
.card-maps:hover {
    border-color: var(--maps-color);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px var(--maps-glow);
}
.card-maps .card-icon-wrapper {
    color: var(--maps-color);
}
.card-maps:hover .card-icon-wrapper {
    background: var(--maps-color);
    color: #ffffff;
    box-shadow: 0 0 15px var(--maps-glow);
}

/* ---------------- Quick Direct CTA Strip ---------------- */
.quick-cta {
    width: 100%;
    margin-top: 6px;
}

.btn-whatsapp-direct {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #25d366, #128c7e);
    border: none;
    border-radius: var(--radius-main);
    color: #ffffff;
    font-family: var(--font-subheading);
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.8px;
    text-decoration: none;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
    transition: var(--transition);
}

.btn-whatsapp-direct:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.5);
    filter: brightness(1.1);
}

/* ---------------- Footer & Tachometer Graphic ---------------- */
.footer {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.tachometer-graphic {
    position: relative;
    width: 120px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 6px;
}

.tacho-line {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, var(--tokopedia-color), var(--accent-orange), var(--accent-red));
}

.tacho-needle {
    position: absolute;
    top: 0;
    left: 0;
    width: 30px;
    height: 100%;
    background: #ffffff;
    filter: blur(2px);
    animation: sweepGauge 3s infinite alternate ease-in-out;
}

@keyframes sweepGauge {
    0% { left: 0%; }
    100% { left: calc(100% - 30px); }
}

.footer-tagline {
    font-family: var(--font-subheading);
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-secondary);
}

/* ---------------- Modal & Popup Styling ---------------- */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 999;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    position: relative;
    background: #121720;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 28px;
    width: 100%;
    max-width: 380px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.close-btn {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.6rem;
    cursor: pointer;
    transition: var(--transition);
}

.close-btn:hover {
    color: var(--accent-red);
}

.modal-header {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-subheading);
    font-size: 1.2rem;
    color: var(--text-primary);
}

.modal-header i {
    color: var(--accent-red);
}

.qr-container {
    background: #ffffff;
    padding: 12px;
    border-radius: 14px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

.qr-container img {
    display: block;
    width: 150px;
    height: 150px;
}

.copy-box {
    display: flex;
    width: 100%;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 6px;
    border-radius: 12px;
}

.copy-box input {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 8px;
    font-size: 0.85rem;
    outline: none;
}

.btn-copy {
    background: var(--accent-red);
    border: none;
    color: #ffffff;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-subheading);
    font-weight: 700;
    transition: var(--transition);
}

.btn-copy:hover {
    background: #e02437;
}

.copy-toast {
    display: none;
    font-size: 0.8rem;
    color: #25d366;
    font-weight: 600;
}

/* ---------------- Responsive Web Design (RWD) ---------------- */

/* Mobile Small (< 380px) */
@media (max-width: 380px) {
    .container {
        padding: 16px 14px 30px 14px;
        gap: 16px;
    }

    .brand-title {
        font-size: 1.5rem;
    }

    .brand-subtitle {
        font-size: 0.82rem;
    }

    .link-card {
        padding: 14px 16px;
    }

    .card-icon-wrapper {
        width: 42px;
        height: 42px;
        min-width: 42px;
        margin-right: 12px;
    }

    .brand-svg {
        width: 22px;
        height: 22px;
    }

    .card-text h2 {
        font-size: 1rem;
    }

    .card-text p {
        font-size: 0.75rem;
    }
}

/* Tablet & Up (> 540px) */
@media (min-width: 541px) {
    .container {
        padding-top: 40px;
        padding-bottom: 50px;
    }

    .link-card {
        padding: 18px 24px;
    }

    .card-text h2 {
        font-size: 1.25rem;
    }

    .card-text p {
        font-size: 0.88rem;
    }
}
