/* ===== RESET & BASE ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Work Sans', 'Segoe UI', sans-serif;
  line-height: 1.75;
  background-color: #FFFFFF;
  color: #2E2E2E;
  -webkit-font-smoothing: antialiased;
  display: flex;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
  padding: 0;
}

/* ===== SIDEBAR ===== */
.sidebar {
  width: 280px;
  min-height: 100vh;
  background: #1A1F2E;
  color: rgba(255,255,255,0.85);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.sidebar-inner {
  padding: 40px 28px 32px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.sidebar-photo {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 24px;
  border: 3px solid rgba(255,255,255,0.15);
}

.sidebar h1 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
  line-height: 1.3;
}

.sidebar-subtitle {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  margin-bottom: 32px;
  line-height: 1.5;
  letter-spacing: 0.2px;
}

/* ===== SIDEBAR NAV ===== */
.sidebar nav {
  background: transparent;
  position: static;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  padding: 0;
}

.sidebar .nav-links {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0;
}

.sidebar .nav-links a {
  color: rgba(255,255,255,0.6);
  font-weight: 500;
  font-size: 0.9rem;
  padding: 10px 14px;
  border-radius: 8px;
  transition: all 0.2s ease;
  display: block;
  border: none;
}

.sidebar .nav-links a:hover {
  color: #fff;
  background: rgba(255,255,255,0.08);
}

.sidebar .nav-links a.active {
  color: #fff;
  background: rgba(122, 196, 165, 0.15);
  font-weight: 600;
  border: none;
}

.sidebar .nav-links a.active::after {
  display: none;
}

.sidebar-contact {
  margin-top: auto;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.sidebar-contact a {
  color: #7BC4A5;
  font-size: 0.82rem;
  font-weight: 500;
  transition: color 0.2s;
  display: block;
}

.sidebar-contact a + a {
  margin-top: 6px;
}

.sidebar-contact a:hover {
  color: #fff;
}

/* ===== MAIN CONTENT ===== */
.main-content {
  margin-left: 280px;
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== LEGACY HEADER (hidden in sidebar layout) ===== */
.header {
  display: none;
}

/* ===== SECTIONS ===== */
.section {
  padding: 56px 60px;
  text-align: left;
}

.section.bg-light {
  background: #F5F7F4;
}

.section h2 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 1.55rem;
  color: #1A1F2E;
  margin-bottom: 18px;
  font-weight: 600;
  letter-spacing: -0.3px;
}

.section p {
  font-size: 1rem;
  line-height: 1.8;
  color: #4A4A4A;
  text-align: left;
  max-width: 680px;
}

/* ===== PAGE TITLE ===== */
.page-title {
  padding: 48px 60px 0;
}

.page-title h2 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 2rem;
  color: #1A1F2E;
  font-weight: 700;
  margin-bottom: 8px;
}

.page-title p {
  color: #888;
  font-size: 0.95rem;
}

/* ===== HERO ===== */
.hero {
  padding: 64px 60px 56px;
  background: #FFFFFF;
}

.flex-container {
  display: flex;
  align-items: flex-start;
  gap: 0;
  flex-direction: column;
}

.img-container {
  display: none; /* Photo is in sidebar now */
}

.presentacion-img {
  display: none;
}

.content {
  flex: 1;
  text-align: left;
  max-width: 680px;
}

.content h2 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 2.2rem;
  color: #4A8B6E;
  margin-bottom: 16px;
  min-height: 2.8rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.content p {
  font-size: 1.08rem;
  color: #4A4A4A;
  margin-bottom: 24px;
  text-align: left;
  line-height: 1.85;
}

.icons {
  margin-bottom: 32px;
  padding: 0;
  border-left: none;
}

.icons li {
  padding: 10px 0 10px 0;
  font-size: 0.98rem;
  color: #2E2E2E;
  position: relative;
  padding-left: 32px;
  line-height: 1.6;
}

.icons li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 2px;
  background: #4A8B6E;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 13px 32px;
  background: #4A8B6E;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.15s ease;
  letter-spacing: 0.2px;
}

.btn:hover {
  background: #3A7159;
  transform: translateY(-1px);
}

.btn + .btn {
  margin-left: 12px;
  background: transparent;
  color: #4A8B6E;
  border: 2px solid #4A8B6E;
}

.btn + .btn:hover {
  background: #4A8B6E;
  color: #fff;
}

/* ===== FORMS ===== */
form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 480px;
  text-align: left;
}

form label {
  font-weight: 600;
  color: #1A1F2E;
  font-size: 0.88rem;
  letter-spacing: 0.2px;
}

form input,
form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #D8D8D8;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s ease;
  background: #FAFAFA;
}

form input:focus,
form textarea:focus {
  outline: none;
  border-color: #4A8B6E;
  background: #fff;
}

form textarea {
  height: 120px;
  resize: vertical;
}

form button {
  background: #4A8B6E;
  color: #fff;
  border: none;
  padding: 13px 28px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s ease;
  align-self: flex-start;
}

form button:hover {
  background: #3A7159;
}

/* ===== CARDS & LISTS ===== */
.lineas-centrado {
  text-align: left;
  max-width: 680px;
}

.lineas-centrado h2 {
  font-size: 1.55rem;
  margin-bottom: 14px;
  text-align: left;
}

.lineas-centrado p {
  font-size: 1rem;
  margin-bottom: 20px;
  text-align: left;
}

.lineas-centrado ul {
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
}

.lineas-centrado ul li {
  padding: 14px 0;
  position: relative;
  line-height: 1.7;
  padding-left: 32px;
  border-bottom: 1px solid #EAEAEA;
}

.lineas-centrado ul li:last-child {
  border-bottom: none;
}

.lineas-centrado ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: #4A8B6E;
  border-radius: 2px;
}

/* ===== Congress list ===== */
#congresos ul {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
  max-width: 680px;
}

#congresos ul li {
  background: #F5F7F4;
  padding: 20px 24px;
  border-radius: 10px;
  border: none;
  border-left: 3px solid #4A8B6E;
  transition: background 0.2s ease;
}

#congresos ul li::before {
  display: none;
}

#congresos ul li:hover {
  background: #EDF2ED;
}

#congresos ul li strong {
  color: #1A1F2E;
  font-size: 0.94rem;
  display: block;
  margin-bottom: 4px;
}

#congresos ul li em {
  color: #555;
  font-size: 0.92rem;
  line-height: 1.6;
}

#congresos ul li a {
  color: #4A8B6E;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s;
}

#congresos ul li a:hover {
  color: #1A1F2E;
}

/* ===== CONTACT INFO ===== */
#contacto-info {
  padding: 56px 60px;
}

#contacto-info ul {
  display: block;
  text-align: left;
}

#contacto-info ul li {
  padding: 8px 0;
  font-size: 1rem;
  padding-left: 0;
  border-bottom: none;
}

#contacto-info ul li::before {
  display: none;
}

#contacto-info a {
  color: #4A8B6E;
  font-weight: 600;
  transition: color 0.2s;
  text-decoration: underline;
  text-underline-offset: 3px;
}

#contacto-info a:hover {
  color: #1A1F2E;
}

/* ===== PROJECTS ===== */
.proyecto-sofey h3 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 1.4rem;
  color: #1A1F2E;
  margin-bottom: 14px;
}

.video-container {
  margin-top: 24px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #E0E0E0;
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  max-width: 680px;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* ===== FOOTER ===== */
.footer {
  background: #F5F7F4;
  color: #888;
  text-align: left;
  padding: 24px 60px;
  font-size: 0.85rem;
  margin-top: auto;
  border-top: 1px solid #E8E8E8;
}

.footer .container {
  width: 100%;
  max-width: none;
}

.footer p {
  margin: 2px 0;
}

.footer a {
  color: #4A8B6E;
  font-weight: 600;
  transition: color 0.2s;
}

.footer a:hover {
  color: #1A1F2E;
}

/* ===== FAQ / H3 sections ===== */
.lineas-centrado h3 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-size: 1.15rem;
  color: #1A1F2E;
  margin-top: 28px;
  margin-bottom: 10px;
  font-weight: 600;
}

.lineas-centrado h3 + p {
  margin-bottom: 8px;
}

/* ===== Sidebar figure & picture ===== */
.sidebar figure {
  margin: 0;
  padding: 0;
}

.sidebar figure picture {
  display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  body {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    min-height: auto;
    position: relative;
    flex-direction: row;
    align-items: center;
  }

  .sidebar-inner {
    padding: 20px 24px;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
  }

  .sidebar-photo {
    width: 56px;
    height: 56px;
    margin-bottom: 0;
    border-radius: 8px;
  }

  .sidebar h1 {
    font-size: 1.1rem;
    margin-bottom: 0;
  }

  .sidebar-subtitle {
    display: none;
  }

  .sidebar nav {
    width: 100%;
  }

  .sidebar .nav-links {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px;
  }

  .sidebar .nav-links a {
    padding: 8px 12px;
    font-size: 0.82rem;
  }

  .sidebar-contact {
    display: flex;
    gap: 16px;
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    width: 100%;
  }

  .sidebar-contact a {
    display: inline;
    font-size: 0.78rem;
  }

  .sidebar-contact a + a {
    margin-top: 0;
  }

  .main-content {
    margin-left: 0;
  }

  .section,
  .hero,
  .page-title,
  #contacto-info,
  .footer {
    padding-left: 28px;
    padding-right: 28px;
  }
}

@media (max-width: 480px) {
  .sidebar-inner {
    padding: 16px 18px;
  }

  .sidebar-photo {
    width: 44px;
    height: 44px;
  }

  .sidebar h1 {
    font-size: 0.95rem;
  }

  .sidebar .nav-links a {
    padding: 6px 10px;
    font-size: 0.78rem;
  }

  .section,
  .hero,
  .page-title,
  #contacto-info,
  .footer {
    padding-left: 20px;
    padding-right: 20px;
  }

  .content h2 {
    font-size: 1.7rem;
  }

  .section {
    padding-top: 40px;
    padding-bottom: 40px;
  }
}
