/* ============================
   GLOBAL
============================ */
html,
body {
    height: 100%;
    margin: 0;
}

body {
    overflow: hidden;
    font-family: Arial, Helvetica, sans-serif;
}

/* ============================
   APP LAYOUT
============================ */
#app {
    display: flex;
    height: calc(100vh - 56px); /* tinggi navbar bootstrap */
}

/* ============================
   VIEWER
============================ */
#preview {
    flex: 1;
    position: relative;
    background-color: #f0f0f0;
}

/* ============================
   SIDEBAR (RIGHT)
============================ */
#sidebar {
    width: 260px;
    background-color: #f8f9fa;
    border-left: 1px solid #ddd;
    padding: 12px;
    overflow-y: auto;
}

#sidebar h5 {
    font-weight: 600;
}

#sidebar {
    display: flex;
    flex-direction: column;
}
/* ============================
   SIDEBAR TITLES
============================ */
#sidebar h6,
#sidebar label.form-label {
    font-weight: 700; /* bold */
}
#statusContainer {
    margin-top: 16px;
}
/* ============================
   TOOLTIP
============================ */
#tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    color: #ffffff;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 13px;
    pointer-events: none;
    display: none;
    z-index: 1000;
}

/* ============================
   FORGE VIEWER OVERRIDE
============================ */
#timeline {
    display: none !important;
}

#modelUnavailable {
    position: absolute;
    inset: 0;
    background: rgba(240, 240, 240, 0.95);
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
    color: #b00020;
    z-index: 999;
}
/* ============================
   MODE TOGGLE (PILL STYLE)
============================ */
.mode-toggle {
    display: flex;
    background: #5a566b;
    border-radius: 999px;
    padding: 4px;
    gap: 4px;
}

.mode-toggle input {
    display: none;
}

.mode-toggle label {
    flex: 1;
    text-align: center;
    padding: 6px 0;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: #ffffff;
    transition: all 0.2s ease;
}

/* ACTIVE */
.mode-toggle input:checked + label {
    background: #ffffff;
    color: #1f1f1f;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* HOVER */
.mode-toggle label:hover {
    background: rgba(255,255,255,0.15);
}
.status-panel {
    margin-top: 12px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 12px;
}

.status-grid {
    display: grid;
    grid-template-columns: 70px 12px auto; /* LABEL | = | VALUE */
    column-gap: 6px;
    align-items: center;
    margin-bottom: 6px;
}

.status-label {
    font-weight: 600;
}

.status-eq {
    text-align: center;
}

.status-value {
    word-break: break-word;
}
.legend-panel {
    margin-top: auto;
    padding-top: 8px;
    border-top: 1px solid #333;
    font-size: 11px;
}

.legend-title {
    font-weight: 600;
    margin-bottom: 6px;
    color: #ccc;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    font-size: 14px;      /* FONT LEBIH BESAR */
    font-weight: 500;    /* SEDIKIT LEBIH TEGAS */
}

.legend-box {
    width: 14px;
    height: 14px;
    border-radius: 2px;
    display: inline-block;
    border: 2px solid #000;   /* BORDER HITAM TEBAL */
    box-sizing: border-box;
}

/* WARNA SESUAI STATUS_COLOR */
.legend-box.unavailable { background: rgb(255, 0, 0); }
.legend-box.notyet      { background: rgb(255, 255, 0); }
.legend-box.done        { background: rgb(255, 165, 0); }
.legend-box.finish      { background: rgb(0, 255, 0); }
.legend-box.installed   { background: rgb(0, 0, 255); }

.legend-box.comm-red    { background: rgb(255, 0, 0); }
.legend-box.comm-yellow { background: rgb(255, 255, 0); }
.legend-box.comm-orange { background: rgb(255, 165, 0); }
.legend-box.comm-green  { background: rgb(0, 255, 0); }
.legend-box.comm-blue   { background: rgb(0, 0, 255); }

#statusEmpty {
    font-size: 18px;
    font-weight: 600;
    color: #6c757d;
    text-align: center;
    padding: 20px 10px;
    border: 1px dashed #ccc;
    border-radius: 6px;
}

#preview-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

#preview {
    width: 100%;
    height: 100%;
}

/* OVERLAY */
#welcomeOverlay {
    position: absolute;
    inset: 0;
    background: #e2e7ec;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    text-align: center;
}

.welcome-content h2 {
    font-size: 40px;
    font-weight: 600;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.welcome-content h1 {
    font-size: 50px;
    font-weight: 700;
    margin: 12px 0 4px;
}

.welcome-content h3 {
    font-size: 30px;
    font-weight: 500;
    color: #3f3f3f;
}

.welcome-hint {
    margin-top: 28px;
    font-size: 28px;
    font-weight: 600;
    color: #000000;
}
.welcome-logos {
    display: flex;
    gap: 32px;
    margin: 20px 0;
}

.welcome-logos img {
    height: 400px !important;
    width: auto !important;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .welcome-logos img {
        height: 80px !important;
    }
}
