/* === RESET === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Arial", sans-serif;
}

/* === COLORES === */
:root {
  --fondo-principal: #1E2A38;
  --tarjeta-fondo: #243240;
  --color-secundario: #E5E5E5;
  --acento: #2A9D8F;
  --texto-principal: #F8F9FA;
  --texto-secundario: #B0B0B0;
}

/* === MODO CLARO === */
.light-mode {
  --fondo-principal: #f5f5f5;
  --tarjeta-fondo: #ffffff;
  --color-secundario: #dcdcdc;
  --acento: #2A9D8F;
  --texto-principal: #1E2A38;
  --texto-secundario: #444444;
}

/* === CUERPO === */
body {
  background-color: var(--fondo-principal);
  color: var(--texto-principal);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* === CONTENEDOR PRINCIPAL === */
.cv-container {
  display: flex;
  flex-wrap: wrap;
  max-width: 1100px;
  margin: 60px auto;
  background-color: var(--tarjeta-fondo);
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
}

/* === COLUMNA IZQUIERDA === */
.cv-left {
  flex: 1;
  min-width: 320px;
  background-color: var(--fondo-principal);
  padding: 40px 25px;
  border-right: 2px solid var(--acento);
  transition: background-color 0.4s ease;
}

.cv-left h3 {
  color: var(--acento);
  font-size: 1.2rem;
  margin-top: 25px;
  margin-bottom: 10px;
  border-bottom: 2px solid var(--acento);
  padding-bottom: 5px;
}

.cv-left p,
.cv-left li {
  color: var(--texto-secundario);
  font-size: 0.95rem;
  line-height: 1.5;
}

.cv-left ul {
  list-style: none;
  padding-left: 10px;
}

.cv-left ul li::before {
  content: "• ";
  color: var(--acento);
}

/* FOTO DE PERFIL */
.perfil-img {
  display: flex;
  justify-content: center;
  margin-bottom: 25px;
}

.perfil-img img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--acento);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.perfil-img img:hover {
  transform: scale(1.05);
}

/* === COLUMNA DERECHA === */
.cv-right {
  flex: 2;
  padding: 50px 40px;
}

.cv-right h1 {
  color: var(--texto-principal);
  font-size: 2rem;
  margin-bottom: 5px;
}

.cv-right h2 {
  color: var(--acento);
  font-size: 1.3rem;
  margin-bottom: 20px;
}

.cv-right h3 {
  color: var(--acento);
  margin-top: 25px;
  margin-bottom: 10px;
  border-bottom: 2px solid var(--acento);
  padding-bottom: 5px;
}

.cv-right p {
  color: var(--texto-secundario);
  font-size: 1rem;
  margin-bottom: 15px;
}

.cv-right b {
  color: var(--texto-principal);
}

/* === BOTÓN DESCARGAR === */
.btn-descargar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--acento);
  color: var(--texto-principal);
  padding: 0.8rem 1.6rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease, transform 0.3s ease;
  margin-top: 10px;
}

.btn-descargar:hover {
  background-color: #21867b;
  transform: scale(1.05);
}

/* === MODAL DE IMAGEN === */
.modal-foto {
  display: none;
  position: fixed;
  z-index: 2000;
  padding-top: 60px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.8);
}

.modal-foto .modal-contenido {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 500px;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
  transition: transform 0.3s ease;
  animation: aparecer 0.3s ease;
}

.modal-foto .modal-contenido:hover {
  transform: scale(1.02);
}

.modal-foto .cerrar {
  position: absolute;
  top: 20px;
  right: 40px;
  color: var(--texto-principal);
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}

.modal-foto .cerrar:hover {
  color: var(--acento);
}

@keyframes aparecer {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* === FOOTER === */
footer {
  background: #162029;
  color: var(--texto-secundario);
  text-align: center;
  padding: 1rem;
  margin-top: 40px;
  font-size: 0.9rem;
  transition: background-color 0.4s ease, color 0.4s ease;
}

.light-mode footer {
  background: #e0e0e0;
  color: #333;
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .cv-container {
    flex-direction: column;
    margin: 30px 20px;
  }

  .cv-left {
    border-right: none;
    border-bottom: 2px solid var(--acento);
    padding: 30px 20px;
  }

  .cv-right {
    padding: 30px 20px;
  }

  .cv-right h1 {
    font-size: 1.6rem;
  }

  .cv-right h2 {
    font-size: 1.1rem;
  }
}

/* === OCULTAR SCROLL === */
::-webkit-scrollbar {
  width: 0px;
  background: transparent;
}
html {
  scrollbar-width: none;
}
body {
  overflow-y: scroll;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* === CORRECCIÓN DE RESPONSIVIDAD PARA EMAIL === */
.cv-left ul li,
.cv-left p {
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-all;
}

/* Opcional: reduce un poco el tamaño del texto en móviles */
@media (max-width: 480px) {
  .cv-left {
    font-size: 0.9rem;
  }
}