/*
========================================
PRODUCT GRID – Nyaman di HP & Desktop
- HP (≤600px): 2 kolom, font & tombol lebih kecil
- Desktop: grid fleksibel 3–4 kolom
- Ubah warna aksen di :root (--accent-a, --accent-b)
========================================
*/
:root{
  --card-bg: rgba(35, 35, 45, 0.7);
  --ring: rgba(255,255,255,.1);
  --accent-a: #0077ff;
  --accent-b: #00c6ff;
  --text: #ffffff;
  --shadow: 0 8px 24px rgba(0,0,0,.35);
}

*{ box-sizing: border-box; }

/* Background halus (butuh  di HTML) */
body{
  margin:0;
  font-family:'Inter',system-ui,-apple-system,Segoe UI,Roboto,sans-serif;
  color:var(--text);
}
.page-bg{
  position: fixed;
  inset: 0;
  z-index:-1;
  background:
    radial-gradient(800px 400px at 10% -10%, #0b1b2d 0%, transparent 60%),
    radial-gradient(1000px 600px at 90% 110%, #0f2037 0%, transparent 60%),
    linear-gradient(180deg, #07090f, #0c1220 60%, #07090f 100%);
}

/* Container */
.product-grid-container{
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 16px;
}
.section-title{
  text-align:center;
  font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.1rem);
  font-weight:800;
  letter-spacing:-0.02em;
  margin:0 0 28px 0;
}

/* Grid (default) */
.product-grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  align-items: stretch;
}

/* HP: paksa 2 kolom & kecilkan elemen */
@media (max-width: 600px){
  .product-grid{
    grid-template-columns: repeat(2, minmax(0,1fr)) !important;
    gap: 12px;
  }
}

/* Card */
.product-card{
  background: var(--card-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border:1px solid var(--ring);
  border-radius:16px;
  box-shadow: var(--shadow);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  width:100%;
  transition: transform .3s ease, box-shadow .3s ease;
  animation: fadeIn .45s ease-out both;
}
@keyframes fadeIn{
  from{ opacity:0; transform: translateY(12px); }
  to{ opacity:1; transform: translateY(0); }
}

/* Hover berat hanya di desktop */
@media (hover:hover) and (pointer:fine){
  .product-card:hover{
    transform: translateY(-6px);
    box-shadow: 0 16px 36px rgba(0,0,0,.5);
  }
}

/* Header logo: konsisten tinggi, anti layout shift */
.product-card-header{
  display:grid;
  place-items:center;
  padding:16px;
  background: rgba(0,0,0,.18);
  aspect-ratio: 16 / 9;
  min-height: 120px; /* fallback */
}
.product-card-logo{
  max-width:72%;
  max-height:72px;
  object-fit:contain;
  filter: drop-shadow(0 0 10px rgba(0,0,0,.35));
}

/* Body & Title */
.product-card-body{
  padding:16px;
  display:flex;
  flex-direction:column;
  gap:10px;
  flex:1 1 auto;
}
.product-card-title{
  font-size: clamp(.98rem, .9rem + .4vw, 1.15rem);
  font-weight:700;
  margin:0;
  text-align:center;
  line-height:1.3;
}
.product-card-title a{
  color:var(--text);
  text-decoration:none;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  transition: color .25s ease;
}
.product-card-title a:hover{ color: var(--accent-b); }

/* Footer */
.product-card-footer{ margin-top:auto; text-align:center; }
.product-card-price{
  font-size: clamp(1.1rem, 1rem + .6vw, 1.5rem);
  font-weight:800;
  margin:0 0 10px 0;
  text-shadow: 0 0 10px rgba(0,191,255,.4);
}

/* Tombol – aksesibel, nyaman disentuh */
.product-card-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:44px;          /* desktop/tablet default */
  padding:10px 22px;
  border-radius:999px;
  border:none;
  font-weight:700;
  font-size:.95rem;
  color:#fff;
  text-decoration:none;
  background: linear-gradient(45deg, var(--accent-a), var(--accent-b));
  box-shadow:0 4px 15px rgba(0,150,255,.3);
  transition: transform .15s ease, box-shadow .15s ease, opacity .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.product-card-button:hover{
  transform: translateY(-1px);
  box-shadow:0 6px 20px rgba(0,150,255,.45);
}
.product-card-button:active{
  transform: translateY(0);
  box-shadow:0 2px 10px rgba(0,150,255,.35);
}

/* Fokus keyboard yang jelas (aksesibilitas) */
.product-card-button:focus-visible,
.product-card-title a:focus-visible{
  outline: 3px solid #7dd3fc;
  outline-offset: 3px;
  border-radius: 10px;
}

/* ===============================
   TUNING MOBILE: font & tombol kecil
   =============================== */
@media (max-width: 600px){
  .section-title{
    font-size: 1.2rem;          /* lebih kecil di HP */
    margin-bottom: 18px;
    letter-spacing: -0.015em;
  }
  .product-card-header{
    aspect-ratio: 16 / 10;      /* sedikit lebih ramping */
    min-height: 0;
  }
  .product-card-logo{ max-height: 56px; }

  .product-card-body{ padding: 12px; gap: 8px; }

  .product-card-title{
    font-size: .82rem;           /* ↓ dari default */
    line-height: 1.25;
  }
  .product-card-price{
    font-size: 1rem;             /* ↓ dari default */
    margin-bottom: 6px;
    text-shadow: 0 0 6px rgba(0,191,255,.35);
  }
  .product-card-button{
    min-height: 34px;            /* ↓ dari 44px */
    padding: 6px 12px;           /* ↓ dari 10px 22px */
    font-size: .75rem;           /* ↓ dari .95rem */
    box-shadow: 0 2px 8px rgba(0,150,255,.22);
  }
}

/* Layar mini (≤380px): lebih padat lagi */
@media (max-width: 380px){
  .product-grid{ gap: 10px; }
  .product-card-body{ padding: 8px; }
  .product-card-title{ font-size: .78rem; }
  .product-card-price{ font-size: .95rem; }
  .product-card-button{
    min-height: 32px;
    padding: 6px 10px;
    font-size: .72rem;
  }
  .product-card-header{ aspect-ratio: 16 / 11; }
  .product-card-logo{ max-height: 50px; }
}

/* Desktop tweaks */
@media (min-width: 1024px){
  .product-grid{ gap: 20px; }
  .product-card{ border-radius: 20px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  .product-card{ animation:none; transition:none; }
  .product-card-button{ transition:none; }
}

/*
========================================
SECTION: SERTIFIKAT PROFESIONAL
========================================
*/

.certificate-container {
  font-family: 'Inter', sans-serif;
  max-width: 1200px;
  margin: 60px auto 40px auto;
  padding: 0 15px;
}

.certificate-container .section-title {
  text-align: center;
  font-size: 32px !important;
  font-weight: 800 !important;
  color: #ffffff !important;
  margin-bottom: 40px !important;
  letter-spacing: -1px;
}

/* FIX: Warna judul saat tema terang */
html[data-bs-theme="light"] .certificate-container .section-title,
html[data-theme="light"] .certificate-container .section-title {
  color: #212529 !important;
}

/* Style untuk setiap baris sertifikat */
.certificate-item {
  display: flex;
  align-items: center;
  background: rgba(35, 35, 45, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 25px;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.certificate-item:hover {
  background: rgba(45, 45, 55, 0.6);
  border-color: rgba(255, 255, 255, 0.2);
}

/* Kolom Kiri: Gambar Sertifikat */
.certificate-image-wrapper {
  flex-shrink: 0;
  margin-right: 30px;
}

.certificate-image-wrapper img {
  width: 250px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.certificate-image-wrapper img:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 25px rgba(0,0,0,0.4);
}

/* Kolom Kanan: Detail Teks */
.certificate-details {
  flex-grow: 1;
}

.certificate-header {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.certificate-title {
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  margin: 0 15px 5px 0 !important; /* Margin bawah jika wrap */
}

.certificate-year {
  background-color: #0077ff;
  color: #ffffff;
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 6px;
  line-height: 1;
}

.certificate-description {
  font-size: 15px !important;
  color: #cccccc !important;
  line-height: 1.7 !important;
  margin: 0 !important;
}

/* Style untuk Subtitle Baru */
.certificate-subtitle {
  font-size: 16px !important;
  font-style: italic !important;
  color: #b0b0b0 !important; /* Warna abu-abu yang sedikit lebih terang dari deskripsi */
  line-height: 1.5 !important;
  margin-top: -8px !important; /* Tarik sedikit ke atas agar lebih dekat dengan judul */
  margin-bottom: 15px !important;
}

/* Pengaturan untuk layar mobile (Responsif) */
@media (max-width: 768px) {
  .certificate-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .certificate-image-wrapper {
    margin-right: 0;
    margin-bottom: 25px;
    width: 100%;
  }

  .certificate-image-wrapper img {
    width: 100%;
  }
}

/*
========================================
SECTION: SERTIFIKAT PROFESIONAL
========================================
*/

.certificate-container {
  font-family: 'Inter', sans-serif;
  max-width: 1200px;
  margin: 60px auto 40px auto;
  padding: 0 15px;
}

.certificate-container .section-title {
  text-align: center;
  font-size: 32px !important;
  font-weight: 800 !important;
  color: #ffffff !important;
  margin-bottom: 40px !important;
  letter-spacing: -1px;
}

/* FIX: Warna judul saat tema terang */
html[data-bs-theme="light"] .certificate-container .section-title,
html[data-theme="light"] .certificate-container .section-title {
  color: #212529 !important;
}

/* Style untuk setiap baris sertifikat */
.certificate-item {
  display: flex;
  align-items: center;
  background: rgba(35, 35, 45, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 25px;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.certificate-item:hover {
  background: rgba(45, 45, 55, 0.6);
  border-color: rgba(255, 255, 255, 0.2);
}

/* Kolom Kiri: Gambar Sertifikat */
.certificate-image-wrapper {
  flex-shrink: 0;
  margin-right: 30px;
}

.certificate-image-wrapper img {
  width: 250px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.certificate-image-wrapper img:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 25px rgba(0,0,0,0.4);
}

/* Kolom Kanan: Detail Teks */
.certificate-details {
  flex-grow: 1;
}

.certificate-header {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.certificate-title {
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  margin: 0 15px 5px 0 !important; /* Margin bawah jika wrap */
}

.certificate-year {
  background-color: #0077ff;
  color: #ffffff;
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 6px;
  line-height: 1;
}

.certificate-description {
  font-size: 15px !important;
  color: #cccccc !important;
  line-height: 1.7 !important;
  margin: 0 !important;
}

/* Style untuk Subtitle Baru */
.certificate-subtitle {
  font-size: 16px !important;
  font-style: italic !important;
  color: #b0b0b0 !important; /* Warna abu-abu yang sedikit lebih terang dari deskripsi */
  line-height: 1.5 !important;
  margin-top: -8px !important; /* Tarik sedikit ke atas agar lebih dekat dengan judul */
  margin-bottom: 15px !important;
}

/* Pengaturan untuk layar mobile (Responsif) */
@media (max-width: 768px) {
  .certificate-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .certificate-image-wrapper {
    margin-right: 0;
    margin-bottom: 25px;
    width: 100%;
  }

  .certificate-image-wrapper img {
    width: 100%;
  }
}