/* ===== Estilos compartidos para páginas de detalle ===== */

.back-link{
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:13.5px;
  font-weight:500;
  color:rgba(251,246,236,0.7);
  margin-bottom:32px;
  transition:color 0.2s;
}
.back-link:hover{color:var(--gold-500);}

.page-hero{
  background:var(--wine-900);
  padding:160px 0 80px;
  color:var(--cream);
}
.page-hero .eyebrow{color:var(--gold-500);}
.page-hero .eyebrow::before{background:var(--gold-500);}
.page-hero h1{
  font-size:clamp(32px,4.5vw,50px);
  color:var(--cream);
  margin-bottom:20px;
  max-width:780px;
}
.page-lede{
  font-size:18px;
  color:rgba(251,246,236,0.78);
  max-width:640px;
}

/* ===== CV específico ===== */
.cv-section{padding:90px 0;background:var(--paper);}
.cv-section-alt{background:var(--cream);}
.cv-h2{
  font-size:28px;
  color:var(--wine-800);
  margin-bottom:48px;
}

.cv-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:24px;
}
.cv-card{
  background:linear-gradient(145deg, var(--glass-light-strong), rgba(243,233,213,0.54));
  border:1px solid var(--glass-border);
  border-radius:16px;
  padding:30px;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(20px) saturate(1.18);
  -webkit-backdrop-filter:blur(20px) saturate(1.18);
  transition:border-color 0.2s, transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.cv-card:hover{
  border-color:rgba(121,31,31,0.26);
  transform:translateY(-2px);
  box-shadow:var(--glass-shadow-hover);
}
.cv-card-featured{
  background:linear-gradient(145deg, rgba(80,19,19,0.92), rgba(46,10,10,0.86));
  border-color:var(--glass-border-dark);
}
.cv-card-featured h3,
.cv-card-featured .cv-inst{color:var(--cream);}
.cv-card-featured p:not(.cv-inst){color:rgba(251,246,236,0.78);}

.cv-tag{
  font-family:var(--font-mono);
  font-size:11.5px;
  text-transform:uppercase;
  letter-spacing:0.08em;
  color:var(--wine-700);
  background:var(--cream-deep);
  padding:5px 11px;
  border-radius:2px;
  display:inline-block;
  margin-bottom:16px;
}
.cv-tag-gold{
  background:rgba(250,199,117,0.16);
  color:var(--gold-600);
}
.cv-card h3{
  font-size:19px;
  color:var(--wine-800);
  margin-bottom:6px;
}
.cv-inst{
  font-size:13px;
  color:var(--ink-soft);
  font-weight:500;
  margin-bottom:14px;
}
.cv-card p:not(.cv-inst){
  font-size:14px;
  color:var(--ink-soft);
}

@media (max-width:900px){
  .cv-grid{grid-template-columns:1fr 1fr;}
}
@media (max-width:600px){
  .cv-grid{grid-template-columns:1fr;}
}

.exp-list{
  display:flex;
  flex-direction:column;
  gap:36px;
}
.exp-item{
  display:grid;
  grid-template-columns:140px 1fr;
  gap:32px;
  padding-bottom:32px;
  border-bottom:1px solid var(--border-soft);
}
.exp-item:last-child{border-bottom:none;}
.exp-period{
  font-family:var(--font-mono);
  font-size:12.5px;
  color:var(--wine-600);
  font-weight:500;
  text-transform:uppercase;
  letter-spacing:0.06em;
}
.exp-body h3{
  font-size:20px;
  color:var(--ink);
  margin-bottom:4px;
}
.exp-org{
  font-size:13.5px;
  color:var(--wine-700);
  font-weight:600;
  margin-bottom:10px;
}
.exp-body p:not(.exp-org){
  font-size:15px;
  color:var(--ink-soft);
}

@media (max-width:700px){
  .exp-item{grid-template-columns:1fr;gap:8px;}
}

.skills-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:28px;
}
.skill-cat h4{
  font-family:var(--font-display);
  font-size:15px;
  color:var(--wine-700);
  margin-bottom:8px;
  font-weight:600;
}
.skill-cat p{
  font-size:13.5px;
  color:var(--ink-soft);
}

@media (max-width:880px){
  .skills-grid{grid-template-columns:1fr 1fr;}
}
@media (max-width:520px){
  .skills-grid{grid-template-columns:1fr;}
}

/* ===== Página de proyecto individual ===== */
.proj-meta-bar{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin:28px 0 0;
}
.proj-meta-bar span{
  font-family:var(--font-mono);
  font-size:12px;
  padding:6px 14px;
  background:rgba(250,199,117,0.12);
  color:var(--gold-500);
  border-radius:3px;
  border:1px solid rgba(250,199,117,0.25);
}

.proj-body{
  padding:90px 0;
  background:var(--paper);
}
.proj-content{
  display:grid;
  grid-template-columns:1.5fr 1fr;
  gap:64px;
}
.proj-main h2{
  font-size:24px;
  color:var(--wine-800);
  margin:40px 0 16px;
}
.proj-main h2:first-child{margin-top:0;}
.proj-main p{
  font-size:16px;
  color:var(--ink-soft);
  margin-bottom:16px;
}
.proj-main ul{
  list-style:none;
  display:flex;
  flex-direction:column;
  gap:12px;
  margin:16px 0;
}
.proj-main ul li{
  font-size:15px;
  color:var(--ink-soft);
  padding-left:22px;
  position:relative;
}
.proj-main ul li::before{
  content:'';
  position:absolute;
  left:0;top:9px;
  width:8px;height:1px;
  background:var(--wine-600);
}
.proj-main ul li strong{color:var(--ink);font-weight:600;}

.proj-sidebar{
  display:flex;
  flex-direction:column;
  gap:20px;
}
.proj-sidebar-card{
  background:linear-gradient(145deg, var(--glass-light-strong), rgba(243,233,213,0.56));
  border:1px solid var(--glass-border);
  border-radius:16px;
  padding:24px;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(20px) saturate(1.18);
  -webkit-backdrop-filter:blur(20px) saturate(1.18);
}
.proj-sidebar-card h4{
  font-family:var(--font-mono);
  font-size:11.5px;
  text-transform:uppercase;
  letter-spacing:0.08em;
  color:var(--wine-600);
  margin-bottom:12px;
}
.proj-stat{
  font-family:var(--font-display);
  font-size:26px;
  font-weight:600;
  color:var(--wine-800);
  margin-bottom:4px;
}
.proj-stat-label{
  font-size:12.5px;
  color:var(--ink-soft);
}
.proj-sidebar-card + .proj-sidebar-card{margin-top:0;}

@media (max-width:900px){
  .proj-content{grid-template-columns:1fr;}
}

.proj-nav-footer{
  display:flex;
  justify-content:space-between;
  padding:40px 0;
  border-top:1px solid var(--border-soft);
  background:var(--cream);
}
.proj-nav-footer a{
  font-size:14px;
  font-weight:600;
  color:var(--wine-700);
}

/* ===== Investigación ===== */
.inv-detail-grid{
  display:grid;
  grid-template-columns:1fr;
  gap:32px;
  max-width:780px;
}
.inv-detail-card{
  background:linear-gradient(145deg, var(--glass-light-strong), rgba(243,233,213,0.56));
  border:1px solid var(--glass-border);
  border-radius:16px;
  padding:36px;
  display:grid;
  grid-template-columns:auto 1fr;
  gap:24px;
  align-items:start;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(20px) saturate(1.18);
  -webkit-backdrop-filter:blur(20px) saturate(1.18);
}
.inv-detail-icon{
  width:52px;height:52px;
  border-radius:50%;
  background:var(--wine-800);
  color:var(--gold-500);
  display:flex;align-items:center;justify-content:center;
  font-family:var(--font-display);
  font-size:22px;
  flex-shrink:0;
}
.inv-detail-card h3{
  font-size:21px;
  color:var(--wine-800);
  margin-bottom:10px;
}
.inv-detail-card p{
  font-size:15px;
  color:var(--ink-soft);
  margin-bottom:14px;
}

@media (max-width:600px){
  .inv-detail-card{grid-template-columns:1fr;}
}

/* ===== Herramienta URL / QR ===== */
.tool-hero .page-lede{
  max-width:760px;
}

.tool-section{
  padding:90px 0;
  background:var(--paper);
}
.tool-layout{
  display:grid;
  grid-template-columns:minmax(0,1.2fr) minmax(320px,0.8fr);
  gap:36px;
  align-items:start;
}
.tool-panel,
.tool-result,
.tool-info-card{
  background:linear-gradient(145deg, var(--glass-light-strong), rgba(243,233,213,0.52));
  border:1px solid var(--glass-border);
  border-radius:16px;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(20px) saturate(1.18);
  -webkit-backdrop-filter:blur(20px) saturate(1.18);
}
.tool-panel{
  padding:34px;
}
.tool-form{
  display:flex;
  flex-direction:column;
  gap:12px;
}
.tool-label{
  font-size:13px;
  font-weight:700;
  color:var(--wine-800);
}
.tool-input{
  width:100%;
  min-height:48px;
  border:1px solid var(--border-soft);
  border-radius:4px;
  background:var(--paper);
  color:var(--ink);
  font:500 15px var(--font-body);
  padding:0 14px;
  outline:none;
  transition:border-color 0.2s, box-shadow 0.2s;
}
.tool-input:focus{
  border-color:var(--wine-600);
  box-shadow:0 0 0 3px rgba(121,31,31,0.1);
}
.tool-help,
.tool-note{
  font-size:13px;
  color:var(--ink-soft);
}
.tool-options{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin-top:14px;
  padding:20px;
  background:rgba(255,253,249,0.62);
  border:1px solid var(--glass-border);
  border-radius:14px;
  backdrop-filter:blur(14px) saturate(1.12);
  -webkit-backdrop-filter:blur(14px) saturate(1.12);
}
.tool-check{
  display:grid;
  grid-template-columns:18px 1fr;
  gap:10px;
  align-items:start;
  font-size:13.5px;
  color:var(--ink-soft);
}
.tool-check input{
  margin-top:3px;
  accent-color:var(--wine-700);
}
.tool-actions,
.qr-result-actions{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin-top:18px;
}
.tool-secondary{
  border-color:var(--border-soft);
  background:var(--paper);
  color:var(--wine-800);
}
.tool-secondary:hover{
  border-color:var(--wine-600);
  background:var(--wine-800);
  color:var(--cream);
}
.tool-actions .btn-gold:hover{
  background:var(--wine-800);
  color:var(--cream);
}
.tool-message{
  min-height:22px;
  margin-top:8px;
  font-size:13.5px;
  font-weight:600;
}
.tool-message.is-error{color:#9c3030;}
.tool-message.is-success{color:var(--wine-700);}
.short-url-result{
  display:flex;
  flex-direction:column;
  gap:6px;
  margin-top:18px;
  padding:16px;
  background:rgba(255,253,249,0.68);
  border:1px solid var(--glass-border);
  border-left:3px solid var(--gold-600);
  border-radius:14px;
  backdrop-filter:blur(14px) saturate(1.12);
  -webkit-backdrop-filter:blur(14px) saturate(1.12);
}
.short-url-result[hidden]{
  display:none;
}
.short-url-result span{
  font-family:var(--font-mono);
  font-size:11.5px;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:var(--wine-600);
}
.short-url-result a{
  font-size:16px;
  font-weight:700;
  color:var(--wine-800);
  overflow-wrap:anywhere;
}
.tool-result{
  padding:28px;
  position:sticky;
  top:96px;
}
.qr-frame{
  position:relative;
  width:100%;
  aspect-ratio:1;
  background:rgba(255,253,249,0.72);
  border:1px solid var(--glass-border);
  border-radius:16px;
  display:grid;
  place-items:center;
  overflow:hidden;
}
.qr-frame canvas{
  width:min(320px,100%);
  height:auto;
}
.qr-placeholder{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:10px;
  text-align:center;
  color:var(--ink-soft);
  background:var(--paper);
}
.qr-placeholder span{
  font-family:var(--font-display);
  font-size:48px;
  color:var(--wine-800);
}
.qr-placeholder p{
  font-size:14px;
}
.qr-color-panel{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin-top:18px;
  padding:14px;
  background:rgba(255,253,249,0.62);
  border:1px solid var(--glass-border);
  border-radius:14px;
  backdrop-filter:blur(14px) saturate(1.12);
  -webkit-backdrop-filter:blur(14px) saturate(1.12);
}
.qr-color-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
}
.qr-color-head span{
  font-size:13px;
  font-weight:700;
  color:var(--wine-800);
}
.qr-color-head input{
  width:42px;
  height:34px;
  padding:3px;
  border:1px solid var(--border-soft);
  border-radius:8px;
  background:var(--paper);
  cursor:pointer;
}
.qr-swatches{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}
.qr-swatch{
  width:34px;
  height:34px;
  border:1px solid rgba(46,10,10,0.16);
  border-radius:50%;
  background:var(--swatch);
  box-shadow:inset 0 0 0 3px rgba(255,253,249,0.72), 0 8px 18px rgba(46,10,10,0.12);
  cursor:pointer;
  transition:transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.qr-swatch:hover,
.qr-swatch.is-active{
  transform:translateY(-1px);
  border-color:var(--gold-600);
  box-shadow:inset 0 0 0 3px rgba(255,253,249,0.82), 0 10px 22px rgba(46,10,10,0.2);
}
.qr-result-actions .btn:disabled{
  opacity:0.5;
  cursor:not-allowed;
}
.tool-note{
  margin-top:16px;
}
.featured-tools-section{
  padding:90px 0;
  background:linear-gradient(135deg, var(--wine-900), #4a1010 58%, #2f0a0a);
  color:var(--cream);
}
.featured-tools-head{
  max-width:760px;
  margin-bottom:34px;
}
.featured-tools-head .eyebrow{
  color:var(--gold-500);
  margin-bottom:12px;
}
.featured-tools-head .eyebrow::before{
  background:var(--gold-500);
}
.featured-tools-head h2{
  font-size:clamp(30px,4vw,44px);
  color:var(--cream);
  margin-bottom:14px;
}
.featured-tools-head p{
  font-size:17px;
  color:rgba(251,246,236,0.76);
}
.featured-tools-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:24px;
}
.featured-tool-card{
  display:flex;
  flex-direction:column;
  min-height:330px;
  padding:34px;
  color:var(--cream);
  text-decoration:none;
  background:linear-gradient(145deg, rgba(255,253,249,0.14), rgba(250,199,117,0.08));
  border:1px solid rgba(255,253,249,0.18);
  border-radius:18px;
  box-shadow:0 24px 70px rgba(0,0,0,0.28);
  backdrop-filter:blur(22px) saturate(1.2);
  -webkit-backdrop-filter:blur(22px) saturate(1.2);
  transition:transform 0.22s, border-color 0.22s, box-shadow 0.22s, background 0.22s;
}
.featured-tool-card:hover{
  transform:translateY(-3px);
  border-color:rgba(250,199,117,0.48);
  background:linear-gradient(145deg, rgba(255,253,249,0.18), rgba(250,199,117,0.13));
  box-shadow:0 30px 86px rgba(0,0,0,0.34);
}
.featured-tool-tag{
  align-self:flex-start;
  font-family:var(--font-mono);
  font-size:11.5px;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:var(--gold-500);
  background:rgba(250,199,117,0.12);
  border:1px solid rgba(250,199,117,0.22);
  border-radius:3px;
  padding:7px 12px;
  margin-bottom:22px;
}
.featured-tool-card h3{
  font-size:clamp(24px,3vw,32px);
  color:var(--cream);
  margin-bottom:14px;
}
.featured-tool-card p{
  font-size:15.5px;
  line-height:1.75;
  color:rgba(251,246,236,0.76);
}
.featured-tool-card .featured-tool-detail{
  margin-top:14px;
  padding-top:14px;
  border-top:1px solid rgba(255,253,249,0.14);
  color:rgba(251,246,236,0.66);
}
.featured-tool-link{
  margin-top:auto;
  padding-top:26px;
  font-size:14px;
  font-weight:800;
  color:var(--gold-500);
}
.tool-info-section{
  padding:90px 0;
  background:var(--paper);
}
.tool-info-heading{
  margin-bottom:24px;
}
.tool-info-heading .eyebrow{
  color:var(--wine-700);
  margin-bottom:10px;
}
.tool-info-heading h2{
  font-size:clamp(26px,3vw,36px);
  color:var(--wine-800);
}
.tool-info-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
  gap:22px;
}
.tool-info-card{
  padding:28px;
  transition:border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.tool-info-card-muted{
  background:linear-gradient(145deg, rgba(255,253,249,0.66), rgba(243,233,213,0.44));
}
.tool-link-card{
  display:flex;
  flex-direction:column;
  color:inherit;
  min-height:280px;
  text-decoration:none;
  background:linear-gradient(145deg, rgba(255,253,249,0.82), rgba(243,233,213,0.58));
}
.tool-info-card:hover{
  border-color:rgba(121,31,31,0.24);
  transform:translateY(-2px);
  box-shadow:var(--glass-shadow-hover);
}
.tool-info-card h3{
  font-size:19px;
  color:var(--wine-800);
  margin-bottom:10px;
}
.tool-info-card p{
  font-size:14.5px;
  color:var(--ink-soft);
}
.tool-card-link{
  display:inline-flex;
  margin-top:auto;
  padding-top:18px;
  font-size:13.5px;
  font-weight:800;
  color:var(--wine-700);
}
.tool-link-card:hover .tool-card-link{
  color:var(--gold-600);
}

@media (max-width:920px){
  .tool-layout{grid-template-columns:1fr;}
  .tool-result{position:static;}
  .featured-tools-grid{grid-template-columns:1fr;}
  .tool-info-grid{grid-template-columns:1fr;}
}

@media (max-width:560px){
  .tool-panel,
  .tool-result,
  .featured-tool-card,
  .tool-info-card{padding:22px;}
  .featured-tool-card{min-height:0;}
  .tool-actions .btn,
  .qr-result-actions .btn{
    width:100%;
    justify-content:center;
  }
}
