/* ===== Sidebar Card Style ===== */
.sidebar {
  width: 240px !important;
  padding: 30px 20px;
  font-size: 14px;
  background-color: #ffffff;
  border-right: 1px solid #eee;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  overflow-y: auto;
  box-shadow: 2px 0 10px rgba(0,0,0,0.05);
}

/* Profile image styling (clamped) */
.sidebar img.profile-pic {
  width: 120px !important;
  height: 120px !important;
  max-width: 120px !important;
  max-height: 120px !important;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 0 auto 15px;
}

/* Name */
.sidebar .name {
  font-size: 22px;
  text-align: center;
  margin: 10px 0 5px;
  font-weight: 700;
}

/* Role / subtitle */
.sidebar .role {
  font-size: 14px;
  color: #777;
  text-align: center;
  margin-bottom: 15px;
}

/* Short bio */
.sidebar .bio {
  font-size: 13px;
  color: #555;
  text-align: center;
  margin-bottom: 15px;
  line-height: 1.5;
}

/* Contact links */
.sidebar .contact {
  font-size: 13px;
  color: #333;
  line-height: 1.6;
  text-align: center;
  margin-top: 10px;
}
.sidebar .contact a {
  color: #0366d6;
  text-decoration: none;
  font-weight: 500;
}
.sidebar .contact a:hover {
  text-decoration: underline;
}

/* ===== Main Content Area ===== */
.wrap {
  margin-left: 260px !important;   /* sidebar width + spacing */
  max-width: 960px !important;
  padding: 50px 40px;
}

/* Headings in main content */
.wrap h2 {
  border-bottom: 1px solid #eee;
  padding-bottom: 5px;
  margin-top: 40px;
}

/* Paragraph spacing */
.wrap p {
  line-height: 1.6;
  margin: 0.5em 0;
}

/* Images and iframes centered */
.wrap img,
.wrap iframe {
  display: block;
  margin: 20px auto;
  max-width: 100%;
  height: auto;
}

/* ===== Contact form ===== */
.contact-wrap {
  max-width: 720px;
  margin-left: 0;
  margin-right: auto;
  text-align: left;
  padding-left: 0;
}
.contact-intro {
  color: #666;
  margin: 6px 0 18px;
  text-align: left;
}
.contact-form {
  display: grid;
  gap: 16px;
}
.contact-form label {
  display: grid;
  gap: 8px;
  font-weight: 600;
  color: #222;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #d8d8df;
  border-radius: 10px;
  background: #fff;
  color: #111;
  font: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.contact-form textarea {
  resize: vertical;
  min-height: 160px;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #9aa1ad;
}
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: #0366d6;
  box-shadow: 0 0 0 3px rgba(3,102,214,.15);
}
.contact-form button[type="submit"] {
  justify-self: start;
  padding: 10px 18px;
  border: 1px solid #0366d6;
  background: #0366d6;
  color: #fff;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: transform .02s ease-in, box-shadow .15s;
}
.contact-form button[type="submit"]:hover {
  box-shadow: 0 6px 18px rgba(3,102,214,.25);
}
.contact-form button[type="submit"]:active {
  transform: translateY(1px);
}

/* Dark-mode safeguard */
@media (prefers-color-scheme: dark) {
  .contact-form input,
  .contact-form textarea {
    background: #111418;
    color: #e7e9ee;
    border-color: #2a2e35;
  }
  .contact-form label { color: #e7e9ee; }
  .contact-intro { color: #aab2bf; }
}

/* ===== Mobile-friendly Layout ===== */
@media screen and (max-width: 768px) {
  .sidebar {
    position: static;
    width: 100% !important;
    height: auto;
    text-align: center;
    border-right: none;
    border-bottom: 1px solid #eee;
    box-shadow: none;
    padding: 20px;
  }
  .sidebar img.profile-pic {
    width: 96px !important;
    height: 96px !important;
    max-width: 96px !important;
    max-height: 96px !important;
  }
  .wrap {
    margin-left: auto !important;
    margin-right: auto !important;
    max-width: 95% !important;
    padding: 20px;
    text-align: center;
  }
  .wrap img,
  .wrap iframe {
    display: block;
    margin: 20px auto;
  }
  .contact-wrap {
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
  }
}
