/* ============================================================
   Halaman unduhan aplikasi — app.dhybr.id/<slug>/
   Tata letak dua kolom, pas satu layar pada laptop/PC.
   ============================================================ */

:root {
    --bg: #f5f5fa;
    --card: #ffffff;
    --line: #d1d1d9;
    --fg: #1a1a2e;
    --muted: #4a4a5e;
    --dim: #6c6c8a;
    --accent: #86198f;
    --accent2: #a21caf;
    --gold: #f5c518;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
    background: var(--bg);
    color: var(--fg);
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.5;
    overflow: hidden;           /* satu layar, tanpa scroll halaman */
    -webkit-font-smoothing: antialiased;
}
.wrap {
    height: 100%;
    max-width: 1060px;
    margin: 0 auto;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* ---- Header ---- */
.head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.logo {
    width: 44px; height: 44px;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--accent), var(--accent2));
    color: #fff;
    font-size: 22px; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 20px rgba(134, 25, 143, .28);
}
.head h1 { margin: 0; font-size: 22px; letter-spacing: .2px; }
.tag { margin: 1px 0 0; color: var(--muted); font-size: 13px; }
.ver-badge {
    background: #f3e8f5;
    border: 1px solid #e2c9e6;
    color: var(--accent);
    font-weight: 700;
    font-size: 12.5px;
    padding: 6px 13px;
    border-radius: 999px;
    white-space: nowrap;
}

/* ---- Tata letak dua kolom mengisi sisa tinggi ---- */
.grid {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 18px;
}
.panel {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 12px 40px rgba(26, 26, 46, .10);
    display: flex;
    flex-direction: column;
    min-height: 0;
}
.panel-title {
    margin: 0 0 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--dim);
    flex: none;
}
.panel-scroll {
    flex: 1;
    min-height: 0;
    overflow: auto;             /* isi panel yang bisa digulir sendiri */
    padding-right: 4px;
}

/* ---- Kolom kiri: unduhan ---- */
.notes { margin: 0 0 14px; color: var(--muted); font-size: 13.5px; }
.facts {
    list-style: none;
    margin: 0 0 14px;
    padding: 0;
    border-top: 1px solid var(--line);
}
.facts li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 0;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
}
.facts span { color: var(--dim); }
.facts strong { color: var(--fg); font-weight: 600; text-align: right; }
.btn {
    display: block;
    text-align: center;
    text-decoration: none;
    background: linear-gradient(145deg, var(--accent), var(--accent2));
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    padding: 12px 18px;
    border-radius: 12px;
    box-shadow: 0 10px 24px rgba(134, 25, 143, .30);
    transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(134, 25, 143, .38);
}
.btn-off {
    display: block;
    text-align: center;
    background: #ecebf1;
    color: var(--dim);
    font-size: 15px;
    font-weight: 700;
    padding: 12px 18px;
    border-radius: 12px;
    cursor: not-allowed;
}
.steps {
    margin: 14px 0 8px;
    padding-left: 20px;
    color: var(--muted);
    font-size: 13px;
}
.steps li { margin: 3px 0; }
.steps code, .md5-box code, .hint code {
    background: #f0eef5;
    border: 1px solid var(--line);
    border-radius: 5px;
    padding: 1px 6px;
    font-size: 12px;
    color: var(--accent);
}
.hint { margin: 6px 0 0; font-size: 12px; color: var(--dim); }

/* ---- Blok MD5 ---- */
.md5-box {
    margin-top: 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 10px 12px;
    background: #faf9fc;
}
.md5-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--dim);
    margin-bottom: 6px;
}
.md5-row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.md5-row code {
    flex: 1;
    min-width: 0;
    overflow-wrap: anywhere;
    font-family: "Consolas", "Courier New", monospace;
    font-size: 12px;
    color: var(--fg);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
}
.copy {
    flex: none;
    cursor: pointer;
    border: 1px solid var(--accent);
    background: #fff;
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 6px;
    transition: background .12s ease, color .12s ease;
}
.copy:hover { background: var(--accent); color: #fff; }

/* ---- Kolom kanan: riwayat versi ---- */
.timeline {
    list-style: none;
    margin: 0;
    padding: 0 0 0 6px;
}
.rel {
    position: relative;
    padding: 0 0 16px 22px;
    border-left: 2px solid var(--line);
}
.rel:last-child { border-left-color: transparent; padding-bottom: 0; }
.rel::before {
    content: "";
    position: absolute;
    left: -7px; top: 3px;
    width: 12px; height: 12px;
    border-radius: 50%;
    background: var(--card);
    border: 2px solid var(--line);
}
.rel:first-child::before {
    background: var(--accent);
    border-color: var(--accent);
}
.rel-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.rel-ver { font-weight: 700; font-size: 15px; color: var(--accent); }
.rel-date { margin-left: auto; font-size: 12px; color: var(--dim); }
.tag-latest {
    background: var(--gold);
    color: #3a2c00;
    font-size: 10.5px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.rel-title { margin-top: 3px; font-weight: 600; font-size: 13.5px; }
.rel-notes { margin: 3px 0 0; font-size: 13px; color: var(--muted); }

/* ---- Footer ---- */
.foot {
    flex: none;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: var(--dim);
}
.foot a { color: var(--accent); text-decoration: none; font-weight: 600; }
.foot a:hover { text-decoration: underline; }
.foot .usage { color: var(--accent); font-weight: 600; }

/* ---- Ponsel/tablet kecil: izinkan satu kolom & scroll normal ---- */
@media (max-width: 820px) {
    body { overflow: auto; }
    .wrap { height: auto; }
    .grid { grid-template-columns: 1fr; }
    .panel-scroll { overflow: visible; }
}
