/* ========== Theming & Base ========== */
:root {
  --bg: #f5f7fa;
  --fg: #333;
  --primary: #0d6efd;
}

[data-theme="dark"] {
  --bg: #121212;
  --fg: #f0f0f0;
  --primary: #339af0;
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: linear-gradient(135deg, #ffe0e0 0%, #e8f1ff 100%);
  color: var(--fg);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
}

a { color: var(--primary); }
a:hover { text-decoration: none; }

/* ========== Navbar ========== */
.navbar, .bg-light { background-color: transparent !important; }
.navbar { padding-top: 2rem; padding-bottom: 2rem; }
.navbar-light .navbar-nav .nav-link { color: var(--fg); font-size: 1.3rem; }
.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-brand:hover { color: var(--primary) !important; }
.navbar-brand {
  font-size: 2.2rem;
  font-weight: 900;
  background: linear-gradient(90deg, #000000, #000000, #000000, #000000);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
@media (max-width: 600px) {
  .navbar-brand { font-size: 1.6rem; }
  .navbar-light .navbar-nav .nav-link { font-size: 1.05rem; }
  .navbar { padding-top: 1.1rem; padding-bottom: 1.1rem; }
}
.nav-link.active { font-weight: 600; color: var(--primary) !important; }

/* ========== Hero Section (Home) ========== */
.hero {
  position: relative;
  background:
    linear-gradient(rgba(0,0,0,0.4),rgba(0,0,0,0.4)),
    url('images/hero-bg.jpg') center/cover no-repeat;
  padding: 6rem 2rem;
  text-align: center;
}
.hero img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.3);
  border: 2px solid #fff;
}
.hero h1, .hero .lead {
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.6);
}

/* ========== Section Titles & Text ========== */
.section-title {
  font-size: 2rem;
  font-weight: 600;
  margin: 2rem 0 1rem;
  color: #2c3e50;
}
.lead { font-size: 1.125rem; }

/* ========== Cards ========== */
.card-title { color: var(--primary); }
#experience .work-card {
  transition: transform .2s, box-shadow .2s;
}
#experience .work-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

/* ========== Certificates Grid & Images ========== */
#certificates .cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
#certificates .cert-item { text-align: center; }
#certificates .cert-img {
  width: 100%;
  max-width: 200px;
  height: auto;
  object-fit: contain;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  margin-bottom: .5rem;
  background: #fff;
  cursor: pointer;
}

/* ========== Universal Project Hero (Projects) ========== */
.project-hero {
  background: #e6ecf3;
  text-align: center;
  padding: 3rem 2rem;
}
.project-hero h1 { color: #0d6efd; font-weight: bold; }
@media (max-width: 600px) {
  .project-hero { padding: 2rem 1rem; }
  .project-hero h1 { font-size: 1.35rem; }
}

/* ========== Project Images & Gallery ========== */
.project-image, .project-img-thumb {
  width: 100%;
  max-width: 340px;
  height: 190px;
  object-fit: cover;
  border: 1px solid #ccc;
  border-radius: 10px;
  margin-bottom: .7rem;
  background: #fff;
  transition: transform .2s, box-shadow .2s;
}
.project-image:hover, .project-img-thumb:hover {
  transform: scale(1.04);
  box-shadow: 0 8px 32px rgba(0,0,0,0.13);
}
@media (max-width: 768px) {
  .project-image, .project-img-thumb { height: 120px; }
}

/* ========== Gallery Title & Captions ========== */
.gallery-title {
  font-size: 1.19rem;
  font-weight: 600;
  color: #1976d2;
  margin: 2rem 0 1rem;
}
.img-caption {
  font-size: .98rem;
  color: #4d5a6b;
  min-height: 38px;
  margin-bottom: .5rem;
}

/* ========== Scroll Top Button ========== */
.scroll-top {
  display: none; position: fixed; bottom: 35px; right: 30px;
  width: 45px; height: 45px; border: none; outline: none;
  border-radius: 50%; background: #0d6efd; color: #fff;
  font-size: 20px; cursor: pointer; z-index: 99;
  box-shadow: 0 2px 6px rgba(0,0,0,.13);
  transition: background .2s;
}
.scroll-top:hover { background: #274c77; }

/* ========== Accordion Active Header ========== */
.accordion-button:not(.collapsed) {
  background: #e6ecf3; color: #0d6efd;
}

/* ========== See All Link for Galleries ========== */
.see-all-link {
  font-size: .98rem;
  color: #1976d2;
  cursor: pointer;
  text-decoration: underline;
}
.see-all-link:hover { color: #0d6efd; }

/* ========== Lightbox Descriptions ========== */
.glightbox-clean .gdesc-inner {
  color: #222;
  font-size: 1rem;
}

/* ========== Utility Responsive Fixes ========== */
.row { margin-left: 0; margin-right: 0; }
[class^="col-"], [class*=" col-"] { padding-left: 0.6rem; padding-right: 0.6rem; }

/* ========== Footer ========== */
footer { font-size: 1rem; }

