/* ===== Base / Layout ===== */
html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: Arial, sans-serif;
}

.wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Space for sticky navbar + clear section separation */
section {
  scroll-margin-top: 80px;
  padding-top: 4rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid #e0e0e0;
}

body[data-theme="dark"] section {
  border-bottom: 1px solid #444;
}

/* Content container spacing */
.content {
  flex: 1;
  margin-top: 16px;
}

/* ===== Theme ===== */
body[data-theme="dark"] {
  background-color: #121212;
  color: #ffffff;
}

body[data-theme="dark"] .navbar {
  background-color: #343a40 !important;
}

body[data-theme="dark"] .navbar a {
  color: #ffffff !important;
}

body[data-theme="light"] .navbar {
  background-color: #ffffff !important;
}

body[data-theme="light"] .navbar a {
  color: #000000 !important;
}

.theme-icon {
  background: none;
  border: none;
  cursor: pointer;
}

.theme-icon i {
  font-size: 1.5rem;
}

body[data-theme="light"] .theme-icon i { color: #000000; }
body[data-theme="dark"] .theme-icon i { color: #ffffff; }

/* ===== Navbar links ===== */
.nav-link {
  font-weight: normal;
  transition: font-weight 0.2s;
}

.nav-link.active,
.nav-link:hover {
  font-weight: bold;
}

/* ===== Media / Misc ===== */
.about-photo img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
}

/* ===== Resume / CV preview ===== */
.resume-actions .btn + .btn {
  margin-left: .5rem;
}

.pdf-embed {
  border: 1px solid #e0e0e0;
  border-radius: .5rem;
  overflow: hidden;
  background: #fff;
}

/* Responsive heights for the embedded PDF */
@media (min-width: 992px) {
  .pdf-embed { height: 80vh; }
}
@media (max-width: 991.98px) {
  .pdf-embed { height: 60vh; }
}

.pdf-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

body[data-theme="dark"] .pdf-embed {
  border-color: #444;
  background: #171717;
}

/* ===== Footer ===== */
footer {
  padding: 10px 0;
  text-align: center;
  background-color: #f8f9fa;
  font-size: 0.9rem;
  border-top: 1px solid #e0e0e0;
}

body[data-theme="dark"] footer {
  background-color: #343a40;
  color: #d3d3d3;
  border-top: 1px solid #555555;
}

/* ===== Dark-mode safety net for injected accordions (ensures readability) ===== */
body[data-theme="dark"] .accordion-item { border-color: #3a3f47; }
body[data-theme="dark"] .accordion-button {
  color: #ffffff !important;
  background-color: rgba(255,255,255,0.06) !important;
}
body[data-theme="dark"] .accordion-button.collapsed {
  background-color: transparent !important;
  color: #f1f3f5 !important;
}
body[data-theme="dark"] .accordion-body { color: #eaeaea !important; }
body[data-theme="dark"] .accordion-button:focus {
  box-shadow: 0 0 0 4px rgba(13,110,253,.3) !important;
}
body[data-theme="dark"] .accordion-button::after {
  filter: invert(0.9);
}
