/* ---------- THEME ---------- */
:root{
  --bg: #0b0f14;
  --bg-soft: #0f141b;
  --text: #e8fff7;
  --muted: #9fe6d1;
  --neon: #00ffa6;
  --cyan: #00e5ff;
  --border: #18313a;
  --shadow: 0 0 18px rgba(0,255,166,.24), 0 0 40px rgba(0,229,255,.14);
}

*{ box-sizing:border-box; }
html,body{ height:100%; scroll-behavior:smooth; }
body{
  margin:0; background:var(--bg); color:var(--text);
  font: 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  overflow-x:hidden;
}

/* ---------- NAVBAR ---------- */
.navbar{
  position:fixed; top:0; left:0; right:0; z-index:1000;
  display:flex; align-items:center; gap:1rem;
  padding: .9rem 1rem;
  background: linear-gradient(180deg, rgba(0,0,0,.65), rgba(0,0,0,.35));
  border-bottom:1px solid #0e2a2f;
  backdrop-filter: blur(8px);
}
.navbar.scrolled{ box-shadow: 0 6px 30px rgba(0,0,0,.35); }
.brand{
  font-weight:800; letter-spacing:.5px; text-decoration:none; color:var(--neon);
  text-shadow: 0 0 10px var(--neon), 0 0 25px rgba(0,255,166,.7);
}
.navbar nav{ display:flex; gap:1rem; margin-left:auto; }
.navbar .nav-link{
  color:var(--muted); text-decoration:none; padding:.35rem .6rem; border-radius:12px;
  transition:.25s ease; border:1px solid transparent;
}
.navbar .nav-link:hover{ color:var(--text); text-shadow:0 0 8px var(--cyan); }
.navbar .nav-link.active{ border-color:#144e57; box-shadow: var(--shadow); color:var(--text); }
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem;
  padding:.55rem .9rem; border-radius:14px; text-decoration:none; cursor:pointer;
  border:1px solid #155a65; transition:.25s ease; white-space:nowrap;
}
.btn-primary{ background:linear-gradient(90deg, var(--neon), var(--cyan)); color:#051110; font-weight:700; }
.btn-primary:hover{ filter:brightness(1.08); box-shadow: var(--shadow); }
.btn-outline{ color:var(--text); background:transparent; }
.btn-outline:hover{ box-shadow: var(--shadow); color:var(--text); }
.btn-ghost{ color:var(--muted); border-color:#13444d; }
.btn-ghost:hover{ color:var(--text); box-shadow:var(--shadow); }

.mobile-toggle{ display:none; background:transparent; border:0; margin-left:.25rem; }
.mobile-toggle span{ display:block; width:24px; height:2px; background:#93ffe0; margin:5px 0; border-radius:2px; }

/* ---------- BACKGROUND FX ---------- */
.bg{ position:fixed; inset:0; z-index:-2; overflow:hidden; }
.bg .grid{
  position:absolute; inset:-10% -10% 0 -10%;
  background:
    radial-gradient(circle at 20% 10%, rgba(0,255,170,.25), transparent 35%),
    radial-gradient(circle at 80% 80%, rgba(0,229,255,.18), transparent 40%),
    linear-gradient(180deg, rgba(0,0,0,.1), rgba(0,0,0,.3));
  mask-image: radial-gradient(circle at 50% -20%, black, transparent 70%);
}
.bg .radial{
  position:absolute; inset:0;
  background:
    repeating-linear-gradient( to right, rgba(0,255,166,.06) 0 2px, transparent 2px 120px ),
    repeating-linear-gradient( to top, rgba(0,229,255,.06) 0 2px, transparent 2px 120px );
  animation: drift 22s linear infinite;
  opacity:.35;
}
@keyframes drift{
  0%{ transform: translate3d(0,0,0) }
  100%{ transform: translate3d(-120px,-120px,0) }
}

/* ---------- SECTIONS ---------- */
.section{ padding: 110px 24px 72px; position:relative; }
.title{ font-size:2.2rem; margin:0 0 .35rem; text-shadow:0 0 12px var(--neon); }
.subtitle{ color:var(--muted); margin-bottom:1.2rem; }

.hero{ text-align:center; }
.hero-image{
  width:min(1000px, 92vw); border-radius:18px; box-shadow:var(--shadow);
  display:block; margin-inline:auto;
}
.hero-cta{ margin-top:18px; display:flex; gap:12px; justify-content:center; }

/* ABOUT */
.about-card{
  display:grid; grid-template-columns: 220px 1fr; gap:24px; align-items:center;
  background:linear-gradient(180deg, rgba(14,20,27,.8), rgba(14,20,27,.55));
  border:1px solid var(--border); border-radius:20px; padding:20px;
  box-shadow: var(--shadow);
}
.about-media img{
  width:100%; height:auto; border-radius:16px; border:1px solid #194a53;
  display:block; box-shadow: var(--shadow);
}
.about-highlights{ margin:10px 0 16px; padding-left:18px; }
.about-actions{ display:flex; gap:10px; flex-wrap:wrap; }

.about-contact {
  margin-top: 1rem;
  font-size: 1rem;
  color: #24ca69;
}

.about-contact a {
  color: #24ca69;
  text-decoration: none;
  transition: color 0.3s ease;
}

.about-contact a:hover {
  color: #ffffff;
  text-shadow: 0 0 8px #00ffe0;
}


/* PROJECTS */
.projects .cards{
  display:grid; gap:16px;
  grid-template-columns: repeat(12, 1fr);
}
.card{
  grid-column: span 4;
  display:flex; flex-direction:column; justify-content:space-between;
  background:linear-gradient(180deg, #0f141b, #0b1116);
  border:1px solid var(--border); border-radius:16px; padding:16px;
  box-shadow: var(--shadow); transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover{ transform: translateY(-4px); box-shadow: 0 0 26px rgba(0,255,166,.35); }
.card h3{ margin:8px 0 6px; }
.card p{ color:#c7f7ea; }
.card-footer{ display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; margin-top:12px; }
.tag{ padding:.25rem .6rem; border-radius:999px; border:1px solid #12535c; color:#a9f4e2; font-size:.85rem; }

/* ---------- PROJECTS GRID (with images) ---------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 1.5rem;
}

.project-card {
  background: linear-gradient(180deg, rgba(15, 20, 27, 0.9), rgba(10, 15, 20, 0.7));
  border: 1px solid #144e57;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 0 15px rgba(0, 255, 166, 0.15);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 30px rgba(0, 255, 166, 0.35);
}

.project-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-bottom: 1px solid #144e57;
}

.project-info {
  padding: 14px 16px;
}

.project-info h3 {
  margin: 0 0 8px;
  color: #c7fff0;
  font-size: 1.1rem;
}

.project-info p {
  color: #a7e8d3;
  font-size: 0.9rem;
}

.project-links {
  display: flex;
  justify-content: center;
  padding: 10px;
  border-top: 1px solid #144e57;
}

.project-links a {
  color: #00ffe0;
  transition: color 0.3s ease;
}

.project-links a:hover {
  color: #ffffff;
  text-shadow: 0 0 8px #00ffe0;
}


/* IMAGE SECTIONS */
.media-section .section-image{
  width:min(1100px, 92vw); border-radius:18px; border:1px solid #123b42; box-shadow:var(--shadow);
  display:block; margin:10px auto 0;
}

/* CONTACT */
.contact .socials{ display:flex; gap:14px; flex-wrap:wrap; justify-content:center; }
.social{
  display:inline-flex; align-items:center; gap:.55rem; padding:.6rem .9rem; border-radius:12px;
  border:1px solid #13444d; color:#c7f7ea; text-decoration:none; transition:.25s ease;
}
.social:hover{ color:var(--text); box-shadow: var(--shadow); }
.contact-actions{ margin-top:12px; display:flex; gap:12px; justify-content:center; }

/* REVEAL ANIMATIONS */
.reveal{ opacity:0; transform: translateY(16px) scale(.98); }
.reveal.visible{ opacity:1; transform: translateY(0) scale(1); transition: .6s cubic-bezier(.2,.75,.2,1); }

/* BACK TO TOP */
.to-top{
  position:fixed; right:18px; bottom:18px; z-index:999;
  width:42px; height:42px; border-radius:50%; border:1px solid #1a5661;
  background:#0c141a; color:#cffff0; box-shadow:var(--shadow);
  opacity:0; visibility:hidden; transition:.25s ease; cursor:pointer;
}
.to-top.show{ opacity:1; visibility:visible; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1000px){
  .card{ grid-column: span 6; }
  .about-card{ grid-template-columns: 1fr; text-align:center; }
  .about-media{ order:-1; }
  .navbar nav{ display:none; }
  .mobile-toggle{ display:block; }
}
@media (max-width: 640px){
  .card{ grid-column: span 12; }
  .btn{ padding:.5rem .75rem; }
  .title{ font-size:1.9rem; }
}
/* ---------- CERTIFICATES SECTION ---------- */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 1.5rem;
}

.cert-card {
  background: linear-gradient(180deg, rgba(15, 20, 27, 0.9), rgba(10, 15, 20, 0.7));
  border: 1px solid #144e57;
  border-radius: 16px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 0 10px rgba(0, 255, 166, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.cert-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 25px rgba(0, 255, 166, 0.35);
}

.cert-card h3 {
  color: #c7fff0;
  margin-bottom: 8px;
}

.cert-card p {
  color: #a7e8d3;
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.cert-card .verify {
  display: inline-block;
  margin-top: 6px;
  color: #00ffe0;
  font-size: 0.85rem;
  text-decoration: underline;
}
.cert-card .verify:hover {
  color: #fff;
}

/* ---------- BADGES SECTION ---------- */
.badges-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 40px;
  margin-top: 1.5rem;
}

.badges-grid img {
  width: 200px; /* fixed equal width */
  height: auto; /* maintain correct proportions */
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid #144e57;
  box-shadow: 0 0 18px rgba(0, 255, 166, 0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  background-color: rgba(10, 15, 20, 0.5);
  padding: 8px;
}

.badges-grid img:hover {
  transform: scale(1.05);
  box-shadow: 0 0 35px rgba(0, 255, 166, 0.45);
}
