/* =========================================
   SECTION ISI — Tools · Research · Certifications · Business · Blog · Contact
   ========================================= */

/* --- TOOLS I USE ----------------------------------------------------- */
.tools-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1.75rem 2rem;
    margin: 1.25rem 0 0;
    padding: 0;
    list-style: none;
}

.tool-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.625rem;
    width: 4rem;
}

/* Kanvas tetap 48×48 supaya semua ikon sejajar; logo di dalamnya
   diskalakan lewat atribut style agar ukuran tampaknya seragam. */
.tool-icon-slot {
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-icon {
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(15, 23, 42, 0.1));
    transition: transform 0.25s var(--ease-spring), filter 0.3s ease;
}
.tool-item:hover .tool-icon {
    transform: scale(1.14);
    filter: drop-shadow(0 6px 10px rgba(15, 23, 42, 0.18));
}

.tool-icon-empty {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    border-radius: 0.625rem;
    background: var(--border);
    color: var(--faint);
    font-size: 0.8125rem;
    font-weight: 900;
}

.tool-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--muted);
    text-align: center;
    line-height: 1.3;
    transition: color 0.2s ease;
}
.tool-item:hover .tool-label { color: var(--ink); }

/* =========================================
   RESEARCH & CREDENTIALS
   Keduanya memakai anatomi kartu yang sama: pita aksen berwarna jenis di
   tepi kiri, satu ubin penjangkar (tahun / ikon), isi di tengah, dan panah
   di kanan. Seluruh kartu bisa diklik lewat pola "stretched link", jadi
   sasaran kliknya lebar tanpa menambah tautan kedua bagi pembaca layar.
   ========================================= */

/* Warna per jenis — dipakai pita, ubin, dan panah. */
.pub-item--journal,    .cert-item--journal    { --k: #2563eb; --k-bg: #eff6ff; --k-bd: #bfdbfe; }
.pub-item--proceeding, .cert-item--proceeding { --k: #6d28d9; --k-bg: #f5f3ff; --k-bd: #ddd6fe; }
.pub-item--thesis,     .cert-item--thesis     { --k: #b45309; --k-bg: #fffbeb; --k-bd: #fde68a; }
.cert-item--certification                     { --k: #15803d; --k-bg: #f0fdf4; --k-bd: #bbf7d0; }
.cert-item--speaker                           { --k: #be123c; --k-bg: #fff1f2; --k-bd: #fecdd3; }
.cert-item--ip                                { --k: #0369a1; --k-bg: #f0f9ff; --k-bd: #bae6fd; }

.pub-list, .cert-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.pub-item, .cert-item {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    background: #fff;
    border: 2px solid var(--border-strong);
    border-radius: 0.875rem;
    box-shadow: var(--lip);
    padding: 0.9375rem 1rem;
    transition: transform 0.2s var(--ease-out),
                border-color 0.2s ease,
                box-shadow 0.2s ease;
}

/* Jenis ditandai badge dan ubin kiri saja — tanpa pita warna di tepi. */
.pub-item:hover, .cert-item:hover {
    transform: translateY(-2px);
    border-color: #cbd5e1;
    box-shadow: 0 4px 0 var(--border-strong);
}

/* Seluruh kartu jadi sasaran klik. Tautan aslinya tetap satu, sehingga
   pembaca layar tidak mendengar tautan ganda. */
.pub-item.is-linked .pub-title::after,
.cert-item.is-linked .cert-title::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
}
.pub-item.is-linked, .cert-item.is-linked { cursor: pointer; }

/* Fokus keyboard menyorot seluruh kartu, bukan sepotong teks. */
.pub-item.is-linked:focus-within,
.cert-item.is-linked:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
.pub-item.is-linked .pub-title:focus-visible,
.cert-item.is-linked .cert-title:focus-visible { outline: none; }

/* --- Ubin tahun (Research) ------------------------------------------- */
.pub-year {
    flex-shrink: 0;
    width: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.375rem 0;
    border: 1.5px solid var(--border);
    border-radius: 0.5rem;
    background: #f8fafc;
}
.pub-year .y {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--ink-soft);
    letter-spacing: -0.02em;
}
.pub-year .y--empty { color: var(--faint); }

/* --- Ubin ikon (Credentials) ----------------------------------------- */
.cert-icon {
    flex-shrink: 0;
    width: 2.375rem;
    height: 2.375rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--k-bd, var(--border));
    border-radius: 0.625rem;
    background: var(--k-bg, #f8fafc);
    color: var(--k, var(--muted));
    transition: transform 0.25s var(--ease-spring);
}
.cert-icon svg { width: 1.125rem; height: 1.125rem; }
.cert-item:hover .cert-icon { transform: scale(1.08); }

/* --- Isi kartu -------------------------------------------------------- */
.pub-main, .cert-main { flex: 1; min-width: 0; display: block; }

.pub-meta, .cert-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.375rem;
}

.pub-cited {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.125rem 0.4375rem;
    border-radius: 999px;
    border: 1.5px solid var(--border-strong);
    background: #f8fafc;
    font-size: 0.6875rem;
    font-weight: 800;
    color: var(--muted);
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}
/* Yang sitasinya sudah banyak diberi bobot lebih. */
.pub-cited--high {
    border-color: #fde68a;
    background: #fffbeb;
    color: #b45309;
}

.cert-date {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--faint);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    white-space: nowrap;
}

.pub-title, .cert-title {
    display: block;
    font-size: 0.9375rem;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.4;
    letter-spacing: -0.01em;
    margin: 0;
    transition: color 0.2s ease;
}
.pub-item.is-linked:hover .pub-title,
.cert-item.is-linked:hover .cert-title { color: var(--k, var(--accent)); }
.pub-title--plain, .cert-title--plain { cursor: default; }

.pub-authors, .cert-issuer {
    display: block;
    margin-top: 0.3125rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--muted);
    line-height: 1.5;
}

.pub-venue {
    display: block;
    margin-top: 0.1875rem;
    font-size: 0.75rem;
    font-weight: 600;
    font-style: italic;
    color: var(--faint);
}

.cert-credential {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--faint);
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* --- Panah kanan ------------------------------------------------------ */
.pub-go, .cert-go {
    flex-shrink: 0;
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 0.5rem;
    color: var(--faint);
    opacity: 0.65;
    transition: color 0.2s ease, opacity 0.2s ease,
                background-color 0.2s ease, transform 0.2s var(--ease-out);
}
.pub-item:hover .pub-go, .cert-item:hover .cert-go {
    color: var(--k, var(--accent));
    background: var(--k-bg, var(--border));
    opacity: 1;
    transform: translate(2px, -2px);
}

@media (max-width: 480px) {
    /* Layar sempit: panah dilepas, ubin dikecilkan — ruang untuk judul. */
    .pub-go, .cert-go { display: none; }
    .pub-item, .cert-item { gap: 0.75rem; padding-right: 0.875rem; }
    .pub-year { width: 2.625rem; }
}

/* --- Halaman /publications ------------------------------------------- */
.pub-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: #fff;
    border: 2px solid var(--border-strong);
    border-radius: 1rem;
    box-shadow: var(--lip);
    margin-bottom: 2.5rem;
}

.pub-summary-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.pub-summary-stat { display: flex; flex-direction: column; }
.pub-summary-stat .v {
    font-family: 'Nunito', sans-serif;
    font-size: 1.25rem;
    font-weight: 900;
    color: var(--ink);
    line-height: 1.1;
    letter-spacing: -0.02em;
}
.pub-summary-stat .l {
    margin-top: 0.125rem;
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--faint);
    white-space: nowrap;
}

.pub-summary-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3125rem;
    padding: 0.4375rem 0.875rem;
    border-radius: 0.625rem;
    border: 2px solid var(--border-strong);
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--muted);
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s, background-color 0.2s;
}
.pub-summary-link:hover {
    color: var(--accent);
    border-color: #bfdbfe;
    background: var(--accent-soft);
}

/* Kepala tiap kelompok jenis (Journal / Proceeding / Thesis) */
.pub-group-head {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin-bottom: 1rem;
}

.pub-group-count {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--faint);
}

.pub-group-rule {
    flex: 1;
    height: 2px;
    border-radius: 2px;
    background: var(--border);
}

/* --- BUSINESS -------------------------------------------------------- */
.biz-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.875rem;
}

@media (min-width: 640px) {
    .biz-grid { grid-template-columns: repeat(2, 1fr); }
}

.biz-card {
    background: #fff;
    border: 2px solid var(--border-strong);
    border-radius: 1rem;
    box-shadow: var(--lip);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s var(--ease-out), border-color 0.2s ease;
}
.biz-card:hover { transform: translateY(-3px); border-color: #cbd5e1; }

.biz-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.875rem;
}

.biz-logo {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.75rem;
    border: 2px solid var(--border);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}
.biz-logo img { width: 100%; height: 100%; object-fit: contain; padding: 2px; }
.biz-icon { font-size: 1.25rem; line-height: 1; }

.biz-category {
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--faint);
    background: #f8fafc;
    border: 1px solid var(--border);
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    white-space: nowrap;
}

.biz-name {
    margin: 0;
    font-size: 1rem;
    font-weight: 800;
    color: var(--ink);
    letter-spacing: -0.015em;
}

.biz-subtitle {
    margin: 0.1875rem 0 0;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--muted);
}

.biz-desc {
    margin: 0.625rem 0 0;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--muted);
    line-height: 1.6;
}

.biz-link {
    margin-top: auto;
    padding-top: 0.875rem;
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--accent);
}

/* --- DAFTAR ARTIKEL (home & /blog) ----------------------------------- */
.post-list { display: flex; flex-direction: column; gap: 0.5rem; }

.post-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.875rem 1rem;
    background: #fff;
    border: 2px solid var(--border-strong);
    border-radius: 0.875rem;
    box-shadow: var(--lip);
    transition: transform 0.2s var(--ease-out), border-color 0.2s ease;
}
.post-row:hover { transform: translateY(-2px); border-color: #cbd5e1; }

.post-date {
    flex-shrink: 0;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.625rem;
    background: var(--accent-soft);
    color: #1d4ed8;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.post-date .d { font-size: 0.9375rem; font-weight: 900; }
.post-date .m { font-size: 0.5625rem; font-weight: 800; text-transform: uppercase;
                letter-spacing: 0.06em; margin-top: 0.125rem; }

.post-info { flex: 1; min-width: 0; }

.post-title {
    margin: 0;
    font-size: 0.9375rem;
    font-weight: 800;
    color: var(--ink);
    letter-spacing: -0.01em;
    line-height: 1.35;
}

.post-excerpt {
    margin: 0.25rem 0 0;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--muted);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-arrow {
    flex-shrink: 0;
    color: var(--faint);
    font-weight: 800;
    transition: transform 0.2s var(--ease-out), color 0.2s ease;
}
.post-row:hover .post-arrow { transform: translateX(3px); color: var(--accent); }

.post-empty {
    padding: 3rem 1rem;
    text-align: center;
    color: var(--muted);
    font-weight: 600;
    font-size: 0.9375rem;
}

/* --- CONTACT --------------------------------------------------------- */
.contact-card {
    background: #fff;
    border: 2px solid var(--border-strong);
    border-radius: 1rem;
    box-shadow: var(--lip);
    padding: 1.5rem;
}

.contact-lead {
    margin: 0 0 1.25rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--muted);
    line-height: 1.65;
}

.contact-details { margin: 0; padding: 0; }

.contact-row {
    display: flex;
    gap: 1rem;
    padding: 0.625rem 0;
    border-top: 1px solid var(--border);
}

.contact-row dt {
    flex-shrink: 0;
    width: 5rem;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--faint);
    padding-top: 0.125rem;
}

.contact-row dd {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--ink-soft);
}
.contact-row dd a { color: var(--accent); }
.contact-row dd a:hover { text-decoration: underline; }

.contact-cta { margin-top: 1.5rem; }
