*,
*::before,
*::after {
  box-sizing: border-box;
}

.profile-view-link-wrapper {
  width: 100%;
  max-width: var(--tc-max-width);

  margin: 1rem auto 1rem;

  display: flex;
  justify-content: flex-start;
}

/** >>>>>>>>>>>>>> Theme <<<<<<<<<<<<<<<<<<<<<<<<<<< */
.change-theme-style {
  width: 100%;
  max-width: var(--tc-max-width);
  margin: 2rem auto 0;
  padding: 1rem 1.2rem;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);
  box-shadow: var(--tc-shadow-soft);
}

.theme-style-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.theme-style-title {
  color: var(--tc-text);
  font-size: 1.05rem;
  font-weight: 700;
}

.theme-selector-form {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.theme-selector-label {
  color: var(--tc-text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  margin-right: 0.2rem;
}

.theme-selector-select {
  min-width: 170px;
  padding: 0.65rem 2.4rem 0.65rem 0.9rem;

  color: var(--tc-text);
  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-sm);

  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;

  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.theme-selector-select:hover {
  border-color: var(--tc-border-strong);
  background: var(--tc-card-soft);
}

.theme-selector-select:focus {
  border-color: var(--tc-primary);
  box-shadow: 0 0 0 3px var(--tc-primary-soft);
}

.theme-selector-select option {
  color: var(--tc-text);
  background: var(--tc-bg-soft);
}
/** >>>>>>>>>>>>>> Profile region <<<<<<<<<<<<<<<<<< */
.region-profile {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 2rem 1rem 1rem;
}

/* CARD PRINCIPAL */
.profile-card {
  position: relative;
  width: 100%;
  max-width: var(--tc-max-width);
  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow);
  overflow: hidden;

  display: grid;
  grid-template-columns: 190px 1fr;
  grid-template-areas:
    "banner banner"
    "image header"
    "info info"
    "resume resume";
}

/* BANNER */
.profile-banner {
  grid-area: banner;
  height: 230px;
  overflow: hidden;
  border-bottom: 1px solid var(--tc-border);
}

.profile-banner-img {
  display:block;
  width:100%;
  height:100%;
  object-fit:contain;
  object-position:center;
}

/* IMAGEN PERFIL */
.profile-header-left {
  grid-area: image;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 0 1.5rem;
  margin-top: -55px;
  z-index: 2;
}

.profile-img {
  width: 135px;
  height: 135px;
  object-fit: cover;
  border-radius: var(--tc-radius-lg);
  border: 4px solid var(--tc-card);
  background: var(--tc-bg-soft);
  box-shadow: var(--tc-shadow-soft);
}

/* NOMBRE + TITULO */
.profile-header-right {
  grid-area: header;
  margin-top: 1rem;
  margin-right: 1.5rem;
  padding: 1rem 1.5rem;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-md);
  background: var(--tc-card-soft);
}

.profile-name {
  margin: 0;
  color: var(--tc-text);
  font-size: 1.5rem;
  font-weight: 700;
}

.profile-professional-title {
  margin: 0;
  color: var(--tc-text-soft);
  font-size: 1rem;
  font-weight: 500;
  text-align: right;
}

/* BOTON EDIT */
.profile-card-actions {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  z-index: 20;
}

.profile-edit-btn {
  padding: 0.65rem 1rem;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: var(--tc-radius-sm);

  background: rgba(0,0,0,0.35);
  backdrop-filter: blur(10px);

  border: 1px solid rgba(255,255,255,0.15);

  color: var(--tc-text);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.profile-edit-btn:hover {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
  transform: translateY(-1px);
}

/* INFO PERSONAL */
.profile-section {
  grid-area: info;
  padding: 1.5rem 2.2rem 2rem;
}

.profile-section-title {
  display: none;
}

.profile-info-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 1.2rem;
  align-items: start;
}

.profile-info-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  align-items: flex-start;
  text-align: left;
}

.profile-info-item:nth-child(1),
.profile-info-item:nth-child(5){
    grid-column: span 2;
}

.profile-label {
  color: var(--tc-text-muted);
  font-size: 0.82rem;
  font-weight: 500;
}

.profile-value {
  color: var(--tc-text);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  word-break: break-word;
}

/* LINKS CV */
.profile-card > .profile-section:last-child {
  grid-area: resume;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--tc-border);
  background: var(--tc-bg-soft);
}

.profile-links {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.profile-link {
  padding: 0.55rem 0.9rem;
  border-radius: var(--tc-radius-sm);
  border: 1px solid var(--tc-primary);
  background: var(--tc-primary-soft);
  color: var(--tc-primary-hover);
  text-decoration: none;
  font-weight: 600;
}

.profile-link:hover {
  background: var(--tc-primary);
  color: var(--tc-text);
}

/** languages, skills, sm */
.region-languages,
.region-skills {
  width: 100%;
  max-width: var(--tc-max-width);
  margin-left: auto;
  margin-right: auto;
  padding: 0 1rem;
}

/* Social media plano */
.region-social-media {
  width: 100%;
  max-width: var(--tc-max-width);

  margin: 1rem auto 1.2rem;

  box-sizing: border-box;
}

.social-card {
  width: 100%;
  padding: 1.2rem 1.4rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);
  box-shadow: var(--tc-shadow-soft);
}

.social-card .section-card-header {
  width: 100%;
  margin-bottom: 0;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Languages y Skills en 2 columnas */
.region-languages,
.region-skills {
  display: inline-block;
  width: calc((var(--tc-max-width) / 2) - 0.8rem);
  max-width: calc(50% - 0.8rem);
  vertical-align: top;
  padding: 0;
}

.region-languages {
  margin-left: calc((100% - var(--tc-max-width)) / 2);
  margin-right: var(--tc-gap);
}

.region-skills {
  margin-right: calc((100% - var(--tc-max-width)) / 2);
}

.lang-card,
.skill-card {
  width: 100%;
  min-height: 260px;
  padding: 1.5rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow-soft);
}

.section-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.2rem;
}

.lang-title,
.skill-title,
.social-title {
  margin: 0;
  color: var(--tc-text);
  font-size: 1.35rem;
  font-weight: 700;
}

.lang-list,
.skill-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.lang-item,
.skill-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  padding: 0.75rem 0.9rem;
  border-radius: var(--tc-radius-md);
  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);
}

.lang-left,
.skill-left {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.lang-dot,
.skill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tc-primary);
  flex-shrink: 0;
}

.lang-name,
.skill-name {
  color: var(--tc-text);
  font-weight: 600;
}

.lang-native {
  color: var(--tc-text-muted);
  font-size: 0.85rem;
}

.lang-level-value,
.skill-level-value {
  color: var(--tc-primary-hover);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
}

.social-list {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.social-item {
  padding: 0.65rem 1rem;

  border-radius: var(--tc-radius-md);
  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);

  color: var(--tc-text);
  text-decoration: none;
  font-weight: 600;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.social-item:hover {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
  color: var(--tc-primary-hover);
  transform: translateY(-2px);
}

/**********************************/
/************ TABS ***************/
/**********************************/

.profile-tabs {
  width: 100%;
  max-width: var(--tc-max-width);

  margin: 2rem auto;
  padding: 0 1rem;
}

/* ocultar radios */
.profile-tabs input[type="radio"] {
  display: none;
}

/* HEADER */
.profile-tabs-header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
  padding: 0.9rem;
  flex-wrap: wrap;
  backdrop-filter: blur(10px);
  border-radius: var(--tc-radius-lg);
  background: var(--tc-card);
  border: 1px solid var(--tc-border);
}

/* BOTON TAB */
.profile-tab-btn {
  padding: 0.8rem 1.2rem;

  border-radius: var(--tc-radius-md);

  background: var(--tc-card);
  border: 1px solid var(--tc-border);

  color: var(--tc-text-soft);

  font-size: 0.95rem;
  font-weight: 600;

  cursor: pointer;
  user-select: none;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.profile-tab-btn:hover {
  background: var(--tc-card-soft);
  border-color: var(--tc-primary);
  color: var(--tc-text);

  transform: translateY(-1px);
}

/* TAB ACTIVO */
#tab-projects:checked ~ .profile-tabs-header label[for="tab-projects"],
#tab-studies:checked ~ .profile-tabs-header label[for="tab-studies"],
#tab-workexp:checked ~ .profile-tabs-header label[for="tab-workexp"],
#tab-about:checked ~ .profile-tabs-header label[for="tab-about"] {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
  color: var(--tc-primary-hover);

  box-shadow: 0 0 0 1px var(--tc-primary-soft);
}

/* CONTENT */
.profile-tabs-content {
  width: 100%;
}

/* PANELS */
.profile-tab-panel {
  display: none;

  animation: fadeTab 0.25s ease;
}

/* PANEL ACTIVO */
#tab-projects:checked ~ .profile-tabs-content .profile-tab-projects,
#tab-studies:checked ~ .profile-tabs-content .profile-tab-studies,
#tab-workexp:checked ~ .profile-tabs-content .profile-tab-workexp,
#tab-about:checked ~ .profile-tabs-content .profile-tab-about {
  display: block;
}

/* ABOUT ME */
.profile-section-aboutMe {
  padding: 2rem;

  background: var(--tc-card);

  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);

  box-shadow: var(--tc-shadow-soft);
}

.profile-text {
  margin: 0;

  color: var(--tc-text-soft);

  font-size: 1rem;
  line-height: 1.8;

  white-space: pre-line;
}

/* ANIMACION */
@keyframes fadeTab {
  from {
    opacity: 0;
    transform: translateY(6px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/**********************************/
/*********** PROJECTS *************/
/**********************************/

.region-projects {
  width: 100%;
}

/* TOP TITLE */
.projects-topbar {
  margin-bottom: 1.2rem;
}

.projects-main-title {
  margin: 0;
  color: var(--tc-text);
  font-size: 1.6rem;
  font-weight: 800;
}

/* CARDS */
.project-groups-card,
.projects-card {
  padding: 1.5rem;
  margin-bottom: 1.4rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow-soft);
}

/* HEADERS */
.projects-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  margin-bottom: 1.2rem;
}

.projects-section-title {
  margin: 0;
  color: var(--tc-text);
  font-size: 1.25rem;
  font-weight: 700;
}

/* GROUPS */
.project-groups-form {
  width: 100%;
}

.project-groups-list {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.project-group-item {
  padding: 0.65rem 1rem;

  border-radius: var(--tc-radius-md);
  border: 1px solid var(--tc-border);

  background: var(--tc-bg-soft);
  color: var(--tc-text-soft);

  font-size: 0.95rem;
  font-weight: 600;

  cursor: pointer;

  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.project-group-item:hover {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
  color: var(--tc-text);
  transform: translateY(-1px);
}

.project-group-item.active {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
  color: var(--tc-primary-hover);
}

/* PROJECT LIST */
.projects-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 320px));
  gap: 1.1rem;
  justify-content: left;
}

.project-link {
  text-decoration: none;
  color: inherit;
}

.project-item {
  height: 100%;
  overflow: hidden;

  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);

  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.project-link:hover .project-item {
  border-color: var(--tc-primary);
  transform: translateY(-4px);
  box-shadow: var(--tc-shadow-soft);
}

/* IMAGE */
.project-image-wrapper {
  width: 100%;
  height: 155px;

  overflow: hidden;
  background: var(--tc-card-soft);
  border-bottom: 1px solid var(--tc-border);
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;

  transition: transform 0.3s ease;
}

.project-link:hover .project-image {
  transform: scale(1.05);
}

/* CONTENT */
.project-content {
  padding: 1rem;
}

.project-title {
  margin: 0 0 0.5rem;

  color: var(--tc-text);
  font-size: 1.05rem;
  font-weight: 700;
}

.project-summary {
  margin: 0;

  color: var(--tc-text-soft);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* EMPTY */
.projects-empty {
  padding: 1.2rem;

  background: var(--tc-bg-soft);
  border: 1px dashed var(--tc-border);
  border-radius: var(--tc-radius-md);

  color: var(--tc-text-muted);
  text-align: center;
}

/* BOTONES EDIT PEQUEÑOS */
.projects-section-header .profile-edit-btn {
  position: static;
  padding: 0.55rem 0.85rem;
  font-size: 0.82rem;
}

/**********************************/
/****** PROJECT DETAIL PAGE *******/
/**********************************/

.project-detail-section {
  width: 100%;
  padding: 2rem 1rem;
}

.project-detail-container {
  width: 100%;
  max-width: var(--tc-max-width);
  margin: 0 auto;
}

/* HERO */
.project-detail-hero {
  position: relative;
  overflow: hidden;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow);

  margin-bottom: 1.5rem;
}

.project-detail-back {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 5;
}

/* COVER */
.project-cover-img-wrapper {
  width: 100%;
  height: 360px;

  background: var(--tc-bg-soft);
  border-bottom: 1px solid var(--tc-border);
  overflow: hidden;
}

.project-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;

  opacity: 0.9;
}

/* HERO CONTENT */
.project-detail-hero-content {
  padding: 2rem;
}

.project-detail-title {
  margin: 0 0 0.8rem;

  color: var(--tc-text);
  font-size: 2rem;
  font-weight: 800;
}

.project-detail-summary {
  max-width: 850px;
  margin: 0;

  color: var(--tc-text-soft);
  font-size: 1rem;
  line-height: 1.7;
}

/* LINKS */
.project-detail-links {
  padding: 0 2rem 2rem;

  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

/* INFO CARDS */
.project-detail-info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--tc-gap);

  margin-bottom: 1.5rem;
}

.project-detail-info-card {
  padding: 1.4rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);
  box-shadow: var(--tc-shadow-soft);
}

.project-detail-info-card h2 {
  margin: 0 0 0.6rem;

  color: var(--tc-text);
  font-size: 1.05rem;
  font-weight: 700;
}

.project-detail-info-card p {
  margin: 0;

  color: var(--tc-primary-hover);
  font-weight: 600;
  line-height: 1.5;
}

/* DESCRIPTION */
.project-detail-description,
.project-detail-gallery {
  padding: 1.6rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow-soft);

  margin-bottom: 1.5rem;
}

.project-detail-description h2,
.project-detail-gallery h2 {
  margin: 0 0 1rem;

  color: var(--tc-text);
  font-size: 1.35rem;
  font-weight: 800;
}

.project-detail-description p {
  margin: 0;

  color: var(--tc-text-soft);
  font-size: 1rem;
  line-height: 1.8;

  white-space: pre-line;
}

/* GALLERY */
.project-detail-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.project-detail-gallery-img {
  width: 100%;
  height: 170px;

  object-fit: cover;
  display: block;

  border-radius: var(--tc-radius-md);
  border: 1px solid var(--tc-border);
  background: var(--tc-bg-soft);

  cursor: pointer;

  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.project-detail-gallery-img:hover {
  transform: translateY(-3px);
  border-color: var(--tc-primary);
  box-shadow: var(--tc-shadow-soft);
}

/* MODAL SLIDER */
.cp-project-slider-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;

  display: none;
  align-items: center;
  justify-content: center;

  padding: 2rem;

  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
}

.cp-project-slider-modal.active {
  display: flex;
}

.cp-project-slider-content {
  position: relative;

  width: min(100%, 1000px);
  padding: 1rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow);
}

.cp-project-slider-image {
  width: 100%;
  max-height: 70vh;

  object-fit: contain;
  display: block;

  border-radius: var(--tc-radius-lg);
  background: var(--tc-bg);
}

.cp-project-slider-close,
.cp-project-slider-btn {
  position: absolute;
  z-index: 2;

  border: 1px solid var(--tc-border);
  background: rgba(0, 0, 0, 0.45);
  color: var(--tc-text);

  cursor: pointer;

  transition:
    background 0.2s ease,
    border-color 0.2s ease;
}

.cp-project-slider-close {
  top: 1rem;
  right: 1rem;

  width: 42px;
  height: 42px;

  border-radius: 50%;
}

.cp-project-slider-btn {
  top: 50%;
  transform: translateY(-50%);

  width: 46px;
  height: 56px;

  border-radius: var(--tc-radius-md);

  font-size: 2rem;
}

.cp-project-slider-prev {
  left: 1rem;
}

.cp-project-slider-next {
  right: 1rem;
}

.cp-project-slider-close:hover,
.cp-project-slider-btn:hover {
  background: var(--tc-primary-soft);
  border-color: var(--tc-primary);
}

.cp-project-slider-title {
  margin: 1rem 0 0.3rem;

  color: var(--tc-text);
  font-size: 1.2rem;
}

.cp-project-slider-counter {
  margin: 0;

  color: var(--tc-text-muted);
}

/**********************************/
/************ STUDIES *************/
/**********************************/

.region-studies {
  width: 100%;
}

.study-card {
  padding: 1.6rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow-soft);
}

.study-title {
  margin: 0;

  color: var(--tc-text);
  font-size: 1.35rem;
  font-weight: 800;
}

.study-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.study-item {
  padding: 1.2rem;

  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);

  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.study-item:hover {
  border-color: var(--tc-primary);
  transform: translateY(-2px);
  box-shadow: var(--tc-shadow-soft);
}

.study-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.2rem;
}

.study-main-info {
  min-width: 0;
}

.study-name {
  margin: 0 0 0.4rem;

  color: var(--tc-text);
  font-size: 1.1rem;
  font-weight: 800;
}

.study-institution-row {
  color: var(--tc-text-soft);
  font-size: 0.95rem;
  line-height: 1.5;
}

.study-institution {
  font-weight: 600;
}

.study-location,
.study-separator {
  color: var(--tc-text-muted);
}

.study-dates {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;

  padding: 0.45rem 0.7rem;

  background: var(--tc-primary-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-sm);

  color: var(--tc-primary-hover);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
}

.study-date-current {
  color: var(--tc-primary-hover);
}

.study-description {
  margin-top: 1rem;
  padding-top: 1rem;

  border-top: 1px solid var(--tc-border);
}

.study-description p {
  margin: 0;

  color: var(--tc-text-soft);
  font-size: 0.95rem;
  line-height: 1.7;

  white-space: pre-line;
}

/* botón pequeño */
.study-card .profile-edit-btn {
  position: static;
  padding: 0.55rem 0.85rem;
  font-size: 0.82rem;
}

/**********************************/
/******** WORK EXPERIENCE *********/
/**********************************/

.region-workexp {
  width: 100%;
}

.workexp-card {
  padding: 1.6rem;

  background: var(--tc-card);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-xl);
  box-shadow: var(--tc-shadow-soft);
}

.workexp-title {
  margin: 0;

  color: var(--tc-text);
  font-size: 1.35rem;
  font-weight: 800;
}

.workexp-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.workexp-item {
  padding: 1.2rem;

  background: var(--tc-bg-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-lg);

  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.workexp-item:hover {
  border-color: var(--tc-primary);
  transform: translateY(-2px);
  box-shadow: var(--tc-shadow-soft);
}

.workexp-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.2rem;
}

.workexp-main-info {
  min-width: 0;
}

.workexp-position {
  margin: 0 0 0.4rem;

  color: var(--tc-text);
  font-size: 1.1rem;
  font-weight: 800;
}

.workexp-company-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;

  color: var(--tc-text-soft);
  font-size: 0.95rem;
  line-height: 1.5;
}

.workexp-company {
  font-weight: 600;
}

.workexp-location,
.workexp-separator {
  color: var(--tc-text-muted);
}

.workexp-dates {
  flex-shrink: 0;
}

.workexp-date {
  margin: 0;

  padding: 0.45rem 0.7rem;

  background: var(--tc-primary-soft);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-sm);

  color: var(--tc-primary-hover);
  font-size: 0.85rem;
  font-weight: 700;

  white-space: nowrap;
}

.workexp-date-current {
  color: var(--tc-primary-hover);
}

.workexp-description {
  margin-top: 1rem;
  padding-top: 1rem;

  border-top: 1px solid var(--tc-border);
}

.workexp-description p {
  margin: 0;

  color: var(--tc-text-soft);
  font-size: 0.95rem;
  line-height: 1.7;

  white-space: pre-line;
}

/* botón pequeño */
.workexp-card .profile-edit-btn {
  position: static;
  padding: 0.55rem 0.85rem;
  font-size: 0.82rem;
}

/************************************/
/********* Project videos **********/
/************************************/
.project-video-buttons{
  display:flex;
  flex-wrap:wrap;
  gap:0.8rem;

  margin-top:1rem;
}

.profile-video-btn{
  appearance:none;
  border:none;

  padding:0.9rem 1.25rem;

  border-radius:var(--tc-radius-lg);

  background:linear-gradient(
    135deg,
    var(--tc-primary),
    var(--tc-primary-hover)
  );

  color:var(--tc-text);

  font-weight:600;
  font-size:0.95rem;

  cursor:pointer;

  transition:
    transform .18s ease,
    box-shadow .18s ease,
    filter .18s ease;

  box-shadow:
    0 6px 18px rgba(0,0,0,0.25);
}

.profile-video-btn:hover{
  transform:translateY(-3px);

  filter:brightness(1.08);
    background:linear-gradient(
    135deg,
    var(--tc-text),
    var(--tc-text)
  );

  color:var(--tc-primary);
  box-shadow:
    0 12px 28px rgba(0,0,0,0.35);
}

.profile-video-btn:active{
  transform:translateY(0);
}

.profile-video-btn::before{
  content:"▶";
  margin-right:0.55rem;
  font-size:0.85rem;
}

.project-video-modal{
  position:fixed;
  inset:0;
  display:none;
  align-items:center;
  justify-content:center;
  padding:1rem;
  background:rgba(0,0,0,0.75);
  z-index:9999;
}

.project-video-modal.is-open{
  display:flex;
}

.project-video-modal-content{
  width:min(900px, 100%);
  background:var(--tc-card);
  border:1px solid var(--tc-border);
  border-radius:var(--tc-radius-xl);
  padding:1.5rem;
  position:relative;
  box-shadow:var(--tc-shadow);
}

.project-video-close{
  position:absolute;
  top:1rem;
  right:1rem;
  border:none;
  border-radius:var(--tc-radius-sm);
  background:var(--tc-primary);
  color:var(--tc-text);
  padding:0.4rem 0.7rem;
  cursor:pointer;
}

.project-video-title{
  color:var(--tc-text);
  margin-bottom:1rem;
  padding-right:3rem;
}

.project-video-iframe{
  width:100%;
  aspect-ratio:16 / 9;
  border:0;
  border-radius:var(--tc-radius-lg);
}

.project-detail-videos{
  padding:1.5rem;
  border-radius:var(--tc-radius-xl);
  background:var(--tc-card);
  border:1px solid var(--tc-border);
  box-shadow:var(--tc-shadow-soft);
  margin-bottom: 1rem;
}

.project-detail-videos h2{
  margin:0 0 1rem;
  color:var(--tc-text);
  font-size:1.2rem;
}

/* RESPONSIVE */
@media (max-width: 950px) {
    .region-social-media,
    .region-languages,
    .region-skills {
        display: block;
        width: 100%;
        max-width: var(--tc-max-width);
        margin-left: auto;
        margin-right: auto;
        padding: 0 1rem;
    }
    .projects-list {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .project-cover-img-wrapper {
        height: 260px;
    }

    .project-detail-info-grid {
        grid-template-columns: 1fr;
    }

    .project-detail-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 768px) {
  .change-theme-style {
    flex-direction: column;
    align-items: stretch;
  }

  .theme-selector-form {
    width: 100%;
    align-items: stretch;
  }

  .theme-selector-label {
    width: 100%;
  }

  .theme-selector-select {
    width: 100%;
  }

  .profile-card {
    grid-template-columns: 1fr;
    grid-template-areas:
      "banner"
      "image"
      "header"
      "info"
      "resume";
  }

  .profile-header-left {
    margin-top: -60px;
  }

  .profile-header-right {
    margin: 1rem;
    flex-direction: column;
    text-align: center;
  }

  .profile-professional-title {
    text-align: center;
  }

  .profile-info-grid {
    grid-template-columns: 1fr;
  }

  .profile-info-item,
  .profile-info-item:nth-child(n + 3) {
    align-items: flex-start;
    text-align: left;
  }

  .profile-tabs-header {
    gap: 0.6rem;
  }

  .profile-tab-btn {
    flex: 1 1 calc(50% - 0.6rem);
    text-align: center;
  }

  .profile-section-aboutMe {
    padding: 1.5rem;
  }

  .project-groups-card,
  .projects-card {
    padding: 1.1rem;
  }

  .projects-section-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .projects-list {
    grid-template-columns: 1fr;
  }

  .project-image-wrapper {
    height: 180px;
  }
  .project-detail-hero-content,
  .project-detail-links {
    padding-left: 1.2rem;
    padding-right: 1.2rem;
  }

  .project-cover-img-wrapper {
    height: 210px;
  }

  .project-detail-gallery-grid {
    grid-template-columns: 1fr;
  }
  .study-card {
    padding: 1.2rem;
  }

  .study-top {
    flex-direction: column;
  }

  .study-dates {
    width: fit-content;
  }

  .workexp-card {
    padding: 1.2rem;
  }

  .workexp-top {
    flex-direction: column;
  }

  .workexp-date {
    width: fit-content;
  }
  .profile-banner{
      height:180px;
  }
}